Skip to main content
API errors return a JSON body with an error code and a human-readable message. Treat the HTTP status and error as the machine-readable contract.

Error format

Error codes

Interpret server_error together with its HTTP status. A 500 is an unexpected internal failure, a 502 identifies an upstream operation failure, and a 503 is explicitly temporary and retryable.

Validation errors

400 validation_error messages name the failing field path and the violated constraint, one path: constraint entry per issue, separated by ;. The offending value is never echoed back.

Common scenarios

Missing API key

Returns 401 unauthorized with Invalid or missing API key.

Agent version conflict

Fetch the agent again and retry the full update body with the latest expectedVersion.

Turn already in progress

A session runs one turn at a time. Either wait for the running turn to end, or send the message with delivery: "when_idle" so Herm queues it and starts it automatically once the session is idle — see Queue a message while a turn is running.

Rate limits

Per-agent user limits return a structured 429 response:
resource is conversations or messages. Wait at least the integer number of seconds in Retry-After before retrying. Handle rate_limited explicitly in your client. Successful operations include RateLimit-Limit, RateLimit-Remaining, and RateLimit-Reset. See Rate limits for configuration and counting behavior.

Agent not found

Last modified on July 25, 2026