Skip to content
Beta

These docs are in progress. Some pages are incomplete or may change. Report a problem

Developer docs

GET /schemas/:version/categories

List the categories defined in a schema version.

Developer docs menu
Small, cheap response. Use for populating category pickers or learning the schema's category order.

Summary

Returns every category in the schema version, in declaration order. Supports locale filtering.

Request

GET https://api.dtpr.io/api/v2/schemas/:version/categories
ParamInDescription
versionpathCanonical version.
localesqueryComma-separated locale codes. E.g. ?locales=en,fr. Omit for every locale.

Response

HTTP/1.1 200 OK
Content-Type: application/json
DTPR-Content-Hash: sha256-…
Cache-Control: no-store

{
  "ok": true,
  "version": "dtpr@2026-09-01-beta",
  "categories": [
    {
      "id": "purpose",
      "name": [{"locale":"en","value":"Purpose"}],
      "description": [{"locale":"en","value":"Why the technology is deployed."}],
      "shape": "hexagon",
      "context": {
        "values": [
          { "id": "commercial", "color": "#…", "label": [{"locale":"en","value":"Commercial"}] }
        ]
      }
    }
  ]
}

Errors

CodeHTTPMeaning
bad_request400Malformed :version.
not_found404Version is not registered.

Example

curl -s "https://api.dtpr.io/api/v2/schemas/dtpr@2026-09-01-beta/categories?locales=en"

See also