#mink4501_webhooks
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. Thank you for your patience!
âąď¸ We automatically close idle threads, which makes them read-only. Make sure you stick around to chat in realtime! If this thread is closed and you have another question you'll need to start a new thread.
đ 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/1214453724504924211
đ Have more to share? You can add more detail below, including code, screenshots, videos, etc.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- mink4501_webhooks, 21 hours ago, 49 messages
- mink4501_webhooks, 3 days ago, 23 messages
- mink4501_webhooks, 4 days ago, 6 messages
- mink4501_webhooks, 4 days ago, 13 messages
- mink4501_webhooks, 5 days ago, 5 messages
- mink4501_webhooks, 6 days ago, 9 messages
Hi.
Q1. What is the difference between invoice and payment intent in Stripe?
Q2. I was wondering if the payment identifier in a subscription is the invoice id or the payment intent id.
In the system I'm building, I want to store the PG's payment identifier internally, which I'll use to store the payment when the payment is completed and to look up and process the payment based on that identifier when the payment is refunded.
Q3. when the checkout.session.completed event arrives, the payment_intent_id in the event is null. is it okay to use the invoiceid to look up the invoice to get the payment identifier and use the payment intent id from there?
Could you elaborate your question here?
Please see this
Okie I see
Q1: They are ... totally different thing. Invoice will have PaymentIntent, but PaymentIntent could not belong to any Invoice
Q2: You would want to save both, but theoritically you can retrieve the Invoice inside the Subscription, and retrieve the PaymentIntent inside an Invoice
Q3: Can you provide the exact event id you are looking at evt_xxx ?
Q3: Can you provide the exact event id you are looking at evt_xxx ?
=> evt_1OqrHLH7t32LLKQxJYwr4YGw
here it is
Ah okie. This is a subscription mode Checkout Session
When you have the event, you can all Retrieve Checkout Session and expand invoice.payment_intent,
or alternatively call Retrieve Invoice and expand payment_intent
Q1: They are ... totally different thing. Invoice will have PaymentIntent, but PaymentIntent could not belong to any Invoice
Q2: You would want to save both, but theoritically you can retrieve the Invoice inside the Subscription, and retrieve the PaymentIntent inside an Invoice
=> That said, I guess I could use payment_intent_id as the payment identifier in a normal PG, is that correct?
When I used the free trial period, an invoice is created, but it doesn't seem to create a payment intent because no payment actually occurred.
From this, it looks like the id of the payment intent is the payment identifier.
Is my thinking correct?
If so, I would like to recognize the ID of the payment intent as the payment identifier and store it inside our system, not the ID of the invoice.
Yeah that sounds good to me too