SuperAPI AI Directory

llm-prices

Zero-dependency Python CLI and library for comparing LLM API pricing across 21 providers (123+ models). Query pricing, calculate costs, find the cheapest option for a given token budget. Install: pip install git+https://github.com/benbencodes/llm-prices.git or `brew install benbencodes/tap/llm-pri

Open website

About this tool

Purpose

llm-prices is a zero-dependency Python CLI tool and library, mainly used to query and compare the costs of major LLM APIs. It requires no API key, and the pricing data is built into the package and updated with each release. The material states that it covers 277 models and 47 providers, including OpenAI, Anthropic, Google, Mistral, Groq, Cohere, DeepSeek, xAI, Together AI, Fireworks AI, Perplexity, Cerebras, SambaNova, Amazon Bedrock, AI21 Labs, DeepInfra, Lambda AI, Novita AI, Nebius AI, Moonshot AI (Kimi K2), Hyperbolic, Crusoe, Qwen/Alibaba Cloud, Microsoft Azure, Inflection AI, NVIDIA NIM, NousResearch, ZhipuAI, MiniMax, IBM, ByteDance, Baidu, Xiaomi, Z.AI, Tencent, Arcee AI, InclusionAI, StepFun, Reka, Morph, Perceptron.

Main capabilities

  • List all models;
  • Export as a Markdown table (for README, docs, PR);
  • Export as CSV (for spreadsheets, databases);
  • Calculate the cost of a specific call;
  • Provide JSON output for use in scripts;
  • Compare models side by side;
  • Find the cheapest model based on workload;
  • Filter a single provider or get a Markdown table;
  • Calculate how many calls fit within a budget;
  • View recently added models;
  • Can be used as a Python library.

Usage

The material provides the following installation methods:

  • pipx (recommended, global installation, no venv needed):
pipx install llm-prices
  • Homebrew(macOS/Linux):
brew install benbencodes/tap/llm-prices
  • pip install:
pip install git+https://github.com/benbencodes/llm-prices.git

Requires Python 3.8+, with no other dependencies.

MCP server

llm-prices has a built-in MCP server, allowing you to query pricing data directly in any MCP-compatible AI assistant. The material mentions that it can be installed with MCP support, and gives the Claude Desktop configuration method: on macOS, add it to ~/Library/Application Support/Claude/claude_desktop_config.json; uvx can also be used. The material lists the "Available MCP tools" heading, but does not provide specific tool names and parameter details.

Use cases

Suitable for developers who need to quickly query or compare the pricing of multiple LLM APIs, for example when doing cost estimation, model selection, budget planning, or generating documentation or tables. It can also be used to call pricing data directly in an MCP-compatible AI assistant.

Limitations

The material clearly states that pricing is built into the package with each release and may lag behind provider price changes, so it is recommended to check each provider's sources for the latest prices. PRs to update llm_prices/data.pyare welcome, and please cite the source. The material lists the URLs of some providers' pricing sources. This project is built and maintained by an AI agent, donations go to the human operator's wallet, there is no promised return, it is simply a tip.