#istcf_webhooks

1 messages ¡ Page 1 of 1 (latest)

humble monolithBOT
#

👋 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/1498639291096760362

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

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.

long talon
#

hi there!

iron glacier
#

hi

long talon
#

payment_intent.processing doesn't hold info for the subscription, so I can't know to which subscription to associate it with.
the PaymentIntent has an Invoice, and the Invoice is linked to a Subscription. so by making a few extra API calls you can get the information you need.

iron glacier
#

where do I see the invoice the payment intent is attached to?

long talon
#

it depends. which API version are you using?

iron glacier
#

2019-11-05

#

@long talon are you there?

long talon
#

no need to ping me, please be patient as I'm helping other developers at the same time.

#

then you should get an invoice property on the PaymentIntent directly.

iron glacier
long talon
#

yes that seems a bit tricky for a daily subscription. because if you don't have a default Payment Method set, then all invoices will fail.

#

can you try setting the default payment method as soon as possible in the flow, so before receveing the payment_succeeded event?

iron glacier
#

how? from where? which event holds that data?

#

is it the payment_intent.processing we spoke about before?

long talon
#

sorry about the delay. yes payment_intent.processing should contain a Payment Method. can you try attaching it to the customer at this stage to see if it works?

iron glacier
#

I'll try. looks like it's the only choice.