Never leave tokens on the table. Track usage across all your AI subscriptions and route requests to the provider with the most headroom.
# Check current usage across all providers
npx @bytespell/model-provider-usage-limits
# Find the best provider for your next request
npx @bytespell/model-provider-usage-limits --route claude-sonnet-4-5Monitor consumption across multiple time windows:
anthropic:
5h: 45% used
7d: 30% used
github-copilot:
30d: 60% usedAutomatically route to the subscription with most available capacity:
github-copilot has most headroom (-15% pace)
- github-copilot: score -15 (pace: -15%)
- anthropic: score 8 (pace: +8%)- Anthropic - Claude Pro / Max
- GitHub - Copilot
- OpenAI - ChatGPT Plus
- Codex
npx @bytespell/model-provider-usage-limits [options]| Option | Description |
|---|---|
--provider <id> |
Query specific provider (anthropic, github-copilot, openai) |
--route <model> |
Pick best provider for a model |
--json |
Output JSON |
--no-cache |
Bypass cache |
npm install @bytespell/model-provider-usage-limitsimport { getUsage } from "@bytespell/model-provider-usage-limits";
// Auto-detect tokens
const results = await getUsage({ autoDetectAuthTokens: true });
// Or explicit tokens
const results = await getUsage({
tokens: { anthropic: "sk-...", "github-copilot": "ghu_..." },
});| Option | Description |
|---|---|
autoDetectAuthTokens |
Read tokens from known sources |
tokens |
Explicit token map (overrides auto-detected) |
bypassCache |
Skip cache |
import {
getUsage,
pickBestProvider,
} from "@bytespell/model-provider-usage-limits";
const results = await getUsage({ autoDetectAuthTokens: true });
const best = pickBestProvider(
{ providerID: "anthropic", modelID: "claude-sonnet-4-5" },
results,
);
// best.providerID = 'github-copilot'
// best.modelID = 'claude-sonnet-4.5'
// best.reason = 'github-copilot has most headroom (-15% pace)'- Add Gemini support
- Add open-code-router plugin to auto-route open-code requests based on current utilization
Want to contribute? We're looking for help with finalizing the open-code-router plugin! See CONTRIBUTING.md
MIT