- Shipped
- April 20, 2026 at 7:43 PM UTC
- Author
- Kamo
- Commit
- 620164f
- PlatformAdminController at /api/billing/platform (class-level @PlatformAdminOnly) - GET /orgs, GET /orgs/{orgId} - POST /orgs/{orgId}/grants, PATCH|DELETE /orgs/{orgId}/grants/{subId} - GET /plans (includes isPublic=false) - GET /events - PlatformAdminService: grant creates COMP SubscriptionRecord, cancels prior active sub, emits SubscriptionEvent **************** 5s idempotency - @PlatformAdminOnly + HandlerInterceptor: allow god-mode-active OR (TeamMember.isOrganizationOwner AND Organization.isTopLevel, re-read from DB) - SubscriptionRenewalScheduler: COMP branch cancels on expiry (COMP_EXPIRED) and never calls Stripe - BillingAdminService: MRR/ARR aggregation excludes paymentMethod=COMP - Long ids exposed as String (CockroachDB unique_rowid precision)