Client timeout while waiting for video generation: setting sensible timeouts for Seedance tasks

Client timeouts happen when your HTTP client closes the connection before a Seedance task finishes, so the fix is to treat video generation as asynchronous: submit with POST /v1/video/generations, then poll GET /v1/video/generations/{task_id} until the status is succeeded or failed, or set metadata.callback_url for webhook delivery. Since clips run up to 15 seconds and are billed per generated video, avoid holding one long synchronous request open.

Why client timeouts occur with Seedance

Timeouts occur because a single video request can outlast a default client socket timeout, not because the API failed. On RelayDance, you submit a task and then poll GET /v1/video/generations/{task_id} until status is succeeded or failed; the result then contains the video url. A request can include clips up to 15 seconds, plus up to 9 reference images, 3 reference videos and 3 audio tracks, all of which extend processing. Keeping one connection open for the full duration is what triggers the client side timeout, so the recommended pattern separates submission from result retrieval.

Recommended timeout patterns: polling versus webhook

Two patterns avoid client timeouts: interval polling and webhook callbacks. For polling, submit the task, capture the task_id, then repeatedly call GET /v1/video/generations/{task_id} on a short client timeout per poll until status is succeeded or failed. For webhooks, set metadata.callback_url and the final state is POSTed to your server, so no long-lived client connection is required.

  1. Submit: POST /v1/video/generations with model, prompt and seconds.
  2. Poll: GET /v1/video/generations/{task_id} until status is succeeded or failed.
  3. Or webhook: set metadata.callback_url and receive the final state by POST.

Configuration: OpenAI-compatible base URL and auth

Configure your existing OpenAI client by changing the base URL, which keeps client setup minimal. According to the official relaydance.com/docs: "set base_url to https://relaydance.com/v1 and keep your OpenAI SDK". Use Authorization: Bearer YOUR_API_KEY with a key created at the console. Because the protocol is OpenAI compatible with the base URL set to https://relaydance.com/v1, your client's per-request timeout and retry settings carry over directly. See the docs at https://relaydance.com/docs for endpoint details.

Billing impact of retries and failed requests

Retrying after a client timeout carries no billing penalty for failed calls, because failed or errored requests are never billed. According to the official relaydance.com docs: "failed or errored requests are never billed". Billing is pay-as-you-go per generated video. Current per-model rates are listed at https://relaydance.com/models.

Model / tierRate
Seedance 2.0 720pabout $0.190 / second
Seedance 2.0 1080pabout $0.470 / second
Seedance Fastabout $0.152 / second
Seedance native 4Kabout $4.90 per 5-second clip

FAQ

Does a client timeout mean I was charged? No. Failed or errored requests are never billed; billing applies per generated video.

Should I poll or use a webhook? Either works. Poll GET /v1/video/generations/{task_id} until status is succeeded or failed, or set metadata.callback_url to receive the final state by POST.

How long can a clip run? Clips run up to 15 seconds per request, and a request can cite up to 9 reference images, 3 reference videos and 3 audio tracks.

According to the official relaydance.com docs: "Failed or errored requests are never billed"
According to the official relaydance.com/docs docs: "Set base_url to https://relaydance.com/v1 and keep your OpenAI SDK"

Key facts and figures

ItemValueSource
Seedance 2.0 720p priceabout $0.190 / secondrelaydance.com/models
Seedance 2.0 1080p priceabout $0.470 / secondrelaydance.com/models
Seedance Fast priceabout $0.152 / secondrelaydance.com/models
Seedance native 4K priceabout $4.90 per 5-second cliprelaydance.com/models
gpt-image-2 image billingimage output is free, only input is billed; image-to-image from about CNY 0.035; 4K and 1K output cost the samerelaydance.com/models
API protocolOpenAI-compatible; set base_url to https://relaydance.com/v1relaydance.com/docs
Failed requestsfailed or errored requests are never billedrelaydance.com/docs

Data verified 2026-06-29; live prices are on the official /models page.


RelayDance home · Models and pricing · Docs · All guides · Telegram community · RelayRouter (LLM API) · Live playground · Privacy Policy · User Agreement