# nodeInventory

Audience: Programmer

Fetches an object given its ID.

Fetches an object given its ID.

**Served by:** [inventory](https://docs.pyck.cloud/latest/api/services/inventory.md)

## Arguments

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `id` | ID! |  | ID of the object. |

## Returns

[NodeInventory](https://docs.pyck.cloud/latest/api/interfaces/nodeinventory.md)

## Example

Fetches one inventory item by its global ID. The inline fragment selects the InventoryItem fields; the lookup returns null when no object has that ID.

```graphql
query GetNodeInventory($id: ID!) {
  nodeInventory(id: $id) {
    id
    ... on InventoryItem {
      tenantID
      sku
      dataTypeSlug
      data
      createdAt
    }
  }
}
```

**Variables**

```json
{
  "id": "<inventory item ID>"
}
```
