ByteDance: Doubao Seed 2.0 Code PreviewAPI pricing
Doubao Seed 2.0 Code Preview is a language model from ByteDance, tuned for writing and editing code.
- 每100万枚代币的价格
- $0.48 / $2.41input / output
- 缓存的输入
- $0.096per 1M tokens
- 上下文
- 256K tokens128K max output
- 服务提供商
- 2
服务提供商
2 providers ·
256K context · 128K max output
支持的参数11
- 抽样
温度top_ptop_k种子logit_bias- 处罚
存在惩罚- 输出
停止response_format结构化输出- 工具
工具工具选择
256K context · 128K max output
支持的参数7
- 抽样
温度top_p种子logit_bias- 处罚
存在惩罚- 输出
停止response_format- 未确认
工具
价格走势
API
curl https://api.opencheap.si/v1/chat/completions \
-H "Authorization: Bearer $OPENCHEAP_API_KEY" -H "Content-Type: application/json" \
-d '{ "model": "opencheap/doubao-seed-2.0-code-preview", "messages": [{ "role": "user", "content": "Hi" }] }'import os
from openai import OpenAI
client = OpenAI(base_url="https://api.opencheap.si/v1", api_key=os.environ["OPENCHEAP_API_KEY"])
r = client.chat.completions.create(model="opencheap/doubao-seed-2.0-code-preview",
messages=[{"role": "user", "content": "Hi"}])
print(r.choices[0].message.content)import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.opencheap.si/v1", apiKey: process.env.OPENCHEAP_API_KEY });
const r = await client.chat.completions.create({ model: "opencheap/doubao-seed-2.0-code-preview",
messages: [{ role: "user", content: "Hi" }] });
console.log(r.choices[0].message.content);致电 Doubao Seed 2.0 Code Preview 使用 OpenAI SDK:将其指向 https://api.opencheap.si/v1 并传递模型 ID opencheap/doubao-seed-2.0-code-preview;其余代码保持不变。
About Doubao Seed 2.0 Code Preview
- 请求示例
- $0.007210,000 in + 1,000 out
- 端点
https://api.opencheap.si/v1- 模型 ID
每个请求都会发送给模型中成本最低且状态正常的提供者,而每个响应都会报告其成本为 使用成本. Every model on OpenCheap is called with one key at the same OpenAI-compatible endpoint, https://api.opencheap.si/v1.
用文字表述价格
Doubao Seed 2.0 Code Preview costs from $0.48 per 1M input tokens and $2.41 per 1M output tokens on OpenCheap, with cached input at $0.096 per 1M tokens. It has no public list price to compare with. At that price, a request with 10,000 input tokens and 1,000 output tokens costs about $0.0072, and 1,000 such requests about $7.23.
2 providers serve Doubao Seed 2.0 Code Preview on OpenCheap. Its context window is 256K tokens (256,000), room for roughly 190,000 words of English in one request.
Doubao Seed 2.0 Code Preview is one of 24 ByteDance models on OpenCheap.
Prices as of 2026-12-04 11:48 UTC.
关于定价的问题
How much does the Doubao Seed 2.0 Code Preview API cost per 1M tokens?
Doubao Seed 2.0 Code Preview costs from $0.48 per 1M input tokens and $2.41 per 1M output tokens on OpenCheap, with cached input at $0.096 per 1M tokens. Prices as of 2026-12-04 11:48 UTC.
What does one Doubao Seed 2.0 Code Preview request cost?
A request with 10,000 input tokens and 1,000 output tokens costs about $0.0072, and 1,000 such requests about $7.23. Every answer reports its own cost in usage.cost.
Which providers serve Doubao Seed 2.0 Code Preview?
2 providers serve Doubao Seed 2.0 Code Preview on OpenCheap. Each request goes to the cheapest healthy provider of the model; the table on this page lists every provider with its price, speed and uptime.
What is the context window of Doubao Seed 2.0 Code Preview?
Its context window is 256K tokens (256,000), room for roughly 190,000 words of English in one request.
How do I call the Doubao Seed 2.0 Code Preview API?
Point the OpenAI SDK at https://api.opencheap.si/v1 and pass the model id opencheap/doubao-seed-2.0-code-preview. One OpenCheap key works for every model; the rest of your code stays the same.
More from ByteDance
- Doubao Seed 1.6doubao-seed-1.6$0.11 / $1.10 per 1M · 256K context
- Doubao Seed 1.6 Flashdoubao-seed-1.6-flash$0.021 / $0.21 per 1M · 256K context
- Doubao Seed 1.6 Litedoubao-seed-1.6-lite$0.041 / $0.33 per 1M · 256K context
- Doubao Seed 1.6 Thinkingdoubao-seed-1.6-thinking$0.11 / $1.10 per 1M · 256K context
- doubao-seed-2.0-code-preview-260215doubao-seed-2.0-code-preview-260215$0.82 / $4.08 per 1M · 127K context
- Doubao Seed 2.0 Litedoubao-seed-2.0-lite-260215$0.25 / $2.00 per 1M · 256K context
- Doubao Seed 2.0 Lite 260428doubao-seed-2.0-lite-260428$0.09 / $0.54 per 1M · 256K context
- Doubao Seed 2.0 Minidoubao-seed-2.0-mini-260215$0.10 / $0.48 per 1M · 256K context
类似型号
- Grok Code Fast 1xAI · 256K context$1.00 / $2.00 per 1M9 % cheaper
- Kimi K2.7 代码Moonshot · 26.2万上下文$0.25 / $1.08 per 1M55 % cheaper
- Qwen 3 Coder 480B TurboQwen · 256K context$0.42 / $1.80 per 1M25 % cheaper
- Qwen3 Coder PlusQwen · 1M 语料库$0.55 / $2.19 per 1M8 % cheaper
- GPT-5.3-CodexOpenAI · 400K context$0.70 / $5.60 per 1M
- 基米 K2.6Moonshot · 26.2万上下文$0.32 / $1.57 per 1M35 % cheaper
Compare Doubao Seed 2.0 Code Preview with any model →Cheapest LLM API