Get Cost Over Time changedapi/admin/analytics/cost/list
Nearest release: v2.1.245, published an hour after this site recorded the change. Shown because the two are within 24 hours of each other. Nothing here says the release caused the edit.
Recorded here
Lines+47added
Lines−20removed
From line
1
where the diff opens
First seen
14 Aug 2026
this site's first read of the page
Recorded edits6to this page, all time
# Get Cost Over Time ## Query parameters ## Returns ## Example ### Response (200) ## Get Cost Over Time ### Query Parameters ### Returns ### Example #### Response
The whole hunk
from line 1, old and new numbered
/
from line 1
1---
2title: Get Cost Over Time
3url: https://platform.claude.com/docs/en/api/admin/analytics/cost/list
4---
1# Get Cost Over Time
52
6## Get Cost Over Time
3**GET** `/v1/organizations/analytics/cost_report`
74
8**get** `/v1/organizations/analytics/cost_report`
9
105Get cost in USD over time across a date range.
116
127Returns cost bucketed by minute, hour, or day, optionally broken down by
from line 9
149token type. Available to organizations on a Claude Enterprise plan.
1510Requires an API key with the `read:analytics` scope.
1611
17### Query Parameters
12## Query parameters
1813
1914- `starting_at: string`
2015
2116 Start of range, inclusive. RFC 3339 tz-aware. Must be within the last 365 days and no earlier than 2026-01-01T00:00:00Z.
2217
18 format: date-time
19
2320- `bucket_width: optional "1d" or "1h" or "1m"`
2421
2522 Time bucket granularity.
2623
24 default: 1d
25
2726 - `"1d"`
2827
2928 - `"1h"`
from line 33
3433
3534 Filter to specific context-window pricing tiers. Use `group_by[]=context_window` to break out per-tier values.
3635
36 maxItems: 100
37
3738 - `"0-200k"`
3839
3940 - `"200k-1M"`
from line 43
4243
4344 End of range, exclusive. When omitted, defaults to the earlier of now and `starting_at` + 31 days. The range may span at most 31 days.
4445
46 format: date-time
47
4548- `group_by: optional array of "context_window" or "cost_type" or "inference_geo" or 6 more`
4649
4750 Dimensions to break each time bucket out by. Defaults to no grouping (one total per bucket). Each bucket reports at most its top 100 groups; a group beyond that cap has no row in that bucket (there is no remainder row), so grouped buckets are not exhaustive when a dimension has more than 100 distinct values.
4851
52 maxItems: 100
53
4954 - `"context_window"`
5055
5156 - `"cost_type"`
from line 73
6873
6974 Filter to specific inference regions. `not_available` matches rows where the region is unset. Use `group_by[]=inference_geo` to break out per-region values.
7075
76 maxItems: 100
77
7178 - `"global"`
7279
7380 - `"not_available"`
from line 85
7885
7986 Maximum number of time buckets per page. Defaults and caps vary by bucket_width (1d: default 7, max 31; 1h: default 24, max 168; 1m: default 60, max 256).
8087
88 minimum: 1
89
8190- `models: optional array of string`
8291
8392 Models to include. Defaults to all models. Use `group_by[]=model` to break out per-model values.
8493
94 maxItems: 100
95
8596- `page: optional string`
8697
8798 Opaque cursor from a previous response's `next_page` field.
from line 101
90101
91102 Product surfaces to include. Defaults to all products. Use `group_by[]=product` to break out per-product values. Values include "chat", "claude_code", "cowork", "office_agent", "claude_in_chrome", "claude_design", and "claude-in-slack". "claude-in-slack" (with hyphens) is Claude Tag, the Claude product in Slack. A similarly spelled legacy value (underscores instead of hyphens) identifies the retiring v1 Slack chat bot and appears only for organizations that used it.
92103
104 maxItems: 100
105
93106- `rbac_group_ids: optional array of string`
94107
95108 Filter to usage attributed to specific RBAC groups. Accepts tagged RBAC group IDs (`rbac_group_...`) or bare group UUIDs. A row matches when the user belonged to any of the listed groups on the (UTC) day the usage occurred; usage with no group attribution never matches.
96109
110 maxItems: 100
111
97112- `slack_channel_ids: optional array of string`
98113
99114 Filter to usage originating from specific Slack channels. Use `group_by[]=slack_channel_id` to break out per-channel values.
100115
116 maxItems: 100
117
101118- `speeds: optional array of "fast" or "standard"`
102119
103120 Filter to fast or standard inference mode. Use `group_by[]=speed` to break out per-mode values.
104121
122 maxItems: 100
123
105124 - `"fast"`
106125
107126 - `"standard"`
from line 129
110129
111130 Filter to specific users by tagged user ID.
112131
113### Returns
132 maxItems: 100
114133
115- `CostBucket object { data, data_refreshed_at, has_more, 2 more }`
134## Returns
116135
117 - `data: array of object { ending_at, results, starting_at }`
136- `CostBucket object`
118137
138 - `data: array of object`
139
119140 Time buckets for this page, oldest first: one per `bucket_width` interval, including intervals with no data (their `results` list is empty). A page holds at most `limit` buckets.
120141
121142 - `ending_at: string`
from line 143
122143
123144 End of the time bucket (exclusive) in RFC 3339 format.
124145
125 - `results: array of object { amount, context_window, cost_type, 10 more }`
146 format: date-time
126147
148 - `results: array of object`
149
127150 Rows for this time bucket. Empty when the bucket has no data; otherwise a single combined row when `group_by[]` is omitted, or one row per group (subject to the per-bucket group cap described on the `group_by[]` parameter).
128151
129152 - `amount: string`
from line 175
152175
153176 Currency code for the cost amount. Currently always `"USD"`.
154177
155 - `"USD"`
178 default: USD
156179
157180 - `inference_geo: "global" or "us" or null`
158181
from line 235
212235
213236 Start of the time bucket (inclusive) in RFC 3339 format.
214237
238 format: date-time
239
215240 - `data_refreshed_at: string or null`
216241
217242 RFC 3339 timestamp of the export this response was served from. Null when no export yet covers any part of the requested range, in which case every bucket's `results` list is empty. Buckets beyond this watermark are incomplete; for stable results, set `ending_at` to this value or earlier. Data is typically refreshed every 4 hours but not final until about 30 days after the usage date (late-arriving events, reconciliation adjustments).
218243
244 format: date-time
245
219246 - `has_more: boolean`
220247
221248 Whether another page is available. When true, pass `next_page` as the `page` parameter to fetch it.
from line 255
228255
229256 ID of the Organization.
230257
231### Example
258## Example
232259
233```http
260```bash
234261curl https://api.anthropic.com/v1/organizations/analytics/cost_report \
235262 -H 'anthropic-version: 2023-06-01' \
236263 -H "X-Api-Key: $ANTHROPIC_ADMIN_API_KEY"
237264```
238265
239#### Response
266### Response (200)
240267
241268```json
242269{
No line in this hunk matches that.