Supported models
Run inference against any Model API to get started.Context and output limits reflect Baseten’s live serving configuration, which can differ from a model’s advertised native maximum. Baseten extends limits as they meet its performance bar. This table and
/v1/models always reflect what’s currently served.Some models are also available in a Fast tier: a variant intended for real-time and performance-sensitive workloads. A Fast model serves the same model weights as its base model on dedicated capacity engineered for higher sustained per-user throughput. It has its own slug (for example,
zai-org/GLM-5.2-Fast), pricing, and rate limits. It uses the same API, so you switch by changing the model slug. If Fast capacity is temporarily saturated, Baseten serves requests on base-model capacity instead: slower, not failed.Feature support
All models support tool calling (also known as function calling), structured outputs, and JSON mode. See the table below for per-model coverage of reasoning, vision, and audio. For reasoning-specific configuration, see Reasoning. For image and video inputs, see Vision. For audio inputs, see Audio.GLM 4.7 and Nemotron Ultra also support
top_p and top_k sampling parameters. GLM 5.2 and GLM 5.2 Fast support top_p.Run inference
Model APIs support both OpenAI’s Chat Completions and Anthropic’s Messages APIs. Set your base URL, API key, and model name to start making requests.Use the OpenAI SDK
Call supported models using the OpenAI Chat Completions API athttps://inference.baseten.co/v1/chat/completions.
- Python
- JavaScript
- cURL
To call a model with the Chat Completions API:
chat_completions.py
Use the Anthropic SDK
Call supported models using the Anthropic Messages API athttps://inference.baseten.co/v1/messages.
Anthropic Messages API support is in beta. Behavior may change before general availability. For production workloads, use the OpenAI Chat Completions API.
- Python
- JavaScript
- cURL
To call a model with the Messages API:
messages_api.py
x-api-key by default. Baseten reads Authorization, so override default_headers as shown.
List available models
Query the/v1/models endpoint for the current list of models with metadata including pricing, context windows, and supported features:
Request
Migrate
To migrate to Baseten, change the base URL, API key, and model name.- OpenAI SDK
- Anthropic SDK
To migrate from the OpenAI SDK:
- Replace your OpenAI API key with a Baseten API key.
- Change the base URL to
https://inference.baseten.co/v1. - Update the model name to a Baseten model slug.
migrate.py
Handle errors
Model APIs return standard HTTP error codes:
Each error response includes a JSON body with details about the issue and suggested resolutions.
Next steps
Coding agents
Call Model APIs from Pi, Droid, or OpenCode, or connect Claude Code and Codex CLI with Baseten Switch
Reasoning
Control extended thinking for complex tasks
Vision
Send images and videos alongside text
Audio
Send audio alongside text
Pricing and limits
Pricing, rate limits, budgets, and usage tracking
API reference
Complete parameter documentation