#Lenin
1 messages ยท Page 1 of 1 (latest)
Um don't think there is data.payment_method inside a Checkout Session
what do you want to expand exactly?
๐ taking over for my colleague. Let me catch up.
i'm terribly sorry for the late reply
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
line_items are no longer expandable, instead you should use a separate API call
Bu ti am able to expand via curl
curl https://api.stripe.com/v1/checkout/sessions/cs_test_b1wGlNXhYAc4UzLxZQa0dsQNVR2tPa3vYkSNZYoRHFFB9m0A7DHJb613Vu -u sk_123: -d "expand[]"=line_items -G
it depends on the Stripe-API version
I see here it says for checkout i can expand
is this not updated?
yes I guess so
But we were depending on this property. I need to expand multiple parameters
Do I have to send separate calls for each?
I need to expand shipping_options.shipping_rate, line_items, line_items.data.price.product
and maybe couple more
you can expand all of the properties on the checkout session except line_items
when you retrieve the line_items
you can expand data.price.product
I tried to expand shipping_options, even that I cannot expand
via php client
via curl I am able to do
which version?
the current version is https://stripe.com/docs/upgrades#2022-11-15
how do I get my client to use it?
I am not specifying the version anywhere. Client automagically selects
sorry I need to step away, my colleague will be with you shortly
Hi! I'm taking over from my colleague. Please, give me a moment to catch up.
how do I get my
clientto use it?
You mean the frontend?
No, the php client
the one provided by Stripe
i am using that in my backend server
Oh, you mean the Stripe SDK?
yes
You can override the default version of your Stripe account like this: https://stripe.com/docs/api/versioning
I see ok
Let me try this today
But that still doesnt explain why the shipping_options is also not getting expanded
as per tarzan, it should work as only line_items behaviour got changed in the API
I am not sure exactly. Please try the new version and let us know if it works. If not, we will investigate further.
ok i will try, and update here
Happy to help!