Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

How to subscribe to webhook topics that provide App Subscription events information?

How to subscribe to webhook topics that provide App Subscription events information?

lifesight_user
Shopify Partner
3 0 0

I would require to be able to receive the event specified on this page: https://shopify.dev/api/partner/2022-04/objects/SubscriptionChargeAccepted

How can I subscribe to the following webhook topics:  SubscriptionChargeAccepted, SubscriptionChargeActivated, SubscriptionChargeActivated objects? 

 

Since these events are app-specific and not store-specific, what would the endpoint be?

Reply 1 (1)

dewyze
Shopify Staff
10 1 1

Hello! Thanks for the question.

 

This forum section is typically for question regarding subscriptions and selling plans (customers purchasing subscriptions). But I did reach out to our app developer team and got this response:

 

It looks like they want to make a Partner API client and use that to query for app events. You can make a partner API client in the partner org settings:

https://partners.shopify.com/{orgId}/settings/partner_api_clients 

 

Once you’ve made a client there is a link to a graphql client you can test withthe query would look something like this
app(id: {some app id}) {
    events(first: 100) {
      edges {
        node {
          type
          occurredAt
          shop
          app {
            name
          }
        }
      }
    }
  }

They said that the app events were not webhooks, so you would need to fetch it each time. The existing webhooks that have "subscription" in the name reference the recurring purchase type of subscription, not for app development. Apologies if that caused any confusion.

To learn more visit the Shopify Help Center or the Community Blog.