Shopify flow - Check if sales channel is active?

Topic summary

Main issue: Set a Shopify Flow condition to detect whether a product is published to a specific sales channel (especially Online Store), or to detect if it’s unpublished everywhere.

Key constraint: Flow currently doesn’t support passing arguments to fields (e.g., product.publishedOnPublication<publication_id>). Native “Check if published to Online Store” isn’t available yet; arguments support is being developed (focused on metafields).

Workarounds discussed:

  • Inspect product.resourcePublications.nodes (GraphQL) and match the publication id/name (e.g., “Online Store”), then check isPublished.
  • Use aggregate fields to detect no channels: product.publicationsCount or product.availablePublicationCount = 0.

Practical automation shared (inventory-driven):

  • Trigger on inventory change. If inventory = 0, unpublish from all channels. If inventory > 0, check how many channels it’s published on; if fewer than a target (e.g., 6), publish to all. Note: channel counts depend on each store’s setup.

Outcomes/caveats:

  • The inventory-based Flow is the closest functional solution reported and works immediately upon saving stock changes. Ensure listings are correct before adding stock.

Status: No simple one-field condition for “Online Store published” until Flow supports field arguments; workarounds remain necessary.

Summarized with AI on December 30. AI used: gpt-5.

Hi,

How can i setup a condition that lets me check if a product is online on specific sales channels?

I’d be trying something like:

1 Like

It did not work at all…

Another guess?

It should just be a super simple condition: “Check if product is published to sales channel: (Online store)”

The “easy” field requires an argument, which is something that Flow doesn’t support yet, but is building. It would be product.publishedOnPublication<publication_id>.

Flow is working on allowing arguments for some fields, but is focused on metafields currently.

I think the workaround above is the way, but not sure what’s not working for you.

Here’s data I see for my test shop, which should help you build a condition

"data": {
    "product": {
      "id": "gid://shopify/Product/8006388645910",
      "resourcePublications": {
        "nodes": [
          {
            "publication": {
              "id": "gid://shopify/Publication/62653235222",
              "name": "Point of Sale"
            },
            "isPublished": true
          },

made the workaround, but it seems like it is not registering “Online Store” as sales channel quite correct.

Maybe you know what i do wrong here?

you aren’t using the fields I showed above.

Sorry i used the other guys sollution, i think i am quite close here, but maybe you can see what is not correct.

i want it to make the “Condition” true, if sales channel: Online store, is not actiavted

I seem to have the sollution if it is just “online store” that is not published but others are.

But i need something that also can trigger, if no sales channels is online.

Maybe just check product.publicationsCount or product.availablePublicationCount = 0

Don’t know if this’ll help you any but it’s what I’m using. It triggers whenever any stock is added/removed, if stock has went to 0 id unpublishs from all channels, if stock is over 0 it checks how many channels its publish on and if it’s 6 it does nothing and if less than 6 it publishs it everywhere.

Our channels are 6 becuse of Online Store =1, Shop =1, Google & Youtbe =2 and Facebook & Instagram =2, yous may be different.

Thanks man, i think this is what comes closest to a functional sollution, compared to all the other stuff.

No worries mate, hope it helped. I should of mentioned that the method above means that when you add stock and hit save it lists straight away so you need to make sure your listings are correct before adding stock, this works for us but may not be perfect for others.