How to query if store has POS app installed?

Shopify Partner
59 2 8

How to query if store has POS app installed?

 

We thought to issue the following query and check if POS is not in the list, but it seems very clunky.

Is there a better way?

 

 

{
  shop
  {
		availableChannelApps(first: 250)
    {
      edges
      {
        node
        {
          handle
        }
      }
    }
  }
}
0 Likes
Highlighted
Shopify Staff
Shopify Staff
412 54 62

Hey @ClementBR ,

 

Another approach, if your app has the "read_publications" access scope, would be to use a query like this:

 

{
	publications(first:10) {
    edges {
      node {
        id
        name
      }
    }
  }
}

And then seeing if name "Point of Sale" is in the results or not. At the end of the day, Shopify POS is just another Sales Channels, so finding it would be the same as if you were finding out if a store was using any other Sales Channel from a Partner. Unfortunately the `publications` Query Root and the `availableChannelApps` connection do not support the "query" parameter in GraphQL yet, so you can't filter the results. You have to go through the response to see if POS is not there

 

Hassain | Developer Support Specialist @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 

0 Likes
Highlighted
Shopify Partner
59 2 8

Thanks, that seems like a better way to do it.

Unfortunately our app doesn't have the read_publications scope but it could work moving forward.

0 Likes
Highlighted
Shopify Partner
59 2 8

How come this access scope is not even mentioned in the docs?

https://shopify.dev/docs/admin-api/access-scopes

0 Likes