Developer API
The Canonical JSON API.
Every grade, alias, and proposal — free, rate-limited, no key required. Base URL https://wpi-canonical.xdvu.com.
Endpoints
| Method | Path | Purpose |
|---|---|---|
| GET | /v1/grades | Paginated grade list · supports ?limit=&offset=&q= |
| GET | /v1/grades/{wpi_id} | Grade by canonical ID (WPI-g-000042) |
| GET | /v1/grades/by-slug/{slug} | Grade by slug |
| POST | /v1/grades/{wpi_id}/aliases | Add an alias (idempotent; body: {text, source}) |
| GET | /v1/resolve?q= | Freetext → canonical ID via alias resolver |
| GET | /v1/proposals?status=pending | List open data-quality proposals |
| POST | /v1/proposals | Propose a field change (entity_type, field, proposed_value) |
Example
# Resolve a freetext name to a canonical ID
$ curl -s "https://wpi-canonical.xdvu.com/v1/resolve?q=newsprint"
{"matched":true,"wpi_id":"WPI-g-000074","normalized":"newsprint"}
# Fetch that grade
$ curl -s "https://wpi-canonical.xdvu.com/v1/grades/WPI-g-000074"
{"wpi_id":"WPI-g-000074","slug":"newsprint",...}Canonical ID format
WPI-<type>-<6-digit-integer> where type is one of:
WPI-g-*· GradeWPI-m-*· MillWPI-b-*· BrandWPI-c-*· CertificationWPI-s-*· Source document (provenance)