Authentication
The authenticated routes live under/v1/passports and take the same API key as every other API, sent as a bearer token. The key’s organization is the only source of tenancy: there is no organization parameter, and another organization’s data cannot be addressed. Generate keys on the API Keys page.
Scopes map to roles
A read needs
read (or execute, which includes it), a content write needs ingest, and a decision needs execute: a key that edits and publishes holds both. A route outside the key’s scope returns 403 with code scope_missing.
API keys never reach admin
Archiving a passport, minting, listing and revoking access grants, inviting and revoking suppliers, registry registration (currently a simulation; the EU registry is not accepting submissions) and loading sample data all need a Product Passport admin working in the app. No API key can call them, so a leaked key cannot create a credential or take a passport down.Passports
A passport is bound to one product (a model), one lot (a batch) or one tracked unit (an item). It references the item master you already ingested rather than duplicating it, so the item must exist first. Every:id below takes the passport’s id or ext:<external_id>, your own id for it, URL-encoded: GET /v1/passports/ext:NW-OXF-000123. An id we do not know is a 404.
Create a passport
{ passport }. A batch passport needs a lot and an item passport needs a tracked unit; an item, lot, variant or EPC that does not exist returns 404, and a duplicate external_id returns 409.
List passports
Returns the list object described under Conventions, most recently updated first: pass
next_cursor back as cursor until has_more is false. The older passports, total, limit and offset fields and the offset parameter still work and are deprecated.
Get and update
GET /v1/passports/:id returns passport, view (the internal projection, including the work queue of gaps), completeness and digital_link. PATCH accepts title, brand, category, gtin, batch_lot, serial, public_enabled and draft_data (merged into the existing draft), and returns the passport with its new completeness. An archived passport cannot be edited (409).
Materials and events
The bill of materials and substance declarations are replaced as whole sets. Lifecycle events are added one at a time. Every write rescores the passport, and the response carries the new completeness.Replace the bill of materials
Send the whole tree in{ "materials": [...] } (up to 500 rows). Rows are replaced, not merged. Rows that suppliers submitted through their own links are kept and are not part of your set.
Replace substance declarations
Send{ "substances": [...] } (up to 1000 rows): REACH SVHC, REACH Annex XVII, POP and CLP declarations.
Add a lifecycle event
{ event, completeness }. Events are idempotent on external_id, so a retry is safe. To correct an event, send it again with the same id.
Publishing
Publishing freezes an immutable version of the passport with a SHA-256 checksum. It is hard-gated: a passport with an unmet blocking requirement cannot be published.
The body is optional;
change_note (500 characters at most) is stored with the version.
Response: 200 OK.
422 Unprocessable.
Publishing does not make the passport publicly resolvable. That is a separate
public_enabled decision (set it with PATCH), so a version of record can exist before you expose it to consumers.Public resolution
A published passport can be read with no credential in two forms: a web page for people and JSON for systems. Both show the consumer view, and both resolve only a published passport withpublic_enabled set.
The web page: digital_link
GET /v1/passports/:id returns the passport’s digital_link: its GS1 Digital Link, built from the GTIN and, when the passport has them, the lot and the serial. A passport without a valid GTIN has no link, and digital_link is null.
The JSON: passport views
The same passport as JSON, for a system that reads it: a retailer’s product page, a repair or resale service, a customs or recycling workflow.01 and the GTIN (8, 12, 13 or 14 digits with a valid check digit), then optionally 10 and the lot, then optionally 21 and the serial. A lot or a serial is 1 to 20 characters, URL-encoded.
Response: 200 OK, with request_id, duration_ms and the passport in the consumer view.
- Most specific match. A serial that has its own passport answers with it; otherwise the lot’s passport answers, and otherwise the model’s.
passport.resolvedGranularitysays which one answered (item,batchormodel), andpassport.broadenedistruewhen the answer is less specific than the address asked for. Use the two to say “batch-level information shown” and never imply the data is unit-specific. - Language.
?lang=dereturns the texts in that language where the passport has them, and in English where it does not. The default isen. - Caching. The answer carries
Cache-Control: public, max-age=300: it can be cached for five minutes. - Limit. 120 requests a minute for each calling address. Past it the answer is a 429 with
Retry-After,X-RateLimit-LimitandX-RateLimit-Remaining. - A miss is a 404. An identifier that is not valid, a GTIN with no passport, a passport that is not published or has public access switched off: each answers the same 404, so the address cannot be used to find out what exists. The body of this 404 and of the 429 is
erroras a plain string withrequest_id, not the error object of the keyed routes. GETonly. Any other method answers 405 withAllow.
view parameter added to the address changes nothing.
Recycler and authority views
A Product Passport admin issues a grant link for therecycler or authority audience in the app, with an optional expiry. The link is shown once. It ends in the grant token (48 hexadecimal characters), and the same token reads the view as JSON:
public_enabled is not needed, because the token is the permission. A token that was revoked or has expired answers the same 404 as any miss. The answer carries Cache-Control: private, no-store and must not be cached by a shared cache. Links to documents in it expire after 15 minutes: read the view again for fresh ones. ?lang= and the limit work as on the consumer view.
Errors and limits
Errors are JSON with anerror object (type, code, message, param) and a request_id. The same id is in the X-Request-ID header. Quote it when reporting a problem. The shape is described under Conventions, and every code is in the error reference.
Limits and retries
- API keys: 120 requests per minute per key, then the key’s daily limit; every answer carries the RateLimit headers.
- Retries: events and documents upsert on their external id, and materials and substances replace whole sets, so a retried request cannot double-write.