cheapmodel API Reference
cheapmodel provides one account, one balance, and multiple API-compatible entry points for production model access. Use OpenAI, Anthropic, Google, and video task formats from the same console token.
Quick Start
Create a token in the console, choose a model from the model marketplace, and set the base URL for the protocol you want to use.
from openai import OpenAI
client = OpenAI(
api_key="YOUR_CHEAPMODEL_KEY",
base_url="https://cheapmodel.ai/v1",
)
response = client.chat.completions.create(
model="gpt-5.5",
messages=[{"role": "user", "content": "Hello from cheapmodel"}],
)
print(response.choices[0].message.content)
Authorization: Bearer YOUR_CHEAPMODEL_KEY. The same token is used for all supported protocol formats.
Protocol Endpoints
| Protocol | Base URL | Typical use |
|---|---|---|
| OpenAI compatible | https://cheapmodel.ai/v1 | Chat, images, embeddings, model list, and most OpenAI SDK calls. |
| Anthropic compatible | https://cheapmodel.ai/v1/messages | Claude-style Messages API requests. |
| Google compatible | https://cheapmodel.ai/v1beta | Gemini-style generateContent requests. |
| Video API | https://cheapmodel.ai/video/v1https://cheapmodel.ai/v1/video | Seedance 2.0 and Happy Horse asynchronous video tasks. |
AI Model APIs
Model List
Return available models for the current token and enabled groups.
Chat Completions
OpenAI-compatible text and multimodal chat requests.
Anthropic Messages
Use Anthropic-style message payloads with supported Claude models.
Google Generate Content
Use Gemini-style payloads through the Google-compatible endpoint.
Images
Generate images with supported image models such as gpt-image-2.
Videos
Create asynchronous Seedance and Happy Horse video tasks.
Video APIs
Video models use asynchronous task APIs. cheapmodel normalizes token authentication, task IDs, status queries, and account billing across supported video providers.
Seedance 2.0
Text, image, video, and audio reference inputs with token-based billing after task completion.
Happy Horse
Text-to-video, image-to-video, reference-to-video, and video editing with duration and resolution based billing.
curl https://cheapmodel.ai/video/v1/video/generations \
-H "Authorization: Bearer YOUR_CHEAPMODEL_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "doubao-seedance-2-0-fast-260128",
"prompt": "Two cats run and playfully chase each other",
"size": "9:16",
"duration": -1,
"generate_audio": true,
"watermark": false
}'
Billing
Text and image models follow the model marketplace price table. Native video tasks are charged only after a provider task completes successfully, based on the provider usage returned by the task query.
| Model family | Billing unit | When charged |
|---|---|---|
| OpenAI-compatible text | Input, output, and cache-hit tokens where supported | At request completion |
| Images | Per image or provider-reported usage | At request completion |
| Seedance 2.0 | USD usage-token pricing, rounded to two decimals | When task status is success |
| Happy Horse | USD per-second pricing by output resolution, rounded to two decimals | When task status is success |