#nero_1113_49637

1 messages · Page 1 of 1 (latest)

wary leafBOT
#

Hello! We'll be with you shortly. 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.

swift quest
#

Hi, let me help you with this.

#

What type of webhook events are you listening to?

swift quest
#

If you're listening to invoice.paid event, an Invoice generated by a Subscription will have a subscription parameter set to the Subscription ID. One-time Invoices will have null.

#

If it's payment_intent.succeeded then you have to check the invoice property of the event payload. It's empty if you used the PaymentIntent.create() method, and set to an Invoice ID if it was created by an Invoice. Then you have to fetch the actual Invoice and check if it's attached to a Subscription.