Skip to main content
POST
Get team credit usage over time

Authorizations

x-magnific-api-key
string
header
required

Your Magnific API key. Required for authentication. Learn how to obtain an API key

Body

application/json
granularity
enum<string>
default:day

Time bucket granularity for aggregation. Defaults to day if omitted.

Available options:
day,
week,
month,
year
Example:

"month"

start_date
string<date>

Start date for the query range (YYYY-MM-DD). Defaults to 7 days ago.

Example:

"2026-01-01T00:00:00.000Z"

end_date
string<date>

End date for the query range (YYYY-MM-DD). Defaults to today.

Example:

"2026-03-31T00:00:00.000Z"

project_references
string<uuid>[]

Filter by specific project references.

Example:
api_key_ids
string[]

Filter by specific API key IDs.

Example:
group_ids
integer[]

Filter by specific team group IDs. Members of these groups are included in the results.

Required range: x >= 1
Example:

Response

OK

data
object[]