Developer Documentation

Build on
BizPrint

Three ways to integrate cloud printing into your product. Custom print templates, a REST API for direct control, and an MCP server for AI agents.

Print Templates

Build custom receipt and label layouts. Register templates, inject content with WP actions, and modify meta with filters.

Learn more

REST API

Full programmatic control over printers, stations, and print jobs from any language or platform.

Learn more

MCP Server

Connect AI agents to BizPrint using the Model Context Protocol. Works with Claude, Cursor, and any MCP-compatible client.

Learn more

01
Print Manager

Print Templates

Build fully custom receipt, label, and packing slip layouts for Print Manager. Register templates as a plugin add-on, inject content with WP actions, and modify item meta with filters. Available in versions 4.0.1 and above.

Registering a Custom Template

Use the zprint_loaded hook to safely register your template

Always register inside the zprint_loaded action to prevent loading errors. Call ZprintTemplates::registerTemplate() with an object implementing ZprintTemplateIndex.

The global $order variable is available in every template file. Use $order->get_meta to access custom fields, and $templateOptions to read the current location’s saved settings.

add_action('zprint_loaded', 'my_template_init');

function my_template_init() {
ZprintTemplates::registerTemplate( new MyCustomTemplate() );
}

ZprintTemplateIndex Interface

Required methods for every custom template class

getName() → string

Human-readable name shown in location settings dropdown

getSlug() → string

Unique identifier slug for this template

getPath($format) → string

Returns file path for html or plain format

getFormats() → array

Supported formats, e.g. ['html' => true, 'plain' => false]

For custom options, also implement ZprintTemplateOptions. Add renderOptions($options) to output settings HTML and processOptions($options) to handle and return the saved POST data.

WP Actions

Inject content at specific positions in the print output

add_action('Zprinttemplatescustomer-htmlafterShippingDetails', 'my_cb', 10, 1);

function my_cb( int $order_id ): void {
echo '<p>Custom content here</p>';
}


Zprint{template}-{format}afterShippingDetails
Fires after shipping details. Arg: int $order_id

Zprint{template}-{format}beforeFooter
Fires before the footer. Arg: int $order_id

Zprinttemplatesorder-{format}end
Fires at the end of the order template. Arg: int $order_id

Templates: customer, details, order. Formats: html, plain.

WP Filters

Modify order item meta before it renders in templates

add_filter('Zprinttemplatescustomer-htmlorderItemMeta', 'my_filter', 10, 1);

function my_filter( array $meta ): array {
// Add, remove, or reorder meta entries
return $meta;
}


Zprint{template}-{format}orderItemMeta
Filterable: array $meta

Zprint{template}-{format}orderItemRawMeta
Filterable: array $meta — also receives WC_Order_Item $item

Plain / Thermal Output

ZprintDocument static helpers for ESC/POS-style formatting

Document::centerLine($str)

Centers a string across the printer’s column width

Document::symbolsAlign($l, $r)

Two-column layout joined by spaces — for label/price rows

Document::line($str)

Prints a string on its own line with word-wrap

Document::emptyLine()

Inserts a blank line for spacing

Enable Print symbols for layout debug in location settings to replace alignment spaces with dots for easier column debugging.

Sample Template

A pre-wired scaffold to start from — included in Plus plan and above

Installs as a plugin add-on and immediately adds a “Fancy” option to your location’s template selector. Customize the HTML and CSS files to build your layout — all field access via $order->get_meta is available out of the box.

Do not edit templates inside the core plugin’s /templates directory. Plugin updates overwrite those changes. The custom template registration API is the supported path.

AI-Powered Template Builder

BizPrint Template Developer GPT

A custom GPT trained on BizPrint’s template system. Describe the layout you want and get working PHP — or paste in an existing template for refinement.

02
Direct Integration

REST API

Full programmatic access to the BizPrint Cloud. Manage printers and stations, send jobs, and query status from any platform or language.

Building with Lovable, Bolt, Replit or Cursor? Start with the Print API.

API Reference

Full interactive documentation with request/response schemas, authentication details, and live examples.

bizswoop-development.github.io/bizprint-api

GitHub Repository

