#oboxodo
1 messages · Page 1 of 1 (latest)
Hi there. Looking
thanks
Do you have the request id?
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.
Cool thanks
I took a look at the customer object in the request body above and they don't have an address associated with them. You can see this here: https://dashboard.stripe.com/test/customers/cus_NuBYQ3YvhzjNbr
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
So that's why
wait
I know the customer doesn't have an address
but that's not required to create a checkout session as long as we allow the checkout session to update the address with the customer_update.address property set to "auto", which we do
and as I said, this worked yesterday, also with just created customers
with no address
let me try to find an example from last night in the logs...
Found it
Ok I gotcha. Yeah an existing example to compare would be great
Look:
- customer being created:
req_k4XN1qBOCo76tV - immediately after, checkout session for that user being created:
req_TjkwVpRQmB71AE
Both with 200 OK response from Stripe
Hm yeah
Let me ask a colleague what might be going on here
You're just doing what we say to do in the docs here: https://stripe.com/docs/payments/checkout/taxes?tax-calculation=stripe-tax#existing-customers
I suspect Stripe deployed some change since yesterday which caused this behavior change. It looks like if the API couldn't recognize that I AM setting customer_update.address = "auto"
Can you provide an example where you just pass customer_update.address=auto
The second example you shared that succeeded also passed customer_update.shipping=auto
We always pass both. The failing example I passed you first today didnn't include the shipping because I wanted to give you the shortest example possible. But it fails today even passing both. Let me show you. I'll do a new request passing both.
Got it yeah can you share that
Here you have a fresh failed try including both billing and shipping auto settings: req_fPswwBhgm3fEEF
BTW... including "billing_address_collection": "required" or not doesn't change the result.
Ok thanks. Will get back to you when I know more
Thanks. This is a key functionality we need.
By the way... a teammate of mine who is using a separate stripe test account than mine is also experiencing the same problem. The same code stopped working for him in the last ~10 hours.
So this is certainly not affecting my own setup.
Ok my colleague wants to see what would happen if you try the following:
Can they try create a session with cus_NuBYQ3YvhzjNbr and set shipping_address_collection?
You set shipping[address] on creation here: https://dashboard.stripe.com/test/logs/req_KhTjlM57YZgMBN but it's invalid for a US address. But because you're not passing shipping_address_collection, Checkout can't collect a valid address. And we always default to a shipping address for tax calculation when available.
So can you try doing ^ and send the request id?
mmm... not sure I fully understand what you want but I'll try something. Give me a minute.
Just this piece: Can they try create a session with cus_NuBYQ3YvhzjNbr and set shipping_address_collection?
So like replay this request: https://dashboard.stripe.com/test/logs/req_fPswwBhgm3fEEF
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
But add shipping_address_collection
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
I added this:
shipping_address_collection: {
allowed_countries: ["US"]
},
And it worked: https://dashboard.stripe.com/test/logs/req_U4hBQ9DikiNltE
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
but I don't understand why it worked with that today, but it wasn't needed yesterday.
The issue is the requests you have shared aren’t the same. You created Customers with different parameters:
-The creation request for the Customer that doesn’t work with an auto tax session (cus_NuBYQ3YvhzjNbr): https://dashboard.stripe.com/test/logs/req_KhTjlM57YZgMBN
-The creation request for the Customer that did work with an auto tax session (cus_NttZ2ehQhZFhxz): https://dashboard.stripe.com/test/logs/req_k4XN1qBOCo76tV
Because the former has an invalid shipping address for tax calculations, Checkout needs new details. But in the example sessions you've shared upi weren’t passing shipping_address_collection so Checkout can’t collect new details, and as such it just errors as the existing shipping details are incorrect.
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
this solution won't work for us because we don't WANT to ask for a shipping addres when the customer is only purchasing digital goods.
but why did this same code work until yesterday?
did Stripe change something yes or no?
Taking over here. The issue is you provided the shipping parameter when you created cus_NuBYQ3YvhzjNbr
Nothing has changed here, in fact the 2 examples you've shared are totally different and we've outlined why they're broken
Then don't pass shipping when you create your Customers and Checkout will instead use billing address to calculate tax due
oh! so the problem is at the time of creating the CUSTOMER, not the checkout session.
I think I got it. You're saying if the customer does have a shipping address, even if it's incomplete, then the checkout session MUST include the shipping_address_collection property. Am I right?
Yes, exactly. Because you created cus_NuBYQ3YvhzjNbr (here: https://dashboard.stripe.com/test/logs/req_KhTjlM57YZgMBN) with an invalid shipping address, Checkout needs to collect new, valid address details in order to calculate tax (we will always default to a shipping address to calculate tax when available).
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
ok. undeerstood.
If there was no shipping address set on that Customer, then you could just collect a billing address for tax calculation as per: https://stripe.com/docs/tax/checkout#use-addresses-collected-during-checkout-for-taxes