Docs
Metrics and telemetry ›

Get running over time

GET/v1/metrics/running

How many of your sandboxes were running, step by step.

RequestTypeScript
  1. import { Agental } from "agental-sdk";
  2. const agental = new Agental();
  3. const running = await agental.runningOverTime();
Answer200 OK · RunningOverTime
  1. {
  2. "since": string,
  3. "until": string,
  4. "stepSeconds": integer,
  5. "points": [{
  6. "at": string,
  7. "running": integer,
  8. }],
  9. }

How many of the caller's sandboxes were running at each step between two moments.

Query

since
string
Count from this moment. 24 hours before until when omitted. e.g. "2026-10-13T16:00:00Z"
until
string
Count up to this moment. Now when omitted, and never later than now.
stepSeconds
integer
Seconds between two points. When omitted, a step that gives about 288 points. e.g. 300

Headers

Authorizationrequired
Bearer key
An API key that may make this call.

Returns

200 How many of the caller's sandboxes were running at each step between two moments. It is counted from the record of what ran, which is what is billed from, so it is there wherever sandboxes run, and a sandbox deleted since is still counted.

RunningOverTime4 fields
since
string
until
string
stepSeconds
integer
points
object[]2 fields
at
string
running
integer

Errors and other answers

400 since is not before until, the two are more than 366 days apart, or stepSeconds would give more than 1500 points.
404 Not found.

Every error answers { "error": { "code", "message" } }; a key without the action a call needs answers 403 key_action_forbidden, naming it.