Source code, SDK clients, and examples. Open issues, contribute, or fork to build a custom client.

github.com/bizswoop-development/bizprint-api

Core Endpoints
GET/printersList printers (paginated)

GET/printers/{id}Get a printer by ID

GET/stationsList print stations (paginated)

GET/stations/{id}Get a station by ID

POST/jobsCreate a print job

GET/jobs/{id}Get a print job and its status

GET/jobsList print jobs (paginated, perPage max 100)

Create a Print Job: POST /jobs body
REQprinterIdnumber. The printer ID from GET /printers.

REQurlstring. A URL BizPrint can fetch: the page, receipt, ticket or label to print.

REQdescriptionstring. Shown in the job list.

OPTprintOptionobject or JSON string. Reserved for print settings. Leave it out unless BizPrint support gives you a value.
# Response
{ "data": { "id": 1042, "status": "pending", "printerId": 12, "url": "...", "description": "...", "createdAt": "...", "updatedAt": "..." } }

# Job status values
pending, processing, connecting-to-printer, done, failed, archived

# Errors
{ "errorCode": "ERR_UNAUTHORIZED", "message": "..." }

Authentication
# Every request is signed. Your secret key never leaves your server.

# POST: add publicKey and time (Unix seconds) to the JSON body
hash = sha256_hex( JSON.stringify(body) + ":" + SECRET_KEY )
# Send the body with hash added. Content-Type: application/json

# GET: add publicKey and time as query parameters
hash = sha256_hex( queryString + ":" + SECRET_KEY )
# queryString has no leading "?". Then add hash as a query parameter.

# Base URL
https://print.bizswoop.app/api/connect-application/v1

Signing in Node.js
import { createHash } from "crypto";

const API = "https://print.bizswoop.app/api/connect-application/v1";
const sign = (s) => createHash("sha256")
.update(`${s}:${process.env.BIZPRINT_SECRET_KEY}`)
.digest("hex");
const now = () => Math.floor(Date.now() / 1000);

// POST /jobs
const body = {
printerId: 12,
url: "https://yourapp.com/tickets/abc123",
description: "Order 1042",
publicKey: process.env.BIZPRINT_PUBLIC_KEY,
time: now(),
};
await fetch(`${API}/jobs`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ ...body, hash: sign(JSON.stringify(body)) }),
});

// GET /printers
const q = new URLSearchParams({
publicKey: process.env.BIZPRINT_PUBLIC_KEY,
time: String(now()),
});
q.set("hash", sign(q.toString()));
await fetch(`${API}/printers?${q}`);

Prefer a library? @bizswoop/print-client signs requests for you. To debug a signature, use @bizswoop/print-sign-request-cli. Both are in the GitHub repository.

03
AI Agent Integration

MCP Server

Connect AI assistants to BizPrint using the Model Context Protocol. The MCP Server runs locally on your machine and lets agents find printers and stations, send print jobs and check job status. Included on all paid plans. See pricing.

GitHub Repository

Open source. Install the Claude Desktop extension, or clone and build it for other MCP clients.

github.com/bizswoop-development/bizprint-mcp-server

AI Printing Solutions

Learn how AI agents connect to your commerce print infrastructure. Use cases, architecture, and setup.

getbizprint.com/ai-printing

Available Tools
GETlist_printersList all configured printers with their settings

GETget_printerGet details for a specific printer by ID

GETlist_stationsList all print stations and their status

GETget_stationGet details for a specific station by ID

POSTcreate_print_jobSend a document URL to a printer

GETget_print_jobCheck the status of a print job

GETlist_print_jobsList print jobs with pagination

Quick Start
# Option 1: Claude Desktop (recommended)
# Settings > Extensions > search "BizPrint" > Install
# Enter your BizPrint API keys when prompted

# Option 2: Build from source
git clone https://github.com/bizswoop-development/bizprint-mcp-server.git
cd bizprint-mcp-server
npm install
npm run build
# Point your MCP client at build/index.js
# Set BIZPRINT_PUBLIC_KEY and BIZPRINT_SECRET_KEY

The MCP Server runs locally. There is no hosted version. Install the extension in Claude Desktop, or point any MCP client that runs local servers at build/index.js.