{"openapi":"3.1.0","info":{"title":"SeedVideo AI API","version":"1.0.0","description":"Use the SeedVideo AI API to create video tasks, track their status, and check your available credits. Video generation runs asynchronously, so create a task first and poll it until it completes or fails."},"servers":[{"url":"https://www.seeddance.io"}],"tags":[{"name":"Video generation","description":"Create videos with Seedance models."},{"name":"Tasks","description":"Check the status of tasks created by your account."},{"name":"Credits","description":"Check total, reserved, and available credits."}],"paths":{"/v1/videos/generations":{"post":{"tags":["Video generation"],"operationId":"createVideoGeneration","x-codeSamples":[{"lang":"go","label":"Go","source":false},{"lang":"java","label":"Java","source":false},{"lang":"csharp","label":"C#","source":false},{"lang":"bash","label":"cURL","source":"curl -X POST \"https://www.seeddance.io/v1/videos/generations\" \\\n  -H \"Authorization: Bearer sk_sd_example\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"model\": \"seedance-2.0-fast\",\n    \"prompt\": \"A paper boat crossing a rain-soaked neon street\",\n    \"duration\": 5,\n    \"quality\": \"720p\"\n  }'"},{"lang":"js","label":"JavaScript","source":"const response = await fetch(\n  'https://www.seeddance.io/v1/videos/generations',\n  {\n    method: 'POST',\n    headers: {\n      Authorization: 'Bearer sk_sd_example',\n      'Content-Type': 'application/json',\n    },\n    body: JSON.stringify({\n      model: 'seedance-2.0-fast',\n      prompt: 'A paper boat crossing a rain-soaked neon street',\n      duration: 5,\n      quality: '720p',\n    }),\n  }\n);\n\nconst task = await response.json();"},{"lang":"python","label":"Python","source":"import requests\n\nresponse = requests.post(\n    \"https://www.seeddance.io/v1/videos/generations\",\n    headers={\"Authorization\": \"Bearer sk_sd_example\"},\n    json={\n        \"model\": \"seedance-2.0-fast\",\n        \"prompt\": \"A paper boat crossing a rain-soaked neon street\",\n        \"duration\": 5,\n        \"quality\": \"720p\",\n    },\n    timeout=30,\n)\ntask = response.json()"}],"summary":"Create a video task","description":"Starts a Seedance video task and returns its ID. Use `GET /v1/tasks/{task_id}` to check the status. If you retry this request, the API may create a second task.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoGenerationRequest"},"examples":{"textToVideo":{"summary":"Text to video","value":{"model":"seedance-2.5","prompt":"A paper boat crossing a rain-soaked neon street, cinematic camera movement","duration":10,"quality":"720p","aspect_ratio":"16:9","generate_audio":true}},"imageToVideo":{"summary":"Image to video","value":{"model":"seedance-2.5","prompt":"Slow dolly in while the fabric moves in a light breeze","image_urls":["https://example.com/reference.jpg"],"duration":5,"quality":"720p"}},"referenceToVideo":{"summary":"Reference to video","value":{"model":"seedance-2.5","prompt":"Keep the character and product consistent across the shot","image_urls":["https://example.com/character.jpg","https://example.com/product.jpg"],"reference_mode":true,"quality":"720p"}}}}}},"responses":{"200":{"description":"The API accepted the task.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskAccepted"},"example":{"task_id":"vid_01JZK7R7KCYQ3T9F33A7K0J6XB","status":"pending","created_at":"2026-07-22T08:30:00.000Z"}}}},"400":{"description":"The request body is not valid JSON.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"invalid_request","message":"Request body must contain valid JSON.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"401":{"description":"The Bearer API key is missing, invalid, or revoked.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"invalid_api_key","message":"The API key is invalid, expired, or revoked.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"402":{"description":"The account does not have enough available credits, or its free trial has ended.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"insufficient_credits","message":"This request requires 25 credits, but only 10 are available.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"403":{"description":"The account plan cannot use the requested model or quality.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"plan_upgrade_required","message":"The requested model or quality requires a higher plan.","param":"model","request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"415":{"description":"The request is not JSON.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"invalid_request","message":"Content-Type must be application/json.","param":"content-type","request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"422":{"description":"A field is invalid, or the prompt violates the content policy.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"invalid_request","message":"Unsupported model.","param":"model","request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"429":{"description":"The API key reached its rate limit, or the account reached its concurrent generation limit.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"rate_limit_exceeded","message":"API rate limit exceeded. Try again later.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"500":{"description":"An internal error prevented the API from creating the task.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"internal_error","message":"The request could not be completed.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"502":{"description":"The video provider could not start the task.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"provider_error","message":"The video provider could not start this task. Try again later.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"503":{"description":"Video generation or moderation is temporarily unavailable.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"service_unavailable","message":"Video generation is temporarily unavailable.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}}}}},"/v1/tasks/{task_id}":{"get":{"tags":["Tasks"],"operationId":"getTask","x-codeSamples":[{"lang":"go","label":"Go","source":false},{"lang":"java","label":"Java","source":false},{"lang":"csharp","label":"C#","source":false},{"lang":"bash","label":"cURL","source":"curl \"https://www.seeddance.io/v1/tasks/vid_01JZK7R7KCYQ3T9F33A7K0J6XB\" \\\n  -H \"Authorization: Bearer sk_sd_example\""},{"lang":"js","label":"JavaScript","source":"const response = await fetch(\n  'https://www.seeddance.io/v1/tasks/vid_01JZK7R7KCYQ3T9F33A7K0J6XB',\n  { headers: { Authorization: 'Bearer sk_sd_example' } }\n);\n\nconst task = await response.json();"},{"lang":"python","label":"Python","source":"import requests\n\nresponse = requests.get(\n    \"https://www.seeddance.io/v1/tasks/vid_01JZK7R7KCYQ3T9F33A7K0J6XB\",\n    headers={\"Authorization\": \"Bearer sk_sd_example\"},\n    timeout=30,\n)\ntask = response.json()"}],"summary":"Get a video task","description":"Returns a task created by the authenticated account. While the status is `pending` or `processing`, poll this endpoint with backoff. A completed task includes a durable SeedVideo AI video URL.","security":[{"bearerAuth":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"description":"`POST /v1/videos/generations` returns this task ID.","schema":{"type":"string"},"example":"vid_01JZK7R7KCYQ3T9F33A7K0J6XB"}],"responses":{"200":{"description":"The task's current state.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Task"},"examples":{"processing":{"summary":"Processing","value":{"task_id":"vid_01JZK7R7KCYQ3T9F33A7K0J6XB","status":"processing","model":"seedance-2.0-fast","output":null,"credits_used":25,"error":null,"created_at":"2026-07-22T08:30:00.000Z","completed_at":null}},"completed":{"summary":"Completed","value":{"task_id":"vid_01JZK7R7KCYQ3T9F33A7K0J6XB","status":"completed","model":"seedance-2.0-fast","output":{"video_url":"https://media.seeddance.io/videos/vid_01JZK7R7KCYQ3T9F33A7K0J6XB.mp4","duration":5,"quality":"720p"},"credits_used":25,"error":null,"created_at":"2026-07-22T08:30:00.000Z","completed_at":"2026-07-22T08:31:12.000Z"}}}}}},"401":{"description":"The Bearer API key is missing, invalid, or revoked.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"invalid_api_key","message":"The API key is invalid, expired, or revoked.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"404":{"description":"This account has no task with this ID.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"task_not_found","message":"Task not found.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"429":{"description":"The API key reached its rate limit.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"rate_limit_exceeded","message":"API rate limit exceeded. Try again later.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"500":{"description":"An internal error prevented the API from reading the task.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"internal_error","message":"The request could not be completed.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}}}}},"/v1/credits":{"get":{"tags":["Credits"],"operationId":"getCredits","x-codeSamples":[{"lang":"go","label":"Go","source":false},{"lang":"java","label":"Java","source":false},{"lang":"csharp","label":"C#","source":false},{"lang":"bash","label":"cURL","source":"curl \"https://www.seeddance.io/v1/credits\" \\\n  -H \"Authorization: Bearer sk_sd_example\""},{"lang":"js","label":"JavaScript","source":"const response = await fetch('https://www.seeddance.io/v1/credits', {\n  headers: { Authorization: 'Bearer sk_sd_example' },\n});\n\nconst credits = await response.json();"},{"lang":"python","label":"Python","source":"import requests\n\nresponse = requests.get(\n    \"https://www.seeddance.io/v1/credits\",\n    headers={\"Authorization\": \"Bearer sk_sd_example\"},\n    timeout=30,\n)\ncredits = response.json()"}],"summary":"Get available credits","description":"Returns the account's total credits, the credits reserved for active video tasks, and the credits available for a new task.","security":[{"bearerAuth":[]}],"responses":{"200":{"description":"Current credit balances for the account.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Credits"},"example":{"total":1000,"reserved":50,"available":950}}}},"401":{"description":"The Bearer API key is missing, invalid, or revoked.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"invalid_api_key","message":"The API key is invalid, expired, or revoked.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"429":{"description":"The API key reached its rate limit.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"rate_limit_exceeded","message":"API rate limit exceeded. Try again later.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}},"500":{"description":"An internal error prevented the API from reading the credit balance.","headers":{"X-Request-Id":{"description":"The unique ID for this API request. Include it when you contact support.","schema":{"type":"string","example":"req_2YgM6pg5oM2WkKpQ"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"example":{"error":{"code":"internal_error","message":"The request could not be completed.","param":null,"request_id":"req_2YgM6pg5oM2WkKpQ"}}}}}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"sk_sd_...","description":"Create a SeedVideo AI API key in Settings. Send it only from a trusted server."}},"schemas":{"VideoGenerationRequest":{"type":"object","additionalProperties":false,"required":["model","prompt"],"properties":{"model":{"type":"string","enum":["seedance-1.0-pro-fast","seedance-2.0","seedance-2.0-fast","seedance-2.0-mini","seedance-2.5"],"description":"A public Seedance model ID."},"prompt":{"type":"string","minLength":1,"description":"Describe the video you want to create. Each model has its own prompt length limit."},"duration":{"type":"integer","minimum":2,"maximum":30,"description":"The video length in seconds. The supported range depends on the model."},"quality":{"type":"string","enum":["480p","720p","1080p"],"description":"The output resolution. Available options depend on the model and account plan. Seedance 2.0 Mini supports up to 720p."},"aspect_ratio":{"type":"string","enum":["16:9","9:16","1:1","4:3","3:4","21:9","adaptive"],"description":"The output aspect ratio. Only supported models accept `adaptive`."},"generate_audio":{"type":"boolean","description":"Set to `true` to generate synchronized audio when the model supports it."},"image_urls":{"type":"array","maxItems":30,"description":"Public HTTPS JPEG, PNG, or WebP URLs. Seedance 2.5 accepts up to 30 images; each must be 300 to 6000 px per side, use a 0.4 to 2.5 aspect ratio, and be at most 30 MB. With no video or audio input, one image selects image to video, two images select first and last frame mode, and three or more images select reference mode.","items":{"type":"string","format":"uri"}},"video_urls":{"type":"array","maxItems":10,"description":"Public HTTPS MP4 or MOV reference URLs. Seedance 2.5 accepts up to 10 videos, 2 to 30 seconds each and 30 seconds total, at 24 to 60 FPS. Each video may be at most 200 MB, 300 to 6000 px per side, 0.4 to 2.5 aspect ratio, and 409,600 to 8,295,044 frame pixels.","items":{"type":"string","format":"uri"}},"audio_urls":{"type":"array","maxItems":10,"description":"Public HTTPS MP3 or WAV reference URLs for Seedance 2.5. Send up to 10 files, 2 to 30 seconds each and 30 seconds total, with a maximum size of 15 MB per file.","items":{"type":"string","format":"uri"}},"output_format":{"type":"string","enum":["mp4","mov"],"description":"The Seedance 2.5 output container. Defaults to `mp4`."},"content_filter":{"type":"boolean","description":"Controls the optional Seedance 2.5 content filter. Defaults to `true`. Setting it to `false` applies the provider 1.1x rate."},"web_search":{"type":"boolean","description":"Allows web search for Seedance 2.5 text-to-video requests. Defaults to `false`."},"reference_mode":{"type":"boolean","description":"Set to `true` to treat one or two images as references instead of first and last frames. Supported by Seedance 2.0 and 2.5 models and requires at least one media URL."}}},"TaskAccepted":{"type":"object","additionalProperties":false,"required":["task_id","status","created_at"],"properties":{"task_id":{"type":"string","description":"The SeedVideo AI task ID used to check status."},"status":{"type":"string","enum":["pending"]},"created_at":{"type":"string","format":"date-time"}}},"Task":{"type":"object","additionalProperties":false,"required":["task_id","status","model","output","credits_used","error","created_at","completed_at"],"properties":{"task_id":{"type":"string"},"status":{"type":"string","enum":["pending","processing","completed","failed"]},"model":{"type":"string","enum":["seedance-1.0-pro-fast","seedance-2.0","seedance-2.0-fast","seedance-2.0-mini","seedance-2.5"]},"output":{"oneOf":[{"$ref":"#/components/schemas/TaskOutput"},{"type":"null"}]},"credits_used":{"type":"integer","minimum":0,"description":"The API reserves these credits while the task is active and deducts them when it completes."},"error":{"oneOf":[{"type":"string","description":"A task failure message that is safe to display."},{"type":"null"}]},"created_at":{"type":"string","format":"date-time"},"completed_at":{"oneOf":[{"type":"string","format":"date-time"},{"type":"null"}]}}},"TaskOutput":{"type":"object","additionalProperties":false,"required":["video_url"],"properties":{"video_url":{"type":"string","format":"uri","description":"A durable video URL returned after the task completes successfully."},"duration":{"type":"number","description":"The video length in seconds."},"quality":{"type":"string","description":"The selected output quality."}}},"Credits":{"type":"object","additionalProperties":false,"required":["total","reserved","available"],"properties":{"total":{"type":"integer","minimum":0,"description":"The account's total active credits."},"reserved":{"type":"integer","minimum":0,"description":"Credits held for active video tasks."},"available":{"type":"integer","minimum":0,"description":"Credits the account can use for a new task."}}},"Error":{"type":"object","additionalProperties":false,"required":["error"],"properties":{"error":{"type":"object","additionalProperties":false,"required":["code","message","param","request_id"],"properties":{"code":{"type":"string","description":"A stable code for programmatic error handling."},"message":{"type":"string","description":"An error message that is safe to show users."},"param":{"oneOf":[{"type":"string"},{"type":"null"}],"description":"The request field that caused the error, when known."},"request_id":{"type":"string","description":"The request ID for support and tracing."}}}}}}}}