/api/v1/templates/{category}Get a category template
Returns the full regulatory field schema for one DPP category — every field with its key, English label, data type, required flag, access level, validation bounds, enum options (where applicable), and the governing regulation article/annex (`regulationRef`). This is the lookup that powers compliance-aware integrations and the MCP server's compliance copilot.
The projection is lean for API/AI consumers: it drops internal AI hints, the multilingual placeholder maps, and per-field sort bookkeeping, keeping the regulatory substance. Labels are returned in canonical English; the full localized label maps stay on the dashboard template API.
`{category}` is one of the 12 category keys (battery, textile, electronics, construction, steel, chemicals, packaging, furniture, tyres, jewelry, toys, fmcg). An unknown category returns 404 with a `TEMPLATE_NOT_FOUND` code — list valid keys with `GET /api/v1/templates`.
Path parameters
- categoryrequired
string
One of the 12 category keys, e.g. `battery`, `textile`, `electronics`.
e.g. battery
Headers
- Authorizationrequired
string
`Bearer <token>` — either a `tp_` API key (Developer → API Keys; simplest, for server-to-server) or an OAuth 2.0 access token (Developer → OAuth Apps; for user-authorized apps, scoped + revocable). The Authentication page has the full OAuth flow and scope list.
e.g. Bearer tp_REDACTED_xxxxxxxxxxxx
Request
curl -sS https://app.tracepass.eu/api/v1/templates/battery \
-H "Authorization: Bearer tp_REDACTED_xxxxxxxxxxxx"Response
{
"category": "battery",
"categoryLabel": "Battery",
"version": 3,
"regulation": "EU Battery Regulation 2023/1542",
"fieldCount": 93,
"requiredFieldCount": 64,
"fields": [
{
"key": "battery_chemistry",
"label": "Battery chemistry",
"dataType": "enum",
"required": true,
"accessLevel": "public",
"category": "Battery characteristics",
"enumOptions": [
{ "value": "lithium-ion", "label": "Lithium-ion" },
{ "value": "lead-acid", "label": "Lead-acid" }
],
"validation": {},
"regulationRef": "Annex VI, Part A"
}
]
}