#sarita_21302
1 messages · Page 1 of 1 (latest)
You can use Retrieve Payment Intent API to retrieve the payment details with a given payment_intent: https://stripe.com/docs/api/payment_intents/retrieve
And can I also get a copy of receipt?
You may expand latest_charge, then get the URL of the receipt from latest_charge.receipt_url and download it
- Expand an object: https://stripe.com/docs/api/expanding_objects
receipt_url: https://stripe.com/docs/api/charges/object#charge_object-receipt_url
What if it's a guest customer payment?
For payment intent integration, email will only be sent if receipt_email is set: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-receipt_email
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
We don't want to collect email address before payment but after the payment, if they like to receive a receipt and provide an email address.
can the payment_intend be updated with the email adress and then trigger a receipt?
That's possible. Updating the receipt_email on Payment Intent will send the receipt
Ok, thanks. I'll give it a try.
Please note that email is not sent in test mode and will only be sent in live mode
Does the payment intend needs amount in the format 1000 for $10 ? Is there a helper function to convert 12.12 to 1212 Or do we need to handle it internally
Oh, good do know
Does the payment intend needs amount in the format 1000 for $10 ?
Stripe follows the smallest unit of a currency for the amount: https://stripe.com/docs/currencies
Depending on the currency, the format can be different. For example, the smallest unit of USD is cent. So the amount will be in cents, i.e. 1000 cents = 10 dollars
Is there a helper function to convert 12.12 to 1212 Or do we need to handle it internally
There is no helper function. Your system should handle it internally
Cool
One more question - updating payment intend - will that require any kind of re-confirmation?
Depending on the fields being updated
If the payment has been made sucessfully, updating fields like receipt_email will not require re-confirmation
Thanks