InventoryItem

Required access

read_inventory access scope

Represents the goods available to be shipped to a customer. It holds essential information about the goods, including SKU and whether it is tracked.

Show definition
# Represents the goods available to be shipped to a customer.
# It holds essential information about the goods, including SKU and whether it is tracked.
type InventoryItem implements LegacyInteroperability & Node {
  # The date and time when the inventory item was created.
  createdAt: DateTime!

  # Globally unique identifier.
  id: ID!

  # URL for inventory history web page.
  inventoryHistoryUrl: URL

  # Get the inventory level at a specific location.
  inventoryLevel(
    # ID of the location for which the inventory level is requested.
    locationId: ID!
  ): InventoryLevel

  # Paginated list of inventory levels for each location that the inventory item is stocked at.
  inventoryLevels(
    # Returns the elements that come after the specified cursor.
    after: String

    # Returns the elements that come before the specified cursor.
    before: String

    # Returns up to the first `n` elements from the list.
    first: Int

    # Returns up to the last `n` elements from the list.
    last: Int

    # Supported filter parameters:
    #  - `created_at`
    #  - `inventory_group_id`
    #  - `inventory_item_id`
    #  - `updated_at`
    #
    # See the detailed [search syntax](https://help.shopify.com/api/getting-started/search-syntax).
    query: String

    # Reverse the order of the underlying list.
    reverse: Boolean = false
  ): InventoryLevelConnection!

  # The ID of the corresponding resource in the REST Admin API.
  legacyResourceId: UnsignedInt64!

  # The number of locations where this inventory item is stocked.
  locationsCount: Int!

  # Whether the item requires shipping or not.
  requiresShipping: Boolean!

  # Inventory item SKU.
  sku: String

  # Whether the inventory quantities of inventory levels for the item are tracked or not.
  tracked: Boolean!

  # Unit cost associated with the inventory item.
  unitCost: MoneyV2

  # The date and time when the inventory item was updated.
  updatedAt: DateTime!

  # The variant that owns this inventory item.
  variant: ProductVariant!
}

Implements

Connections

inventoryLevels   (InventoryLevelConnection!)

Paginated list of inventory levels for each location that the inventory item is stocked at.

Argument Type Default Description
after

String

Returns the elements that come after the specified cursor.

before

String

Returns the elements that come before the specified cursor.

first

Int

Returns up to the first n elements from the list.

last

Int

Returns up to the last n elements from the list.

query

String

Supported filter parameters:

  • created_at
  • inventory_group_id
  • inventory_item_id
  • updated_at

See the detailed search syntax.

reverse

Boolean

false

Reverse the order of the underlying list.

Fields

createdAt   (DateTime!)

The date and time when the inventory item was created.

id   (ID!)

Globally unique identifier.

inventoryHistoryUrl   (URL)

URL for inventory history web page.

inventoryLevel   (InventoryLevel)

Get the inventory level at a specific location.

Argument Type Default Description
locationId

required

ID!

ID of the location for which the inventory level is requested.

legacyResourceId   (UnsignedInt64!)

The ID of the corresponding resource in the REST Admin API.

locationsCount   (Int!)

The number of locations where this inventory item is stocked.

requiresShipping   (Boolean!)

Whether the item requires shipping or not.

sku   (String)

Inventory item SKU.

tracked   (Boolean!)

Whether the inventory quantities of inventory levels for the item are tracked or not.

unitCost   (MoneyV2)

Unit cost associated with the inventory item.

updatedAt   (DateTime!)

The date and time when the inventory item was updated.

variant   (ProductVariant!)

The variant that owns this inventory item.

Sign up for a Partner account to get started.

Sign up