Hi Shopify,
We created two products — one with “Track Inventory” enabled and one without.
After testing the quantity update from my App to Shopify, we found that the product without tracking updated successfully, while the one with tracking did not.
This is my screenshot
var adjustRequest = new GraphQLRequest
{
Query = [email removed] mutation inventoryAdjustQuantities($input: InventoryAdjustQuantitiesInput!) {
inventoryAdjustQuantities(input: $input) {
userErrors {
field
message
}
inventoryAdjustmentGroup {
createdAt
reason
referenceDocumentUri
changes {
name
delta
}
}
}
}"
};
I using C#, Send params:
inventoryItemAdjustmentsVariablesForGraphQL.Add(new
{
inventoryItemId = $“gid://shopify/InventoryItem/{inventoryAdjust.InventoryItemId}”,
delta = inventoryAdjust.AvailableAdjustment,
locationId = $“gid://shopify/Location/{inventoryAdjust.LocationId}”
});
var graphQLClient = new GraphQLHttpClient(webUrl + “admin/api/2024-01/graphql.json”, new NewtonsoftJsonSerializer());
graphQLClient.HttpClient.DefaultRequestHeaders.Add(“X-Shopify-Access-Token”, _store.
Admin API access scopeswrite_order_edits, read_order_edits, write_orders, read_orders, write_customers, read_customers, write_product_listings, read_product_listings, write_products, read_products, write_assigned_fulfillment_orders, read_assigned_fulfillment_orders, write_merchant_managed_fulfillment_orders, read_merchant_managed_fulfillment_orders, write_third_party_fulfillment_orders, read_third_party_fulfillment_orders, write_inventory, read_inventory, write_locations, read_locations
Looking for your support
Thank you!!