Skip to main content
GET
Get the cost of metered usage over a window

Authorizations

Authorization
string
header
required

Archil API key, including its key- prefix

Query Parameters

start
string

Start of the window, inclusive: an RFC 3339 timestamp, or a YYYY-MM-DD date taken at midnight in timezone. Defaults to seven days (hourly: 24 hours) before end. Not with for.

Example:

"2026-10-13"

end
string

End of the window, exclusive, in the same forms as start. Defaults to now. Not with for.

Example:

"2026-10-20"

for
enum<string>

A named window relative to now in timezone, instead of start and end. Weeks start on Monday. A window may run past now; the intervals after it are left out.

Available options:
today,
yesterday,
this-week,
last-week,
this-month,
last-month
granularity
enum<string>
default:1d

Width of each interval. Days are aligned to timezone; hours are UTC.

Available options:
1d,
1h
timezone
string
default:UTC

IANA timezone that day intervals and dates are aligned to.

Example:

"America/Los_Angeles"

Response

Cost over the window and per interval

success
boolean
required
data
object
required