Inventory

List inventory movements

Gets a seller's immutable inventory ledger.

GET
/v1/inventory-movements

Filter by Variant, warehouse (warehouseId) or type to audit adjustments, reservations, sales, returns, and transfers. The ledger is not deleted when a Variant or a warehouse is archived.

curl "$BACKEND_URL/v1/inventory-movements?warehouseId=$WAREHOUSE_ID&type=transfer" \
  -H "Authorization: Bearer mk_your_api_key" \
  -H "Seller-Id: $SELLER_ID"

Each movement says in which warehouse it happened (warehouseId). A transfer is two movements with the same transferId: the outbound, with a negative quantity, at the source, and the inbound, positive, at the destination. When you filter by warehouseId, it shows up in the list of both warehouses, one row in each. In any other type, transferId is null.

Authorization

api_key
headerAuthorizationBearer <token>

API key (mk_...)

Query Parameters

page?integer

Page number, starting at 1. Defaults to 1. A page beyond pagination.totalPages is not an error: it returns empty data.

Range1 <= value <= 9007199254740991
Default1
pageSize?integer

Items per page, from 1 to 100. Defaults to 20.

Range1 <= value <= 100
Default20
variantId?string

Only movements of this variant.

Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid
warehouseId?string

Only movements recorded in this warehouse. A transfer shows up in the listing of both of its warehouses, one movement each.

Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid
type?string

Only movements of this type.

Value in"adjustment""reservation""release""sale""return""transfer"

Header Parameters

Seller-Id*string

The id of the seller the request is about, as POST /v1/sellers returned it. Not a secret: the API key authenticates, and this header only picks the seller.

Formatuuid

Response Body

Inventory movements newest first.

application/json
  1. response

One page of inventory movements.

data*array<>

Inventory movements in reverse chronological order.

pagination*

Where this page sits in the whole listing: the totals and whether there are pages before and after it.

curl -X GET "https://example.com/v1/inventory-movements" \  -H "Seller-Id: 3d1c8a52-7f0e-4b0a-8a65-9c1b2f6d7e01"
{  "data": [    {      "id": "cf41b959-9430-4fef-8f8a-2c8edc9199b9",      "sellerId": "3d1c8a52-7f0e-4b0a-8a65-9c1b2f6d7e01",      "variantId": "47c9f819-fcf6-4478-b21a-678ecc594a11",      "warehouseId": "b7e2a1c4-5d3f-4e8a-9b6c-2f1d0a8e7c35",      "type": "adjustment",      "quantity": 7,      "reason": "Initial stock count",      "reference": null,      "transferId": null,      "createdAt": "2026-10-10T12:00:00.000Z"    }  ],  "pagination": {    "page": 1,    "pageSize": 20,    "totalItems": 57,    "totalPages": 3,    "hasNext": true,    "hasPrev": false  }}