#zhansf_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.
⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always 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/1266274596403806232
📝 Have more to share? Add more details, code, screenshots, videos, etc. below.
🗣️ Sorry, English only
We can only provide help in English on Discord, but you can contact Stripe support for help in other languages. 🌐 Translate this message
hi?
hello! As mentioned, we can only help in English on this channel. Can you describe what you need help with in English?
How to get the checkout/session metadata from the invoice.paid webhook
https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-subscription_data-metadata - If you pass the metadata into subscription_data.metadata (this is for mode="subscription") when creating the Checkout Session, the Subscription will contain that metadata, and so will the Invoice Line Items : https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-metadata
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Let me try
Wait a minute, I have another question. If mode=subscribe, there is an invoice.paid event. If it is Recharge, there is no invoice.paid event. How do I know that the payment is successful?
what does Recharge mean? Do you mean mode=payment in a Checkout Session?
Recharge means Top-up
sure, but how are you creating a Top-up? What's the API endpoint you are using? I won't know / understand your internal terms. You need to explain to me with reference to Stripe products and APIs
You can check this product-id:prod_QJc980FvliPCFh
those are one-time Prices under that Product from what I'm seeing. So again, can you confirm that you're using mode=payment with Checkout Sessions with those Prices?
yes
https://docs.stripe.com/api/checkout/sessions/create#create_checkout_session-payment_intent_data-metadata - If you pass in the metadata into payment_intent_data.metadata (this is for mode="payment") - the PaymentIntent will contain that metadata : https://docs.stripe.com/api/checkout/sessions/create#create_checkout_session-payment_intent_data-metadata
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Which event should I use to know that the customer has made a purchase? And I want to know the lookup_key of the product price in the webhook event.
Yīnwèi wǒ fāxiàn mode=payment hǎoxiàng méiyǒu invoice.Paid shìjiàn
38 / 5,000
Because I found that mode=payment does not seem to have an invoice.paid event
mode=payment does not have a invoice.paid event by default. You can set it such that the Checkout Session creates an Invoice for mode=payment with https://docs.stripe.com/api/checkout/sessions/create#create_checkout_session-invoice_creation-enabled so that you can also listen for the invoice.paid event for it. You can also pass in the relevant metadata in https://docs.stripe.com/api/checkout/sessions/create#create_checkout_session-invoice_creation-invoice_data-metadata
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.