genmux API is now generally available. Read the docs →
genmux API
Doubao Seed 2.0 Pro emblem

Doubao Seed 2.0 Pro API

ByteDance's flagship Doubao model with vision and web search — for complex reasoning and multimodal tasks. 256K-token context, streaming and an OpenAI-compatible endpoint, billed per token in prepaid credits — no subscription.

from $1.063 per 1M input tokens · $5.10 output

  • Context window: 256K tokens
  • Tool calling: yes (OpenAI tools)
  • Thinking mode: yes

Pricing

Billed per token: input (every message you send) and output (the reply, including reasoning) at separate rates. Credits are reserved when the request starts and settled to the actual usage when it ends.

TokensCredits per 1MUSD per 1M
Input85 credits
$1.063
≈ $0.0011 per 1K
Output408 credits
$5.10
≈ $0.0051 per 1K

USD figures are converted at the Scale pack rate; larger packs are cheaper per credit. See pricing for the full pack list.

What a 1M-token month costs

750,000 tokens input + 250,000 tokens output = 165.75 credits ≈ $2.072.

75/25 input/output mix, at the Scale pack rate. Reasoning tokens count as output.

All credit packs →

List prices elsewhere

Publicly listed per-token prices for the same model at the vendor and other providers, read from their own pricing pages. Prices change without notice — follow the links for the current figure.

ProviderInput $/1MOutput $/1MBlended $/1MChecked on
genmux API
85 / 408 credits · at the Scale pack rate
$1.063$5.10$2.072live
Volcengine (Doubao)
Volcengine CNY 3.20/16.00 per 1M tokens (<=32K context tier), converted at 1 CNY = $0.1490. Volcengine's own docs page (docs.volcengine.com/docs/82379/1544106) is JS-rendered and returned empty on fetch; figure corroborated by independent launch-day coverage (80aj.com, 53ai.com), not the raw vendor table.
$0.477$2.384$0.9542026-09-06

At a 75/25 input/output mix: $2.072 per 1M tokens with genmux API vs $0.954 at the list price of Volcengine (Doubao).

Blended = 75 % input + 25 % output. Our figure is in USD at the Scale pack rate for comparability; competitor list prices as checked on 2026-09-06.

At a glance

Model id
doubao-seed-2-pro
Capability
text.chat
Context window
256K tokens
Max output
16,384 tokens
Default max_tokens
8,192 tokens
Thinking mode
yes
Web search
yes
Image input
yes
Tool calling
yes (OpenAI tools)
Streaming
yes (SSE)
OpenAI SDK
compatible (set base_url)

Quick start

Create a key in the dashboard, then call the OpenAI-compatible endpoint directly or through the official OpenAI SDK with a custom base_url. The usage block of every response carries the credits charged.

cURL
cURL
curl -s -X POST https://api.genmux.tech/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"doubao-seed-2-pro","messages":[{"role":"system","content":"You are a concise assistant."},{"role":"user","content":"Explain idempotency keys in two sentences."}],"max_tokens":200}'
Response · 200 OK
{
  "id": "0d8b6a3e-2f1c-4a5b-9c1d-7e2f3a4b5c6d",
  "object": "chat.completion",
  "created": 1756411279,
  "model": "doubao-seed-2-pro",
  "choices": [
    {"index": 0, "message": {"role": "assistant", "content": "…"}, "finish_reason": "stop"}
  ],
  "usage": {"prompt_tokens": 31, "completion_tokens": 58, "total_tokens": 89, "cost": 0.026, "cost_source": "vendor"}
}
cURL · streaming
cURL · streaming
curl -sN -X POST https://api.genmux.tech/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"doubao-seed-2-pro","messages":[{"role":"system","content":"You are a concise assistant."},{"role":"user","content":"Explain idempotency keys in two sentences."}],"max_tokens":200,"stream":true}'
Response · text/event-stream
data: {"id":"0d8b6a3e-…","object":"chat.completion.chunk","model":"doubao-seed-2-pro","choices":[{"index":0,"delta":{"role":"assistant","content":"An"},"finish_reason":null}]}

data: {"id":"0d8b6a3e-…","object":"chat.completion.chunk","model":"doubao-seed-2-pro","choices":[{"index":0,"delta":{"content":" idempotency"},"finish_reason":null}]}

…

data: {"id":"0d8b6a3e-…","object":"chat.completion.chunk","model":"doubao-seed-2-pro","choices":[{"index":0,"delta":{},"finish_reason":"stop"}]}

data: {"id":"0d8b6a3e-…","object":"chat.completion.chunk","model":"doubao-seed-2-pro","choices":[],"usage":{"prompt_tokens":31,"completion_tokens":58,"total_tokens":89,"cost":0.026,"cost_source":"estimated"}}

data: [DONE]
Python · openai SDK
Python · openai SDK
import os
from openai import OpenAI

client = OpenAI(base_url="https://api.genmux.tech/v1", api_key=os.environ["API_KEY"])

