CodeIssuesPull RequestsActionsSecurityInsights
✨ AI
More
Settings

fix(billing): the subscription repair queue is operator-only; customers meter on their quota #5451

Merged⚡ AI-generatedXSccantynz wants to mergefix/repair-queue-owner-onlymainopened 24d ago
ccantynzcommented 24d ago

Any write-access user clicking "Fix this for me" was queuing work the owner-subscription agent would implement — free AI labor billed to the owner.

  • Health repair route: agent-queue path requires isSiteAdmin(); customers always take createSpecPR, where assertAiQuota meters spend against their own AI budget.
  • Spec-failure queue: POST 403s for non-admins; the queue button renders for site admins only.
  • /drain-repairs protocol: owner-authored-only hard rule — a customer-authored ai:repair issue gets a redirect-to-billing comment, never an implementation (the label alone is not authorization).

tsc clean; spec/health suites green (6 pre-existing deploy-gate failures, identical on main).

🤖 Generated with Claude Code

ccantynzAI Reviewcommented 24d ago

AI Triage

(no summary)

Priority: medium Risk area: mixed

Suggested labels: (no label suggestions) Suggested reviewers: (no reviewer suggestions)

Suggestions only — nothing has been applied. The PR author stays in control.

gluecron[bot]🤖 botAI Reviewcommented 24d ago

AI review unavailable

The platform's AI balance is exhausted, so AI generation is temporarily unavailable. Nothing was lost. You can queue this as a repair for the internal agent from the repository's Health page, or try again once the balance is restored. The PR is otherwise unchanged.

Cross-repo impact

See what breaks downstream if this PR merges.

Analyze →
⮌ Merged

This pull request was merged into main.

c comment · e edit title · m merge · a approve · r request changes · ? shortcuts