Use case
Returns labels: RMA codes and return labels on demand
A return label is requested by a customer, not queued by a warehouse: someone opens a web page, picks the order and the item, and a label has to exist a moment later. This page covers what a return label and the tags around it carry, the barcodes they typically have, the data behind them and how a server produces and delivers them. No standard defines these labels: they are practice, so your returns process decides what is on them.
The label at a glance
The numbers in the drawing match the list. Sample data is made up.
- Return-to addressWhere the parcel goes back to, as text.
- RMA codeYour own return authorization number, in large text. It ties the parcel to the order.
- Linear barcodeThe RMA code as Code 128, with the text under the bars, so the receiving desk scans it.
- 2D symbol (optional)A QR Code can carry text, such as the RMA number or a reference to the record in your own system.
- Carrier areaReserved for the carrier's own barcode and tracking number. They come from the carrier, not from BarcoderX.
- Order and countThe order reference, and a count such as "1 of 2" when a return has several parcels.
What is printed, and why
A return label sends a parcel back. It carries the return-to address, an RMA code of your own (a return authorization number that ties the parcel to the order and the reason) and, if you use a carrier, the carrier's own barcode and tracking number. Repair and refurbishment tags then follow the item inside your site: the RMA code, the reported fault and the status.
The return label is usually a PDF that the customer prints at home on an ordinary printer. At a service desk or a drop-off point it can be a thermal label instead. No standard governs the label: the carrier you ship with sets whatever it needs on its own part.
Which barcodes, and why
| Barcode | Why it is on the label | Edition |
|---|---|---|
| Code 128 | A linear barcode for the RMA code or the order reference. Code 128 holds letters and digits in one line of bars, and the site's symbology table pairs it with data that has no GS1 structure. | Basic |
| QR Code | A 2D symbol holds more data in a small area and carries error correction. It can carry text, such as the RMA number or a reference to the record in your own system. | Ultimate |
The carrier's barcode is not in this table on purpose: its symbology and its number come from the carrier. A home printer makes different dots from a thermal print head, so how well a barcode scans from its page depends on the printer and the paper. Test with the printers your customers use.
BarcoderX enforces quiet zones, snaps the module width to whole dots and reports the effective size. Symbol options
The data that fills it
| Field | Sample value | Where it goes |
|---|---|---|
| Return-to name and address | Example Logistics Inc., 123 Example Street, Panama City | Text, element 1. |
| RMA code | RMA-48213-1 | Large text, element 2, and the barcode, element 3. |
| Order reference and count | PO-48213, 1 of 2 | Text, element 6. |
| Reported fault (repair tag) | Does not power on | Text on the repair tag, not on the return label. |
| Carrier barcode and tracking number | Supplied by the carrier | The carrier area, element 5. Your system passes the value in as data, and BarcoderX draws it when its symbology is one listed on the barcodes page. |
The values come from your order system and your returns process. When the customer picks an order, your system creates the RMA code and, if you use a carrier, gets the carrier's label data. BarcoderX prints what you give it.
The values come from objects, a DataTable, CSV, JSON or XML. Counters, masks and more than 100 built-in functions produce the values that change on every label. Templates and data
Why generate it from code
A return label is requested from a web page, for one order, at any hour. Nobody at your company opens a program and presses print, so the label has to be generated on a server, on demand. The REST API renders and exports a label from a template and your data. The browser never calls a port on your machine: the web app sends the job to the server, and from there the file goes back to the customer or the job goes to a printer. Print thermal labels from a web app
How it reaches the printer
- As a file, for the customer. Your server exports the label as a PDF, which is vector with searchable text and subset fonts embedded, or as a PNG, JPG, SVG, PCX or HTML file. Your page offers the file, and the customer prints it on whatever printer they have.
- On a thermal printer, at a desk. At a service point the label prints on a thermal printer by the two routes below.
The printer commands are the same on both routes, and both run on infrastructure you operate.
- Direct, from your application. The SDK packages send the printer commands from your own .NET process over TCP port 9100, serial, the Windows spooler, CUPS or USB. No API server and no agent is in the path.
- Through your API server. Your application queues a print job through the REST API on your API server. A print agent on the printer's network collects it and writes it to the printer beside it. The agent only dials out, so the printer network needs no inbound port.
Delivery to the agent is at-least-once and the agent de-duplicates by job id, so a reconnect does not print a label twice. Print jobs honor an idempotency key, so a retried request does not queue a second label.
Paper and stock depend on the route. At home, the paper and the printer are the customer's. At a desk, the stock and the ribbon are your choice. Direct thermal media darkens under the heat of the print head and the print fades with heat, light and age; thermal transfer melts ink from a ribbon and lasts longer (see direct thermal and thermal transfer). In ZPL, ^MT tells the printer which one is loaded.
Which edition covers it
EditionsBasic covers the linear (1D) and postal symbologies, including every GS1 DataBar variant; Ultimate adds the PDF417 family, other multi-row symbologies, every matrix (2D) symbology and GS1 composites, as set out on the pricing page.
For return labels, that means Code 128 is in Basic. A QR Code is a matrix (2D) symbology and needs Ultimate. Basic and Ultimate differ only by the barcode symbologies they include, so exporting a PDF does not depend on the edition.
The ZPL behind it
Printer commands a label like this can use. Each page explains one command in our own words.
^BC- Prints a Code 128 barcode.
^BQ- Prints a QR Code barcode.
^BY- Sets the module width of the barcodes that follow.
^FB- Turns text into a block that wraps.
^PQ- Sets how many labels print, how many print between pauses and how many times each serial number repeats.
The PDF route does not use ZPL: the same layout also exports to six file formats.
What BarcoderX does not do here
BarcoderX does not issue tracking numbers or carrier barcodes. They come from the carrier, and your system passes them in as data. BarcoderX calls no carrier or other third-party service; it renders and prints from the data it is given. It does not create the RMA code, decide whether a return is accepted or follow the parcel: your returns system does. BarcoderX does not read barcodes, so receiving a return is your scanner and your software.
Keep reading
Shipping labels Print thermal labels from a web app: four ways The REST API Server-side label printing for .NET Templates and data ZPL 2D codes: QR Code, Data Matrix, PDF417 Warehouse labels: locations, totes and count tags Use cases Pricing: what each edition coversNew to the printer language? Read the ZPL guides and command reference.
Sources What this page says about BarcoderX comes from its published barcodes, pricing, printing and export, API, templates and data, FAQ, glossary and web-app printing pages. The description of return labels is general and ours. No carrier is named on purpose, and no standard is cited because none defines these labels.
Written by BarcoderX in its own words.
ZPL and ZPL II are trademarks of Zebra Technologies Corporation. BarcoderX is an independent product and is not affiliated with, endorsed by or sponsored by Zebra Technologies.