Skip to main content

Premium overview

The repository includes a premium purchase flow used to sell the template itself. This flow is separate from your app’s billing system.

What the premium flow does

  • Creates a one-time Stripe Checkout session
  • Verifies payment on success
  • Collects GitHub email, GitHub username, and Twitter handle
  • Stores purchase data in premium_purchase

Key files

  • src/app/api/premium-purchase/*
  • src/app/api/webhooks/premium-purchase/route.ts
  • src/app/actions/premium-purchase.ts
  • src/lib/premium-purchase.ts
  • src/lib/premium-purchase/hooks.ts
If you are a premium customer using the template, the purchase flow can be removed from your product after you are done selling the template itself.