skip to Main Content

This is the query im using:

        mutation {
          inventoryAdjustQuantities(input: {
            changes: [
              {
                inventoryItemId: "gid://shopify/InventoryItem/52015591457087",
                delta: 11,
                locationId: "gid://shopify/Location/101265211711"
              }
            ],
            name: "available",
            reason: "other"
          }) {
            userErrors {
              field
              message
              code
            }
          }
        }

and its returning me this

{
    "data": {
        "inventoryAdjustQuantities": {
            "userErrors": [],
        }
    },
    "extensions": {
        "cost": {
            "requestedQueryCost": 12,
            "actualQueryCost": 12,
            "throttleStatus": {
                "maximumAvailable": 2000.0,
                "currentlyAvailable": 1988,
                "restoreRate": 100.0
            }
        }
    }
}

Its not returning any error. But its not having any effects in my product.
I am using the 2024/07 version.

2

Answers


  1. I replicate the case & copy the mutation, replace the inventoryItemId & locationId & got the same response. But the product quantity is incrreased for me, may be your are checking different product.

    Login or Signup to reply.
  2. The query is working fine. Make sure you have right product inventoryItemId & shop locationId.

         mutation {
              inventoryAdjustQuantities(input: {
                changes: [
                  {
                    inventoryItemId: "gid://shopify/InventoryItem/52015591457087",
                    delta: 11,
                    locationId: "gid://shopify/Location/101265211711"
                  }
                ],
                name: "available",
                reason: "other"
              }) {
                userErrors {
                  field
                  message
                  code
                }
              }
            }
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search