Skip to main content

Labels

List all available labels​

Request​

GET http://printer/api/v3/labels

Response​

Dictionary of objects.

Get a label​

Request​

GET http://printer/api/v3/labels/{name}

Path Parameters​

NameTypeDescription
nameStringLabel name

Response​

Label object.

Delete a label​

Request​

DELETE http://printer/api/v3/labels/{name}

Path Parameters​

NameTypeDescription
nameStringLabel name

Response​

None.

Create or modify a label​

Request​

PUT http://printer/api/v3/labels/{name}

See Label.

Path Parameters​

NameTypeDescription
nameStringLabel name

Response​

None.

Get a print simulation of a label​

Request​

GET http://printer/api/v3/labels/{name}/simulation

Path Parameters​

NameTypeDescription
nameStringLabel name

Query Parameters​

NameTypeDescription
tableNameStringOptional table name.
keyColumnStringOptional column to search for a key.
keyStringOptional key value to search for.

Response​

A PNG image of the label.

Examples​

Without table:

GET http://printer/api/v3/labels/MyLabel/simulation

With table:

GET http://printer/api/v3/labels/MyLabel/simulation?tableName=MyTable&keyColumn=SKU&key=12345

Get a pixmap of a label v5.4​

Removed

This endpoint was removed in v6.0. To render a label to an image, use Get a print simulation of a label or Get a bitmap of a label.

Render a label for a printer at a given resolution, with the printer's color channels. See getLabelPixmap for details.

Request​

GET http://printer/api/v3/labels/{name}/pixmap?dpi={dpi}

Path Parameters​

NameTypeDescription
nameStringLabel name

Query Parameters​

NameTypeDescription
dpiIntegerResolution in dots per inch.
printerStringPrinter ID. Required if more than one printer is available.
tableNameStringOptional table name.
keyColumnStringOptional column to search for a key.
keyStringOptional key value to search for.

Response​

A PNG image of the label, or a TIFF image for a CMYK printer, as given by the Content-Type header. Returns 404 Not Found if the label does not exist, and 400 Bad Request if dpi is missing or invalid.

Examples​

GET http://printer/api/v3/labels/MyLabel/pixmap?dpi=300

Get a bitmap of a label v5.2.4​

Render a label to a printer-independent, bi-level (black and white) PNG image at a given resolution. See getLabelBitmap for details.

Request​

GET http://printer/api/v3/labels/{name}/bitmap?dpi={dpi}

Path Parameters​

NameTypeDescription
nameStringLabel name

Query Parameters​

NameTypeDescription
dpiIntegerResolution in dots per inch.
tableNameStringOptional table name.
keyColumnStringOptional column to search for a key.
keyStringOptional key value to search for.

Response​

A PNG image of the label. Returns 404 Not Found if the label does not exist, and 400 Bad Request if dpi is missing or invalid.

Examples​

GET http://printer/api/v3/labels/MyLabel/bitmap?dpi=300

With table:

GET http://printer/api/v3/labels/MyLabel/bitmap?dpi=300&tableName=MyTable&keyColumn=SKU&key=12345