Appearance
BytePlus
Generate Seedance videos through RemoteGPU's BytePlus-compatible API. Use a RemoteGPU Token Factory key and the base URL https://byteplus.remotegpu.ai/api/v3.
Send requests
Create a key using API keys, then set REMOTEGPU_API_KEY in your shell. This example creates a five-second video. Submitting it incurs a charge.
bash
curl --fail-with-body \
'https://byteplus.remotegpu.ai/api/v3/contents/generations/tasks' \
-H "Authorization: Bearer $REMOTEGPU_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"model": "dreamina-seedance-2-0-mini-260615",
"content": [{"type": "text", "text": "A sailboat crossing a calm lake."}],
"resolution": "480p",
"ratio": "1:1",
"duration": 5,
"generate_audio": false
}'The response contains an id. Save it to query the task and download its result.
Models
Use the exact model ID in requests. Available resolutions and output durations are listed below. See Pricing for customer rates.
| Model ID | Resolutions | Duration in seconds |
|---|---|---|
dreamina-seedance-2-5-260628 | 480p, 720p, 1080p | 5–30 |
dreamina-seedance-2-0-260128 | 480p, 720p, 1080p, 4k | 5–15 |
dreamina-seedance-2-0-fast-260128 | 480p, 720p | 5–15 |
dreamina-seedance-2-0-mini-260615 | 480p, 720p | 5–15 |
You can also set duration to -1 to let the model choose the duration. Model availability can change temporarily. If a model is unavailable, the API rejects the request before starting generation.
How requests work
- RemoteGPU validates the request and reserves the estimated charge from your wallet. If your available balance is insufficient, the request is rejected before generation is submitted.
- The task runs asynchronously. Poll its ID to check progress.
- On success, RemoteGPU stores the output and settles the charge. The task response includes a download URL.
To safely retry a create request, send an Idempotency-Key header and reuse the same key and request body. Use a new key only for a new generation. If a request loses its response, creating another task with a new key can incur another charge.
Request options
| Field | Behavior |
|---|---|
resolution | Defaults to 720p; supported values depend on the model. |
ratio | 16:9, 4:3, 1:1, 3:4, 9:16, 21:9, or adaptive (default). |
duration | Defaults to -1 for Seedance 2.5 and 5 for other models. Use an integer in the model's range, or -1. |
generate_audio | Defaults to true. |
watermark | Defaults to false. |
return_last_frame | Defaults to false; request the last-frame image as an additional output. |
execution_expires_after | Requested execution timeout; accepts 3,600–259,200 seconds and defaults to 172,800. Current video tasks run for at most 21,600 seconds. This setting does not extend result retention. |
priority | Integer from 0–9; defaults to 0. |
safety_identifier | Optional ASCII identifier returned with the task; accepts 1–64 characters. Do not include names, email addresses, or other personal data. |
metadata | Optional JSON object returned with the task; accepts up to 2 KB of JSON. |
callback_url | Optional public HTTP or HTTPS URL that receives task updates. HTTPS is recommended. |
The content array accepts a text prompt and reference images, videos, or audio. Use image_url with role reference_image, video_url with role reference_video, or audio_url with role reference_audio. For example, add this item to the array to supply a reference video:
json
{
"type": "video_url",
"video_url": { "url": "https://example.com/reference.mp4" },
"role": "reference_video"
}Seedance 2.5 accepts up to 30 images, 10 videos, and 10 audio references. The other models accept up to nine images, three videos, and three audio references. The request supports at most one text item and 51 content items in total. For models other than Seedance 2.5, reference audio must be accompanied by at least one reference image or video.
Reference videos must use a public HTTPS URL. Images and audio can use a public HTTPS URL or a supported base64 data URL. Each decoded inline file can be up to 10 MB. Media URLs cannot contain credentials or fragments.
Parameters camera_fixed, draft, frames, seed, and tools are not supported. Omit them or send null. Only the default service tier is supported.
Seedance 2.5 options
Set output_format to mp4 (default) or mov. Other models do not support this parameter.
For Seedance 2.5 requests with reference media, omni_reference_task_type accepts auto (default), reference, edit, or extend. Both edit and extend require a reference video and ratio: "adaptive". For edit, also set duration: -1. Omit this parameter for requests without reference media or for other models.
Check task status
Set TASK_ID to the returned ID:
bash
curl --fail-with-body \
"https://byteplus.remotegpu.ai/api/v3/contents/generations/tasks/$TASK_ID" \
-H "Authorization: Bearer $REMOTEGPU_API_KEY"Poll while the status is queued or running. Stop polling when it is succeeded, failed, cancelled, or expired. On success, download the video from content.video_url. When requested, content.last_frame_url contains the last-frame image URL.
List tasks
List tasks when you need to recover task IDs or inspect several generations:
bash
curl --fail-with-body \
'https://byteplus.remotegpu.ai/api/v3/contents/generations/tasks?page_num=1&page_size=20&filter.status=succeeded' \
-H "Authorization: Bearer $REMOTEGPU_API_KEY"The response contains items and the total number of matching tasks in total. Tasks are ordered from newest to oldest.
| Query parameter | Values |
|---|---|
page_num | Page number from 1–500; defaults to 1. |
page_size | Results per page from 1–500; defaults to 20. |
filter.status | queued, running, succeeded, failed, cancelled, or expired. |
filter.model | Exact model ID. |
filter.task_ids | Task ID; repeat the parameter to select up to 100 task IDs. |
filter.service_tier | default, the only supported service tier. |
Receive status callbacks
Set callback_url in the create request to receive HTTP POST notifications. The JSON body has the same task fields as the status endpoint. Return any 2xx status within five seconds to acknowledge a callback. Redirects are not followed.
RemoteGPU makes one delivery attempt for an observed queued or running state and up to four attempts for succeeded, failed, or expired. A state can be skipped if the task changes before its callback is delivered, and a callback can arrive more than once. No callback is sent for cancelled tasks. Keep polling as a fallback and make your callback handler idempotent.
Callbacks do not contain a signature or authorization header. Use an unguessable value in the callback URL path if you need to identify the sender, and never put your RemoteGPU API key in the URL. Before taking an important action, query the task with your API key and verify its current status.
Cancel or delete a task
Send DELETE to the same task URL. A queued task can be cancelled; a running task cannot. Deleting a completed task removes its record from the API and does not refund the generation charge.
A completed deletion returns HTTP 204. HTTP 409 with CancellationPending means cancellation still needs confirmation. Query the task again to learn its outcome; the reserved balance remains held until the outcome is resolved.
Billing and retention
Prices are in USD per million generated tokens. On the pricing page, With ref video means the request includes a reference video; Without ref video means it does not. These are separate rates, not two charges for the same request.
Before submission, RemoteGPU reserves an estimate based on resolution, duration, and reference-video duration. The final charge uses the reported token usage. If a successful task has no usable token count, the original estimated token count is used instead.
A successful result is delivered even when the final charge exceeds the reserve. Your balance can become negative, which prevents another generation until you add funds. Confirmed failed, cancelled, or expired generations release the reserve. An unresolved submission keeps its reserve while RemoteGPU checks the outcome.
Outputs are retained privately for three days. Download files before the third day; removal can occur shortly after the retention period, so it is not an exact 72-hour guarantee. Download URLs expire sooner. Query the task again for a fresh URL while the output is still retained. Refreshing the URL does not extend the retention period.
After the output is removed, the task remains succeeded so its execution and billing history stay intact. Reading that task directly returns HTTP 410 with RemoteGPU.ResultExpired. Task lists continue to include it with result_expired: true and no content field; one expired output does not prevent other tasks from being listed.
Handle errors
Error responses use this structure:
json
{
"error": {
"code": "RemoteGPU.InvalidParameter",
"message": "The field is missing or invalid.",
"type": "invalid_request_error",
"param": "duration"
}
}Every response includes X-Request-Id. Save it when contacting support. An error with x-should-retry: true also includes Retry-After; wait that many seconds before retrying. Reuse the original Idempotency-Key when retrying a create request whose outcome is unknown.
| HTTP status | Common error code | What to do |
|---|---|---|
400 | InvalidParameter, UnsupportedFeature | Correct the field named by param. |
401 | AuthenticationRequired | Send a valid Token Factory API key. |
402 | InsufficientBalance | Add funds before creating another task. |
404 | NotFound | Check the model or task ID and confirm the task belongs to your account. |
409 | TaskConflict, CancellationPending | Check the task again before deciding whether another action is needed. |
410 | ResultExpired | The retained output is no longer available. |
413 | RequestTooLarge | Reduce the request body below 64 MB. |
422 | IdempotencyConflict | Use the same body with that key, or use a new key for a new generation. |
429 | RateLimited | Wait for Retry-After, then retry with the same Idempotency-Key. |
503 | ServiceUnavailable, ResultUnavailable | Retry later; reuse the same key if this was a create request. |
Reference
All paths below are relative to https://byteplus.remotegpu.ai/api/v3 and require Authorization: Bearer <api-key>.
| Method | Path | Purpose |
|---|---|---|
POST | /contents/generations/tasks | Create a generation task. |
GET | /contents/generations/tasks | List your tasks. |
GET | /contents/generations/tasks/{id} | Read task status and output URLs. |
DELETE | /contents/generations/tasks/{id} | Cancel a queued task or delete a completed record. |
Read next
- Read API keys to create or manage your Token Factory key.
- Read Token Factory for Text and Image API guides.
- See Pricing for published customer prices.