Get Spend Trend
Return historical spend bucketed by the chosen granularity, plus a trailing 3-bucket moving average and the window’s total spend.
Authorizations
Enter your MeshAPI key (rsk_...) — sent as Authorization: Bearer <key>.
Headers
Dated version of the API contract to pin this request to. Omit it and the request is served under 2026-08 — the oldest supported version, so an existing integration is never moved by a release. A malformed or unsupported value is rejected with 400 invalid_api_version rather than falling back silently. The version actually served is echoed as X-Mesh-Version on every response, including errors.
2026-08 Query Parameters
Organisation UUID
Team UUID (optional filter)
Bucketing window: 'hourly' (last 24h, hourly), 'weekly' (last 12 weeks, weekly), 'monthly' (last 30 days, daily).
hourly, weekly, monthly Skip the cache and recompute from the database.
Response
Successful Response