Get a product group with its packaging
const url = 'https://api.europlaybook.com/v1/product-groups/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0?history=false';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.europlaybook.com/v1/product-groups/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0?history=false' \ --header 'Authorization: Bearer <token>'The group, its members (with the layers they override) and its packaging tree on on.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Query Parameters
Section titled “Query Parameters”Responses
Section titled “Responses”OK
object
Unique per account: a Shopify product gid or a SKU stem.
Products in the group.
Packaging lines of the group (all versions).
object
Layers on which the member has its own lines today (it does not inherit those).
The group’s own lines: every member’s default.
object
The day the totals are for.
object
Sales (primary), grouped (secondary) or transport (tertiary).
One packaging line: quantity parts of item per sales unit, valid over a date range.
object
Proposed = not yet checked by a person; confirmed = part of a gate-1 confirmation.
Parts per sales unit (may be a fraction, e.g. 1 film per 1440).
Ends up with households (counts as household packaging).
Packaging mass per sales unit for this line (item mass x quantity).
Counted in totals_by_material: valid on on and not limited to a channel/fulfilment.
Where the line came from (provenance).
Which record of that source, e.g. api:token:<prefix>.
The line is the product group’s: the product has no own line on that layer.
object
Name of the packaging part.
Your code for the part (unique per account when set).
Usual role: sales, grouped, transport, shipping or filler.
Usually ends up with households (vs. businesses).
Can be separated from the other parts by hand.
Material breakdown of ONE part.
object
Material code from the knowledge pack (see /reference/materials).
Mass in milligrams.
Sum of the materials, milligrams.
Mass per sales unit of this layer’s lines that count in the totals.
object
Material code from the knowledge pack (see /reference/materials).
Mass in milligrams.
Example
{ "id": "0199f5a2-7c1e-7b4a-9d0e-3f6c2a1b8e44", "name": "Green tea", "code": "TEA", "source": "manual", "source_ref": "", "packaging": { "layers": [ { "layer": "sales", "lines": [ { "id": "0199f5a2-7c1e-7b4a-9d0e-3f6c2a1b8e44", "state": "proposed", "quantity": "1.0000", "source": "manual", "source_ref": "", "inherited": false, "item": { "id": "0199f5a2-7c1e-7b4a-9d0e-3f6c2a1b8e44", "name": "Folding box S", "code": "BOX-S", "rigidity": "rigid", "materials": [ { "material": "paper", "mass_mg": 12000 } ], "total_mass_mg": 12500 } } ] } ], "totals_by_material": [ { "material": "paper", "mass_mg": 12000 } ] }}Bad Request
object
Example
{ "detail": "This API key lacks the scope catalogue:write", "code": "insufficient_scope", "params": { "required_scope": "catalogue:write" }}Unauthorized
object
Example
{ "detail": "This API key lacks the scope catalogue:write", "code": "insufficient_scope", "params": { "required_scope": "catalogue:write" }}Forbidden
object
Example
{ "detail": "This API key lacks the scope catalogue:write", "code": "insufficient_scope", "params": { "required_scope": "catalogue:write" }}Not Found
object
Example
{ "detail": "This API key lacks the scope catalogue:write", "code": "insufficient_scope", "params": { "required_scope": "catalogue:write" }}Conflict
object
Example
{ "detail": "This API key lacks the scope catalogue:write", "code": "insufficient_scope", "params": { "required_scope": "catalogue:write" }}Unprocessable Content
object
What went wrong, in English, for people and logs.
Stable machine-readable error code; translate and branch on this.
Per-field problems (pydantic format: loc, msg, type).
object
Example
{ "detail": "This API key lacks the scope catalogue:write", "code": "insufficient_scope", "params": { "required_scope": "catalogue:write" }, "errors": []}Too Many Requests
object
Example
{ "detail": "This API key lacks the scope catalogue:write", "code": "insufficient_scope", "params": { "required_scope": "catalogue:write" }}