REST API
Labels API
Manage label templates, barcodes, and printing.
Generated from the Celerp 2.4.0 OpenAPI schema, 16 September 2026.
POST /api/labels/bulk-print
Bulk Print
Generate a PDF label sheet for multiple items.
Request body
| Field | Type | Required | Description |
|---|
entity_ids | array of string | yes | Entity Ids |
template_id | string, optional | -- | Template Id |
Responses
| Status | Description | Body |
|---|
200 | Successful Response | -- |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/api/labels/bulk-print \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'
POST /api/labels/print/{entity_id}
Print Single
Generate a PDF label for a single item.
Parameters
| Name | In | Required | Type | Description |
|---|
entity_id | path | yes | string | -- |
Responses
| Status | Description | Body |
|---|
200 | Successful Response | -- |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/api/labels/print/:entity_id \
-H "Authorization: Bearer $TOKEN"
GET /api/labels/templates
List Templates
Responses
| Status | Description | Body |
|---|
200 | Successful Response | object |
Example
curl -X GET http://localhost:8000/api/labels/templates \
-H "Authorization: Bearer $TOKEN"
POST /api/labels/templates
Create Template
Request body
| Field | Type | Required | Description |
|---|
name | string | yes | Name |
format | string | -- | Format |
orientation | string | -- | Orientation |
width_mm | number, optional | -- | Width Mm |
height_mm | number, optional | -- | Height Mm |
fields | array of object | -- | Fields |
copies | integer | -- | Copies |
notes | string, optional | -- | Notes |
Responses
| Status | Description | Body |
|---|
201 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/api/labels/templates \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'
GET /api/labels/templates/{template_id}
Get Template
Parameters
| Name | In | Required | Type | Description |
|---|
template_id | path | yes | string | -- |
Responses
| Status | Description | Body |
|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X GET http://localhost:8000/api/labels/templates/:template_id \
-H "Authorization: Bearer $TOKEN"
PUT /api/labels/templates/{template_id}
Update Template
Parameters
| Name | In | Required | Type | Description |
|---|
template_id | path | yes | string | -- |
Request body
| Field | Type | Required | Description |
|---|
name | string, optional | -- | Name |
format | string, optional | -- | Format |
orientation | string, optional | -- | Orientation |
width_mm | number, optional | -- | Width Mm |
height_mm | number, optional | -- | Height Mm |
fields | array of object, optional | -- | Fields |
copies | integer, optional | -- | Copies |
notes | string, optional | -- | Notes |
Responses
| Status | Description | Body |
|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X PUT http://localhost:8000/api/labels/templates/:template_id \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'
DELETE /api/labels/templates/{template_id}
Delete Template
Parameters
| Name | In | Required | Type | Description |
|---|
template_id | path | yes | string | -- |
Responses
| Status | Description | Body |
|---|
204 | Successful Response | -- |
422 | Validation Error | HTTPValidationError |
Example
curl -X DELETE http://localhost:8000/api/labels/templates/:template_id \
-H "Authorization: Bearer $TOKEN"