completion = client.chat.completions.create(
    model="doubao-seed-2-pro",
    messages=[
        {"role": "system", "content": "You are a concise assistant."},
        {"role": "user", "content": "Explain idempotency keys in two sentences."},
    ],
    max_tokens=200,
)

print(completion.choices[0].message.content)
print(completion.usage.total_tokens, "tokens,", completion.usage.model_extra["cost"], "credits")
Node.js · openai SDK
Node.js · openai SDK
import OpenAI from "openai";

const client = new OpenAI({ baseURL: "https://api.genmux.tech/v1", apiKey: process.env.API_KEY });

const completion = await client.chat.completions.create({
  model: "doubao-seed-2-pro",
  messages: [
    { role: "system", content: "You are a concise assistant." },
    { role: "user", content: "Explain idempotency keys in two sentences." },
  ],
  max_tokens: 200,
});

console.log(completion.choices[0].message.content);
console.log(completion.usage.total_tokens, "tokens,", completion.usage.cost, "credits");

// Streaming: the final chunk carries usage
const stream = await client.chat.completions.create({
  model: "doubao-seed-2-pro",
  messages: [{ role: "user", content: "Explain idempotency keys in two sentences." }],
  stream: true,
});
for await (const chunk of stream) {
  process.stdout.write(chunk.choices[0]?.delta?.content ?? "");
  if (chunk.usage) console.log(`\n${chunk.usage.total_tokens} tokens, ${chunk.usage.cost} credits`);
}
Python · streaming, reading usage
Python · streaming, reading usage
import os
from openai import OpenAI

client = OpenAI(base_url="https://api.genmux.tech/v1", api_key=os.environ["API_KEY"])

stream = client.chat.completions.create(
    model="doubao-seed-2-pro",
    messages=[{"role": "user", "content": "Explain idempotency keys in two sentences."}],
    max_tokens=200,
    stream=True,
)

for chunk in stream:
    if chunk.choices and chunk.choices[0].delta.content:
        print(chunk.choices[0].delta.content, end="", flush=True)
    if chunk.usage:  # the last chunk: token counts and the credits charged
        print(f"\n{chunk.usage.total_tokens} tokens, {chunk.usage.model_extra['cost']} credits")
Full API reference →

Frequently asked questions

