BeansAI
ModelsPricingDocs
Sign inSign up
ModelsPricingDocs
Sign inSign up

Quickstart

  • Overview

Clients

  • Claude Code
  • CC Switch
  • OpenClaw
  • Roo Code
  • OpenCode
  • Codex CLI
  • GPT Image 2
  • Seedance 2.0
  • SkyReels V4
  • Mureka Song
  • Cursor
  • Cherry Studio

Reference

  • Raw API
← Back to Docs

Seedance 2.0

Submit asynchronous Seedance video-generation tasks through BeansAI, including text, image, video, and audio references.

Overview

The upstream 302.ai Seedance documentation uses the Volcengine task API:POST /volcengine/api/v3/contents/generations/tasks to submit a task and GET /volcengine/api/v3/contents/generations/tasks/:id to query it.

BeansAI exposes the same capability through POST /videos and GET /videos/:task_id. The relay routes Volcengine nodes to the 302 task endpoint and wraps task ids so polling returns to the same node.

Supported parameters

ParameterPurpose
modelSeedance model id, for example doubao-seedance-2-0-260128.
content[]Required multimodal input array. Supported item types: text, image_url, video_url, audio_url.
ratioOutput aspect ratio such as 16:9, 9:16, 1:1, 4:3, 3:4, or 21:9.
durationVideo duration, commonly 5 or 10 seconds.
generate_audioBoolean flag for generated audio.
watermarkBoolean flag for watermark output.

Submit a task

curl
curl https://api.beansai.dev/v1/videos \
  -H "Authorization: Bearer sk-beans-..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "doubao-seedance-2-0-260128",
    "content": [
      {
        "type": "text",
        "text": "A glossy green coffee bean mascot walks across a clean studio floor, cinematic product lighting"
      }
    ],
    "ratio": "16:9",
    "duration": "5",
    "generate_audio": false,
    "watermark": false
  }'

Poll task status

Save the returned id or task_id, then poll it until the response includes a completed status and a video URL.

curl
curl https://api.beansai.dev/v1/videos/beansvid_... \
  -H "Authorization: Bearer sk-beans-..."

Reference media

Put reference images, videos, or audio clips in content[]. Use public HTTPS URLs that the upstream provider can fetch.

curl
curl https://api.beansai.dev/v1/videos \
  -H "Authorization: Bearer sk-beans-..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "doubao-seedance-2-0-260128",
    "content": [
      { "type": "text", "text": "Use the reference image as the main character and make a short product reveal video" },
      { "type": "image_url", "image_url": { "url": "https://example.com/reference.png" } },
      { "type": "audio_url", "audio_url": { "url": "https://example.com/music.mp3" } }
    ],
    "ratio": "9:16",
    "duration": "10",
    "generate_audio": true,
    "watermark": false
  }'

Upload image references

If your image is local, upload it to BeansAI first. BeansAI stores it in private R2 and returns a short-lived HTTPS URL that Seedance can fetch.

The dashboard Playground does this automatically when you choose an image file for the video reference field.

upload-reference.sh
curl https://api.beansai.dev/v1/uploads/playground-image \
  -H "Authorization: Bearer sk-beans-..." \
  -F "file=@./reference.png"
generate-with-uploaded-reference.sh
curl https://api.beansai.dev/v1/videos \
  -H "Authorization: Bearer sk-beans-..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "doubao-seedance-2-0-260128",
    "content": [
      { "type": "text", "text": "Animate this product image into a smooth cinematic reveal" },
      { "type": "image_url", "image_url": { "url": "https://<signed-r2-url-from-upload>" } }
    ],
    "ratio": "16:9",
    "duration": "5",
    "generate_audio": false,
    "watermark": false
  }'

Simple prompt shortcut

BeansAI also accepts a simple prompt field on POST /videos. For Volcengine nodes it is converted into content[] before forwarding.

curl
curl https://api.beansai.dev/v1/videos \
  -H "Authorization: Bearer sk-beans-..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "doubao-seedance-2-0-260128",
    "prompt": "A quiet macro shot of green coffee beans forming the BeansAI logo",
    "ratio": "1:1",
    "duration": "5"
  }'

Tips

  • Use the dashboard Playground to test prompts, aspect ratios, duration, audio, and watermark settings visually.
  • Video generation is asynchronous; store task ids if you need to resume polling later.
  • Reference media URLs should be stable and reachable without browser cookies.