Download OpenAPI specification:
Item management service.
Git Commit ID: d14e0d5e25b97b49cc9cd4e667800f701236d40d
Software Version: 0.0.1
Build: 2026-08-13 09:13:51
Creates a new item, updates an existing item by item_id, or finds an existing item by stock, position, and number.
For new items, stock, position, and item_name are required. If no number is supplied for a new item, an available item number is generated automatically.
| item_id | integer or null Existing item ID to update |
| stock | string or null <= 3 characters Stock code. Required when creating a new item. |
| position | string or null [ 1 .. 8 ] characters Stock position. Required when creating a new item. |
| number | integer or null Item number used with stock and position to find an existing item |
| item_name | string or null Item name. Required when creating a new item. |
| item_qty | integer or null |
| status | string or null |
| condition | string or null |
| item_image | string or null Item image as a data URI (e.g. data:image/jpeg;base64,...) |
| id_account | integer or null Account ID to link the item to |
| id_ticket | integer or null Ticket ID to link the item to |
object or null Key/value metadata to sync for the item |
{- "stock": "A",
- "position": "B12",
- "item_name": "Laptop charger",
- "item_qty": 1,
- "status": "in",
- "condition": "working"
}{- "message": "Item updated.",
- "item": { },
- "pdf": "data:application/pdf;base64,JVBERi0xLjQK..."
}Searches for items by integer ID, id_ticket, id_account, full item number, or free text (item name). Normal text search terms are trimmed and must be 3-30 characters long. Numeric search terms (plain integers) bypass the 3-character minimum length requirement.
Requires Priv items_search_stocks for non-service calls.
Accepts comma-separated stock codes (e.g. "NAU,GEP") or all.
Items whose stock does not match the user's allowed values are removed from results
(except for id_ticket and id_account searches, which return all matching items unfiltered).
search_term formats:
"42"): searches by items.id.{"id_ticket": 31090}): searches items linked to that ticket.
No stock permission filtering is applied!!! Intended for internal service calls.{"id_account": 500}): searches items linked to that account.
No stock permission filtering is applied!!! Intended for internal service calls."NAUB1200042"): parsed into stock, position, number components.item_name using accent-insensitive ILIKE.Response items include all fields from the items table plus related metas.
required | string or object |
{- "search_term": "NAUB1200042"
}{- "message": "string",
- "items": [
- {
- "id": 0,
- "stock": "string",
- "position": "string",
- "number": 0,
- "item_nr": "string",
- "item_name": "string",
- "item_qty": 0,
- "status": "string",
- "condition": "string",
- "updated_at": "string",
- "metas": [
- {
- "id": 0,
- "keyword": "string",
- "value": "string"
}
]
}
]
}Returns all log entries associated with the given item ID.
Requires the Priv items_search_stocks permission, and the item's
stock must be included in the user's allowed stock list.
| Privilege name | Sample values | Description |
|---|---|---|
| Priv items_search_stocks * | NAU,GEP / all | Grants access to retrieve item logs. The item's stock must match the allowed stocks. Without it, the request is denied with 403. |
| * required permission. | ||
| id required | integer Item ID to retrieve logs for |
{- "id": 42
}{- "logs": [
- {
- "id": 1001,
- "created_at": "2026-05-19 14:30:00",
- "flag": "info",
- "ip_address": "192.168.1.1",
- "message": "Item updated",
- "message_meta": { }
}
]
}Internal endpoint. Receives the current defaults ({ keyword: value } map) from the emails service and writes them to this service's local defaults.json, but only if the content changed (or the file does not exist yet). Only service-to-service calls (service JWT) are accepted.
required | object Map of keyword to value |
| revision required | integer <int64> >= 0 DB-clock revision of the distributed defaults; older revisions are ignored! |
{- "defaults": {
- "accounts_verifyemail_subject": "Please verify your O.Z.O.R.A. Pass account email",
- "general_emailfrom_oz": "O.Z.O.R.A. Pass <[email protected]>"
}, - "revision": 1786190488163
}{- "message": "Defaults file updated.",
- "created": false,
- "changed": true,
- "rejected": false
}