Overview
Asset types define the structure and custom fields for inventory items. Each asset type belongs to a container and includes field definitions that specify what data can be captured for items of that type. Asset types support image uploads, serialization settings, and collection-specific field mappings.
Create Asset Type
POST /containers/{containerId}/asset-types
Content-Type : multipart/form-data
Create a new asset type within a container with custom field definitions.
ID of the parent container
Asset type name (e.g., “Electronics”, “Books”, “Collectibles”)
Whether items of this type are serialized:
true - Each item is unique with quantity=1 (default)
false - Items can have variable quantities
JSON-encoded array of custom field definition objects Show field definition structure
Unique identifier for the field (e.g., “brand”, “condition”)
Display label for the field
Field type: text, number, date, boolean, select, multiselect, textarea
Whether the field is required
Available options for select and multiselect types
ID of a DataList to use for dynamic select options
Example: [
{
"id" : "brand" ,
"label" : "Brand" ,
"type" : "text" ,
"required" : true
},
{
"id" : "condition" ,
"label" : "Condition" ,
"type" : "select" ,
"options" : [ "New" , "Like New" , "Good" , "Fair" , "Poor" ]
}
]
Optional image file for the asset type icon/thumbnail
curl -X POST "https://api.invenicum.com/containers/5/asset-types" \
-H "Authorization: Bearer {token}" \
-F "name=Electronics" \
-F "isSerialized=true" \
-F 'fieldDefinitions=[{"id":"brand","label":"Brand","type":"text","required":true},{"id":"model","label":"Model","type":"text"},{"id":"condition","label":"Condition","type":"select","options":["New","Like New","Good","Fair"]}]' \
-F "[email protected] "
{
"data" : {
"id" : 12 ,
"name" : "Electronics" ,
"isSerialized" : true ,
"fieldDefinitions" : [
{
"id" : "brand" ,
"label" : "Brand" ,
"type" : "text" ,
"required" : true
},
{
"id" : "model" ,
"label" : "Model" ,
"type" : "text" ,
"required" : false
},
{
"id" : "condition" ,
"label" : "Condition" ,
"type" : "select" ,
"required" : false ,
"options" : [ "New" , "Like New" , "Good" , "Fair" ]
}
],
"images" : [
{
"id" : 78 ,
"url" : "https://storage.example.com/asset-type-12.jpg" ,
"altText" : null ,
"order" : 0
}
],
"possessionFieldId" : null ,
"desiredFieldId" : null
}
}
Unique identifier for the asset type
Whether items are serialized (quantity=1) or can have variable quantities
Array of custom field definitions Whether field is required
Available options for select fields
Reference to a DataList for dynamic options
Array of image objects associated with the asset type Field ID used to track “possessed” count in collections (nullable)
Field ID used to track “desired” count in collections (nullable)
Get Asset Type
GET /asset-types/{assetTypeId}
Retrieve a single asset type by ID.
ID of the asset type to retrieve
{
"data" : {
"id" : 12 ,
"name" : "Electronics" ,
"isSerialized" : true ,
"fieldDefinitions" : [
{
"id" : "brand" ,
"label" : "Brand" ,
"type" : "text" ,
"required" : true
}
],
"images" : [],
"possessionFieldId" : null ,
"desiredFieldId" : null
}
}
Update Asset Type
PATCH /asset-types/{assetTypeId}
Content-Type : multipart/form-data
Update an existing asset type’s name, field definitions, or image.
ID of the asset type to update
JSON-encoded array of updated field definitions
New image file to upload (replaces existing)
Set to true to remove the current image without uploading a new one
curl -X PATCH "https://api.invenicum.com/asset-types/12" \
-H "Authorization: Bearer {token}" \
-F "name=Consumer Electronics" \
-F 'fieldDefinitions=[{"id":"brand","label":"Brand Name","type":"text","required":true}]' \
-F "removeExistingImage=false"
{
"data" : {
"id" : 12 ,
"name" : "Consumer Electronics" ,
"isSerialized" : true ,
"fieldDefinitions" : [
{
"id" : "brand" ,
"label" : "Brand Name" ,
"type" : "text" ,
"required" : true
}
],
"images" : [
{
"id" : 78 ,
"url" : "https://storage.example.com/asset-type-12.jpg" ,
"altText" : null ,
"order" : 0
}
]
}
}
Update Collection Fields
PATCH /asset-types/{assetTypeId}/collection-fields
Content-Type : application/json
Update the field mappings used for collection tracking. Collections use specific fields to track how many items are possessed vs. desired.
Field ID that tracks “possessed” quantity (set to null to clear)
Field ID that tracks “desired” quantity (set to null to clear)
{
"possessionFieldId" : "qty_owned" ,
"desiredFieldId" : "qty_wanted"
}
{
"data" : {
"id" : 12 ,
"name" : "Trading Cards" ,
"possessionFieldId" : "qty_owned" ,
"desiredFieldId" : "qty_wanted" ,
"fieldDefinitions" : [
{
"id" : "qty_owned" ,
"label" : "Quantity Owned" ,
"type" : "number"
},
{
"id" : "qty_wanted" ,
"label" : "Quantity Wanted" ,
"type" : "number"
}
]
}
}
Delete Asset Type
DELETE /asset-types/{assetTypeId}
Permanently delete an asset type. This operation:
First deletes all inventory items of this type (DELETE /asset-types/{assetTypeId}/assets)
Then deletes the asset type itself
This is a destructive operation that cannot be undone. All items associated with this asset type will be permanently deleted.
ID of the asset type to delete
Error Responses
{
"message" : "El tipo de activo no existe o ya fue eliminado."
}
Common errors:
404 Not Found - Asset type doesn’t exist or was already deleted
401 Unauthorized - Invalid or expired authentication token
Field Definition Types
When creating or updating asset types, the following field types are available:
Text Fields
{
"id" : "description" ,
"label" : "Description" ,
"type" : "text" ,
"required" : false
}
Single-line text input.
Textarea Fields
{
"id" : "notes" ,
"label" : "Notes" ,
"type" : "textarea" ,
"required" : false
}
Multi-line text input.
Number Fields
{
"id" : "price" ,
"label" : "Purchase Price" ,
"type" : "number" ,
"required" : false
}
Numeric input (integer or decimal).
Date Fields
{
"id" : "purchase_date" ,
"label" : "Purchase Date" ,
"type" : "date" ,
"required" : false
}
Date picker input.
Boolean Fields
{
"id" : "is_certified" ,
"label" : "Certified Authentic" ,
"type" : "boolean" ,
"required" : false
}
Checkbox (true/false).
Select Fields (Single Choice)
{
"id" : "condition" ,
"label" : "Condition" ,
"type" : "select" ,
"required" : true ,
"options" : [ "Mint" , "Near Mint" , "Excellent" , "Good" , "Fair" , "Poor" ]
}
Dropdown with predefined options.
Multi-Select Fields
{
"id" : "tags" ,
"label" : "Tags" ,
"type" : "multiselect" ,
"required" : false ,
"options" : [ "Vintage" , "Rare" , "Limited Edition" , "Signed" ]
}
Multiple choice selection.
Dynamic Select (DataList)
{
"id" : "category" ,
"label" : "Category" ,
"type" : "select" ,
"required" : false ,
"dataListId" : 5
}
Dropdown populated from a DataList (see Containers ).
Best Practices
Field ID Naming
Use consistent, descriptive IDs:
Use lowercase with underscores: serial_number, purchase_date
Avoid special characters except underscores
Keep IDs stable - changing them breaks existing item data
Serialization Strategy
Use isSerialized: true for:
Unique items (electronics, collectibles, art)
Items with serial numbers or unique identifiers
Items where each instance is distinct
Use isSerialized: false for:
Bulk consumables (screws, cables, office supplies)
Fungible items where individual instances don’t matter
Items tracked by total quantity rather than individual units
Collection Fields
For collection management:
Create number fields for possession and desire tracking
Use the Update Collection Fields endpoint to map them
The frontend can then show “5/10” style progress indicators
{
"fieldDefinitions" : [
{ "id" : "owned" , "label" : "Owned" , "type" : "number" },
{ "id" : "wanted" , "label" : "Wanted" , "type" : "number" }
],
"possessionFieldId" : "owned" ,
"desiredFieldId" : "wanted"
}
Error Handling
All endpoints return standard HTTP status codes:
200 OK - Request successful
201 Created - Asset type created successfully
204 No Content - Deletion successful
400 Bad Request - Invalid field definitions or malformed JSON
401 Unauthorized - Authentication required
404 Not Found - Asset type not found
500 Internal Server Error - Server error
Error responses include a message:
{
"message" : "Error description"
}