Skip to main content
The API limits how many sessions can run at the same time. These are concurrency limits (how many sessions can be active at once), not request-rate limits. A session counts against your quota while it is in a non-terminal state (pending, running, paused, or idle). It frees its slot as soon as it reaches a terminal state (completed, failed, timed_out, interrupted) — including when you cancel it.

Check your quota

GET /api/v2/sessions/quota returns your current concurrency usage:
curl https://agp.eu.hcompany.ai/api/v2/sessions/quota \
  -H "Authorization: Bearer $H_API_KEY"
{
  "scope": "user",
  "limit": 10,
  "active": 3,
  "available": 7
}
FieldTypeDescription
scopestringThe level the limit applies at (user or org).
limitintegerMaximum concurrent sessions allowed.
activeintegerSessions currently active (non-terminal).
availableintegerRemaining slots (limit - active).
See Get quota for the endpoint reference.

When you hit the limit

Creating a session while at your limit returns 429 Too Many Requests. Wait for an active session to finish (or cancel one to free a slot immediately), then retry with exponential backoff. See the retry pattern in Errors. To request a higher limit, contact us at feedback@hcompany.ai.