Stocks/Label templates
Create label template
Creates a new JSON-based label template.
AuthorizationBearer <token>
In: header
namestring
Template name
widthnumber
Label width in mm
heightnumber
Label height in mm
json_layoutstring
JSON layout definition
margin_left?number
Left margin in mm
margin_top?number
Top margin in mm
barcode_type?string
Barcode format (EAN-13, CODE128)
orientation?string
Page orientation (P or L)
sort_order?integer
Sort order
Response Body
curl -X POST "https://og-tenant1.test:8003/api/v2/stocks/label-templates" \
-H "Content-Type: application/json" \
-d '{
"name": "string",
"width": 0,
"height": 0,
"json_layout": "string"
}'{
"data": {
"id": 0,
"name": "string",
"layout_file": "string",
"json_layout": "string",
"width": 0,
"height": 0,
"margin_left": 0,
"margin_top": 0,
"barcode_type": "string",
"orientation": "string",
"sort_order": 0,
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}