Skip to content

Where the margin ID and the feed mark of a new sheet would go on a printer

GET
/api/v1/sheets/margin-check
curl --request GET \
--url 'https://example.com/api/v1/sheets/margin-check?type=example&printer=example' \
--header 'X-Label-Hub-Key: <X-Label-Hub-Key>'

What the first job of a new sheet of the type would do on this printer and tray: the band and corner of the margin ID, whether a QR is drawn next to it, and whether the feed-direction mark prints (in the hub’s current language). printable=false means no margin band is deep enough: the sheet can still be created and the ID added by hand. Read-only.

type
required
Type

Sheet type key.

string
<= 64 characters

Sheet type key.

printer
required
Printer

Slug or UUID.

string
>= 1 characters <= 100 characters

Slug or UUID.

tray
Tray
Any of:
string
>= 1 characters <= 100 characters

Successful Response

Media typeapplication/json
MarginCheckRead

Whether, where and how the margin ID and the feed mark fit a sheet type on a printer.

object
band
required
Band

The band the margin ID goes into, or null.

Any of:
string
Allowed values: top bottom right left
bands_mm
required
MarginBandsMm

Room of each margin band in mm, uncapped; negative if there is none.

object
bottom
required
Bottom
number
left
required
Left
number
right
required
Right
number
top
required
Top
number
corner
required
Corner
Any of:
string
Allowed values: top_left top_right bottom_left
feed_mark
required
Feed Mark

Whether the feed-direction mark prints, in the hub’s current language.

boolean
printable
required
Printable

Whether the margin ID fits somewhere at all.

boolean
qr
required
Qr

Whether a QR is drawn next to the margin text.

boolean
reason
required
Reason

Why not, when printable is false.

Any of:
string
usable_mm
required
Usable Mm

Depth of the chosen band that is drawn (capped).

Any of:
number

Example

{
"band": "top",
"corner": "top_left"
}

These credentials may not use this printer.

Media typeapplication/json
object
detail
required
object
error_code
required
string
error_detail
Any of:
object
key
additional properties
any
error_message
required
string

Example generated

{
"detail": {
"error_code": "example",
"error_detail": {},
"error_message": "example"
}
}

Unknown printer (printer_not_found) or sheet type.

Media typeapplication/json
object
detail
required
object
error_code
required
string
error_detail
Any of:
object
key
additional properties
any
error_message
required
string

Example generated

{
"detail": {
"error_code": "example",
"error_detail": {},
"error_message": "example"
}
}

Not a page printer (media_kind_mismatch) or it is disabled.

Media typeapplication/json
object
detail
required
object
error_code
required
string
error_detail
Any of:
object
key
additional properties
any
error_message
required
string

Example generated

{
"detail": {
"error_code": "example",
"error_detail": {},
"error_message": "example"
}
}

Invalid request (invalid_request) or an unknown tray.

Media typeapplication/json
object
detail
required
object
error_code
required
string
error_detail
Any of:
object
key
additional properties
any
error_message
required
string

Example generated

{
"detail": {
"error_code": "example",
"error_detail": {},
"error_message": "example"
}
}