Developer API

CostMyAI API Documentation

Programmatic access to the CostMyAI pricing database. Query current prices, historical price events, model benchmarks, and provider metadata for 311+ AI models via REST API. JSON responses. API key authentication.

Available endpoints

  • GET /api/v1/models — full model catalog with current pricing, context windows, and benchmark scores
  • GET /api/v1/models/:id — single model detail with pricing, benchmarks, and provider metadata
  • GET /api/v1/providers — provider list with operational status and last sync timestamps
  • GET /api/v1/price-events — historical price change events with timestamps, old price, and new price

Authentication and rate limits

API keys are available on the Growth and Enterprise plans. Pass your key in the Authorization: Bearer header. Rate limits: 100 requests per minute on Growth, 1,000 per minute on Enterprise.

Get API access