#evancowan_best-practices

1 messages ¡ Page 1 of 1 (latest)

cyan leafBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1237927749222535219

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

round badger
#

to be clear, the customer always uses the same email address, but each time we get a new customer in stripe. This makes it really hard for the end user to know what subscriptions they have.

echo geode
#

Looks like you should use Checkout Sessions API, which allow you to specify a customer so that you can avoid creasting duplicate customer objects.

round badger
#

yes, but that would involve me using server side code.. so far we are low / no code for this setup

#

whats the logic for having payment links creating multiple customers for the same email? seems like a werid idea

echo geode
round badger
#

oh thats fantastic! that might solve it for me

#

hmmm. actually spoke too soon.

#

i tried it as a client - i bought a subscription to product 1. tried to buy subscription to product 2. it redirected me to the portal as expected. where i could only cancel (i have turned off switch plan, as i have more than 10 products, and it wont show more than 10) so i cancelled, then i went back and tried to buy product 2 again, and it again sent me to the customer portal, where i could see my cancelled product 1, but i could not buy product 2.

echo geode
#

What's the customer ID?

round badger
#

cus_Q4Tcf1Wg0qohEC

#

(in test mode)

echo geode
#

I can see that the use still have an active subscription sub_1PEKfRCTf5VZYOMNzcxnvQ1V

#

Ok, the cancel option in the billing portal will only set the susbcription's cancel_at_period_end to true, which will schedule the subscription to be cancelled a the end of the period, but not cancel it immeidately.

#

Can you cancel the subscription from your Stripe Dashboard and try the payment link again?

round badger
#

oh ok. maybe i should set cancel immediately and pro-rate rather than end at end of billing cycle?

echo geode
#

Yes you can try that

round badger
#

this setup is still not ideal. if you have a subscription and get redirected to the customer portal, all you can do is cancel it. then it just leaves you on that page

#

is there any way of getting around the 10 products max on the allow users to change plan in the customer portal?

echo geode
#

No, there's no way to adjust the limit

round badger
#

I have also tried setting a URL here, but when I cancel an existing plan, it just sits on the customer portal. I would expect a redirection to my site?