#vickygiyst

1 messages · Page 1 of 1 (latest)

golden baneBOT
subtle tusk
#

Hi
Stripe Checkout Session is just for creating Subscription, not for managing it. You should rather use Customer Portal. In order to let your customers manage their subscriptions and PaymentMethods:
https://stripe.com/docs/customer-management

harsh vector
#

please check this

#

i m referring to return To Giyst LTD

#

i have used this to come to this page

#

const portalSession = await stripe.billingPortal.sessions.create({
customer: checkoutSession.customer,
return_url: returnUrl,
});

subtle tusk
harsh vector
#

is it not correct?

subtle tusk
#

Yes it should be, can you share that customer portal id ?

harsh vector
#

test_YWNjdF8xTWpPeHhLR0UwWWxKMDE1LF9OZWx4azdDTlk3Z0lrVTlpdUhBQUFPVUhibERmaWNp0100nBNz3AYJ

#

is that what you are asking?

subtle tusk
#

yes let me check

#

When I click on return I'm sent back to this page

#

isn't this what you are expecting ?

harsh vector
#

no

#

this should come, after a successful payment

#

i m using this billing url under account section of the user

#

i just save the checkout session id, and used it later for a user when they click on manage subscription button

subtle tusk
harsh vector
#

this is fine if the user clicks on this just after the payment is successful. but i m not using this at the moment

#

i m using at different page

#

and at different time(not just after the payment)

#

suppose the user has made the purchase and after few days they again login and wants to manage their subscription. in this case if they return to success url, that would not be the apprpriate page to see

subtle tusk
harsh vector
#

does this url same as payment success url?

subtle tusk
#

no this is the default returning url of the Customer portal

subtle tusk
harsh vector
#

great, this helps

subtle tusk
#

Cool!

golden baneBOT