Option to bulk remove variants

murale
New Member
3 0 0

Hi,

We're syncing our Shopify shop to our ERP system and our variant pricing dynamically changes. This means we have to clear our variants and add new ones every night.

It seems this is only possible using a single DELETE on a variant but this is tediously slow for 100 variants per product.

Is there a way to bulk delete variants?

 

Best,

 

Tom

0 Likes
ldz
Excursionist
19 1 4

What ERP system are you integrating, and are you creating the integration from scratch with their APIs, or using a pre-built connector?

0 Likes
murale
New Member
3 0 0

hej!

~Thanks

It's a custom connector so we're building the integration from scratch!

 

0 Likes
ldz
Excursionist
19 1 4

oh that's cool!

How slow is doing 100 DELETE operations on average? Is it blocking or can you just run it in a background thread or process?

Also curious, what platform are you creating the custom connector with, AWS / Azure or something like that?

samc
Excursionist
32 1 24

Hi Tom!

Trying to update large number of Shopify resources is a common challenge with Shopify's API rate limiting. A few questions I have in terms of scale here:

1. How frequent do the dynamic pricing happen (it seems to be just once a day where you update at night)
2. How many total products and average number of variants do you have?
3. What are the risk of "delayed syncing"

You can try using Shopify graphQL for bulk deleting. The rate limit would be 10 delete operations/second vs the 2 request/second for the REST API. To make it faster, you can try creating custom apps for the store to acquire more API keys.

And we are also curious what system you are using to build the custom integration and if you plan to host/maintain them yourself?

murale
New Member
3 0 0

To both replies above. We're running a few services on digital ocean that handles it. It's doing nightly updates on products that changes. It results in around 700ms-1400ms per product depending on the variants that we need to create.

We have around 25 variants per product.

We're running each variant delete action in a job, so each product update in a seperate job.

@samcThanks for the GraphQL suggestion. Yeah we're just  hosting them ourselves, it's just a simple Node application.

Best,

Tom

0 Likes
samc
Excursionist
32 1 24

Got it! That makes sense. 

So we released a Shopify automation platform called Shypyard (https://apps.shopify.com/shypyard) that is developer friendly. Essentially you can use the platform to write nodejs code that interacts with Shopify APIs, and the platform handles all the infrastructure issues like scaling, error retries, monitoring and logging. Essentially, you only have to think about your automation business logic, and we take care of the rest. While there are a lot of flexibility of hosting it yourself, we understand it comes with many other cost on maintaining.

I think you might be interested to look into considering you're already using Javascript so it'll be simple to give it a try. Another benefit is you could potentially have a real-time price change update instead of a daily update overnight. 

If you are interested to learn more, please reach us at help@shypyard.io and we can schedule a short demo to learn more about your use cases.