#Henrik Rasmussen-checkout-subscription
1 messages ยท Page 1 of 1 (latest)
Which request times out? What specifically happens from start to finish? (feel free to post a video of what you're seeing too)
Hi @smoky river - thanks for responding.
It is very simple (still) as I call one function for all my checkout sessions.
I pass along the price id and a mode param, which is either "payment" or "subscription".
If I call for a payment the call to createCheckoutSession succeed ut if I call for a subscription it fails.
When it fails the error object is "Timeout while waiting for session response"
I am using still very few param, here is my call
createCheckoutSession(payments, {
mode: modeId,
price: priceId,
collect_shipping_address: true,
success_url: window.location.origin + "?goto=shop",
cancel_url: window.location.origin + "?goto=shop",
shipping_address_collection: {
allowed_countries: ['JP'],
},
})
Does a request ID appear in the logs on the Stripe side? Here's how you can find a request ID: https://support.stripe.com/questions/finding-the-id-for-an-api-request
Find help and support for Stripe. Our support center provides answers on all types of situations, including account information, charges and refunds, and subscriptions information. Get your questions answered and find international support for Stripe.
If not, are you able to do a console.log() after the Checkout Session is created to see what (if anything) is being created?
Ths very helpfull and makes sense. I originally had a subscription in one currency (sek) and now all products are in JPY....
and one customer 2 currencies is a nogo apparently
wonder how I get rid of that problem, starting out in sek was a mistake....
Ahhh, okay. Did you figure out where it was going wrong?
There are a few places a currency could be declared, so I'm unsure what to advise from here without more details
The full error message is:
You cannot combine currencies on a single customer. This customer has had a subscription, coupon, or invoice item with currency sek
That makes sense. You'll have to figure out what currency to present at each given Checkout Session
Not sure if that helps or not, but feel free to reply with any specific questions and I'm happy to assist
I am still not live, still testing. Is there a way I can reset my user, so that sek invoice does not block future purchases which are (for now) all in jpy?
and why can I do purchase in jpy but not subscription?
Did you ever find a request ID for the request that is giving you an error?
I'm curious about this myself, as I didn't think we enforced a single currency on a customer-by-customer basis, but rather I would expect that on the Subscription itself
sorry - here it is
req_N0SMz0CZJr2ofS
Ah, interesting. So I guess it is indeed set on the customer object, but that only applies to recurring products. One-off payments would still be supported in other currencies
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
There's no way to update the currency, so you would have to create a new Customer for the new JPY Subscription
what happens if I delete this customer?
Any subscriptions they have currently active will be cancelled and that Customer object will cease to be usable. So you'd still have to recreate the Customer with the new currency, but you'd just be doing it without the presence of a duplicate Customer
THanks - I do not dare deleting the customer - but I will create a new one and test my code using that one....
It works fine
It got me worried for a bit.
I was unhappy about the error I got back, had it stated the cause, life would have been better
But that is history now ๐
THanks for your help
My pleasure! Glad to assist
Thinking ahead, once I do get to having customers in 2 countries, how to manage which prices to show who?
HI ๐ @smoky river had to step away so I'm taking over. Can you give me a summary of your overall question?
We found out, that subscriptions for a customers should always be in the same currency. This is OK for me for now, as I focus on Japan for now, but what happens when I add another country.
No real question here, just thought on the future ๐
Any good articles about this?
Gotta run, getting late here, I shall revert with these question later
https://stripe.com/docs/invoicing/multiple-currencies is for billing
Which is unfortunately just "don't do that"
Sorry for the delay
thanks anyway