#sushbhat
1 messages · Page 1 of 1 (latest)
There's no API to get the receipt PDF link directly, but there's a receipt_url property on a charge object (https://stripe.com/docs/api/charges/object#charge_object-receipt_url) for your customer to view the receipt
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
ok where will this url be sent in?
after ui does confirmPayment do we get this info?
The receipt_url is a property on a charge object, you can get it from 1st item of the PaymentIntent's charges list.
btw you can't access the PaymentIntent's charges list from frontend, you need to retrieve the PaymentIntent object from backend with your secret key.
oh ok, got it
Another question I had on test cards
when we select a test card from one country and select a different country from the drop down the payment still goes through fine.. is it expected?
I need more context, where do you select the card and where is the drop down?
country dropdown is on the payment element injected by stripe.js
and test cards I am getting from the stripe doc,
for eg: I select a test card for India and then enter the card details on payment element and select US as region payment still goes through fine
OK, card country is ignored when using a test card. As long as the number is correct, and exp date is a future date, the payment will just go through
ok thanks