Add stripe integration
This commit is contained in:
@@ -10,6 +10,7 @@ FlockPal is a Dockerized TypeScript app for tracking flock health with a clean,
|
||||
- Multi-flock model with `standard` household and `rescue` modes
|
||||
- Shared flock member management for both households and rescues
|
||||
- Separate per-flock billing plan foundation with `rescue_free`, `household_basic`, `household_plus`, and `household_macaw`
|
||||
- Stripe-ready per-flock billing identifiers so one account can manage multiple paid flock subscriptions
|
||||
- Bird profiles with name, tag ID, and species
|
||||
- Bird DOB and gotcha day fields
|
||||
- Daily weight recordings
|
||||
@@ -94,8 +95,23 @@ Set these if you want magic links delivered by email instead of logged as a prev
|
||||
- `SMTP_FROM_EMAIL`
|
||||
- `SMTP_FROM_NAME`
|
||||
|
||||
## Stripe billing environment
|
||||
|
||||
Set these when the Stripe Checkout, Customer Portal, and webhook flow is enabled:
|
||||
|
||||
- `STRIPE_SECRET_KEY`
|
||||
- `STRIPE_WEBHOOK_SECRET`
|
||||
- `STRIPE_PRICE_HOUSEHOLD_CONURE`
|
||||
- `STRIPE_PRICE_HOUSEHOLD_INDIANRINGNECK`
|
||||
- `STRIPE_PRICE_HOUSEHOLD_MACAW`
|
||||
- `STRIPE_CHECKOUT_SUCCESS_URL`
|
||||
- `STRIPE_CHECKOUT_CANCEL_URL`
|
||||
- `STRIPE_PORTAL_RETURN_URL`
|
||||
|
||||
## Notes for monetization and security
|
||||
|
||||
This starter now includes the account and flock foundation for monetization, but it still needs production-grade session hardening, invitation verification, billing integration, audit logging, and background reminder delivery before launch.
|
||||
This starter now includes the account and flock foundation for monetization, but it still needs production-grade session hardening, invitation verification, Stripe checkout/customer portal/webhook flows, audit logging, and background reminder delivery before launch.
|
||||
|
||||
Stripe billing should be attached to `workspaces`, not `users`. Each flock has its own billing plan, subscription status, Stripe customer ID, and Stripe subscription ID, which lets one person own multiple household flocks with separate subscriptions while rescue flocks can stay on the free rescue path.
|
||||
|
||||
For account design, `standard` vs `rescue` is best treated as a flock type, not as a user role. If paid plans are added later, a separate `admin account mode` is usually less flexible than flock roles such as `owner`, `assistant`, `caregiver`, and `viewer`. That lets the same underlying account system work for both households and rescues without splitting product logic into unrelated account classes.
|
||||
|
||||
Reference in New Issue
Block a user