Get Supplier Analytics
GET/api/reporting/suppliers/:supplier/analytics
Full per-supplier analytics for the Analytics tab: headline KPIs (purchase volume, sales volume, units purchased/sold, profit, margin %), the composite scorecard, a dual-line current-vs-previous trend chart, and the hottest/coolest products ranked by growth.
reports:readGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Authentication: Requires Bearer token (scope: reports)
Path parameters:
- supplier: the Supplier ID
Required parameters:
- period_mode: yoy | qoq | mom | custom
When period_mode=custom, date_from and date_to (YYYY-MM-DD or m/d/Y) are both required.
Optional:
- growth_basis: spend | sales | profit | margin (default: sales) — drives the trend metric and product mover ranking
- min_volume: numeric (default: 1000)
- include_archived: boolean (default: false)
The response also includes product_heatmap (a period-aware per-product growth heatmap — the supplier's top products by volume, each cell a period-over-period change that follows the period_mode selector) and calendar_year_volume (per calendar year for the trailing 5 years: non-draft PO spend with units/PO counts plus non-draft sales revenue with units/order counts; the current year is year-to-date and is independent of period_mode).
Request
Responses
- 200
- 401
- 403
- 404
- 422
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not Found
Response Headers
Unprocessable Entity
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.