List providers
The public endpoint returns adata array. Retrieve it first so you can copy the exact provider_id instead of guessing from a brand name.
provider_id for subsequent API calls. Display labels are for people: the live response uses provider_name, while the checked-in API schema currently calls that label name. Base integrations on the stable identifier rather than either display-name field.
Pull rates for one provider
Passprovider_id to price search without a model query to browse that provider’s entries. This request asks for the first 100 OpenAI rows and sorts them by model ID.
meta.total_pages with the same filter. If you only need one entry, add model_id using the exact identifier from a returned row. Use q instead when you want a family of related model names. Keep dated versions as separate rows unless you have verified that they represent the same model you intend to deploy.
Build a readable price table
For a text-model table, show the model ID, provider ID, input USD per million tokens, and output USD per million tokens. Compute the last two columns aspricing.prompt * 1_000_000 and pricing.completion * 1_000_000. Retain the original per-token values for calculations; rounding a small rate for display can materially change a large-volume estimate.
Mark null pricing as unavailable and retain any explanatory message. Include cache rates in separate columns if caching matters to your workload. A zero in an unrelated dimension does not establish that the provider supports that feature without charge.
The resulting table helps you spot rate differences, but it does not rank the cost of completing a task. A model with lower input pricing can be more expensive when it produces long answers. To compare hosts for one model, use your expected token mix in Find the cheapest provider. To compare different models, follow the fixed-usage comparison, then measure actual usage in your application.