Skip to content

A budget per developer

This recipe gives every developer on a team their own monthly spending limit for coding agents, with a team-wide cap on top, so one person’s long session cannot use the whole team’s budget.

On Keys, create a virtual key for each developer, named after them, with two tags:

dev=alice, team=platform

Each developer puts their key in their tool’s settings, for example ANTHROPIC_AUTH_TOKEN for Claude Code. Keys are shown once, so send each key to its owner through your password manager, not chat.

On Budgets, add one budget per developer key:

  • Scope: Virtual key, the developer’s key
  • Period: Month
  • Soft limit: for example $150
  • Hard limit: for example $200

At the soft limit you get an alert; at the hard limit that developer’s requests are blocked until the 1st of next month, 00:00 UTC, or until you raise the limit.

Add one more budget with scope Tag team=platform, period Month, and a hard limit for the whole team, for example $1,500. Every request from a key tagged team=platform counts toward it, so the team stops at its total even if each developer is under their own limit.

  • Keys shows each key’s spend this month.
  • Activity, grouped by agent or filtered by tag in Logs, shows where the money goes.
  • Alerts tells you when a developer reaches their soft limit.

Revoke their key on the Keys page. Their tools stop working on the next request, and nobody else’s key changes.

A runnable copy of this setup, with a .env.example, is in the OpenPike examples repo.