Create an inventory type
Die API läuft auf deiner Anwendungsinstanz. Schemas und Feldnamen stammen unverändert aus der OpenAPI-Spezifikation. Browsergebundene Aufrufe benötigen eine Sitzung auf der Instanz.
Requires an authenticated administrator browser session. Type keys are stable identifiers used by inventory records.
adminSessionauthjs.session-token<token>Authenticated Auth.js browser session cookie; each operation declares its required permission. Not restricted to administrators. HTTPS deployments use the secure-prefixed cookie variant.
X-Organization-ID?stringOrganization membership selected for this request. User-bound credentials may select any active membership; standalone tokens may only repeat their pinned organization ID.
uuidapplication/json- body
key*stringStable key of an administrator-configurable inventory type.
^[a-z][a-z0-9_-]{0,63}$1 <= length <= 64label*string1 <= length <= 120description?stringlength <= 5000""color?string1 <= length <= 32"#635bff"icon?string1 <= length <= 80"box"canContain?booleanRecords of this type can be used as parents and structured stock locations.
falsespatialContainment?booleanAutomatically derive containment from map polygons. Requires canContain.
falseposition?integer0 <= value <= 1000000Inventory type created
application/json- response
type*curl -X POST 'https://inventory.example.com/api/v1/inventory-types' \ -H 'Content-Type: application/json' \ -d '{ "key": "string", "label": "string"}'{ "type": { "key": "string", "label": "string", "description": "string", "color": "string", "icon": "string", "canContain": true, "spatialContainment": true, "position": 0, "isSystem": true, "createdBy": "string", "updatedBy": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "archivedAt": "2019-08-24T14:15:22Z" }}List configured inventory types GET
Requires the read scope. Active definitions are returned in configured display order. Administrators may include archived definitions.
Archive an inventory type DELETE
Requires an authenticated administrator browser session. Existing inventory records retain their type; the fallback type cannot be archived.