REST API: Material
This page belongs to the REST API reference, which covers the address, authentication, scopes, pagination and errors. Every path is appended to https://api.litelog.de/api. In the examples $KEY stands for your API key; the example values are made up.
Overview
| Call | Purpose | Scope |
|---|---|---|
GET /v1/material/items |
List material items (master data) | material:read |
POST /v1/material/items |
Create a material item (ERP master-data sync) | material:write |
GET /v1/material/items/{id} |
Material item detail | material:read |
PATCH /v1/material/items/{id} |
Update a material item | material:write |
POST /v1/material/items/{id}/archive |
Archive an item (soft — stock/history stay readable) | material:write |
POST /v1/material/items/{id}/unarchive |
Restore an archived item | material:write |
GET /v1/material/stock |
Stock levels of one property | material:read |
GET /v1/material/warehouse/stock |
Stock levels of a central warehouse | material:read |
GET /v1/material/movements |
List stock movements of one property (journal polling) | material:read |
POST /v1/material/movements |
Book stock movements (adjustments, deliveries, consumption) | material:write |
GET /v1/material/requests |
List material requests (status polling for ERP/purchasing) | material:read |
POST /v1/material/requests |
Create a material request for a property | material:write |
GET /v1/material/requests/{id} |
Get a material request | material:read |
POST /v1/material/requests/{id}/approve |
Approve a pending material request | material:write |
POST /v1/material/requests/{id}/reject |
Reject a pending material request | material:write |
POST /v1/material/requests/{id}/fulfill |
Fulfil an approved request (books both stock sides) | material:write |
POST /v1/material/requests/{id}/cancel |
Withdraw an own pending request | material:write |
GET /v1/material/stock-targets |
Read min/target stock per property | material:read |
PUT /v1/material/stock-targets |
Set min/target stock per property (full replace) | material:write |
POST /v1/material/counts |
Record a stock count (inventory anchor) | material:write |
GET /v1/material/warehouses |
List warehouses (central stock) | material:read |
POST /v1/material/warehouses |
Create a warehouse | material:write |
POST /v1/material/warehouse/movements |
Book central-stock movements (goods receipt, withdrawal) | material:write |
GET /v1/material/units |
List units (serialized items — keys, devices) | material:read |
POST /v1/material/units |
Create a unit (key/device instance) | material:write |
GET /v1/material/units/{id} |
Unit detail incl. hand-over history | material:read |
POST /v1/material/units/bulk |
Create a series of units (e.g. keys SCHL-001…020) | material:write |
GET /v1/material/receipts |
List hand-over receipts (issue/return documents) | material:read |
GET /v1/material/receipts/{id} |
Receipt detail incl. item positions | material:read |
POST /v1/material/transfers |
Issue/return/report loss to persons (key handover) | material:write |
Notes
All /v1/material/… endpoints respond with 403 while your account's Material feature is disabled (company switch under Features) — the same switch that governs the portal and the app.
GET /v1/material/items
List material items (master data).
List material items (filters: search, category, kind, status, barcode for the item that carries a manufacturer barcode) / create one (ERP master-data sync). Every item carries barcodes.
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
search |
query | string | no | — |
category |
query | string | no | — |
kind |
query | string | no | Values: consumable, equipment, serialized. |
status |
query | string | no | Values: active, archived; Default: active. |
barcode |
query | string | no | Exact manufacturer barcode (the value a scanner reads), at most 80 characters. Returns the one item that carries it, or an empty list. Combine with status=archived to look among archived items. |
Example call
curl "https://api.litelog.de/api/v1/material/items?category=Reinigungsmittel&kind=consumable&page=1&pageSize=50" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"item_id": 301,
"uuid": "e3e7ee38-1147-4896-85e8-35105a4cf61d",
"name": "Allzweckreiniger 5 l",
"size": null,
"display_name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"category": "Reinigungsmittel",
"kind": "consumable",
"unit_price_cents": 1290,
"barcodes": [
"4006381333931"
],
"archived": false,
"created_at": "2026-12-01T08:15:00.000Z"
},
{
"item_id": 304,
"uuid": "c435612c-25fd-4fb5-b461-e97c40995115",
"name": "Glasreiniger 1 l",
"size": null,
"display_name": "Glasreiniger 1 l",
"unit": "Flasche",
"category": "Reinigungsmittel",
"kind": "consumable",
"unit_price_cents": 349,
"barcodes": [],
"archived": false,
"created_at": "2026-12-01T08:20:00.000Z"
}
],
"total": 2,
"page": 1,
"pageSize": 50
}
POST /v1/material/items
Create a material item (ERP master-data sync).
List material items (filters: search, category, kind, status, barcode for the item that carries a manufacturer barcode) / create one (ERP master-data sync). Every item carries barcodes.
Scope: material:write
Body fields (JSON)
The example shows the structure of the body.
barcodes takes the manufacturer barcodes from the packaging (EAN-13, EAN-8, UPC-A or Code 128), at most 20 per item. If a barcode already belongs to another active item, the API answers 409 with reason: material_barcode_taken and that item's item_id and item_name; a barcode of an archived item moves to the new item.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/items" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"category": "Reinigungsmittel",
"kind": "consumable",
"unit_price_cents": 1290,
"barcodes": [
"4006381333931"
]
}'
Example response (201)
{
"data": {
"item_id": 301,
"uuid": "e3e7ee38-1147-4896-85e8-35105a4cf61d",
"name": "Allzweckreiniger 5 l",
"size": null,
"display_name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"category": "Reinigungsmittel",
"kind": "consumable",
"unit_price_cents": 1290,
"barcodes": [
"4006381333931"
],
"archived": false,
"created_at": "2026-12-01T08:15:00.000Z"
}
}
GET /v1/material/items/{id}
Material item detail.
Read / update an item. barcodes sets the item's barcodes as the full list; if a barcode belongs to another active item the API answers 409 (material_barcode_taken).
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Example call
curl "https://api.litelog.de/api/v1/material/items/301" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"item_id": 301,
"uuid": "e3e7ee38-1147-4896-85e8-35105a4cf61d",
"name": "Allzweckreiniger 5 l",
"size": null,
"display_name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"category": "Reinigungsmittel",
"kind": "consumable",
"unit_price_cents": 1290,
"barcodes": [
"4006381333931"
],
"archived": false,
"created_at": "2026-12-01T08:15:00.000Z"
}
}
PATCH /v1/material/items/{id}
Update a material item.
Read / update an item. barcodes sets the item's barcodes as the full list; if a barcode belongs to another active item the API answers 409 (material_barcode_taken).
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Body fields (JSON)
The example shows the structure of the body.
barcodes replaces the item's list, [] removes all. If the field is omitted, the barcodes stay as they are.
Example call
curl -X PATCH "https://api.litelog.de/api/v1/material/items/301" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"unit_price_cents": 1390
}'
Example response (200)
{
"data": {
"item_id": 301,
"uuid": "e3e7ee38-1147-4896-85e8-35105a4cf61d",
"name": "Allzweckreiniger 5 l",
"size": null,
"display_name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"category": "Reinigungsmittel",
"kind": "consumable",
"unit_price_cents": 1390,
"barcodes": [
"4006381333931"
],
"archived": false,
"created_at": "2026-12-01T08:15:00.000Z"
}
}
POST /v1/material/items/{id}/archive
Archive an item (soft — stock/history stay readable).
Archive an item (soft — stock and history stay readable) / restore it.
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Example call
curl -X POST "https://api.litelog.de/api/v1/material/items/304/archive" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"archived": true
}
}
POST /v1/material/items/{id}/unarchive
Restore an archived item.
Archive an item (soft — stock and history stay readable) / restore it.
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Example call
curl -X POST "https://api.litelog.de/api/v1/material/items/304/unarchive" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"archived": false
}
}
GET /v1/material/stock
Property stock (property_id required).
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
property_id |
query | integer | yes | — |
Example call
curl "https://api.litelog.de/api/v1/material/stock?property_id=123" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"item_id": 303,
"name": "Einmalhandschuhe Nitril (L)",
"unit": "Packung",
"category": "Arbeitsschutz",
"stock": 2,
"min_qty": 4,
"target_qty": 10,
"status": "low",
"last_count_at": null,
"last_movement_at": "2026-12-03T07:40:00.000Z"
},
{
"item_id": 301,
"name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"category": "Reinigungsmittel",
"stock": 6,
"min_qty": 2,
"target_qty": 8,
"status": "ok",
"last_count_at": "2026-12-01T08:45:00.000Z",
"last_movement_at": "2026-12-02T09:05:00.000Z"
}
],
"total": 2,
"page": 1,
"pageSize": 50
}
GET /v1/material/warehouse/stock
Central-warehouse stock (optional warehouse_id, otherwise the default warehouse).
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
warehouse_id |
query | integer | no | — |
search |
query | string | no | — |
category |
query | string | no | — |
status |
query | string | no | Values: active, archived; Default: active. |
Example call
curl "https://api.litelog.de/api/v1/material/warehouse/stock?warehouse_id=1&category=Reinigungsmittel" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"item_id": 301,
"name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"category": "Reinigungsmittel",
"stock": 36,
"min_qty": 20,
"target_qty": 60,
"status": "ok",
"last_count_at": null,
"last_movement_at": "2026-12-01T10:30:00.000Z"
},
{
"item_id": 304,
"name": "Glasreiniger 1 l",
"unit": "Flasche",
"category": "Reinigungsmittel",
"stock": 0,
"min_qty": null,
"target_qty": null,
"status": "empty",
"last_count_at": null,
"last_movement_at": null
}
],
"total": 2,
"page": 1,
"pageSize": 50
}
GET /v1/material/movements
List stock movements of one property (journal polling).
List / create material movements (up to 200 per request, idempotent via a client uuid).
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
property_id |
query | integer | yes | — |
item_id |
query | integer | no | — |
from |
query | string (date-time) | no | — |
to |
query | string (date-time) | no | — |
Example call
curl "https://api.litelog.de/api/v1/material/movements?property_id=123&item_id=301&from=2026-12-01T00:00:00Z" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"uuid": "48ef02c9-8438-45ea-ab2f-989c281c6083",
"item_id": 301,
"property_id": 123,
"holder_type": "property",
"qty": -2,
"reason": "consume",
"unit_price_cents": 1290,
"account_id": 5,
"occurred_at": "2026-12-02T09:05:00.000Z",
"note": "Wochenreinigung Verkaufsfläche",
"ref_type": null,
"ref_id": null,
"created_at": "2026-12-02T09:06:00.000Z"
},
{
"uuid": "f27d0124-3fb8-4070-94a3-1915a5b35847",
"item_id": 301,
"property_id": 123,
"holder_type": "property",
"qty": 4,
"reason": "refill",
"unit_price_cents": 1290,
"account_id": 5,
"occurred_at": "2026-12-01T10:30:00.000Z",
"note": null,
"ref_type": "material_request",
"ref_id": "43865dc2-3b5e-40a1-a1ad-35d6f571e775",
"created_at": "2026-12-01T10:30:00.000Z"
}
],
"total": 2,
"page": 1,
"pageSize": 50
}
POST /v1/material/movements
Book stock movements (adjustments, deliveries, consumption).
List / create material movements (up to 200 per request, idempotent via a client uuid).
Scope: material:write
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
movements |
array (object) | yes | At most 200 items. |
Example call
curl -X POST "https://api.litelog.de/api/v1/material/movements" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"movements": [
{
"uuid": "48ef02c9-8438-45ea-ab2f-989c281c6083",
"item_id": 301,
"property_id": 123,
"qty": -2,
"reason": "consume",
"occurred_at": "2026-12-02T09:05:00Z",
"note": "Wochenreinigung Verkaufsfläche"
}
]
}'
Example response (201)
{
"data": {
"inserted_uuids": [
"48ef02c9-8438-45ea-ab2f-989c281c6083"
],
"duplicate_uuids": []
}
}
GET /v1/material/requests
List material requests (status polling for ERP/purchasing).
List material requests (filters: status, property_id, item_id, from/to) / create one (uuid is mandatory).
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
status |
query | string | no | Values: pending, approved, rejected, cancelled, fulfilled. |
property_id |
query | integer | no | — |
item_id |
query | integer | no | — |
from |
query | string (date) | no | — |
to |
query | string (date) | no | — |
Example call
curl "https://api.litelog.de/api/v1/material/requests?status=pending&property_id=123&from=2026-12-01&to=2026-12-31" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"uuid": "7ddbefd5-bf88-4374-943f-4c5828e8aec8",
"property_id": 123,
"status": "pending",
"note": "Bitte bis Freitag liefern",
"requested_by_account_id": 41,
"requester_name": "Erika Musterfrau",
"decided_by": null,
"decided_at": null,
"reject_reason": null,
"fulfilled_by": null,
"fulfilled_at": null,
"source_warehouse_id": null,
"created_at": "2026-12-03T07:45:00.000Z",
"items": [
{
"item_id": 303,
"name": "Einmalhandschuhe Nitril (L)",
"unit": "Packung",
"qty": 5,
"approved_qty": null
},
{
"item_id": 302,
"name": "Müllbeutel 120 l",
"unit": "Rolle",
"qty": 10,
"approved_qty": null
}
]
}
],
"total": 1,
"page": 1,
"pageSize": 50
}
POST /v1/material/requests
Create a material request for a property.
List material requests (filters: status, property_id, item_id, from/to) / create one (uuid is mandatory).
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Idempotency-Key |
header | string (uuid) | no | Idempotency key as a header (draft-ietf-httpapi-idempotency-key-header), an alternative to the body field uuid. Without uuid in the body the header becomes the uuid (and so the id of the record); a repeated call with the same key and the same body answers 200 with duplicate: true instead of creating twice. The same key with a DIFFERENT body ⇒ 422 IDEMPOTENCY_KEY_PAYLOAD_MISMATCH (since 22.10.2026; the body fingerprint — SHA-256 of the canonical JSON without the key itself — is stored on create; records created before carry none and replay as before). Header and body uuid that differ ⇒ 422 (path: ["Idempotency-Key"]). Must be a UUID on this endpoint. |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
uuid |
string (uuid) | yes | — |
property_id |
integer | yes | — |
items |
array (object) | yes | At most 100 items. |
note |
string or null | no | — |
Example call
curl -X POST "https://api.litelog.de/api/v1/material/requests" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"uuid": "43865dc2-3b5e-40a1-a1ad-35d6f571e775",
"property_id": 123,
"items": [
{
"item_id": 301,
"qty": 4
}
],
"note": "Nachschub für die Wochenreinigung"
}'
Example response (201)
{
"data": {
"uuid": "43865dc2-3b5e-40a1-a1ad-35d6f571e775",
"property_id": 123,
"status": "pending",
"created_at": "2026-12-01T09:00:00.000Z"
},
"duplicate": false
}
GET /v1/material/requests/{id}
Request detail.
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
Example call
curl "https://api.litelog.de/api/v1/material/requests/7ddbefd5-bf88-4374-943f-4c5828e8aec8" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"uuid": "7ddbefd5-bf88-4374-943f-4c5828e8aec8",
"property_id": 123,
"status": "pending",
"note": "Bitte bis Freitag liefern",
"requested_by_account_id": 41,
"requester_name": "Erika Musterfrau",
"decided_by": null,
"decided_at": null,
"reject_reason": null,
"fulfilled_by": null,
"fulfilled_at": null,
"source_warehouse_id": null,
"created_at": "2026-12-03T07:45:00.000Z",
"items": [
{
"item_id": 303,
"name": "Einmalhandschuhe Nitril (L)",
"unit": "Packung",
"qty": 5,
"approved_qty": null
},
{
"item_id": 302,
"name": "Müllbeutel 120 l",
"unit": "Rolle",
"qty": 10,
"approved_qty": null
}
]
}
}
POST /v1/material/requests/{id}/approve
Approve a pending material request.
Approve, reject or fulfil a request (fulfil books both stock sides) / withdraw your own pending request.
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/requests/43865dc2-3b5e-40a1-a1ad-35d6f571e775/approve" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"warehouse_id": 1
}'
Example response (200)
{
"data": {
"uuid": "43865dc2-3b5e-40a1-a1ad-35d6f571e775",
"property_id": 123,
"status": "approved",
"note": "Nachschub für die Wochenreinigung",
"requested_by_account_id": 5,
"requester_name": "ERP-Schnittstelle",
"decided_by": 5,
"decided_at": "2026-12-01T09:20:00.000Z",
"reject_reason": null,
"fulfilled_by": null,
"fulfilled_at": null,
"source_warehouse_id": 1,
"created_at": "2026-12-01T09:00:00.000Z",
"items": [
{
"item_id": 301,
"name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"qty": 4,
"approved_qty": null
}
]
}
}
POST /v1/material/requests/{id}/reject
Reject a pending material request.
Approve, reject or fulfil a request (fulfil books both stock sides) / withdraw your own pending request.
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/requests/63222481-4b0d-47f8-b8f3-92a6c34ca019/reject" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"reason": "Menge zu hoch – bitte mit der Objektleitung abstimmen"
}'
Example response (200)
{
"data": {
"uuid": "63222481-4b0d-47f8-b8f3-92a6c34ca019",
"property_id": 124,
"status": "rejected",
"note": "Vorrat für das erste Quartal",
"requested_by_account_id": 42,
"requester_name": "Max Mustermann",
"decided_by": 5,
"decided_at": "2026-12-04T08:10:00.000Z",
"reject_reason": "Menge zu hoch – bitte mit der Objektleitung abstimmen",
"fulfilled_by": null,
"fulfilled_at": null,
"source_warehouse_id": null,
"created_at": "2026-12-03T15:20:00.000Z",
"items": [
{
"item_id": 302,
"name": "Müllbeutel 120 l",
"unit": "Rolle",
"qty": 50,
"approved_qty": null
}
]
}
}
POST /v1/material/requests/{id}/fulfill
Fulfil an approved request (books both stock sides).
Approve, reject or fulfil a request (fulfil books both stock sides) / withdraw your own pending request.
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/requests/43865dc2-3b5e-40a1-a1ad-35d6f571e775/fulfill" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"occurred_at": "2026-12-01T10:30:00Z"
}'
Example response (200)
{
"data": {
"uuid": "43865dc2-3b5e-40a1-a1ad-35d6f571e775",
"property_id": 123,
"status": "fulfilled",
"note": "Nachschub für die Wochenreinigung",
"requested_by_account_id": 5,
"requester_name": "ERP-Schnittstelle",
"decided_by": 5,
"decided_at": "2026-12-01T09:20:00.000Z",
"reject_reason": null,
"fulfilled_by": 5,
"fulfilled_at": "2026-12-01T10:30:00.000Z",
"source_warehouse_id": 1,
"created_at": "2026-12-01T09:00:00.000Z",
"items": [
{
"item_id": 301,
"name": "Allzweckreiniger 5 l",
"unit": "Kanister",
"qty": 4,
"approved_qty": null
}
]
}
}
POST /v1/material/requests/{id}/cancel
Withdraw an own pending request.
Approve, reject or fulfil a request (fulfil books both stock sides) / withdraw your own pending request.
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
Example call
curl -X POST "https://api.litelog.de/api/v1/material/requests/a5bd958f-a41b-4158-b951-07fa8febad4e/cancel" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"uuid": "a5bd958f-a41b-4158-b951-07fa8febad4e",
"property_id": 124,
"status": "cancelled",
"note": "Erstausstattung Wohnung 3",
"requested_by_account_id": 5,
"requester_name": "ERP-Schnittstelle",
"decided_by": null,
"decided_at": null,
"reject_reason": null,
"fulfilled_by": null,
"fulfilled_at": null,
"source_warehouse_id": null,
"created_at": "2026-12-04T09:30:00.000Z",
"items": [
{
"item_id": 302,
"name": "Müllbeutel 120 l",
"unit": "Rolle",
"qty": 10,
"approved_qty": null
}
]
}
}
GET /v1/material/stock-targets
Read min/target stock per property.
Read / set min and target stock per property (full replace).
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
property_id |
query | integer | yes | — |
Example call
curl "https://api.litelog.de/api/v1/material/stock-targets?property_id=123" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"item_id": 301,
"min_qty": 2,
"target_qty": 8
},
{
"item_id": 303,
"min_qty": 4,
"target_qty": 10
}
]
}
PUT /v1/material/stock-targets
Set min/target stock per property (full replace).
Read / set min and target stock per property (full replace).
Scope: material:write
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X PUT "https://api.litelog.de/api/v1/material/stock-targets" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"property_id": 123,
"targets": [
{
"item_id": 301,
"min_qty": 2,
"target_qty": 8
},
{
"item_id": 303,
"min_qty": 4,
"target_qty": 10
}
]
}'
Example response (200)
{
"data": [
{
"item_id": 301,
"min_qty": 2,
"target_qty": 8
},
{
"item_id": 303,
"min_qty": 4,
"target_qty": 10
}
]
}
POST /v1/material/counts
Record a stock count (inventory anchor).
Scope: material:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Idempotency-Key |
header | string (uuid) | no | Idempotency key as a header (draft-ietf-httpapi-idempotency-key-header), an alternative to the body field uuid. Without uuid in the body the header becomes the uuid (and so the id of the record); a repeated call with the same key and the same body answers 200 with duplicate: true instead of creating twice. The same key with a DIFFERENT body ⇒ 422 IDEMPOTENCY_KEY_PAYLOAD_MISMATCH (since 22.10.2026; the body fingerprint — SHA-256 of the canonical JSON without the key itself — is stored on create; records created before carry none and replay as before). Header and body uuid that differ ⇒ 422 (path: ["Idempotency-Key"]). Must be a UUID on this endpoint. |
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/counts" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"uuid": "1fd7e4a4-f711-4b57-849c-a6515ec72c6f",
"item_id": 301,
"property_id": 123,
"counted_qty": 4,
"counted_at": "2026-12-01T08:45:00Z",
"note": "Monatsinventur Dezember"
}'
Example response (201)
{
"data": {
"inserted": true
}
}
GET /v1/material/warehouses
List warehouses (central stock).
List / create central warehouses.
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
include_archived |
query | boolean | no | — |
Example call
curl "https://api.litelog.de/api/v1/material/warehouses" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"warehouse_id": 1,
"name": "Zentrallager",
"is_default": true,
"archived": false,
"note": null
},
{
"warehouse_id": 2,
"name": "Außenlager Süd",
"is_default": false,
"archived": false,
"note": "Zugang über den Hof, Tor 2"
}
]
}
POST /v1/material/warehouses
Create a warehouse.
List / create central warehouses.
Scope: material:write
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/warehouses" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"name": "Außenlager Süd",
"note": "Zugang über den Hof, Tor 2"
}'
Example response (201)
{
"data": {
"warehouse_id": 2,
"name": "Außenlager Süd",
"is_default": false
}
}
POST /v1/material/warehouse/movements
Book central-stock movements (goods receipt, withdrawal).
Scope: material:write
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/warehouse/movements" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"warehouse_id": 1,
"movements": [
{
"uuid": "d7489856-11ac-4421-bc8a-7778435a8393",
"item_id": 301,
"qty": 40,
"reason": "delivery",
"occurred_at": "2026-12-01T08:30:00Z",
"note": "Wareneingang Lieferschein 4711"
}
]
}'
Example response (201)
{
"data": {
"inserted_uuids": [
"d7489856-11ac-4421-bc8a-7778435a8393"
],
"duplicate_uuids": []
}
}
GET /v1/material/units
List units (serialized items — keys, devices).
List units (individual pieces with a serial number — keys, devices), create one, or create a series (e.g. SCHL-001…020).
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
item_id |
query | integer | no | — |
account_id |
query | integer | no | — |
search |
query | string | no | — |
status |
query | string | no | Values: active, archived; Default: active. |
Example call
curl "https://api.litelog.de/api/v1/material/units?item_id=310" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"unit_id": 501,
"uuid": "6115088d-4682-4f98-bf72-60360393b412",
"item_id": 310,
"item_name": "Generalschlüssel Filiale Nord",
"serial_no": "SCHL-001",
"chip_id": "04A2B91C5E6F80",
"holder_type": "account",
"holder_id": 41,
"holder_name": "Erika Musterfrau",
"status": "issued",
"note": "Haupteingang und Lager",
"created_at": "2026-12-01T11:00:00.000Z"
},
{
"unit_id": 502,
"uuid": "38ed884c-8b20-4b94-8345-ed5406482e67",
"item_id": 310,
"item_name": "Generalschlüssel Filiale Nord",
"serial_no": "SCHL-002",
"chip_id": null,
"holder_type": null,
"holder_id": null,
"holder_name": null,
"status": "available",
"note": "Reserve",
"created_at": "2026-12-01T11:05:00.000Z"
}
],
"total": 2,
"page": 1,
"pageSize": 50
}
POST /v1/material/units
Create a unit (key/device instance).
List units (individual pieces with a serial number — keys, devices), create one, or create a series (e.g. SCHL-001…020).
Scope: material:write
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/units" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"item_id": 310,
"serial_no": "SCHL-001",
"chip_id": "04A2B91C5E6F80",
"note": "Haupteingang und Lager"
}'
Example response (201)
{
"data": {
"unit_id": 501,
"uuid": "6115088d-4682-4f98-bf72-60360393b412",
"item_id": 310,
"item_name": null,
"serial_no": "SCHL-001",
"chip_id": "04A2B91C5E6F80",
"holder_type": null,
"holder_id": null,
"holder_name": null,
"status": "available",
"note": "Haupteingang und Lager",
"created_at": "2026-12-01T11:00:00.000Z"
}
}
GET /v1/material/units/{id}
Unit detail including hand-over history.
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Example call
curl "https://api.litelog.de/api/v1/material/units/501" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"unit_id": 501,
"uuid": "6115088d-4682-4f98-bf72-60360393b412",
"item_id": 310,
"item_name": "Generalschlüssel Filiale Nord",
"serial_no": "SCHL-001",
"chip_id": "04A2B91C5E6F80",
"holder_type": "account",
"holder_id": 41,
"holder_name": "Erika Musterfrau",
"status": "issued",
"note": "Haupteingang und Lager",
"created_at": "2026-12-01T11:00:00.000Z",
"history": [
{
"movement_id": 9102,
"uuid": "1f66167e-8e24-4701-bf78-2adc5125b592",
"qty": "1.000",
"reason": "issue",
"occurred_at": "2026-12-02T07:30:00.000Z",
"holder_type": "account",
"holder_id": 41,
"holder_name": "Erika Musterfrau",
"actor_name": "ERP-Schnittstelle",
"note": "Schlüsselübergabe Frühschicht",
"transfer_uuid": "1f66167e-8e24-4701-bf78-2adc5125b592",
"receipt_id": null
},
{
"movement_id": 9101,
"uuid": "2e718424-e0ed-5097-a6bc-3443ce70e1d2",
"qty": "-1.000",
"reason": "issue",
"occurred_at": "2026-12-02T07:30:00.000Z",
"holder_type": "stock",
"holder_id": 1,
"holder_name": null,
"actor_name": "ERP-Schnittstelle",
"note": "Schlüsselübergabe Frühschicht",
"transfer_uuid": "1f66167e-8e24-4701-bf78-2adc5125b592",
"receipt_id": null
}
]
}
}
POST /v1/material/units/bulk
Create a series of units (e.g. keys SCHL-001…020).
List units (individual pieces with a serial number — keys, devices), create one, or create a series (e.g. SCHL-001…020).
Scope: material:write
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/units/bulk" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"item_id": 310,
"units": [
{
"serial_no": "SCHL-001"
},
{
"serial_no": "SCHL-002",
"note": "Reserve"
}
]
}'
Example response (201)
{
"data": {
"created": [
{
"unit_id": 502,
"serial_no": "SCHL-002"
}
],
"conflicts": [
{
"index": 0,
"serial_no": "SCHL-001",
"reason": "serial"
}
]
}
}
GET /v1/material/receipts
List hand-over receipts (issue/return documents).
List hand-over receipts (filter: account_id) / receipt detail with positions.
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
account_id |
query | integer | no | — |
Example call
curl "https://api.litelog.de/api/v1/material/receipts?account_id=42" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"receipt_id": 77,
"uuid": "043d3390-ee2e-4ca5-ba36-ca2cf4829e75",
"account_id": 42,
"account_name": "Max Mustermann",
"issued_by_account_id": 41,
"issued_by_name": "Erika Musterfrau",
"kind": "issue",
"signed": true,
"signer_name": "Max Mustermann",
"signed_at": "2026-12-02T06:55:00.000Z",
"note": "Ausstattung Frühschicht Haus Seeblick",
"line_count": 2,
"created_at": "2026-12-02T06:56:00.000Z"
}
],
"total": 1,
"page": 1,
"pageSize": 50
}
GET /v1/material/receipts/{id}
Receipt detail incl. item positions.
List hand-over receipts (filter: account_id) / receipt detail with positions.
Scope: material:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
Example call
curl "https://api.litelog.de/api/v1/material/receipts/043d3390-ee2e-4ca5-ba36-ca2cf4829e75" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"receipt_id": 77,
"uuid": "043d3390-ee2e-4ca5-ba36-ca2cf4829e75",
"account_id": 42,
"account_name": "Max Mustermann",
"issued_by_account_id": 41,
"issued_by_name": "Erika Musterfrau",
"kind": "issue",
"signed": true,
"signer_name": "Max Mustermann",
"signed_at": "2026-12-02T06:55:00.000Z",
"note": "Ausstattung Frühschicht Haus Seeblick",
"line_count": 2,
"created_at": "2026-12-02T06:56:00.000Z",
"lines": [
{
"item_id": 303,
"item_name": "Einmalhandschuhe Nitril (L)",
"unit": "Packung",
"qty": 2,
"serial_no": null,
"unit_price_cents": 890
},
{
"item_id": 311,
"item_name": "Transponder Haus Seeblick",
"unit": "Stk",
"qty": 1,
"serial_no": "TRSP-014",
"unit_price_cents": 2500
}
]
}
}
POST /v1/material/transfers
Issue/return/report loss to persons (e.g. key hand-over).
Scope: material:write
Body fields (JSON)
The example shows the structure of the body.
Example call
curl -X POST "https://api.litelog.de/api/v1/material/transfers" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"transfers": [
{
"uuid": "1f66167e-8e24-4701-bf78-2adc5125b592",
"item_id": 310,
"qty": 1,
"reason": "issue",
"from": {
"type": "stock",
"id": 1
},
"to": {
"type": "account",
"id": 41
},
"unit_uuid": "6115088d-4682-4f98-bf72-60360393b412",
"occurred_at": "2026-12-02T07:30:00Z",
"note": "Schlüsselübergabe Frühschicht"
}
]
}'
Example response (201)
{
"data": {
"inserted_uuids": [
"2e718424-e0ed-5097-a6bc-3443ce70e1d2",
"1f66167e-8e24-4701-bf78-2adc5125b592"
],
"duplicate_uuids": [],
"conflicts": []
}
}
