#clint_webhooks
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ We'll be here soon! We typically respond in a few minutes, but in some cases we might need a bit more time (e.g., server's busy, you've got a complex question, etc.).
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can 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/1256156713115979777
๐ Have more to share? Add details, code, screenshots, videos, etc. below.
hi! when you handle the checkout.session.completed webhook you can look at session->payment_intent->latest_charge->payment_method_details
Thank you, I have completed the entire payment process of Checkout and now wish to obtain the card information through a Webhook after a successful payment. However, I couldn't find it in the returned information.
Can the checkout.session.completed Webhook obtain payment card information, such as card type, card number, etc.?
when you recieve the webhook you can make an API call to get that information yes, using the path I described.
payment_method_id
I checked the document address you provided me, and upon testing, it did not return card information; only billing information was obtained.
How can I obtain the card number and card type?
However, the information for payment_method_details was not returned.
if you're having difficulties please share the exact code you wrote
This is the information returned by the checkout.session.completed Webhook, and there is no payment_method_details information.
yep, indeed
How can I query payment_method_details information?
I said session->payment_intent->latest_charge->payment_method_details
How do I obtain and query the chargeid for a charge?
that means you need to look at the ID of the payment_intent in that payload and call https://docs.stripe.com/api/payment_intents/retrieve , and you can use expand:["latest_charge"] https://stripe.com/docs/expand/