Description
Add Stripe billing to the Optia backend so users can upgrade to Pro and manage their subscription. Reuse the same Stripe account already used for Bridleway.
Flow: the extension opens a Stripe Checkout session (hosted page) for the Pro plan; on success Stripe fires a webhook to the backend, which creates or updates the customer and issues a license. A Stripe customer portal link lets users manage or cancel.
Why
Chrome Web Store Payments no longer exists, so Stripe is how money actually changes hands. Checkout and the customer portal are hosted by Stripe, which keeps us out of scope for handling raw card data and offloads SCA, tax, and dunning. Webhooks are the source of truth for entitlement changes so the system stays correct even if the user closes the tab mid-flow.
Acceptance Criteria
Resources
Description
Add Stripe billing to the Optia backend so users can upgrade to Pro and manage their subscription. Reuse the same Stripe account already used for Bridleway.
Flow: the extension opens a Stripe Checkout session (hosted page) for the Pro plan; on success Stripe fires a webhook to the backend, which creates or updates the customer and issues a license. A Stripe customer portal link lets users manage or cancel.
Why
Chrome Web Store Payments no longer exists, so Stripe is how money actually changes hands. Checkout and the customer portal are hosted by Stripe, which keeps us out of scope for handling raw card data and offloads SCA, tax, and dunning. Webhooks are the source of truth for entitlement changes so the system stays correct even if the user closes the tab mid-flow.
Acceptance Criteria
POST /billing/checkoutcreates a Checkout session and returns the URLPOST /billing/portalreturns a customer portal URL for an existing customerPOST /billing/webhookverifies the Stripe signature and handlescheckout.session.completed,customer.subscription.updated, andcustomer.subscription.deletedResources