Get Model Pricing
Returns pricing configuration for a specific model.
Note: Prices are in USD cents per token.
Supported Providers
openai, anthropic, google, azure-openai, bedrock, mistral-ai, cohere, together-ai, groq, deepseek, fireworks-ai, perplexity-ai, anyscale, deepinfra, cerebras, x-ai, and 25+ more.
Example Response Fields
| Field | Description | Unit |
|---|---|---|
| request_token.price | Input token cost | cents/token |
| response_token.price | Output token cost | cents/token |
| cache_write_input_token.price | Cache write cost | cents/token |
| cache_read_input_token.price | Cache read cost | cents/token |
| additional_units.* | Provider-specific features | cents/unit |
Path parameters
Provider identifier. Use lowercase with hyphens.
Examples: openai, anthropic, google, azure-openai, bedrock, x-ai
Model identifier. Use the exact model name as specified by the provider.
Examples: gpt-4, gpt-4o, claude-3-5-sonnet-20241022, gemini-2.0-flash-001
Response
Pricing configuration for the specified model
Example response
{
"pay_as_you_go": {
"image": {
"standard": {
"1024x1024": {
"price": 4
},
"1024x1792": {
"price": 8
}
},
"hd": {
"1024x1024": {
"price": 8
},
"1024x1792": {
"price": 12
}
}
}
},
"batch_config": {
"request_token": {
"price": 0.000125
},
"response_token": {
"price": 0.0005
}
}
}Changes
Changed in 3 of the 6 revisions of this API.624
- ▲
removed the required property
batch_config/cache_read_input_token/basefrom the response with the200statusresponse-required-property-removed
- ▲
removed the required property
batch_config/cache_read_input_token/multiplierfrom the response with the200statusresponse-required-property-removed
- ▲
removed the required property
batch_config/request_token/basefrom the response with the200statusresponse-required-property-removed
- ▲
removed the required property
batch_config/request_token/multiplierfrom the response with the200statusresponse-required-property-removed
- ▲
removed the required property
batch_config/response_token/basefrom the response with the200statusresponse-required-property-removed
- ▲
removed the required property
batch_config/response_token/multiplierfrom the response with the200statusresponse-required-property-removed
- ●
removed the optional property
batch_config/cache_write_input_tokenfrom the response with the200statusresponse-optional-property-removed
- ○
added the optional property
batch_config/cache_read_input_token/priceto the response with the200statusresponse-optional-property-added
- ○
added the optional property
batch_config/request_token/priceto the response with the200statusresponse-optional-property-added
- ○
added the optional property
batch_config/response_token/priceto the response with the200statusresponse-optional-property-added
This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog
- ▲
- ○
added the optional property
batch_configto the response with the200statusresponse-optional-property-added
- ○
- ●
removed the optional property
batch_configfrom the response with the200statusresponse-optional-property-removed
This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog
- ●