Skip to content
Back to search

aicost

AI-Cost-CLI & MCP (aicost-mcp)

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today

Check it deeper on your machine

It has changed since its scan on 21 Nov 2026.

As a Claude Code plugin, install it and then ask Claude Code:

/plugin marketplace add keithmackay/mackayi/plugin install scanskillsafety@mackayiDo a deep scan of https://github.com/ufhouck/aicost with scanskillsafety

Or from a terminal, clone it and run it:

git clone https://github.com/keithmackay/scanskillsafety-skill ~/.claude/skills/scanskillsafetynode ~/.claude/skills/scanskillsafety/cli.cjs --deep 'https://github.com/ufhouck/aicost'

It checks the exact commit: every file, its packages against OSV (api.osv.dev), how it compares with this page's scan (findsafeskills.com receives the repository's address), and, if you agree, Claude reading every file with your own Claude subscription. It never runs the code.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/ufhouck--aicost/badge.svg)](/listings/ufhouck--aicost)

HTML

<a href="/listings/ufhouck--aicost"><img src="/api/listings/ufhouck--aicost/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

MCP Server (`npx` — Recommended for Claude Desktop, Cursor, Windsurf, VS Code)

Add to your MCP configuration (`claude_desktop_config.json` or `.cursor/mcp.json`):

{
  "mcpServers": {
    "aicost": {
      "command": "npx",
      "args": ["-y", "aicost-mcp"]
    }
  }
}

Python CLI (`pip` / `uv`)

