Print shelf and price labels from the back office
A price change in the back office can print a shelf label on the store's printer without a dialog on the manager's laptop.
For Retailers printing shelf labels from a web back office
Overview
The manager changes a price. The store needs a new shelf label. The back office already has the SKU, price, and barcode. Render it for the store's label printer and POST to that store's printer_code.
DYMO and Brother stores want PDF at the die size. A Zebra in the stockroom wants ZPL. Store the content type with the printer, not as a global flag.
Print a batch for a planogram as many jobs or one multi-label file. A failure should say which SKU, so you do not reprint the whole aisle blindly.
Create the job with POST /v1/print-jobs, an Authorization: Bearer header, printer_code, content_type pdf or raw, and exactly one of content or content_url. The free plan is 100 jobs a month on one computer.
Integration steps
- 01
Decide the printer before the click
Map the station, store, or line to a printer_code from GET /v1/printers. Do not ask the operator to pick a dialog.
- 02
Create the document in your system
PDF for driver printers, raw ZPL or ESC/POS when the device speaks that language.
- 03
POST when the business event happens
Pack, pay, check-in, or scan. Not on every autosave. Use the business id as Idempotency-Key.
- 04
Show the job result where the work is
queued is not done. Surface AGENT_OFFLINE and PRINT_ERROR to the person at the bench.
Node.js
// Shelf label for one SKU
const res = await fetch('https://api.printbase.cloud/v1/print-jobs', {
method: 'POST',
headers: {
Authorization: `Bearer ${process.env.PRINTBASE_API_KEY}`,
'Content-Type': 'application/json',
'Idempotency-Key': idempotencyKey,
},
body: JSON.stringify({
printer_code: Number(process.env.PRINTER_CODE),
content_type: 'pdf',
content: pdf.toString('base64'),
copies: 1,
}),
});
if (!res.ok) throw new Error(`PrintBase ${res.status}: ${await res.text()}`);
const job = await res.json();
// { id: "job_abc", status: "queued" }
Details for this setup
Per store
A chain has one code per store printer, not one code for the headquarters laser.
Effective time
Print when the price is approved, not when someone types in the field. The agent prints only what you send; it does not fetch the document from the platform for you.
Questions
Can headquarters print into every store?
Yes, if each store's agent is online and you send the right code.
Wrong price on the strip?
Fix the data and send a new key. The printer will not recall the old label.
Barcode type?
You draw it, Code 128 or EAN, in ZPL or in the PDF. The call is still POST /v1/print-jobs with a Bearer API key, and HTTP 201 means queued rather than printed.
Is there a retail plugin?
No. The call is still POST /v1/print-jobs with a Bearer API key, and HTTP 201 means queued rather than printed.
Free plan: 100 jobs a month on one computer, no card.