Skip to main content
When a task reaches a terminal state (SUCCESS / FAILURE / TIMEOUT / CANCELLED), if a callBackUrl was specified at submission time, the system will send a POST request to that URL.

Callback Format

POST <callBackUrl>
Content-Type: application/json
The callback data field is identical in format to the query endpoint response:
SUCCESS
{
  "code": 0,
  "msg": "ok",
  "data": {
    "taskId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "status": "SUCCESS",
    "input": {
      "model": "seedance-2.0-fast",
      "prompt": "a cat walking in the garden",
      "ratio": "16:9",
      "resolution": "1080p",
      "duration": 10
    },
    "result": {
      "type": "video",
      "urls": ["https://media.example.com/videos/2026/02/26/a1b2c3d4.mp4"]
    },
    "failure_reason": null,
    "created_at": "2026-02-26T07:42:43Z",
    "updated_at": "2026-02-26T10:12:55Z"
  }
}
FAILURE (content moderation)
{
  "code": 0,
  "msg": "ok",
  "data": {
    "taskId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "status": "FAILURE",
    "input": {
      "model": "seedance-2.0-fast",
      "prompt": "...",
      "ratio": "16:9",
      "resolution": "1080p",
      "duration": 10
    },
    "result": null,
    "failure_reason": "CONTENT_MODERATION",
    "created_at": "2026-02-26T07:42:43Z",
    "updated_at": "2026-02-26T07:42:55Z"
  }
}

result Field Structure

On SUCCESS:
FieldTypeDescription
typestringResult type: image or video
urlsstring[]List of resource URLs. Images may have multiple entries; videos typically have 1. URLs expire after 7 days
On FAILURE / TIMEOUT / CANCELLED: result is null.

failure_reason

Always present in the response. null when no specific actionable reason applies. Values:
ValueMeaningRecommended Action
CONTENT_MODERATIONPrompt or image rejected due to real human faces, copyrighted characters or public figures, or NSFW contentNotify the user; do not retry
INVALID_PARAMETERSSubmitted parameters are invalid. For Seedance media-to-video, check these rules first: mediaUrls must contain 1 to 12 material URLs, include at most 9 images, total uploaded video duration must be 15 seconds or less, and total uploaded audio duration must be 15 seconds or lessFix request parameters; do not retry until corrected
INSUFFICIENT_POINTSAccount has insufficient creditsPrompt user to recharge; do not retry
nullNo specific actionable reason (transient error, timeout, etc.)May retry if appropriate

Important Notes

  • Webhook timeout is 5 seconds; it is sent asynchronously and does not block the main workflow
  • Failed deliveries are logged only and will not be retried
  • callBackUrl does not support localhost / 127.0.0.1 or other internal addresses (SSRF protection)
  • The outer code is always 0; use data.status to determine success or failure