Getmasterkeysspendbykey
Per-master-key spend with previous-window comparison plus a full-slice summary (not limited by limit).
Success data: window, previousWindow, summary, rows (camelCase spend fields, spendChangePercent may be null).
Optional filters: departmentId (UUID) scopes slice; invalid UUID β 400 / 40013.
Authentication
Headers
Required for a normal JWT, Virtual Key, or PAT. A JWT may instead send X-Openmodel-User-Id. Not used by the public health endpoint.
JWT-only alternative to X-Workspace-Id. Must be a UUID equal to the JWT subject; the server uses it as the workspace id. Not valid as the sole workspace header for Virtual Key or PAT authentication.
Query parameters
Calendar preset; default 30d.
YYYY-MM-DD with end.
YYYY-MM-DD with start.
Max keys returned (default 200, max 200).
Optional department UUID filter; must be valid if non-empty.