See what your AI coding agents really consume.

Tokens, cost and an estimate of CO₂ — company-wide, across Claude Code, GitHub Copilot and OpenCode. Open source, self-hosted, and unable to attribute usage to a person.

The dashboard's overview page: company-wide totals for tokens, CO₂ and cost, a trend chart by provider and a comparison table.

Why

Coding agents run all day. The tools themselves don't say what that costs.

Subscriptions hide the tokens

Seat-based plans expose no usage API. The counts exist only inside each developer's CLI.

Cost and carbon, one pipeline

Both derive from the same raw token counts — so one system should produce both.

Visibility without surveillance

The dashboard counts installations and aggregates usage. It cannot attribute a token to a person or a team.

How it works

Plugins push, the backend prices, the frontend shows. Nothing polls a provider.

1 · Capture

A plugin hooks into the CLI's lifecycle and reads the token usage the tool already knows: input, output, cache write, cache read — per model.

2 · Queue & forward

Entries go to a local queue first and are sent in batches when the backend is reachable. Off-VPN, nothing is lost and nothing blocks.

3 · Ingest & enrich

The backend deduplicates, applies per-model prices and CO₂ factors, and stores counts, cost and CO₂ in Postgres.

4 · Visualise

The static frontend renders totals, comparisons and time series for any date range — in German or English.

Sent: token counts, session id, timestamp, a random installation UUID. Never sent: prompt content, usernames, hostnames.

Components

Five repositories. They meet at the backend's ingest and query endpoints.

Frontend

Frontend

Static Astro site with React islands: company-wide KPIs, provider comparison, history charts and one page per provider, broken down by model and token type. German and English.

  • Astro 7
  • React 18
  • Recharts
  • TypeScript
  • nginx
Backend

Backend

Kotlin/Ktor service with Postgres. Plugins push raw token counts; the backend deduplicates, applies prices and CO₂ factors and serves aggregates and time series. It never polls a provider.

  • Kotlin
  • Ktor
  • PostgreSQL
  • Gradle
  • Kotest
Plugin · Claude

Claude Code plugin

Registers hooks in Claude Code, reads the transcript after every turn and queues one entry per model — subagents included. Ships a statusline with session tokens, sync state and price.

  • Node ≥ 18
  • zero dependencies
  • Claude Code hooks
Plugin · Copilot

GitHub Copilot CLI plugin

Copilot CLI only exposes totals in its session.shutdown event, so the plugin captures per session in a detached process that outlives Copilot, and sweeps for missed sessions on the next start.

  • Node ≥ 18
  • zero dependencies
  • Copilot CLI hooks
Plugin · OpenCode

OpenCode plugin

A single dependency-free file loaded in-process by OpenCode. Subscribes to message.updated and session.idle and queues one entry per finalized assistant message.

  • Node ≥ 18 / Bun
  • zero dependencies
  • OpenCode plugin API
Want to track another tool? The ingest contract.

A plugin is anything that POSTs this shape. Ingest routes are unversioned and additive-only, so a plugin written today keeps working. New providers also need a price table and, ideally, a CO₂ factor on the backend side.

POST /api/usage/ingest/<provider>
{
  "user_id": "<random uuid, generated once per installation>",
  "prompts": [{
    "timestamp":  "2026-09-15T10:00:00.000Z",
    "session_id": "…",
    "model":      "claude-sonnet-5",
    "usage": { "input_tokens": 1234, "output_tokens": 567,
               "cache_creation_input_tokens": 0, "cache_read_input_tokens": 890 }
  }]
}

The dashboard

A company-wide overview and one page per provider. Screenshots show demo data.

Three KPI cards: Total tokens 338.6 M, Total CO₂ 64.5 kg, Total cost 5,130.24 $.

Company-wide totals

Tokens, estimated CO₂ and estimated cost for the selected period. Total tokens counts input and output only — cache tokens are shown separately so they don't drown the trend.

Stacked bar chart of daily token usage, one colour per provider, with weekends shaded.

Trend by provider

One stacked bar per day or week, one segment per provider. Switch the view to CO₂, cost or active installations; toggle providers; weekends are shaded.

The date range picker, open, with groups To date, Previous period, Last days and a custom range.

Shareable time ranges

Presets like "this month" or "last 30 days" live in the URL, so a bookmarked "this week" still means this week next Monday.

Plugin panel showing 40 active plugin installations and a copyable npx install command.

Installations and the install command

Each provider page shows how many plugin installations reported in the last four weeks, and the install command with the operator's URLs filled in. Installations are counted, never people.

Stacked bars per model family and a table breaking down tokens, CO₂ and cost per model.

By model and token type

Input, output, cache write and cache read per model family — where cache reads become visible in their true proportion.

A terminal with the two-line statusline: model, session tokens, a synced dot, context window bar, plugin version, up/down tokens and $0.03.

Feedback in the terminal

The plugins install a statusline: model, session tokens, sync state, context window and an estimated price. Illustrative rendering of the real output.

The FAQ page with a table of contents and answers on provider coverage, total tokens and CO₂ calculation.

Methodology in the FAQ

Every estimate carries an asterisk that links here: how CO₂ is derived, how costs are computed, what data exists about installations.

Concepts

The numbers, and what stands behind them. Details live in the repositories.

Four token types

Input, output, cache write, cache read. All four are stored; only input and output form the headline total, because cache reads outnumber everything else by an order of magnitude.

Cost in USD

A price table per model and token type, applied at ingest. Estimates for trend visibility, not billing. Copilot is approximated at one cent per AI unit.

CO₂: 840 g per million output-equivalent tokens

Derived from Jegham et al. for Claude 3.7 Sonnet; input weighted at 1/20 of output, cache reads at 1 %. An order-of-magnitude estimate, not GHG accounting. Derivation

Anonymous by construction

Usage data carries no identifier at all. The only UUID is random, per installation, never derived from a name, and used solely to count active installations. No prompt content, no authentication, VPN only. Security model

Store-and-forward

Plugins queue locally and flush in batches at session boundaries. Transient errors retry; entries expire after 30 days. Plugin ADRs

Self-update, explicit trust

Once a day each plugin fetches its updater from a URL the operator chose at install time. HTTPS only, no redirects. Decision log

Get started

Someone operates the backend and frontend. Every developer installs a plugin.

Operators

Deploy backend and frontend

  1. Run the backend (Kotlin/Ktor, Dockerfile provided) with a Postgres. Seed prices and CO₂ factors.
  2. Build the frontend with your PUBLIC_* variables; serve it and route /api to the backend on the same origin.
  3. Put both behind your VPN — there is no authentication by design.
Developers

Install a plugin

Copy the command from your dashboard's provider page, or adapt one of these. Both flags are required.

Claude Code plugin
npx git+https://github.com/neuland/tokendashboard-plugin-claude.git install \
  --api-base-url https://tokendashboard.example.com \
  --repo-raw-base-url https://raw.githubusercontent.com/neuland/tokendashboard-plugin-claude/main
GitHub Copilot CLI plugin
npx git+https://github.com/neuland/tokendashboard-plugin-copilot.git install \
  --api-base-url https://tokendashboard.example.com \
  --repo-raw-base-url https://raw.githubusercontent.com/neuland/tokendashboard-plugin-copilot/main
OpenCode plugin
npx --allow-git=all git+https://github.com/neuland/tokendashboard-plugin-opencode.git install \
  --api-base-url https://tokendashboard.example.com \
  --repo-raw-base-url https://raw.githubusercontent.com/neuland/tokendashboard-plugin-opencode/main

Contribute

Bugs and features go to the repository they concern.