FROM CACHE - en_header

Sales channel visibility via API

Pete10
New Member
1 0 5

HI!

What are my options for altering sales channel visibility for products that I want to "unpublish"? If I go the route of unpublishing it (by putting published_at to null), then it will kill our back links to that product.

Replies 31 (31)
Jamie_D_
Shopify Staff (Retired)
Shopify Staff (Retired)
533 1 107

Hey Pete,

Setting published_at to null will unpublish the product from online store - the product page 404'ing is an intentional side effect of this.

If you're trying to control the visiblity of a product on a channel other than Point of Sale or Online Store, this is not possible via the API at the moment.

If I've missed the mark here, let me know if I can assist further.

Jamie | Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

Thomas47
Shopify Partner
56 0 12

Hi Jamie, 

any update on this topic? I'd like to control custom collection sales channel visiblity for my sales channel app.

Best regards,

Thomas

f2fteststore_Ad
Shopify Partner
7 0 2

Does anyone know of an alternative product that offers this feature, or of a work around? I have found like 10+ threads on this exact issue dating 2 years back with no new replies.

PROMeera
Shopify Partner
14 0 1

We also need to control sales channels via the API. 


Shopify will you add this to your API please? If not why not?

I  have a custom app to list items on my Shopify and I can add all the information I want this way but can't set the visibility on sales channels other than Online and POS. 

Why oh why? 

Shopify is ace
Jaemin_Choi
Shopify Partner
9 0 1

Is it still NOT possible to set the visibility on sales channels other than Online and POS by API call or by any coding like liquid? This must be possible cuz bulk uploading products in csv causes a lot of pain to shop owners like me trying to add sales channels to hundresd or thousands of products one by one!

John227
Excursionist
13 0 6

Bump. We are also looking for this functionality.

Calvin_Ellis
New Member
1 0 1

Any updates?

Bump. We need this as well for a project we are working on.

Jeff_Lange
Shopify Partner
20 0 2

This makes no sense that there is no feature for this. Every time I add a new product (via api) it doesn't automatically add them to all the sales channels I have to click each and every product to enable each sales channel (instagram, facebook) has to be a faster way?!?!?!

jankadlec
Shopify Partner
12 0 0

We are struggling with exactly same issue - the API for controlling product enlistment in custom sales chanel is highly needed..

 

Jan

dev88
Tourist
11 0 6

This is a highly needed feature. Please provide us with a response.

SaschaX
Tourist
6 0 5

Just encountered the same problem 😄

Please add this feature!

OLerch
Shopify Partner
3 0 4

We have the same issue and need this feature badly for a customers integration of Shopify. Are there even plans to support this? It has been 2 years since this issue was first raised

Daniel_Piech
New Member
1 0 4

We also have this same issue. This is desperately needed.

TrekLightGear
Excursionist
17 0 14

+1 for also needing this. 

 

Main reason: If you have any products in your store that are set to 'Keep selling when out of stock' so you can take Pre-Orders and Backorders, it creates major problems for 3rd party sales channels like Amazon and EBay.  We use a Pre-Order app to properly communicate backorders to our customers on Shopify before they place an order, but these channels have no way of knowing that the product is on back-order and so will take orders as if the product is in stock.  People who order on Amazon/EBay are not expecting any delay in shipping so they will almost always cancel their order once they learn the item is backordered and in turn leave a bad review.

 

With API access, a 3rd party app could automatically unpublish products from Amazon/Ebay when they go out of stock and solve this major problem for us.

 

Alternative: Please make the 'Keep Selling When Out Of Stock' setting channel-specific in Shopify so we could turn it off for those channels, and no 3rd party app or API access is needed to solve this particular problem. 

Kim30
Shopify Expert
138 0 10

Add us to the list - a lot of our clients need it. 

 

Can anyone advise whether it is possible on shopify plus?

The eChics are here to help
paulmangilan
Shopify Partner
1 0 2

+1 for us. I really hope there would be a support for this soon.

blconn
Excursionist
13 0 16

Just adding our $0.02 here also...we have been looking for an option for this since 2016.  I'm really surprised that this has not yet been addressed.

dotdev-xxx
Tourist
11 0 6

This is now possible using the GraphQL Admin API and the following queries:

 


The first approach uses a bit of discovery to find the "Publication" you'd like to publish resources to by using publications query, each node in the response is a Publication Object and will include a mysterious Shopify Publication GID such as gid://shopify/Publication/00012345 along with the Publications name - for us developers this will be the name of our App.


Now you're able to call the publishablePublish endpoint, this expects a "publishable" Shopify Resource GID such as gid://shopify/Product/000123456 and also the Publication GID you'd like to publish too.

Alternatively you can skip discovery and just call the publishablePublishToCurrentSalesChannel with the Shopify Resource GID of your choice, this will publish the publishable to the requesting App's Sales Channel.. I assume - the description (ever descriptive) just says:

 

Publishes a resource to current channel.

I haven't tried this, I assume it doesn't work if your App is not a Sales Channel and I also assume it might work if your app is a Sales Channel.

With a bit of luck, a lot of assumptions and a lot of requests you'll be able to publish all of your products (and other "publishable" resources) to all of your Sales Channels! Woohoo!

Having to publish one at a time on a heavily rate limited API is obviously a very poor solution, it also raises doubt over the future of that ProductListing thing - is that still a thing? maybe that'll be deprecated and replaced by what Shopify is now calling a "Publishable"? Who knows.. 🤷‍♂️ I'm sure they'll announce it at The Hunger Games Unite.

Bye all, have a great weekend!

blconn
Excursionist
13 0 16

Hi dotdev,

 

I have worked through this in GraphQL in the past and I always ended up with multiple failures due to not being "approved" for the permission scope required to use that part of the API.  Do you know if this is now exposed for all devs to use?  I see you're referencing the release candidate version (2020-04) in your links - is this what you tested with?

 

Thanks,

 

Brian