curl --request POST \
--url https://clarus-api.com/api/storage_units/{id}/crossdock_label \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Clarus-Subdomain: <api-key>' \
--data '
{
"data": {
"type": "storage_units",
"attributes": {
"cloud_print": true,
"printer_id": 1
}
}
}
'import requests
url = "https://clarus-api.com/api/storage_units/{id}/crossdock_label"
payload = { "data": {
"type": "storage_units",
"attributes": {
"cloud_print": True,
"printer_id": 1
}
} }
headers = {
"Authorization": "Bearer <token>",
"X-Clarus-Subdomain": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Bearer <token>',
'X-Clarus-Subdomain': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({data: {type: 'storage_units', attributes: {cloud_print: true, printer_id: 1}}})
};
fetch('https://clarus-api.com/api/storage_units/{id}/crossdock_label', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"id": 1,
"type": "documents",
"attributes": {
"status": "processing"
}
}
}{
"error": "<string>"
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}Print a cross-dock label for a storage unit
Generate the cross-dock storage unit (LPN) label for a storage unit. The template is resolved automatically from configuration - the customer’s crossdock_storage_unit_label_template_id if set, otherwise the account’s external_crossdock_options.crossdock_storage_unit_label_template_id, otherwise the account default for the crossdock_storage_unit_label template type. No template can be supplied in the request.
The storage unit must already have an allocation or pick transaction, which happens once its receive task has completed. Called earlier the document is marked failed.
When cloud_print is true, the label is sent directly to the specified printer. When cloud_print is false or omitted, the response is a PDF binary stream (not JSON).
curl --request POST \
--url https://clarus-api.com/api/storage_units/{id}/crossdock_label \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Clarus-Subdomain: <api-key>' \
--data '
{
"data": {
"type": "storage_units",
"attributes": {
"cloud_print": true,
"printer_id": 1
}
}
}
'import requests
url = "https://clarus-api.com/api/storage_units/{id}/crossdock_label"
payload = { "data": {
"type": "storage_units",
"attributes": {
"cloud_print": True,
"printer_id": 1
}
} }
headers = {
"Authorization": "Bearer <token>",
"X-Clarus-Subdomain": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Bearer <token>',
'X-Clarus-Subdomain': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({data: {type: 'storage_units', attributes: {cloud_print: true, printer_id: 1}}})
};
fetch('https://clarus-api.com/api/storage_units/{id}/crossdock_label', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"id": 1,
"type": "documents",
"attributes": {
"status": "processing"
}
}
}{
"error": "<string>"
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}Request Structure
{
"data": {
"type": "storage_units",
"attributes": {
"cloud_print": true,
"printer_id": 1
}
}
}
Key Fields
| Field | Required | Description |
|---|---|---|
cloud_print | No | When true, sends to printer via PrintNode instead of returning PDF |
printer_id | No | PrintNode printer ID (required when cloud_print is true) |
Template Selection
The label template is never chosen in the request. It resolves in order: the customer’s configured cross-dock label, then the account’s cross-dock label default, then the account default for thecrossdock_storage_unit_label type.
Response Behavior
- With
cloud_print: true: Returns JSON acknowledgement that the print job was sent - Without
cloud_print: Returns a PDF binary stream (application/pdf)
Authorizations
OAuth 2.0 authentication. Use the client credentials or authorization code flow to obtain an access token.
The subdomain/tenant name identifying which tenant's data to access. Required for all API requests.
Path Parameters
The unique identifier of the storage unit
Body
Show child attributes
Show child attributes
Response
Label print job created successfully (when cloud_print is true) or PDF binary stream (when cloud_print is false)
Show child attributes
Show child attributes

