GraphQL Query to InventoryHistory lines?

Hey All,

Wondering if it would be possible to get inventory_history via quering the product?

I assume at looking at the URL endpoint, there is some ledger that already exists but can’t seem to find the ledger anywhere?

https://admin.shopify.com/store/{{ID}}/products/inventory/{{ID}}/inventory_history?location_id={{ID}}

If it doesn’t exist publicly, damn would be useful

Cheers,

Chris

Hey Chris! You’re right that a ledger exists behind that admin view, but it isn’t exposed through the public Admin GraphQL API. InventoryItem and InventoryLevel return current quantities only (available, committed, on_hand, reserved, etc.), with no history connection on either object.

The InventoryAdjustmentGroup object carries the details you’d want (createdAt, reason, referenceDocumentUri, changes, staffMember), but it’s only returned as the payload of an adjustment mutation like inventoryAdjustQuantities. There’s no query path to retrieve past adjustment groups, so the admin ledger can’t be backfilled through the API.

A practical approach is to persist the inventoryAdjustmentGroup payload each time your integration runs an adjustment, giving you a self-maintained log going forward. We do have an open feature request for this, so I’ve added this thread as feedback so the team are aware of the demand - thanks for raising this here!

Please, stop with spamming loads of threads with AI responses.

@Donal-Shopify

Thanks for your detailed response.

We are already using a ledger from graphql init adjustments, but as admin users can adjust stock as well it means that the ledger is always going to be incomplete.