{
  "markdown": "<p align=\"center\">\n  <img src=\"docs/src/assets/tokencost-logo.png\" width=\"120\" />\n</p>\n<h1 align=\"center\">tokencost</h1>\n<p align=\"center\">\n  <a href=\"https://www.npmjs.com/package/tokencost-dev\"><img src=\"https://img.shields.io/npm/v/tokencost-dev\" alt=\"npm version\" /></a>\n  <a href=\"https://www.npmjs.com/package/tokencost-dev\"><img src=\"https://img.shields.io/npm/dm/tokencost-dev\" alt=\"npm downloads\" /></a>\n  <a href=\"https://github.com/atriumn/tokencost-dev/actions/workflows/ci.yml\"><img src=\"https://img.shields.io/github/actions/workflow/status/atriumn/tokencost-dev/ci.yml?label=CI\" alt=\"CI status\" /></a>\n  <a href=\"LICENSE\"><img src=\"https://img.shields.io/npm/l/tokencost-dev\" alt=\"license\" /></a>\n</p>\n<p align=\"center\">Ask your AI assistant \"how much does GPT-4o cost?\" — get an instant, accurate answer.</p>\n\n---\n\n<p align=\"center\">\n  <img src=\"tokencost-dev.gif\" alt=\"tokencost demo in Claude Code\" width=\"700\" />\n</p>\n\n## Install in 30 seconds\n\n**Claude Code:**\n\n```bash\nclaude mcp add tokencost-dev -- npx -y tokencost-dev\n```\n\nThen ask: *\"How much would 1M input tokens cost on claude-sonnet-4-5?\"*\n\n**Cursor** (`.cursor/mcp.json`):\n\n```json\n{\n  \"mcpServers\": {\n    \"tokencost-dev\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"tokencost-dev\"]\n    }\n  }\n}\n```\n\nNo API keys. No accounts. No configuration files. Pricing data is fetched from the [LiteLLM community registry](https://github.com/BerriAI/litellm) and cached locally for 24 hours.\n\n## Tools\n\n### `get_model_details`\nLook up pricing, context window, and capabilities for any model. Fuzzy matching means `\"sonnet 4.5\"` works just as well as `\"claude-sonnet-4-5-20250514\"`.\n\n```\n> \"What are Claude Sonnet 4.5's pricing and capabilities?\"\n\nModel: claude-sonnet-4-5\nProvider: anthropic | Mode: chat\n\nPricing (per 1M tokens):\n  Input:  $3.00\n  Output: $15.00\n\nContext Window:\n  Max Input:  200K\n  Max Output: 8K\n\nCapabilities: vision, function_calling, parallel_function_calling\n```\n\n### `calculate_estimate`\nEstimate cost for a given number of input and output tokens.\n\n```\n> \"How much will 1000 input + 500 output tokens cost on Claude Sonnet 4.5?\"\n\nCost Estimate for claude-sonnet-4-5\n\n  Input:  1K tokens × $3.00/1M  = $0.003000\n  Output: 500 tokens × $15.00/1M = $0.007500\n  ─────────────────────────────\n  Total:  $0.0105\n```\n\n### `compare_models`\nFind the most cost-effective models matching your requirements.\n\n```\n> \"What are the cheapest OpenAI chat models?\"\n\nTop 2 most cost-effective models (provider: openai) (mode: chat):\n\n1. gpt-4o-mini\n   Provider: openai | Mode: chat\n   Input: $0.15/1M | Output: $0.60/1M\n   Context: 128K in / 16K out\n\n2. gpt-4o\n   Provider: openai | Mode: chat\n   Input: $5.00/1M | Output: $15.00/1M\n   Context: 128K in / 16K out\n```\n\n### `refresh_prices`\nForce re-fetch pricing data from the LiteLLM registry (cache is refreshed automatically every 24h).\n\n## Docs\n\nFull documentation at [tokencost.dev](https://tokencost.dev)\n\n## License\n\nMIT\n",
  "bytes": 2959,
  "sha": "df5d9cd64d96f73adb699fdf830dec1b01199c0c1b315220bd5d5764a949e22a",
  "repo_slug": "atriumn/tokencost-dev",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_jeff_atriumn_tokencost_dev_7b2b3b6b/readme"
}