Yes, the payment.updated and payment.created events will fire every time a payment is made for a subscription. Also an invoices.paymet.made event will trigger as well.
For a seller view of subscriptions and payments you can see them in the Square Sandbox Seller Dashboard. Also if you want example webhook payloads you can send test events from the webhooks subscription.
Thank you for answering me.
In webhook payload there is event_id, data.id and data.order_id. Could you tell me which one will stay the same for all subsequent payments and which will be unique to individual payment? I wasn’t able to find answer for it myself, thanks.
For initial payment I have order_id generated with payment link so I can compare it to a webhook data but how can I identify future payments? I need some common id to link first payment to future recurring payments. How else can I process recurring payments webhooks?
You’ll use the subscription_id track any further payments associated to the subscription. The invoices events will have the subscription_id associated to the payments.
With initial subscription payment I only get order.* and payment.* webhooks and I’ve subscribed to all webhook events possible. There is no subscription_id in those events data. How can I get it?
I didn’t get any subscription.* event for any of sandbox subscription payments. I’ve subscribed to all events and created requests according to the article I’ve linked before. What can be wrong?
ID: sandbox-sq0idb-8qp-xR55PsSdUt_41lxx6g
Currently url for webhook subscription is incorrect, there was the same result with correct one and there is no subscription.* event in webhook logs.
Oh, are these subscriptions created with CreatePaymentLink? If so this is a gap in Sandbox. They won’t trigger a subscription webhook. However they do trigger them in production. We’re constantly working to improve our features based on feedback like this, so I’ll be sure to share your request to the API product team.
Yes, it’s created with CreatePaymentLink. I can delay integration for a few weeks but I would prefer it to be fully functional in dev mode. Can I get notified when it’s solved?