Skip to content

Query video tasks ​

Video task is submitted with a search for API reading status, progress, result URL and failure information. Even if Webhook is configured, it is recommended that active search capabilities be retained.

Method and Path ​

Suggested uniform query entry:

http
GET /v1/tasks/{task_id}

Compatible entry:

http
GET /v1/videos/{task_id}
GET /v1/video/generations/{task_id}
GET /v1/videos/{task_id}/content
GET /api/v3/contents/generations/tasks/{task_id}

Compatible path also supports the listing and cancellation of task by official shape:

http
GET /api/v3/contents/generations/tasks
DELETE /api/v3/contents/generations/tasks/{task_id}

content.video_url, content.last_frame_url and other field in response compatible path may be only task After success, you will be able to find out which entry you want to use. Check status and error first, then read the result address.

Standard request ​

bash
curl https://moonapix.com/v1/tasks/task_01HX... \
  -H "Authorization: Bearer <MOONAPIX_API_KEY>"

Example response ​

json
{
  "id": "task_01HX...",
  "object": "task",
  "trace_id": "2026060301010100000000000000000000",
  "request_id": "2026060301010100000000000000000000",
  "status": "succeeded",
  "model": "your-video-model",
  "created_at": 1710000000,
  "output": [
    {
      "type": "video",
      "url": "https://example.com/result.mp4"
    }
  ],
  "error": null
}

Status statement ​

StatusAnnotationsRecommendations
pendingMoonApiX is accepted, awaiting submission or systematic preparation.Further queries will be made later.
submittedSubmitted to generate task, pending processing.Further queries will be made later.
runningGenerating.Continue waiting; avoid frequent polling.
succeededAchieved.Reads the result URL and saves it.
failedtask failed.View error, trace_id and original request.
cancelledtask cancelled.Stops the query.

Result field ​

Please judge status, read the URL:

  • When status is succeeded, task is successful and the result URL is read.
  • Do not read a result URL for pending, submitted, running, failed or cancelled. Incomplete or failed responses may omit output and result URLs. For failed, read error, trace_id and request_id.
  • /v1/videos/{task_id}/content only recommends task after success. This compatible download portal may return 302 jump, so HTTP client will follow the direction.

The results of successful task may appear in the following field. The response structure of the different compatible entry points may differ, and please refer to API for actual return.

fieldAnnotations
output[].urlSuggests a read-out video result URL.
urlPartially compatible with the result URL in response.
video_urlThe result of the result in part response is URL.
result_urlPart task-chain response result URL.
content.video_urlVideo result URL in video or official-compatible queries.
content.last_frame_urlOptional image URL for the generated video's last frame, distinct from an input reference image.

Generated Last Frame ​

seedance-2.5-cl has been verified with return_last_frame=true in the creation request. After success, both query endpoints below can return content.last_frame_url. Neither raw mode nor the full original response is required. Check each model's page for support on other models.

Main fields in a successful GET /v1/videos/{task_id} response:

json
{
  "id": "task_xxx",
  "task_id": "task_xxx",
  "status": "succeeded",
  "content": {
    "video_url": "https://example.com/result.mp4",
    "last_frame_url": "https://example.com/last-frame.jpg"
  }
}

Main fields in a successful GET /api/v3/contents/generations/tasks/{task_id} response:

json
{
  "id": "task_xxx",
  "status": "succeeded",
  "content": {
    "video_url": "https://example.com/result.mp4",
    "last_frame_url": "https://example.com/last-frame.jpg"
  }
}

Both id values are MoonApiX public task IDs. On /v1/videos, task_id equals id; the official-compatible response does not require an additional task_id field.

  • Check status=succeeded and the absence of an error before reading the image URL. content.last_frame_url is a separate image URL, not the video URL.
  • The last frame is optional. The field may be omitted if it was not requested, the model did not produce it, or no usable image URL is available. Do not substitute the video URL.
  • An input last_frame_url or reference role=last_frame supplies a reference image; it does not replace return_last_frame=true.
  • Determine the image format from the download response's Content-Type. Do not require PNG; JPEG output has been verified for seedance-2.5-cl.
  • Use the returned image URL without modifying it. It is not guaranteed to remain valid indefinitely; download it to your own storage for long-term retention.

Result URL Policy ​

Successful task may return to the media URL approved by the MoonApiX policy or to the media URL managed by MoonApiX. Both are available to clients; use the full address that API actually returns, not to judge whether task is successful by domain name, and not to force the downloading of content.

Please follow:

  • Do not extrapolate model capabilities or select other downloads from the result URL.
  • Do not spell or rewrite the URL.
  • Saves the complete URL returned by API, including possible signature query parameters; the absence or rewriting of parameters may result in download failure.
  • If the operation requires long-term filing, secondary distribution or removal of ad hoc signature dependence, save it for the operation side download.

Content Download Entry ​

GET /v1/videos/{task_id}/content is a compatible download fallback. Use it after succeeded when the task response provides no usable result URL. It may return a 302 redirect or a video stream. Use curl -L or enable redirects in your SDK.

bash
curl -L https://moonapix.com/v1/videos/task_01HX.../content \
  -H "Authorization: Bearer <MOONAPIX_API_KEY>" \
  -o result.mp4

Recommendation polling ​

  • The first 30 seconds can be checked every 3 to 5 seconds.
  • Long task suggests gradually pacing, e.g. 10 seconds, 20 seconds, 30 seconds.
  • task stops polling after it has been successfully, unsuccessfully or cancelled. Do not judge task success by the presence of URL field in response.
  • Save final URLs and original response in the operations system for subsequent checking.

Relevant Pages ​