#wangtao-PaymentIntent
1 messages · Page 1 of 1 (latest)
Hi! So you have a PaymentIntent ID, and you want to find the corresponding charge ID?
Yes
I'd like to make a transfer and set the source_id to that charge
Basically I'm building a marketplace, where buyers pay on the site, and then I use the charge ID to transfer a certain amount of money to the seller, but I need to get the charge ID to make sure that the transfer amount would not be greater than the buyer's payment
Got it! If you have a PaymentIntent, you should be able to get the charge like this: payment_inttent.charges.data[0].id
https://stripe.com/docs/api/payment_intents/object#payment_intent_object-charges-data
It can happen when a charge fails.
Hmm, so only when it fails?
Can I assume that with a single payment intent, there should be only one successful charge?