Self-hosted, open-source alternative to PrintNode. Submit a print job to a small HTTP API from anywhere; an agent on the machine with the printer picks it up and prints it — documents and label printers (Zebra/ZPL, Bixolon, thermal).
- Agent polls outbound — printers behind NAT/firewall work with no inbound ports
- Server is Python standard library only — no framework, nothing to install
- Web dashboard, REST API, per-client API keys, SQLite job queue
- Cross-platform agent: Windows (
win32print+ SumatraPDF) and Linux (CUPS) - MIT licensed · 67 tests
Server (Python 3.9+):
git clone https://github.com/LukiPrince/printpapi && cd printpapi
PRINTAPI_TOKEN=change-me python -m app.serverOpen the dashboard at http://localhost:3460 and paste the token. Or use the prebuilt Docker image — no build needed (amd64 + arm64):
docker run -e PRINTAPI_TOKEN=change-me -p 3460:3460 ghcr.io/lukiprince/printpapiOr docker compose up -d (persists the DB in a volume — see docker-compose.yml).
Prefer to build it yourself? docker build -t printpapi .
Agent — on the machine with the printers:
-
Copy
agent/print_agent.pythere (Windows also needspywin32+ SumatraPDF for PDF; Linux uses CUPS). -
Create
agent.ininext to it:[agent] server_url = http://yourserver:3460 api_key = your-agent-key name = office-pc printers = Zebra GK420d; HP LaserJet|pdf
-
Run
python print_agent.py.
First print: dashboard → Devices → Test print.
| Server | how it works, configuration, Docker, dashboard, API keys, security |
| Agent | install, agent.ini, printer syntax, labels vs PDF |
| HTTP API | endpoints, auth, content types, job lifecycle |
| Roadmap | what's planned for v2 |
Contributions welcome — see CONTRIBUTING.md.
MIT.
