Topics covering webhook creation & management, event handling, Pub/Sub, and Eventbridge, in Shopify apps.
Hi guys, I seting up recurring charge plan in my app, and subscribe app_subscription_update webhook follow docs in https://shopify.dev/docs/apps/billing/subscriptions/recurring-charges-based-on-usage
Now I want to update some value in my app when shopify automatic monthly charge success. How can I capture that event? Is above webhook fired?
If it can fire, what is payload I receive this case.
If not, how can I capture event when shopify interval charge monthly success?
Thanks in advance guys. Happy coding
APP_SUBSCRIPTIONS_UPDATE webhook fires with every subscription status update. It should contain an AppSubscription object. But in my experience the payload contains different data:
admin_graphql_api_id
name
status
admin_graphql_api_shop_id
created_at
updated_at
currency
capped_amount
any solution?
Yes seems like I do have access without the subscription API to this query if I save the store's subscription ID... so I can use the currentPeriodEnd from it
query {
node(id: "gid://shopify/AppSubscription/<subsciption_id>") {
...on AppSubscription {
createdAt
currentPeriodEnd
id
name
status
test
}
}
}