pip install -U aicost-cli

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 170 lines
  1. # AI-Cost-CLI & MCP (`aicost-mcp`)
  2. [![PyPI](https://img.shields.io/pypi/v/aicost-cli.svg)](https://pypi.org/project/aicost-cli/)
  3. [![npm](https://img.shields.io/npm/v/aicost-mcp.svg)](https://www.npmjs.com/package/aicost-mcp)
  4. [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
  5. [![Python 3.9+](https://img.shields.io/badge/Python-3.9+-blue.svg)](https://www.python.org/downloads/)
  6. [![MCP Registry](https://img.shields.io/badge/MCP-Registry-green.svg)](https://registry.modelcontextprotocol.io)
  7. A terminal-based AI API cost calculator, monthly workload budget estimator, recommender, and **Model Context Protocol (MCP)** server. Covers **60+ curated multimodal models** plus **470+ live models** dynamically, compares Direct providers vs. Aggregators/Gateways, factors in prompt caching and Batch API discounts, and converts across **200+ currencies**.
  8. <!-- mcp-name: io.github.ufhouck/aicost-cli -->
  9. ## Preview: Direct vs. Aggregator Comparison
  10. Compare the effective cost of using frontier models directly vs. through gateways like **OpenRouter**, including platform fees, context windows, and prompt-caching rates.
  11. ```text
  12. Comparison: claude-sonnet-5.5 vs openrouter/claude-sonnet-5.5
  13. ┏━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
  14. ┃ Attribute ┃ claude-sonnet-5.5 ┃ openrouter/claude-sonnet-5.5 ┃
  15. ┡━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
  16. │ Provider │ Anthropic │ OpenRouter │
  17. ├────────────────────┼─────────────────────────┼────────────────────────────────┤
  18. │ Source │ Direct │ Aggregator │
  19. ├────────────────────┼─────────────────────────┼────────────────────────────────┤
  20. │ Platform Fee │ 0.0% │ 5.5% │
  21. ├────────────────────┼─────────────────────────┼────────────────────────────────┤
  22. │ Context Window │ 1M │ 1M │
  23. ├────────────────────┼─────────────────────────┼────────────────────────────────┤
  24. │ Input Cost │ 2.0000 USD (/1M) │ 2.1100 USD (/1M) │
  25. ├────────────────────┼─────────────────────────┼────────────────────────────────┤
  26. │ Cached Input │ 0.1000 USD (/1M) │ 0.1055 USD (/1M) │
  27. ├────────────────────┼─────────────────────────┼────────────────────────────────┤
  28. │ Output / Unit Cost │ 10.0000 USD (/1M) │ 10.5500 USD (/1M) │
  29. └────────────────────┴─────────────────────────┴────────────────────────────────┘
  30. ```
  31. ## Supported Models (Curated Frontier + 470+ Live Catalog)
  32. ### Flagship Text & Reasoning Models
  33. | Model | Provider | Input/1M | Cached/1M | Output/1M | Context |
  34. |-------|----------|----------|-----------|-----------|---------|
  35. | GPT-6.2 Astra (`gpt-6.2-astra`) | OpenAI | $8.00 | $0.40 | $40.00 | 1.05M |
  36. | GPT-6.2 Sol (`gpt-6.2-sol`) | OpenAI | $2.00 | $0.10 | $10.00 | 1.05M |
  37. | GPT-6.1 Terra (`gpt-6.1-terra`) | OpenAI | $1.00 | $0.05 | $5.00 | 1.05M |
  38. | GPT-6 Luna (`gpt-6-luna`) | OpenAI | $0.10 | $0.01 | $0.50 | 1.05M |
  39. | o3 / o3-Pro (`o3`, `o3-pro`) | OpenAI | $2.00 / $20 | $0.50 / - | $8.00 / $80 | 200K |
  40. | Claude Fable 5.2 (`claude-fable-5.2`) | Anthropic | $8.00 | $0.20 | $40.00 | 1M |
  41. | Claude Opus 5.5 (`claude-opus-5.5`) | Anthropic | $4.00 | $0.20 | $20.00 | 1M |
  42. | Claude Sonnet 5.5 (`claude-sonnet-5.5`) | Anthropic | $2.00 | $0.10 | $10.00 | 1M |
  43. | Claude Haiku 5.5 (`claude-haiku-5.5`) | Anthropic | $0.10 | $0.01 | $0.50 | 1M |
  44. | Gemini 4 Neon (`gemini-4-neon`) | Google | $3.00 | $0.15 | $15.00 | 1M |
  45. | Gemini 4 Carbon / Argon (`gemini-4-carbon`) | Google | $2.00 | $0.10 | $10.00 | 1M |
  46. | Gemini 4 Hydrogen (`gemini-4-hydrogen`) | Google | $1.50 | $0.075 | $7.50 | 1M |
  47. | Gemini 3.8 Flash (`gemini-3.8-flash`) | Google | $0.825 | $0.0825 | $4.125 | 1M |
  48. | Grok 4.7 (`grok-4.7`) | xAI | $2.00 | $0.50 | $6.00 | 500K |
  49. | DeepSeek V4 Pro (`deepseek-v4-pro`) | DeepSeek | $0.90 | $0.20 | $1.50 | 1M |
  50. | DeepSeek V4.1 Flash (`deepseek-v4.1-flash`) | DeepSeek | $0.15 | $0.003 | $0.60 | 1M |
  51. | Qwen 4 Max (`qwen4-max`) | Alibaba Qwen | $1.425 | - | $4.275 | 1M |
  52. | Llama 4 Maverick / Scout (`llama-4-maverick`) | Meta | $0.35 / $0.10 | $0.17 / - | $1.00 / $0.30 | 512K / 1.3M |
  53. | Mistral Large 4 (`mistral-large-4`) | Mistral | $0.70 | - | $2.10 | 1M |
  54. | Kimi K3.1 Pro (`kimi-k3.1-pro`) | Moonshot | $0.253 | - | $8.80 | 1M |
  55. | MiniMax M3.1 Flash (`minimax-m3.1-flash`) | MiniMax | $0.075 | - | $0.30 | 1M |
  56. ### Image, Video & Audio Models
  57. | Model | Provider | Price | Billing Unit | Type |
  58. |-------|----------|-------|--------------|------|
  59. | GPT-Image 2.6 Sunburst (`gpt-image-2.6-sunburst`) | OpenAI | $0.08 | per image | Image |
  60. | GPT-Image 2.6 Flare (`gpt-image-2.6-flare`) | OpenAI | $0.025 | per image | Image |
  61. | Imagen 4 Fast / Standard / Ultra | Google | $0.02 / $0.04 / $0.06 | per image | Image |
  62. | Flux 1.1 Pro / Ultra | Black Forest Labs | $0.04 / $0.06 | per image | Image |
  63. | Veo 3.1 Fast / Standard (`veo-3.1`) | Google | $0.10 / $0.40 | per second | Video |
  64. | Lyria 3 Clip / Pro (`lyria-3-pro`) | Google | $0.04 / $0.08 | per clip / song | Music |
  65. | Whisper (`whisper`) | OpenAI | $0.006 | per minute | Speech-to-Text |
  66. | TTS Standard / HD | OpenAI | $15 / $30 | per 1M chars | Text-to-Speech |
  67. > Browse curated models via `aicost list`, include previous-gen models with `--include-legacy`, or query **all 470+ live models** with `aicost list --live`!
  68. ## Features
  69. - **Always-Current Hybrid Catalog:** Weekly automated discovery of newly released flagship models + on-demand fallback to **470+ live OpenRouter models** (never hits "Model not found" on new releases).
  70. - **Dynamic Direct vs. Aggregator Math:** Prefix *any* model with `openrouter/` (e.g., `openrouter/gpt-6.2-astra`) to instantly compare Direct billing vs. OpenRouter's 5.5% fee.
  71. - **Prompt Caching & Batch Discounts:** First-class support for `--cached-input` read rates (up to 95% savings) and `--batch` API discounts.
  72. - **Monthly Workload Estimator (`aicost estimate`):** Forecast daily, 30-day, and annual API spend from expected request traffic.
  73. - **200+ Currencies with Offline Resilience:** Powered by a 3-tier CDN currency engine (`TRY`, `EUR`, `GBP`, `AZN`, `AED`, `JPY`, etc.) with 24-hour local cache.
  74. - **Dual MCP Server Ecosystem (`npx` & `uvx`):** Zero-install MCP integration via npm (`aicost-mcp`) or PyPI (`aicost-cli`).
  75. ## Installation
  76. ### MCP Server (`npx` — Recommended for Claude Desktop, Cursor, Windsurf, VS Code)
  77. Add to your MCP configuration (`claude_desktop_config.json` or `.cursor/mcp.json`):
  78. ```json
  79. {
  80. "mcpServers": {
  81. "aicost": {
  82. "command": "npx",
  83. "args": ["-y", "aicost-mcp"]
  84. }
  85. }
  86. }
  87. ```
  88. ### Python CLI (`pip` / `uv`)
  89. ```bash
  90. pip install -U aicost-cli
  91. ```
  92. ## CLI Usage
  93. ### List & Filter Models
  94. ```bash
  95. aicost list --currency TRY
  96. aicost list --provider Anthropic
  97. aicost list --live --provider Cohere
  98. aicost list --tag agentic --sort input --json
  99. ```
  100. ### Calculate Cost (with Caching & Batch Support)
  101. ```bash
  102. # Frontier model with prompt caching
  103. aicost calc claude-opus-5.5 --input 200000 --cached-input 800000 --output 100000 --currency USD
  104. # Batch API (-50%) calculation
  105. aicost calc gpt-6.2-astra --input 1000000 --output 500000 --batch
  106. # Dynamic OpenRouter aggregator fee breakdown on ANY model
  107. aicost calc openrouter/gemini-4-carbon --input 1000000 --output 500000 --currency TRY
  108. # Multimodal unit calculation (seconds, minutes, images)
  109. aicost calc veo-3.1 --units 8 --currency USD
  110. ```
  111. ### Project Monthly Workload Budget
  112. ```bash
  113. aicost estimate claude-sonnet-5.5 --requests-per-day 2500 --input 1800 --output 450 --currency USD
  114. ```
  115. ### Compare 2+ Models Side-by-Side
  116. ```bash
  117. aicost compare gpt-6.2-astra claude-opus-5.5 gemini-4-neon grok-4.7 --currency USD
  118. ```
  119. ### Get Task Recommendations
  120. ```bash
  121. aicost recommend "fast cheap agentic coding" --max-cost 1.0 --currency USD
  122. ```
  123. ### Sync Latest Pricing, Live 470+ Catalog & Exchange Rates
  124. ```bash
  125. aicost sync
  126. ```
  127. ## Registries
  128. - [PyPI — `aicost-cli`](https://pypi.org/project/aicost-cli/)
  129. - [npm — `aicost-mcp`](https://www.npmjs.com/package/aicost-mcp)
  130. - [MCP Registry](https://registry.modelcontextprotocol.io) — `io.github.ufhouck/aicost-cli`
  131. - [Smithery.ai](https://smithery.ai/skills/ufhouck-oskt/aicost)
  132. - [Skills.sh](https://skills.sh/ufhouck/aicost/aicost)
  133. ## Community & Governance
  134. - [Contributing Guide](CONTRIBUTING.md)
  135. - [Code of Conduct](CODE_OF_CONDUCT.md)
  136. - [Security Policy](SECURITY.md)
  137. - [Privacy Policy](PRIVACY.md)
  138. - [Changelog](CHANGELOG.md)
  139. ## License
  140. MIT — see [LICENSE](LICENSE) for details. Developed by [Ufuk Aydın](https://ufukaydin.com).

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.