budget

A command that reports usage of Vercel and Railway deployment quotas over a rolling 24-hour period. Deployments are published versions of an application or website.

In plain words
What is it for?
Use it to inspect recent marketing and application deployments, check whether the Railway command-line tool is available, and review Railway usage.
Why use it?
It helps teams see how much deployment capacity they have used, estimate when limits may reset, and plan further releases.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/marcusgoll/spec-flow/budget
Clone the repo
git clone --depth 1 https://github.com/marcusgoll/Spec-Flow

Made for: Claude Code.

Per session 25 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,295 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00025 $0.03295
Opus 5 $0.00013 $0.01648
Sonnet 5 $0.00005 $0.00659
Haiku 4.5 $0.00003 $0.00330

Measured 3d ago against content hash b44821e332e2, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

budget scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/deployment/budget.md · 372 lines

How it starts

The opening of the file, as written. The whole thing — 372 lines — stays where its author put it; the contents beside it link to each section on GitHub.

24h timestamp (GNU): !date --version 2>/dev/null | grep -q GNU && date -d '24 hours ago' -Iseconds || echo "N/A"

24h timestamp (BSD): !date --version 2>/dev/null | grep -q GNU || date -u -v-24H -Iseconds 2>/dev/null || echo "N/A"

Marketing deployments (24h): !SINCE=$(date --version 2>/dev/null | grep -q GNU && date -d '24 hours ago' -Iseconds || date -u -v-24H -Iseconds); gh run list --workflow=deploy-staging.yml --created="$SINCE" --json conclusion --jq 'length' 2>/dev/null || echo "0"

App deployments (24h): !SINCE=$(date --version 2>/dev/null | grep -q GNU && date -d '24 hours ago' -Iseconds || date -u -v-24H -Iseconds); gh run list --workflow=deploy-app-staging.yml --created="$SINCE" --json conclusion --jq 'length' 2>/dev/null || echo "0"

Railway CLI installed: !command -v railway >/dev/null 2>&1 && echo "✅ Yes" || echo "❌ No"

Railway usage: !railway usage 2>/dev/null || echo "Railway CLI not available"

Oldest deployment timestamp: !SINCE=$(date --version 2>/dev/null | grep -q GNU && date -d '24 hours ago' -Iseconds || date -u -v-24H -Iseconds); gh run list --workflow=deploy-staging.yml --created="$SINCE" --limit 1 --json createdAt --jq '.[0].createdAt' 2>/dev/null || echo ""

Recent deployment statuses: !SINCE=$(date --version 2>/dev/null | grep -q GNU && date -d '24 hours ago' -Iseconds || date -u -v-24H -Iseconds); gh run list --workflow=deploy-staging.yml --created="$SINCE" --limit 10 --json conclusion,createdAt,displayTitle --jq '.[] | "\(.conclusion) - \(.displayTitle) - \(.createdAt)"' 2>/dev/null || echo ""

What it does:

  • Counts Vercel deployments in 24h rolling window (Marketing + App)
  • Checks Railway compute usage (if CLI available)
  • Calculates quota reset time from oldest deployment
  • Predicts remaining quota after next deployment
  • Provides deployment strategy based on quota status
  • Analyzes recent deployment failure rate

Operating constraints:

  • Vercel Limit — 100 deployments per 24 hours (rolling window)
  • Warning Threshold — Alert when < 20 remaining
  • Critical Threshold — Block when < 10 remaining
  • Read-Only — Never modifies quotas or settings
  • Non-Blocking — Always returns, even on errors

Dependencies:

  • GitHub CLI installed and authenticated (gh auth login)
  • Railway CLI optional (for compute usage tracking)
  • Access to deploy-staging.yml and deploy-app-staging.yml workflows
  1. Calculate total Vercel deployments:

    • Sum Marketing + App deployments from context
    • Calculate remaining: 100 - total_used
    • Determine status:
      • normal: >= 20 remaining (✅)
      • warning: 10-19 remaining (⚠️)
      • critical: < 10 remaining (🚨)
  2. Display Vercel quota section:

    ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
    Deployment Budget (24h rolling)
    ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
    
    Vercel Deployments:
    
      Marketing (staging): {count}
      App (staging): {count}
    
      Total used: {total} / 100
      Remaining: {remaining}
    
      {status_emoji} {STATUS} - {remaining} deployments {available/remaining/left}
    
  3. Display Railway usage (if CLI available):

    • If Railway CLI installed, show usage output
    • If not installed, show installation instructions:
      ⚠️  Railway CLI not installed
         Install: npm install -g @railway/cli
      
  4. Calculate quota reset time:

    • Extract oldest deployment timestamp from context
    • Calculate reset time (24 hours from oldest)
    • Calculate time remaining until reset (hours and minutes)
    • Display:
      ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
      Quota Reset Information
      ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
      
      Oldest deployment: {timestamp}
      Quota resets at: {reset_time}
      Time to reset: {hours}h {minutes}m
      

Read the full file on GitHub · 372 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 372 lines · 25 tokens per session scan A b44821e332e2

Subscribe to this mod's changes

budget is a command published in the GitHub repository marcusgoll/Spec-Flow (91 stars, last pushed 4mo ago), licensed MIT. It adds 25 tokens to every session and 3,295 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.