#adi_api
1 messages ¡ Page 1 of 1 (latest)
đ 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/1412508525988544572
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi, if you pass an amount greated than the charge on https://docs.stripe.com/api/checkout/sessions/create?api-version=2025-08-27.basil#create_checkout_session-payment_intent_data-transfer_data, you should get an error.
In your case, you should just create the payment without passing the transfer data for the $17 (including the discount). Then, you can create a separate Tranfers, https://docs.stripe.com/api/transfers/create?api-version=2025-04-30.preview for the entire $20.
Just to confirm if I understood it correctly. I should not pass that transfer data at all and do that in the background after the checkout. So the customer pays 17, and then i transfer from my account to the connected account the rest? Is there no other way?
That is correct
You also specify the version, is there a newer version? And if is, does that support what I want with all in 1 go or that's not intended like that at all what I tried to implement?
Yeah, upon testing it I do get 'The Checkout Sessions's transfer_amount cannot be greater than the total amount.' error
No, that does not matter
I see, ok. I will try that out to see if it fits my needs. Thank you