Metadata-Version: 2.4
Name: labelixa
Version: 0.2.0
Summary: Render, validate and convert Zebra ZPL label code via the Labelixa API — no printer required.
Project-URL: Homepage, https://labelixa.com
Project-URL: Documentation, https://labelixa.com/docs/api
License-Expression: MIT
Keywords: barcode,epl,label,printing,thermal-printer,zebra,zpl
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Printing
Requires-Python: >=3.9
Requires-Dist: httpx>=0.24
Description-Content-Type: text/markdown

# labelixa

Render, validate and convert **Zebra ZPL** label code from Python — no
printer required. Thin client for the [Labelixa](https://labelixa.com) API.

```bash
pip install labelixa
```

```python
from labelixa import Client

c = Client()                          # anonymous: free, rate-limited
# c = Client(api_key="lbx_...")       # your quota — https://labelixa.com/panel

zpl = "^XA^FO50,50^A0N,40^FDHello^FS^BY3^FO50,120^BCN,100,Y^FD12345678^FS^XZ"

# See what the label looks like
with open("label.png", "wb") as f:
    f.write(c.render_png(zpl, width_in=4, height_in=6))

# Lint before printing
report = c.validate(zpl)
for d in report["diagnostics"]:
    print(d["severity"], d["message"])

# Multi-label PDF, ZPL -> EPL2 translation
pdf = c.render_pdf(zpl)
epl = c.to_epl(zpl)

# 0.2.0: barcode / language detection / printer compatibility
svg = c.barcode("HELLO-123", type="code128")
lang = c.language_detect(raw_label_code)      # confidence TIER, not %
risk = c.compatibility(zpl, "zebra-zd421")    # risk report, not "it works"
```

Quota errors are first-class:

```python
from labelixa import QuotaExceeded

try:
    c.render_png(zpl)
except QuotaExceeded as e:
    print(f"retry in {e.retry_after}s (hint: {e.action})")
```

This SDK is a deliberately thin 1:1 wrapper over the documented REST
API — the [API reference](https://labelixa.com/docs/api) is the source
of truth. AI assistants can also use Labelixa directly over MCP:
point your client at `https://api.labelixa.com/mcp`.
