# List item attributes

Operation ID: `listItemAttributes`

Group: Inventory › Item Attributes

[Open in the interactive reference](https://docs.api.lensing.ai/lensing/v1/endpoints/listItemAttributes)

`GET /inventory/item-attributes`

Read-only: Reads and returns; changes nothing.

Lists item attributes. Filter by itemId to read everything one item is tagged with, or by attributeId to find every item carrying a given attribute. The same fields come back from GET inventory/item-attributes/:id. An identifier that matches no record returns an empty page rather than an error.

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `Api-Version` | header | string · v1 | yes | The API version this request targets, named by its public identifier. Required on every request; omitting it, or naming a version this company does not have, is answered with 400. This document describes version `v1`. |

## Query surface

- `id` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `itemId` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `itemCode` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `attributeId` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `attributeName` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `valueId` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `value` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- Orderable: id, itemCode, attributeName, value
- Selectable: id, itemId, itemCode, attributeId, attributeName, valueId, value
- `page[size]` — Page size
- `page[cursor]` — Opaque continuation cursor

## Response

`200` Success

Under `data`, an array of listItemAttributesRow:

| Field | Type | Required | Filter | Sort | Description |
| --- | --- | --- | --- | --- | --- |
| `id` | string | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | yes | The unique identifier for the item attribute. |
| `itemId` | string | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | no | The unique identifier for the item carrying the attribute. See id on GET inventory/items/:id. |
| `itemCode` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | yes | The item's code, for example 'WIDGET-01'. |
| `attributeId` | string | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | no | The unique identifier for the attribute definition. |
| `attributeName` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | yes | The attribute's name, for example 'Colour'. |
| `valueId` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | no | The unique identifier for the chosen value. Absent when the attribute has been assigned without a value. |
| `value` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | yes | The chosen value's text, for example 'Red'. Absent when the attribute has been assigned without a value. |

```json
{
  "data": [
    {
      "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "itemId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "itemCode": "<itemCode>",
      "attributeId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "attributeName": "<attributeName>",
      "valueId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "value": "<value>"
    }
  ],
  "pagination": {
    "hasMore": true,
    "nextCursor": "<nextCursor>"
  }
}
```

## Statuses

- `400` — Invalid request or business failure
- `401` — The request carries no valid access token.
- `403` — Not authorized
- `404` — Not found
- `429` — Too many requests from this client address. The response has no body and no `Retry-After` header.
- `500` — Internal server error
