Keep your OpenAI code
Set the TokenRoc base URL and a model ID. Switch between DeepSeek, Qwen, Kimi and more without new SDKs.
Read the quickstartOpenAI-compatible API
Use DeepSeek, Qwen, Kimi, GLM and MiniMax for text and code, and Kling and Wan for images and video. Keep your OpenAI code, change the base URL, and pay only for what you use.
37 models · Text, image and video · Pay as you go · Every charge in your usage log
Model families on TokenRoc
Text, images and video through one OpenAI-compatible API, one balance and one usage log.
Set the TokenRoc base URL and a model ID. Switch between DeepSeek, Qwen, Kimi and more without new SDKs.
Read the quickstartChat and code models, image generation up to 4K, and video with resolution and audio options.
How pricing worksVideo charges are reserved when you submit and returned to your balance automatically if the task fails.
Video generation guideUsage Logs show each request and its charge. Task Logs track every video task by ID.
Open Usage LogsSet the base URL and choose a model. Keep your API key in an environment variable.
import os
from openai import OpenAI
client = OpenAI(
api_key=os.environ["TOKENROC_API_KEY"],
base_url="https://api.tokenroc.com/v1",
)
response = client.chat.completions.create(
model="deepseek-v4-flash",
messages=[{"role": "user",
"content": "Say hello."}],
)
print(response.choices[0].message.content)
curl https://api.tokenroc.com/v1/chat/completions \
-H "Authorization: Bearer $TOKENROC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "deepseek-v4-flash",
"messages": [
{"role": "user", "content": "Say hello."}
]
}'
Start with a task, then compare the model and its billing unit.
deepseek-v4-flash$0.2329 input · $0.9314 output per 1M tokens
Low-cost everyday chat.
Detailskimi-k2.7-code$0.7568 input · $3.1825 output per 1M tokens
Coding tasks and code questions.
Detailsqwen3.8-max$1.7778 input · $5.3333 output per 1M tokens
Compare it on harder reasoning tasks.
Detailskling/kling-v3-image-generation$0.0269 per image
Generate images from a prompt or reference.
Detailskling/kling-v3-omni-image-generationfrom $0.026866 per image
4K: $0.053731 per image.
Related image series, with output up to 4K.
Detailswan3.0-videofrom $0.044807 per second
Turn a text prompt or image into video.
Detailskling/kling-v3-video-generationfrom $0.080597 per second
Guide a clip with a prompt or start and end frames.
DetailsPrices checked 16 October 2026. See all live prices in Model Square.
Image and video prices start at the base setting. Check resolution and audio options before sending a request.
Sign up with your email address.
Available payment methods are shown at checkout.
Copy your key and keep it private.
Choose a model and run the quickstart.
Pay for what you use. Check each model's unit before you call it.
Check whether the website and API gateway respond right now.
Find what an error means and when to retry a request.
Review charges and check video statuses in Task Logs.
Send an API, account or billing question to TokenRoc.
Yes for text through Chat Completions. Keep your OpenAI SDK, set the TokenRoc base URL and API key, and choose a supported model ID. Images and video use the endpoints in the docs.
The catalog includes DeepSeek, Qwen, Kimi, GLM and MiniMax for text and code, and Kling and Wan for images and video. Model Square lists the available models and live prices.
Text is billed by input and output tokens, with cheaper cached input on supported models. Images are billed per generated image. Video billing depends on the model. You add funds and pay for what you use.
Add funds through our secure checkout. Available payment methods are shown at checkout.
If the task ends with status failed, the reserved charge is returned to your balance automatically. If your script stops waiting, the task may still be running. Check the same task ID before sending another request.
Usage Logs in the console show each request and its charge. Task Logs show video task IDs and statuses. The dashboard summarizes account activity.
Prices and a first video request.
Read the guide
Token rates and real cost examples.
Read the guide
From API key to a working request.
Read the guide