← All guides

Build an AI video workflow with the Seedance API

Create a video, poll its status and retrieve the finished file from your application.

Keep credentials on your server

Create a workbench API key after Google sign-in. Treat it as a password and keep it in a server environment variable. The API and browser use the same points balance.

Submit an asynchronous task

POST a prompt, model wb-seedance-2-fast and seconds from 4 to 10 to /api/v1/videos. Save the returned task ID. A successful submission does not mean that the video file is ready.

Poll with patience

Query /api/v1/videos/{id} about every ten seconds. Handle queued, in_progress, completed and failed. Avoid retrying a create request blindly after a network timeout: it may create a second billed task.

Download after completion

When the task is completed, fetch /api/v1/videos/{id}/content using the same bearer key. For a failed task, read the error and inspect the request before submitting again. Failed generations are credited back.

Try it in the studio →