api-cost

api-cost is a Claude Code mod by Fabax that shows what each request, the session and the billing month would cost at Claude API list prices, read from the transcripts.

Updated 2026-11-30

What is api-cost?

api-cost is a Claude Code mod by Fabax that shows what each request, the session and the billing month would cost at Claude API list prices, read from the transcripts. It is listed under Cost & usage and has no public popularity data yet.

TypeClaude code mod
AuthorFabax
RepositoryFabax/claude-mod-api-cost
Popularityno public popularity data yet
CategoryCost & usage
SecurityHigh risk (56/100)
Rank#5,888 of 9,397 Claude Code mods; #1,084 in Cost & usage
Last commit2026-11-30
Hooks8 events
Seesevery prompt
Draws onAbovePrompt, CommandOutput

Is api-cost safe to install?

api-cost scores 56/100 on the MCPMods security check: High risk. Things to review: sends data over the network; starts processes outside the sandbox; watches every prompt or event. It passed 3 of 8 checks.

Mod footprints come from claude plugin validate, which lists every event a mod hooks and every API call it makes without running it.

CheckResult
Sends data over the networkReview
Starts processes outside the sandboxReview
Writes no files or configPass
Doesn't read environment variablesPass
Watches every prompt or eventReview
Doesn't drive ClaudePass
Validator reported problemsNote
No license detectedNote

API calls in its code

CallWhat it means
$.clock.now
$.clock.sleep
$.command.register
$.http.fetchnetwork requests
$.process.runruns processes
$.session.id
$.session.usage
$.state.get
$.state.set
$.store.deletekeeps its own state
$.store.getkeeps its own state
$.store.keyskeeps its own state
$.store.setkeeps its own state
$.ui.resolvedraws interface
$.ui.statusdraws interface
$.ui.toastdraws interface

How do I install api-cost?

  1. Check your Claude Code version. Mods need Claude Code 2.1.287 or later and are on by default.
    claude --version
  2. Read its footprint. This lists every event it hooks and every API call it makes, without running it.
    git clone https://github.com/Fabax/claude-mod-api-cost
    claude plugin validate ./claude-mod-api-cost/.
  3. Install it. Run this in your terminal, then /reload-plugins in an open session.
    claude plugin marketplace add Fabax/claude-mod-api-cost && claude plugin install api-cost@api-cost

Or ask Claude to set it up

Paste this into Claude Code and it installs api-cost for you:

Install the "api-cost" Claude Code mod from https://github.com/Fabax/claude-mod-api-cost. Run claude plugin validate on it first and show me what it can access before you enable it.