# bytedance/seedance-2.5-flash

Source: https://docs.sociaro.com/models/bytedance-seedance-2-5-flash/

Seedance 2.5 Flash — the faster, lower-cost tier of Seedance 2.5.

Up to 10 reference images, 5 reference clips and 5 audio tracks, audio-only input, and output up to 30 seconds, at 480p or 720p.

Priced like Seedance 2.0, not like 2.5.

|  |  |
| --- | --- |
| Slug | `bytedance/seedance-2.5-flash` |
| Kind | video |
| Vendor | bytedance |
| Endpoint | `POST /v1/byteplus/contents/generations/tasks` |
| References | [`POST /v1/generations/refs`](https://docs.sociaro.com/reference-images/index.md) |

[View pricing and billing conditions](https://docs.sociaro.com/models/bytedance-seedance-2-5-flash/#pricing)

## Example request

cURL

```bash
curl https://api.sociaro.com/v1/byteplus/contents/generations/tasks \
  -H "Authorization: Bearer $SOCIARO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
        "model": "bytedance/seedance-2.5-flash",
        "content": [{"type": "text", "text": "a paper boat drifts down a rain-soaked street"}],
        "resolution": "720p",
        "duration": 5
      }'

# then poll the job id it returns:
curl https://api.sociaro.com/v1/byteplus/contents/generations/tasks/JOB_ID \
  -H "Authorization: Bearer $SOCIARO_API_KEY"
```

Python

```python
# Requires Python 3 and requests (pip install requests).
import os
import time
import requests

payload = {'model': 'bytedance/seedance-2.5-flash',
 'content': [{'type': 'text',
              'text': 'a paper boat drifts down a rain-soaked street'}],
 'resolution': '720p',
 'duration': 5}

response = requests.post(
    'https://api.sociaro.com/v1/byteplus/contents/generations/tasks',
    headers={
        'Authorization': 'Bearer ' + os.environ['SOCIARO_API_KEY'],
        'Content-Type': 'application/json',
    },
    json=payload,
    timeout=120,
)
response.raise_for_status()
submitted = response.json()
job_id = submitted['id']
print(submitted)

# then poll the job id it returns:
while True:
    response = requests.get(
        'https://api.sociaro.com/v1/byteplus/contents/generations/tasks/' + job_id,
        headers={
            'Authorization': 'Bearer ' + os.environ['SOCIARO_API_KEY'],
        },
        timeout=120,
    )
    response.raise_for_status()
    result = response.json()
    status = result['status']
    if status == 'succeeded':
        break
    if status not in ('queued', 'running'):
        raise RuntimeError(result)
    time.sleep(5)
print(result)
```

JavaScript

```javascript
// Run as an .mjs file with Node.js 22 or later.
let jobId;
let result;

{
  const payload = {
    "model": "bytedance/seedance-2.5-flash",
    "content": [
      {
        "type": "text",
        "text": "a paper boat drifts down a rain-soaked street"
      }
    ],
    "resolution": "720p",
    "duration": 5
  };
  
  const response = await fetch("https://api.sociaro.com/v1/byteplus/contents/generations/tasks", {
    method: "POST",
    headers: {
      "Authorization": "Bearer " + process.env.SOCIARO_API_KEY,
      "Content-Type": "application/json",
    },
    body: JSON.stringify(payload),
  });
  if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
  const submitted = await response.json();
  jobId = submitted.id;
  console.log(submitted);
}

// then poll the job id it returns:
{
  while (true) {
    const response = await fetch("https://api.sociaro.com/v1/byteplus/contents/generations/tasks/" + jobId, {
      headers: {
        "Authorization": "Bearer " + process.env.SOCIARO_API_KEY,
      },
    });
    if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
    result = await response.json();
    const status = result.status;
    if (status === "succeeded") break;
    if (!["queued", "running"].includes(status)) throw new Error(JSON.stringify(result));
    await new Promise(resolve => setTimeout(resolve, 5000));
  }
  console.log(result);
}
```

## Parameters

Seedance 2.5 Flash — the faster, lower-cost 2.5 tier

| Field | Type | Required | Default | Values | What it does |
| --- | --- | --- | --- | --- | --- |
| `content` | array | yes | — | parts, each with its own type and an optional role | This is the whole input. `{"type":"text","text":…}`, `{"type":"image_url","image_url":{"url":…},"role":"first_frame"\|"last_frame"\|"reference_image"}`, `{"type":"video_url",…,"role":"reference_video"}`, `{"type":"audio_url",…,"role":"reference_audio"}`. |
| `resolution` | string | no | 720p | 480p · 720p | A tier this model does not have is refused with a 400 naming the ones it does. The generator would ACCEPT it and silently render 720p, so the check is ours and it costs you nothing. |
| `duration` | integer | no | -1 | 4–30, or -1 | Seconds. `-1` lets the model pick the length that suits the inputs. |
| `ratio` | string | no | adaptive | 21:9 · 16:9 · 4:3 · 1:1 · 3:4 · 9:16 · adaptive |  |
| `output_format` | string | no | mp4 | mp4 · mov | `mov` carries 10-bit colour and PCM audio for editing work, and only the 2.5 models offer it. |
| `generate_audio` | boolean | no | false | true · false | Sound is off unless you send `true`, on every route, except when you send your own audio (a `reference_audio` part) or set the field `omni_reference_task_type` to `edit` or `extend` (2.5 models only): then the generator's own default applies, and it is on. On the 2.0 models an edit or extension is asked for in the prompt, without that field, so it comes back silent unless you send `"generate_audio": true` or your own audio (`reference_audio`), with which sound is on by default. With `true` the clip gets generated sound synchronised with the picture, at the same price: these models are metered per token. |
| `bitrate_mode` | string | no | the model's own | standard · high | Not in the vendor's public reference; passed to the generator as sent. Leave it out to take the model's own. |
| `return_last_frame` | boolean | no | false | true · false | Asks for the closing still beside the clip, at NO extra cost — useful as the `first_frame` of the next clip. The poll returns it as `content.last_frame_url`, the vendor's own link, with `last_frame_media_url` beside it: ours, on the same expiring terms as `media_url`. |
| `watermark` | boolean | no | false | true · false | No mark unless you send `true`, which puts an `AI Generated` mark in the lower right corner. `false` is the generator's own default: `/v1/byteplus` and `/v1/modelark` add no `watermark` to your body, so it applies there, and the other routes send `false` when you leave the field out. |
| `seed` | integer | no | random | — | Every Seedance model we serve accepts it. The same seed gives similar, not identical, results: the vendor says complete consistency is not guaranteed. |
| `execution_expires_after` | integer | no | 172800 | 3600–259200 | Seconds after submission at which the generator gives up on a task that has not finished and marks it `expired`. We charge only a finished clip, so an expired task costs you nothing, and the task stays pollable for its whole window. A value that is not a whole number in the range is refused before anything is created (`400`, `invalid_input` on `/v2/jobs`); `/v1/byteplus` and `/v1/modelark` forward it as sent and the generator refuses a bad one itself. On `/v2/jobs` the job still ends at its own `max_runtime_sec`. |
| `safety_identifier` | string | no | — | 1–64 characters | A fixed id for YOUR end user, one per user, which the generator uses to spot an end user who breaks its usage policy. We never send your value itself: we send a per-organisation pseudonym of your value (64 hex characters, the same for the same value on all your organisation's keys and routes), and the task reports that pseudonym back. A blank or longer value is refused before anything is created (`400`, `invalid_input` on `/v2/jobs`), on every route. |
| `omni_reference_task_type` | string | no | auto | auto · reference · edit · extend | What the references in `content` are FOR — generate from them, edit the source, or extend it; `auto` lets the model infer it from the prompt. Needs REFERENCE media in `content`: the generator refuses it on text-to-video and on first-frame jobs. Under `extend` we read `duration` as the length of the ADDITION rather than of the finished clip, but BytePlus does not state this. The 2.5 models only — the 2.0 rows accept the field and silently ignore it. |

### Worked example

cURL

```bash
# extend an existing clip (whether duration is the length of the addition or of the whole clip is not stated by BytePlus)
curl https://api.sociaro.com/v1/byteplus/contents/generations/tasks \
  -H "Authorization: Bearer $SOCIARO_API_KEY" -H "Content-Type: application/json" \
  -d '{ "model": "bytedance/seedance-2.5-flash",
        "content": [
          { "type": "text", "text": "the camera drifts on past the lantern" },
          { "type": "video_url", "video_url": {"url": "https://your-cdn.example.com/clip.mp4"},
            "role": "reference_video" }
        ],
        "omni_reference_task_type": "extend",
        "resolution": "720p", "duration": 6 }'
```

Python

```python
# Requires Python 3 and requests (pip install requests).
import os
import requests

# extend an existing clip (whether duration is the length of the addition or of the whole clip is not stated by BytePlus)
payload = {'model': 'bytedance/seedance-2.5-flash',
 'content': [{'type': 'text',
              'text': 'the camera drifts on past the lantern'},
             {'type': 'video_url',
              'video_url': {'url': 'https://your-cdn.example.com/clip.mp4'},
              'role': 'reference_video'}],
 'omni_reference_task_type': 'extend',
 'resolution': '720p',
 'duration': 6}

response = requests.post(
    'https://api.sociaro.com/v1/byteplus/contents/generations/tasks',
    headers={
        'Authorization': 'Bearer ' + os.environ['SOCIARO_API_KEY'],
        'Content-Type': 'application/json',
    },
    json=payload,
    timeout=120,
)
response.raise_for_status()
print(response.text)
```

JavaScript

```javascript
// Run as an .mjs file with Node.js 22 or later.

// extend an existing clip (whether duration is the length of the addition or of the whole clip is not stated by BytePlus)
const payload = {
  "model": "bytedance/seedance-2.5-flash",
  "content": [
    {
      "type": "text",
      "text": "the camera drifts on past the lantern"
    },
    {
      "type": "video_url",
      "video_url": {
        "url": "https://your-cdn.example.com/clip.mp4"
      },
      "role": "reference_video"
    }
  ],
  "omni_reference_task_type": "extend",
  "resolution": "720p",
  "duration": 6
};

const response = await fetch("https://api.sociaro.com/v1/byteplus/contents/generations/tasks", {
  method: "POST",
  headers: {
    "Authorization": "Bearer " + process.env.SOCIARO_API_KEY,
    "Content-Type": "application/json",
  },
  body: JSON.stringify(payload),
});
if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
console.log(await response.text());
```

**Seedance 2.5's inputs at Seedance 2.0's price.** Flash keeps 2.5's long output and audio-only input, with smaller reference ceilings and no 1080p:

|  | 2.0 | 2.5 | 2.5 Flash |
| --- | --- | --- | --- |
| reference images | up to 9 | up to 30 | **up to 10** |
| reference videos | up to 3, each 2–15 s | up to 10, each 2–30 s | **up to 5, each 2–30 s** |
| reference audio | up to 3 | up to 10 | **up to 5** |
| audio-only input | not allowed | allowed | **allowed** |
| output length | 4–15 s | up to 30 s | **up to 30 s** |
| resolution | up to 4K | up to 4K | **480p or 720p** |
| draft mode | no | yes | **no** |

Metered per token, with the same minimum cost on video-input jobs as the rest of the family. A tier
this model does not have (1080p, 4K) is a `400` naming 480p and 720p, and `draft: true` is a `400` too
(`draft: false` passes).

`omni_reference_task_type` exists on the 2.5 models alone. The 2.0 rows accept it and ignore it, which
buys you a clip that never used the setting and no error saying so.

## How a job runs

These routes are a **pass-through**: you send BytePlus's own body and get their own response back,
with our additions beside it. Generation takes longer than a request should wait, so it goes in
three moves — submit, poll, collect.

cURL

```bash
# 1. submit — the id comes back as `id`. There is NO `job_id` on THIS response
curl -sS https://api.sociaro.com/v1/byteplus/contents/generations/tasks \
  -H "Authorization: Bearer $SOCIARO_API_KEY" -H "Content-Type: application/json" \
  -d '{ "model": "…", "content": [ … ] }'
# -> { "id": "cgt-…" }

# 2. poll every 5-10 s
curl -sS https://api.sociaro.com/v1/byteplus/contents/generations/tasks/cgt-… \
  -H "Authorization: Bearer $SOCIARO_API_KEY"
# -> { "status": "running", … }
# -> { "status": "succeeded", "content": { "video_url": "<the vendor's own link>" },
#      "media_url": "https://api.sociaro.com/v1/media/<media_id>" }

# 3. collect — the opaque id IS the credential, no header needed
curl -sSL "https://api.sociaro.com/v1/media/<media_id>" -o out.mp4
```

Python

```python
# Requires Python 3 and requests (pip install requests).
from pathlib import Path
import os
import time
import requests

# 1. submit — the id comes back as `id`. There is NO `job_id` on THIS response
# Save the complete request body in request.json.
response = requests.post(
    'https://api.sociaro.com/v1/byteplus/contents/generations/tasks',
    headers={
        'Authorization': 'Bearer ' + os.environ['SOCIARO_API_KEY'],
        'Content-Type': 'application/json',
    },
    data=Path('request.json').read_bytes(),
    timeout=120,
)
response.raise_for_status()
submitted = response.json()
job_id = submitted['id']
print(submitted)

# 2. poll every 5-10 s
while True:
    response = requests.get(
        'https://api.sociaro.com/v1/byteplus/contents/generations/tasks/' + job_id,
        headers={
            'Authorization': 'Bearer ' + os.environ['SOCIARO_API_KEY'],
        },
        timeout=120,
    )
    response.raise_for_status()
    result = response.json()
    status = result['status']
    if status == 'succeeded':
        break
    if status not in ('queued', 'running'):
        raise RuntimeError(result)
    time.sleep(5)
print(result)

# 3. collect — the opaque id IS the credential, no header needed
response = requests.get(
    result['media_url'],
    timeout=120,
)
response.raise_for_status()
Path('out.mp4').write_bytes(response.content)
```

JavaScript

```javascript
// Run as an .mjs file with Node.js 22 or later.
import { readFile, writeFile } from "node:fs/promises";
let jobId;
let result;

// 1. submit — the id comes back as `id`. There is NO `job_id` on THIS response
{
  // Save the complete request body in request.json.
  const response = await fetch("https://api.sociaro.com/v1/byteplus/contents/generations/tasks", {
    method: "POST",
    headers: {
      "Authorization": "Bearer " + process.env.SOCIARO_API_KEY,
      "Content-Type": "application/json",
    },
    body: await readFile("request.json"),
  });
  if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
  const submitted = await response.json();
  jobId = submitted.id;
  console.log(submitted);
}

// 2. poll every 5-10 s
{
  while (true) {
    const response = await fetch("https://api.sociaro.com/v1/byteplus/contents/generations/tasks/" + jobId, {
      headers: {
        "Authorization": "Bearer " + process.env.SOCIARO_API_KEY,
      },
    });
    if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
    result = await response.json();
    const status = result.status;
    if (status === "succeeded") break;
    if (!["queued", "running"].includes(status)) throw new Error(JSON.stringify(result));
    await new Promise(resolve => setTimeout(resolve, 5000));
  }
  console.log(result);
}

// 3. collect — the opaque id IS the credential, no header needed
{
  const response = await fetch(result.media_url);
  if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
  await writeFile("out.mp4", new Uint8Array(await response.arrayBuffer()));
}
```

Images use `POST /v1/byteplus/images/async` and its poll in the same shape, and the faster models
also answer synchronously at `POST /v1/byteplus/images/generations` — one request, the picture in
the response. A model whose render outlasts the gateway's ~2-minute ceiling is refused there by
name, telling you to use the async route.

## Reading the poll

**Two differences will bite a client written against the poll-style routes.** The SUBMIT returns
`id`, not `job_id` — code reading `job_id` there gets nothing and cannot poll at all. And `status`
is the VENDOR'S vocabulary: `running`, `succeeded`, `failed` — not `processing`, `completed`,
`failed`. A check for `completed` on this route never becomes true, which reads as a job that never
finishes rather than as an error.

The POLL response does carry `job_id` beside the vendor's `id`, as a convenience, and it returns
the vendor's whole body — around twenty fields — rather than the five-field shape the other routes
use. Gate on `status` rather than on the poll's HTTP code.

**Prefer `media_url` over the vendor's raw link.** Both are returned: `content.video_url` (or
`data[].url` for images) is theirs, kept for compatibility and due to be removed once nobody reads
it; `media_url` is ours. Ours points at our host, hides the vendor's storage, and expires. A second
asset arrives on the same terms — `return_last_frame` gives `content.last_frame_url` with
`last_frame_media_url` beside it.

## Collecting the result

`media_url` is a **capability**: the opaque id is the credential, so no `Authorization` header is
needed and anyone holding the link can fetch it. It **expires within the hour** — download rather
than store the link.

## Rules the gateway adds

Your key must be granted this model — `403` otherwise — and either spelling satisfies the grant:
our catalogue id or the vendor's own native one.

Because this is a pass-through, unknown fields go to the generator rather than being refused here,
and it is the generator that decides. The exception is `resolution`, which we check ourselves: an
unsupported tier is silently ignored upstream, so you would ask for the higher one, be handed a
lower one, and be charged. A tier we cannot price is refused at submit, before any money is spent,
with a message naming the ones this model has.

Ranges and enums are the generator's own, so an out-of-range value comes back as its rejection, in
its wording and with its numbers.

## Pricing

| Billable unit and options | Rate (USD) |
| --- | --- |
| per 1M tokens 480p | $7.7 |
| per 1M tokens 480p, with input video | $4.73 |
| per 1M tokens 720p | $7.7 |
| per 1M tokens 720p, with input video | $4.73 |
| per second of output video 480p approx., 16:9 | $0.073978 |
| per second of input and output video 480p, with input video approx., 16:9 | $0.045443 |
| per second of output video 720p approx., 16:9 | $0.16632 |
| per second of input and output video 720p, with input video approx., 16:9 | $0.102168 |
| minimum per job 480p, with input video for a 4 s output; more for a longer one | $0.343689 |
| minimum per job 720p, with input video for a 4 s output; more for a longer one | $0.780267 |

- Metered in tokens, so the charge follows the frames rendered; the per-second figures are an estimate for 16:9.
- A job with input video is metered at the with-video rate, and is charged at least the minimum per job in its own row.
- Leaving out resolution gives 720p.

[View this model in the pricing catalogue](https://sociaro.com/pricing?model=bytedance%2Fseedance-2.5-flash). Your [billing logs](https://docs.sociaro.com/billing/index.md) show the actual charge for each request.
