Troubles with fulfillment service location

Troubles with fulfillment service location

kyo00710
Shopify Partner
8 0 2

Hi, 

 

I stuck at update or adjust values for variants with 2024-04 version, with fulfillment service location.

 

 

I wanna  update the workflow updating the quantity of products, from my development app, using GraphQL in 2024-04 version API.

 

The mutation inventorySetQuantities , it will be used for version 2024-07, it's so far.

 

I turned off inventoryManagement, set it to false, and surely that its location is active.

Then I use the inventorySetOnHandQuantities mutation for updating quantity, I received the error

{
     "field": [
         "input",
         "setQuantities",
         "0",
         "locationId"
     ],
      "message": "The specified inventory item is not stocked at the location."
}

I used another mutation is inventoryBulkToggleActivation for activating inventory item in this location  ( the location associated with fulfillment service), and I got the NOT_FOUND location

 
 "userErrors": [
        {
          "field": [
            "inventoryItemUpdates",
            "0",
            "locationId"
          ],
          "message": "The quantity couldn't be updated because the location was not found.",
          "code": "LOCATION_NOT_FOUND"
        }

I tested with shop location which created manually, and it was successful.

 

I wonder that how can I update quantity of products from my app to Shopify, with fulfillment service location?

 

Can anybody show me how to do it?

Replies 2 (2)

kyo00710
Shopify Partner
8 0 2

I realized that the location id created with fulfillment service API.

 

If you create product and variant with this location. You can then use mutation  inventorySetOnHandQuantities  for updating quantity.

 

In case using the mutation productSet for creating product and variant. The created variants could not be handled quantities with the mutation  inventorySetOnHandQuantities, concerning the error product was not stocked on this location.

 

So, how can I update products which created from the productSet mutation?

kyo00710
Shopify Partner
8 0 2

Can anybody help me, please?