Commerce & plans
THE HCLAB supports tiered content access and one-time learning path purchases via Stripe.
Access levels
| Plan | Typical access |
|---|---|
| Free | Public and free-tier content |
| Subscriber | Newsletter-tier gated resources |
| Premium | Subscription content + paths (when subscribed) |
| Enterprise | Highest tier resources |
Plan is stored on User.plan and enforced in download gates, resource access checks, and UI badges.
Stripe flows
| Flow | Entry | Webhook |
|---|---|---|
| Premium subscription | /pricing or account upgrade |
/api/stripe/webhook |
| Learning path purchase | Path detail page checkout | Same webhook |
Checkout creates or reuses a Stripe customer ID on the user record.
Admin visibility
Member plans are editable at /admin/users. Platform analytics on /admin shows subscription counts and path revenue when data exists.
Configuration
Required Stripe environment variables are listed under Production environment. Use test keys locally and live keys in production.
Member account
/account shows current plan badge, upgrade button for free users, purchase history, certifications, and path progress.