# List batch transactions

Operation ID: `batchTransactions`

Group: Inventory › Batch Transactions

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

`GET /inventory/batch-transactions`

Read-only: Reads and returns; changes nothing.

Lists batch transactions.

## 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
- `batchNumberId` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `batchNumber` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `expirationDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between
- `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
- `locationId` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `locationCode` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `transactionDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between
- `sourceDocumentLineType` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `lastModifiedDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between
- Orderable: id, transactionDate, expirationDate, batchNumber, itemCode, locationCode, lastModifiedDate
- Selectable: id, batchNumberId, batchNumber, expirationDate, transactionId, itemId, itemCode, itemName, locationId, locationCode, locationName, unitId, unitCode, transactionDate, inQuantity, outQuantity, unitInQuantity, unitOutQuantity, cost, valueDelta, currency, sourceDocumentLineType, lastModifiedDate
- `page[size]` — Page size
- `page[cursor]` — Opaque continuation cursor

## Response

`200` Success

Under `data`, an array of batchTransactionsRow:

| 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 batch transaction. Format: UUID. Example: `"6d2b8e17-4f90-4c53-a821-0e7d3b95c46f"`. |
| `batchNumberId` | string | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | no | The unique identifier of the batch this transaction is for. Format: UUID. See `id` on GET inventory/batch-numbers/:id (getBatchNumber). Example: `"9c31f5a8-6b02-4e79-b354-8d1a67e0f2b9"`. |
| `batchNumber` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | yes | The batch number, such as a lot number printed on the goods. It is entered on the receipt, inventory increase, or other document that first recorded the batch's stock. The same batch number can be used for other items and in other warehouses, so it identifies a batch only together with the item and the warehouse. Example: 'LOT-2026-08-14'. Example: `"LOT-2026-08-14"`. |
| `expirationDate` | date \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`) | yes | The date the batch expires. It shows the batch's current value, not the value at the time of the batch transaction. Format: YYYY-MM-DD. Example: `"2027-08-14"`. |
| `transactionId` | string \| null | no | no | no | The unique identifier of the inventory transaction this batch transaction belongs to. Format: UUID. See `id` on GET inventory/inventory-transactions/:id (getInventoryTransaction). Example: `"3a7c1f95-04eb-4d62-8917-5c0e2b8d4a63"`. |
| `itemId` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | no | The unique identifier of the item. Format: UUID. See `id` on GET inventory/items/:id (getItem). Example: `"5f21c8b0-9d34-4a76-8e12-04b93c7de5a8"`. |
| `itemCode` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | yes | The code of the item in `itemId`. Example: `"WIDGET-01"`. |
| `itemName` | string \| null | no | no | no | The name of the item in `itemId`. Example: `"Standard widget"`. |
| `locationId` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | no | The unique identifier of the warehouse. Format: UUID. See `id` on GET inventory/warehouses/:id (getWarehouse). Example: `"e1d84c07-5b39-4a26-9f70-2c8b613ad495"`. |
| `locationCode` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | yes | The code of the warehouse in `locationId`. Example: `"WH-01"`. |
| `locationName` | string \| null | no | no | no | The name of the warehouse in `locationId`. Example: `"Rotterdam Distribution Centre"`. |
| `unitId` | string \| null | no | no | no | The unique identifier of the unit of measure the batch transaction was recorded in. Format: UUID. See `id` on GET inventory/unit-of-measures/:id (getUnitOfMeasure). |
| `unitCode` | string \| null | no | no | no | The code of the unit of measure in `unitId`. |
| `transactionDate` | date \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`) | yes | The date of the inventory transaction this batch transaction belongs to. Format: YYYY-MM-DD. Example: `"2026-08-03"`. |
| `inQuantity` | decimal \| null | no | no | no | The quantity of the batch that came into stock, in the item's stocking unit. It is 0 on an inventory revaluation, which changes the batch's cost without moving stock. Example: `"500.00"`. |
| `outQuantity` | decimal \| null | no | no | no | The quantity of the batch that went out of stock, in the item's stocking unit. |
| `unitInQuantity` | decimal \| null | no | no | no | The quantity that came into stock, in the unit of measure named by `unitId`. It can differ from `inQuantity`, which is in the item's stocking unit. |
| `unitOutQuantity` | decimal \| null | no | no | no | The quantity that went out of stock, in the unit of measure named by `unitId`. It can differ from `outQuantity`, which is in the item's stocking unit. |
| `cost` | decimal \| null | no | no | no | The unit cost of the batch, in the currency named by `currency`. When stock comes in, it is the unit cost of the stock received. When stock goes out, it is the batch's unit cost at that time. On an inventory revaluation, it is the batch's new unit cost. Example: `"3.75"`. |
| `valueDelta` | decimal \| null | no | no | no | The change in the total value of the batch's stock from this transaction, in the currency named by `currency`. A negative value is a decrease. Example: `"1875.00"`. |
| `currency` | string \| null | no | no | no | The currency that `cost` and `valueDelta` are in. Format: ISO 4217, for example 'USD'. Example: `"EUR"`. |
| `sourceDocumentLineType` | string \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`), Pattern (`like`) | no | The type of document line the inventory transaction came from. Possible values: 'IMInventorySalesOrderLine', 'IMInventorySalesDeliveryLine', 'IMSalesOrderLine', 'IMInventoryPurchaseReturnLine', 'IMInventorySalesReturnLine', 'IMWarehouseTransferLine', 'IMInventoryDecreaseLine', 'IMInventoryIncreaseLine', 'IMInventoryRevaluationLine', 'IMInventoryTransferLine', 'IMInventoryAdjustmentLine', 'IMInventoryCountLine', 'IMInventoryPutAwayTask', 'IMInventoryPurchaseReturnReversal', 'PurchaseOrderLine', 'IMLandedCostAllocationLine', 'SalesOrderProductItem', 'IMWarehouseTransferOrderLine', 'VendorBillItemBase', 'InvPurchaseDeliveryLine'. Example: `"InvPurchaseDeliveryLine"`. |
| `lastModifiedDate` | date-time \| null | no | Exact (`eq`, `ne`), Range (`gt`, `gte`, `lt`, `lte`, `between`), Any of (`in`, `notIn`) | yes | The date and time the batch transaction last changed, in UTC. Format: YYYY-MM-DDTHH:mm:ss.sssZ. Changes to the batch itself, such as its `expirationDate`, do not update this field. Example: `"2026-08-03T11:15:00.000Z"`. |

```json
{
  "data": [
    {
      "id": "6d2b8e17-4f90-4c53-a821-0e7d3b95c46f",
      "batchNumberId": "9c31f5a8-6b02-4e79-b354-8d1a67e0f2b9",
      "batchNumber": "LOT-2026-08-14",
      "expirationDate": "2027-08-14",
      "transactionId": "3a7c1f95-04eb-4d62-8917-5c0e2b8d4a63",
      "itemId": "5f21c8b0-9d34-4a76-8e12-04b93c7de5a8",
      "itemCode": "WIDGET-01",
      "itemName": "Standard widget",
      "locationId": "e1d84c07-5b39-4a26-9f70-2c8b613ad495",
      "locationCode": "WH-01",
      "locationName": "Rotterdam Distribution Centre",
      "unitId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "unitCode": "<unitCode>",
      "transactionDate": "2026-08-03",
      "inQuantity": "500.00",
      "outQuantity": "19.99",
      "unitInQuantity": "19.99",
      "unitOutQuantity": "19.99",
      "cost": "3.75",
      "valueDelta": "1875.00",
      "currency": "EUR",
      "sourceDocumentLineType": "InvPurchaseDeliveryLine",
      "lastModifiedDate": "2026-08-03T11:15:00.000Z"
    }
  ],
  "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
