#theryanmark

1 messages · Page 1 of 1 (latest)

obsidian fjordBOT
cloud shoal
split verge
#

I was looking at that.
So here is what I am thinking let me know if its no good:
collect user credentials => store in DB table temporarily => Send Stripe Checkout URL to client => User Checks out => once checkout.session.completed hits webhook move user credentials to active status in DB => send email to User that account is active

cloud shoal
#

Yep that sounds reasonable

#

And if you had a landing / thank you page after Checkout, the other option I mentioned would let you go retrieve that Session by ID to get details about whether it was successful etc

split verge
#

Got it. is there a web hook event list somewhere? or is there an checkout.session.declined and checkout.session.canceled event?

#

nvm i just found it.

#

☝️ incase someone else reads this

#

So I was thinking there should be a hook for payment failure and cancel just to clear out the database of failed and canceled attempts

#

checkout.session.expired probably the best for both?

cloud shoal
#

Yea depends on exactly the case you're trying to cover (eg, not finishing Checkout vs an async payment failure after they finish checkout)