Maple-GPT-Software / excel-gpt-3-monorepo

https://excel-gpt-monorepo.vercel.app
1 stars 0 forks source link

[webapp][feature] - Subscription #21

Open tomzacchia opened 1 year ago

tomzacchia commented 1 year ago

Definition of Ready

@ChengCalvin I believe the best way to make sure that we can fetch stripe information for the authenticated user is to do the following

I think this is a good way to make sure that you get valid data when you reach out to Stripe from the client. We can still wrap the entire application with an AuthProvider for firebase to do stuff like hide the menu and show a "Go to dashboard" button when the user is authenticated and they are looking at the landing pages. 1) If the user signs up for a free account, you can redirect them to the portion of the app where we expect them to have Stripe profile and queries to Stripe will return data. 2) If the user signs up for premium they'll be re-directed to a checkout UI hosted by Stripe. On success they'll be redirected them to the portion of the app where we expect them to have Stripe profile and queries to Stripe will return data. 3) If the user goes to the checkout session and abandons, goes back to our app this is when they don't have an account with stripe because of the abandoned session. In this case the context that takes care of stripe subscription can reach out to our server and we'll create a free trial for users that abandon checkout.

Definition of Done

Describe what it takes for this task to be considered as done. Be as specific as possible. Anyone should be able to pick up this task and know exactly what to do.

Additional Notes

Add any relevant details here.

tomzacchia commented 1 year ago

@ChengCalvin I made this figjam https://www.figma.com/file/EiDra0LCulkKltsNKXDvaL/Sign-Up-User-Flow?node-id=0%3A1&t=3rjDIhZPLJNVY0FA-0