improvement(billing): wire up billing, org, teammates tabs + remove deprecated subscription tab#4887
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
PR SummaryMedium Risk Overview The Billing page now consolidates plan summary, org-aware usage limits, on-demand toggles, 80% usage email notifications, Stripe portal / cancel / restore, and invoice history backed by a new Long-running media tool routes (image, video, STT, Textract) raise Organization / teammates UX drops the old table roster and inline invite card in favor of shared Reviewed by Cursor Bugbot for commit 2c638dc. Configure here. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 2c638dc. Configure here.
Greptile SummaryThis PR wires up the Billing, Organization, and Teammates settings tabs with real data and new UI, and removes the deprecated Subscription tab (redirecting legacy
Confidence Score: 4/5Safe to merge after fixing the missing disabled guard on the "View all in Stripe" button — a one-line change. The billing tab expansion is well-structured and permission checks are applied consistently across every control — except the "View all in Stripe" overflow button, which omits the !canManageBilling guard that every other portal-access control in the same file carries. A non-admin team member who has more than 12 invoices will see an active-looking button and get an error toast on click. Everything else — the new invoices API route, org invite modal, member lists, seat-count split, and abort-signal propagation — looks correct. apps/sim/app/workspace/[workspaceId]/settings/components/billing/billing.tsx — the "View all in Stripe" button at line 624. Important Files Changed
Sequence DiagramsequenceDiagram
participant UI as Billing UI
participant IQ as useInvoices hook
participant IR as /api/billing/invoices
participant Stripe as Stripe API
participant BP as /api/billing/portal
UI->>IQ: fetch invoices (context, orgId)
IQ->>IR: "GET /api/billing/invoices?context=..."
IR->>IR: auth + org-admin check
IR->>Stripe: "invoices.list(customerId, limit=12)"
Stripe-->>IR: invoice list + hasMore
IR-->>IQ: "{ invoices, hasMore }"
IQ-->>UI: render invoice rows
alt "hasMore && canManageBilling"
UI->>BP: POST /api/billing/portal
BP->>Stripe: billingPortal.sessions.create
Stripe-->>BP: "{ url }"
BP-->>UI: redirect to Stripe portal
end
Reviews (2): Last reviewed commit: "address comments" | Re-trigger Greptile |
|
@greptile |

Summary
Wire up billing, org, teammates tabs in settings with new ui/ux
Type of Change
Testing
Tested manually
Checklist