Know where your LLM money goes

Zero-config cost & quality monitor for indie AI builders. One-line SDK, local dashboard, per-feature and per-customer attribution — and a budget kill-switch so an agent loop can never surprise you with the bill.

$ npx tokenwatch-sdk serve
“We budgeted $4k/month for our agent. Three weeks later the bill was $11.2k — an uncapped recursive loop. The provider dashboard told us what we spent, not where.”
— the story every AI builder has heard (or lived). TokenWatch exists so it never happens to you.

Up and running in two minutes

STEP 1

Start the dashboard

npx tokenwatch-sdk serve — one process, SQLite, no Docker, no Postgres, no ClickHouse. Your data stays on your machine.

STEP 2

Wrap your client

One line for OpenAI or Anthropic, TypeScript or Python. No proxy in your request path — telemetry ships async on the side.

STEP 3

See everything

Cost by model, feature, and customer. Latency, error rates, daily trends. Set a budget — get webhook alerts at 80% and a hard stop at 100%.

import { wrapAnthropic, init } from 'tokenwatch-sdk';

const claude = wrapAnthropic(new Anthropic(), { feature: 'summarize', customerId: 'acme' });
init({ enforceBudget: true });  // over budget → BudgetExceededError, not a bigger bill

// That's it. Every call (streaming included) is now tracked:
// model, tokens, cost, latency, errors — attributed to features and customers.

Why TokenWatch

🚫 No proxy, no risk

Your requests go straight to the provider. A monitoring tool should never be a single point of failure in your request path.

💸 Margin attribution

Cost per feature and per customer — know which features lose money and which customers are profitable, not just the total.

🛑 Budget kill-switch

Set a monthly budget. At 80% your webhook fires; at 100% wrapped calls throw instead of spending. Agents can't out-loop you.

📦 Actually self-hostable

One process and a SQLite file. No ClickHouse + Postgres + Redis + S3 stack just to see your own spend.

🐍 TS and Python

Both SDKs included. The Python SDK has literally zero dependencies — standard library only.

🔓 MIT, no rug-pull

Open source. Flat simple pricing for the upcoming cloud version — never per-seat enterprise games.

The honest comparison

TokenWatchHeliconeLangfuseEnterprise APMs
Actively developedmaintenance mode✓ (ClickHouse-owned)
Request pathno proxyproxy or asyncasyncasync
Self-host stack1 process + SQLiteheavyClickHouse+PG+Redis+S3n/a
Budget kill-switch✓ built-inlimitsalerts only
Built forsolo devs / small teamsteamsteamsenterprises

Helicone entered maintenance mode after its acquisition (March 2026). Langfuse is excellent for enterprise tracing — TokenWatch is for the rest of us.

Stop guessing what your AI costs

$ npx tokenwatch-sdk serve