Version: unstable
Curl example: "curl -X POST \\\nhttps://your-development-store.myshopify.com/admin/api/unstable/graphql.json \\\n-H 'Content-Type: application/json' \\\n-H 'X-Shopify-Access-Token: {access_token}' \\\n-d '{\n\"query\": \"query { inventoryLevel(id: \\\"gid://shopify/InventoryLevel/523463154?inventory_item_id=30322695\\\") { id quantities(names: [\\\"available\\\", \\\"incoming\\\", \\\"committed\\\", \\\"damaged\\\", \\\"on_hand\\\", \\\"quality_control\\\", \\\"reserved\\\", \\\"safety_stock\\\"]) { name quantity } item { id sku } location { id name } } }\"\n}'\n" Node example: "const client = new shopify.clients.Graphql({session});\nconst data = await client.query({\n data: `query {\n inventoryLevel(id: \"gid://shopify/InventoryLevel/523463154?inventory_item_id=30322695\") {\n id\n quantities(names: [\"available\", \"incoming\", \"committed\", \"damaged\", \"on_hand\", \"quality_control\", \"reserved\", \"safety_stock\"]) {\n name\n quantity\n }\n item {\n id\n sku\n }\n location {\n id\n name\n }\n }\n }`,\n});\n" Ruby example: "session = ShopifyAPI::Auth::Session.new(\n shop: \"your-development-store.myshopify.com\",\n access_token: access_token\n)\nclient = ShopifyAPI::Clients::Graphql::Admin.new(\n session: session\n)\n\nquery = <<~QUERY\n query {\n inventoryLevel(id: \"gid://shopify/InventoryLevel/523463154?inventory_item_id=30322695\") {\n id\n quantities(names: [\"available\", \"incoming\", \"committed\", \"damaged\", \"on_hand\", \"quality_control\", \"reserved\", \"safety_stock\"]) {\n name\n quantity\n }\n item {\n id\n sku\n }\n location {\n id\n name\n }\n }\n }\nQUERY\n\nresponse = client.query(query: query)\n" PHP example: "use Shopify\\Clients\\Graphql;\n\n$client = new Graphql(\"your-development-store.myshopify.com\", $accessToken);\n$query = <<query([\"query\" => $query]);\n" Remix example: "const { admin } = await authenticate.admin(request);\n\nconst response = await admin.graphql(\n `#graphql\n query {\n inventoryLevel(id: \"gid://shopify/InventoryLevel/523463154?inventory_item_id=30322695\") {\n id\n quantities(names: [\"available\", \"incoming\", \"committed\", \"damaged\", \"on_hand\", \"quality_control\", \"reserved\", \"safety_stock\"]) {\n name\n quantity\n }\n item {\n id\n sku\n }\n location {\n id\n name\n }\n }\n }`,\n);\n\nconst data = await response.json();\n" Graphql query: "query {\n inventoryLevel(id: \"gid://shopify/InventoryLevel/523463154?inventory_item_id=30322695\") {\n id\n quantities(names: [\"available\", \"incoming\", \"committed\", \"damaged\", \"on_hand\", \"quality_control\", \"reserved\", \"safety_stock\"]) {\n name\n quantity\n }\n item {\n id\n sku\n }\n location {\n id\n name\n }\n }\n}"
input: null
response: { "data": { "inventoryLevel": { "id": "gid://shopify/InventoryLevel/523463154?inventory_item_id=30322695", "quantities": [ { "name": "available", "quantity": 2 }, { "name": "incoming", "quantity": 146 }, { "name": "committed", "quantity": 1 }, { "name": "damaged", "quantity": 0 }, { "name": "on_hand", "quantity": 33 }, { "name": "quality_control", "quantity": 0 }, { "name": "reserved", "quantity": 30 }, { "name": "safety_stock", "quantity": 0 } ], "item": { "id": "gid://shopify/InventoryItem/30322695", "sku": "element-151" }, "location": { "id": "gid://shopify/Location/346779380", "name": "Ottawa Store" } } } }