When to use this. Barcodes are the pool of EAN barcode values held for your organisation
and assigned to SKUs and style assortments elsewhere in the product lifecycle. This endpoint is
a read-only lookup: use it to list those barcodes and check which are already linked. Assigning
a barcode to a SKU is done on the style’s SKUs, not here.
The workflow
A barcode is an organisation-level value. The usual path is to look the pool up, filter by whether a barcode is already linked, and then reference the ones you need when working with a style’s SKUs.1
List barcodes
GET /api/barcodes to read the organisation’s barcodes, one page at a time.2
Filter by linkage
Narrow the list with
linkedToSku and linkedToStyleAssortment to find barcodes that are
already assigned or still free.3
Page through the results
Follow
pagination.cursor (or increment pageNumber) until hasMore is false.Walkthrough
List the organisation’s barcodes and read the linkage flags off each row. The response wraps the barcodes in the standard paginated envelope.properties array: linkedToSku appears when the barcode is linked to a SKU,
and linkedToStyleAssortment when it is linked to a style assortment. An empty array means the
barcode is not yet linked to either.
Field reference
The fields on a barcode:Roles & permissions
Reading barcodes requires thebarcodes permission on a designer (brand) account with
the Barcodes module enabled — typically a user holding the SKU/Barcodes role. Supplier
accounts cannot read the barcode pool and receive a 403. Results are always scoped to your own
organisation.
When things go wrong
Errors use the standard envelope (status: "error", a code, and error.details[]). Supplying
cursor together with a filter or pageSize/pageNumber is a 400, and pageSize above 100 is
rejected. See Errors & responses for the full list of codes and how to
resolve them.
What to call next
Style SKUs
See the SKUs barcodes are assigned to:
GET /api/skus.Styles
Work with the styles whose SKUs and assortments barcodes attach to.
Authentication
How to get and send your
X-Auth-Token API key.