What is the Doubao Seed 2.0 Pro API?
ByteDance's flagship Doubao model with vision and web search — for complex reasoning and multimodal tasks. Doubao Seed 2.0 Pro belongs to ByteDance's Doubao Seed 2.0 family. It is a proprietary model available only through an API — there are no weights to download. On genmux API it sits behind an OpenAI-compatible chat completions endpoint with a 256K-token context window, billed per token in prepaid credits.
How much does Doubao Seed 2.0 Pro cost per 1M tokens?
Input tokens cost 85 credits per 1M (about $1.063 at the Scale pack rate) and output tokens 408 credits per 1M (about $5.10). Every message in the request — system, user and earlier assistant turns — is input; the reply, including any reasoning, is output. A month of 750,000 tokens in and 250,000 tokens out comes to 165.75 credits, about $2.072. Credits are prepaid: no subscription and no per-seat fee.
How does Doubao Seed 2.0 Pro differ from Doubao Seed 2.0 Lite?
The full Doubao Seed 2.0 tier, ahead of Lite and Mini on reasoning depth and multimodal accuracy. Both are ByteDance models on the same endpoint with the same key, so switching is a one-word change of the model field; GET /v1/models shows the context window, limits and prices of each side by side.
When is Doubao Seed 2.0 Pro worth its price over a cheaper model?
When the quality of the answer is the product: general chat and assistants, step-by-step reasoning, image understanding and answers grounded in web search. Route the routine traffic — short classifications, drafts, extraction — to a cheaper model such as Doubao Seed 2.0 Lite and keep Doubao Seed 2.0 Pro for the calls that need it. With one key and one request shape the split is a routing rule in your code, not a second integration.
What are the context window and max_tokens limits of Doubao Seed 2.0 Pro?
256K tokens of context, shared between the prompt and the completion. max_tokens caps the reply: the model accepts up to 16,384 and uses 8,192 when you omit the field. A prompt that leaves no room for a reply is rejected with 400 context_length_exceeded before anything is charged, and a reply cut off by the cap ends with finish_reason "length".
Does Doubao Seed 2.0 Pro support streaming?
Yes. Send "stream": true and the response is text/event-stream: one chat.completion.chunk per token on data: lines, then a final chunk with an empty choices array and a usage object — prompt_tokens, completion_tokens, total_tokens and cost, the credits charged — followed by data: [DONE]. Read usage from that last chunk; the OpenAI SDKs expose it as chunk.usage. If the upstream fails mid-stream you get a data: {"error": {...}} frame and then [DONE].
Can I use the OpenAI SDK with Doubao Seed 2.0 Pro?
Yes. Point base_url at https://api.genmux.tech/v1, use your genmux API key as api_key and set model to "doubao-seed-2-pro". Chat completions with system, user and assistant messages, streaming, max_tokens, temperature, top_p and stop work as in the SDK. Tools and function calling work as in the SDK too, and response_format json_object / json_schema is validated. n greater than 1 and logprobs are rejected with 400 unsupported_parameter rather than being silently ignored.
Does Doubao Seed 2.0 Pro support tool calling for coding agents?
Yes. Send tools and tool_choice as on the OpenAI API; the reply carries tool_calls (streamed as delta.tool_calls) and you return results as role: tool messages. Function calling is emulated by the api — the tools are rendered into the prompt and parsed back — so it works with OpenCode, Cline, Roo Code, Continue and any OpenAI SDK loop; tool definitions count as prompt tokens (about 40 per tool plus the schema). Configs and measured pass rates are on the coding agents page.
How is thinking mode billed on Doubao Seed 2.0 Pro?
Pass "enable_thinking": true and the model reasons before it answers; the reasoning arrives as reasoning_content next to content (and as a delta in the stream). Reasoning tokens are output tokens, billed at 408 credits per 1M like the visible answer, and they count toward max_tokens — so raise max_tokens for hard problems rather than letting the cap cut the answer short.
Can Doubao Seed 2.0 Pro search the web?
Yes. Pass "web_search": true and the model may consult the web before answering. The extension is accepted only on models whose catalogue entry says web_search: true; elsewhere it is a 400 unsupported_parameter. Whatever the model reads becomes part of the prompt, so a search-heavy answer uses more input tokens — the usage block shows exactly how many.
Can I send images to Doubao Seed 2.0 Pro?
Yes. Put an image_url part in the content array of a user message, as on the OpenAI API, with a public https URL or a data: URL. Images are converted to input tokens (about 1,000 tokens per image) and billed at the input rate; image_url parts are rejected with 400 unsupported_parameter on models without vision.
What am I charged when a request fails or I abort a stream?
Nothing when no tokens were produced: a rejected request, a 503 model_unavailable or a 502 upstream_error refunds the reservation in full. Credits are reserved for the estimated prompt plus min(max_tokens, 8,192) output tokens and settled to the actual usage when the call ends, so an unused reservation is released. If you close a stream early you pay only for the tokens generated up to that point.
What are the rate limits, and how do API keys work?
Each key has a requests-per-second limit (10 by default) and each account a cap on concurrent requests (20 by default); beyond either you get 429 rate_limited with a Retry-After header. Keys are created in the dashboard, shown once, and can carry an IP allowlist and an expiry date. One key works for every model in the catalogue, text and image alike.
Do you store my prompts and completions?
No. The generation record keeps a preview of the last user message (up to 200 characters), the number of messages, a SHA-256 hash of the messages, the token counts and the cost — never the messages or the reply themselves. GET /v1/generations/{id} returns that record so you can reconcile usage; the content exists only in your own process and at the model provider for the duration of the call.
Can I use Doubao Seed 2.0 Pro's output commercially?
Yes. Under our terms of service you own the rights we can pass on to the text the model writes for you and may use it commercially, provided the prompts and the use comply with the terms and the model provider's usage policy. Read the terms before shipping anything customer-facing.
How do I switch from Doubao Seed 2.0 Pro to another model?
Change the model field — nothing else in the request changes, and the same key and balance apply. The closest alternatives in the catalogue are Doubao Seed 2.0 Lite and Doubao Seed 2.0 Code. GET /v1/models lists every id with its context window, limits and prices, and marks which ones accept enable_thinking, web_search and images.
Use it in OpenCode, Aider, Cline or Continue →

Keep reading

Other models

Same key, same request shape — switch by changing the model field.

  • Doubao Seed 2.0 Code API

    doubao-seed-2-code

    Doubao's coding-tuned model with vision — for agentic coding, refactors and UI-from-screenshot tasks.

    $1.063 in · $5.10 out per 1M tokens

  • Doubao Seed 2.0 Lite API

    doubao-seed-2-lite

    Mid-tier Doubao model with vision — general assistants and image-aware chat at a lower cost than Pro.

    $0.213 in · $1.063 out per 1M tokens

  • Doubao Seed 2.0 Mini API

    doubao-seed-2-mini

    The cheapest Doubao model with vision — high-volume, latency-sensitive chat and simple image tasks.

    $0.027 in · $0.85 out per 1M tokens

  • Kimi K3 API

    kimi-k3

    Moonshot's flagship Kimi model with a huge context window — for very long documents and multi-step agents.

    $2.463 in · $12.323 out per 1M tokens

  • Claude Opus 5.5 API

    claude-opus-5-5

    Anthropic's top Claude Opus model — strong reasoning and agentic coding with a large context window for complex, multi-step work.

    $1.836 in · $9.18 out per 1M tokens

  • Claude Fable 5.1 API

    claude-fable-5-1

    Anthropic's premium Claude model for long-form writing — polished drafting and editing with a large context window.

    $21.25 in · $21.25 out per 1M tokens

  • Image models

    The same key and balance also buy image generation: Nano Banana, Seedream, Qwen-Image, FLUX and more, billed per image.