Skip to main content

Documentation · API v1

API documentation

Everything you need to generate ZPL labels with a single API call.

Quick Start

Generate your first label. Replace YOUR_API_KEY with the key from your dashboard.

curl -X POST https://api.zeepler.com/v1/zeeplify \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "config": {
      "size": "4x2"
    },
    "data": {
      "product": "Widget Pro",
      "sku": "WDG-001"
    },
    "templates": [
      {
        "type": "Text",
        "dataPath": "product",
        "coords": [
          50,
          30
        ],
        "font": "0,40"
      },
      {
        "type": "BarCode",
        "dataPath": "sku",
        "coords": [
          50,
          100
        ],
        "style": "code128"
      }
    ]
  }'

Authentication

Every request carries your API key in the x-api-key header. Generate one in your dashboard; it starts with zpl_. A missing, unknown or disabled key is answered with 401.

http
POST /v1/zeeplify
Host: api.zeepler.com
x-api-key: zpl_your_api_key
Content-Type: application/json

Request Body

The request body contains your label data and templates.

configobjectrequired

Label configuration

json
{
  "size": "4x2"  // "3x1" or "4x2"
  // "lang" is optional and only takes "zpl", which is the default
}
dataobjectrequired

Your label data (any key-value pairs)

json
{
  "product": "Widget Pro",
  "sku": "WDG-001",
  "price": "$29.99"
}
templatesarrayrequired

Array of elements to render on the label

Template Types

Each template defines an element on your label. Use dataPath to reference values from your data object.

Text

json
{
  "type": "Text",
  "dataPath": "product",     // Key from your data object
  "coords": [50, 30],        // [x, y] position in dots
  "font": "0,40",            // Optional: font name, height, width
  "maxLength": 22            // Optional: truncate; text does not wrap
}

BarCode

json
{
  "type": "BarCode",
  "dataPath": "sku",
  "coords": [50, 80],
  "style": "code128"         // Optional: code128 (default), code93, ean13
                             // ean13 takes 12 or 13 digits
}

QRCode

json
{
  "type": "QRCode",
  "dataPath": "url",
  "coords": [200, 30],
  "magnification": 5         // Required: size, 1-10
}

Response

On success the API returns ZPL as text/plain, ready to send to a Zebra printer at 203 dpi. This is the exact response to the quick start above.

zpl
^XA^MCY^XZ
    ^XA
    ^SZ2
    ^MMT
    ^MNY
    ^LL406
    ^PW815
    ^LH0,0
^CF0,40^FO50,30^FDWidget Pro^FS
^BY2,2,59^FO50,100^BCN,,N,N,N,A^FDWDG-001^FS
^XZ

Status Codes

200Success - ZPL returned
400Invalid body - every problem is listed with its field
401Missing, unknown or disabled API key
429Too many requests - wait the seconds in the Retry-After header - or monthly spending limit reached
500Our fault, not yours - retry

Label Sizes

Coordinate system uses dots (203 DPI). Origin (0,0) is top-left.

3" x 1"

615 x 210 dots

Good for: Product labels, asset tags

4" x 2"

815 x 406 dots

Good for: Shipping labels, detailed info

Complete Example

A shipping label with product name, SKU barcode and QR code.

json
1{
2 "config": {
3 "size": "4x2"
4 },
5 "data": {
6 "product": "Widget Pro",
7 "sku": "WDG-001",
8 "url": "https://example.com/track/12345"
9 },
10 "templates": [
11 {
12 "type": "Text",
13 "dataPath": "product",
14 "coords": [
15 50,
16 30
17 ],
18 "font": "0,40"
19 },
20 {
21 "type": "BarCode",
22 "dataPath": "sku",
23 "coords": [
24 50,
25 100
26 ],
27 "style": "code128"
28 },
29 {
30 "type": "QRCode",
31 "dataPath": "url",
32 "coords": [
33 560,
34 30
35 ],
36 "magnification": 6
37 }
38 ]
39}

And what the API returns for it:

zpl
^XA^MCY^XZ
    ^XA
    ^SZ2
    ^MMT
    ^MNY
    ^LL406
    ^PW815
    ^LH0,0
^CF0,40^FO50,30^FDWidget Pro^FS
^BY2,2,59^FO50,100^BCN,,N,N,N,A^FDWDG-001^FS
^BY2,2,0^FO560,30^BQN,2,6^FDQA,https://example.com/track/12345^FS
^XZ

Integration guides

Worked labels for public-sector workflows, each with the request, the ZPL it returns, and what to check before going live.

Need Help?

Having trouble? Email us - the first reply comes within 2 business days.