Update kit components via API


I hope you’re doing well.
I’m checking if it’s possible to safely update the kit components of a kit via API. This is mainly due to the fact that we uploaded the components of the kits via CSV upload, but through this way it failed to flag them as kit properly and, therefore, it does not push inventory to the store unless the kit is manually updated via the webpage by adding/removing products.

I saw that there’s a kit_build mutation that I assume overwrites the components that exists in a SKU.
My two questions are:

  1. Is this how it actually works? Or it will add more components infinitely?
  2. I noticed that kit_build is the only mutation out of the 3 that exists for kits that does not include the customer_account_id, what happens if a SKU is repeated in different customers? Does it overwrite the components for all the SKUs that it finds? Can the customer_account_id be added to the mutation?


Hey @cmora,

Thanks for reaching out!
I’ll look into this and get back to you shortly


Hey @cmora,

Thanks for hanging in there!

Using the kit_build mutation on an existing kit will only add components to it. If you try to add a component that already exists with the same quantity using kit_build, nothing will change within the kit after the mutation is run.

If you need to change a kit’s component list completely, running a kit_clear mutation first is advised.

In my tests, when running that mutation from the 3PL, the mutation will only affect one child account when there is a shared SKU between child accounts. I recommend running this mutation using the corresponding child accounts Public API token.

I have passed along your feedback to the team regarding adding the customer_account_id field for the kit_build mutation.

Please let me know if you have any questions or concerns.