Skip to main content

QUOTA_EXHAUSTED

Constant QUOTA_EXHAUSTED 

Source
pub const QUOTA_EXHAUSTED: i32 = -32029;
Expand description

Admission back-pressure: a quota ceiling refused the request before any work was admitted.

Not in A2A 1.0’s error table — the spec defines only permanent missing-capability codes and assigns back-pressure no code at all; its own guidance stops at “return appropriate error responses when rate limits are exceeded”. Reaching into the table anyway would be worse than inventing a code: -32004 UnsupportedOperationError for a full quota teaches a compliant caller that the operation does not exist here — the correct response to which is to abandon, never to retry — when the truthful answer is “not right now”. So the code is drawn from JSON-RPC’s implementation-defined server-error range.

The number is not the identity. A2A 1.0 reserves -32001..-32099 for its own errors, the same band JSON-RPC gives implementations, so a future spec revision could assign this numeral a meaning of its own. What makes the refusal identifiable is the google.rpc.ErrorInfo beside it — ERROR_DOMAIN + QUOTA_EXHAUSTED_REASON, a domain this project controls — and that pair is what this crate’s own client keys its refuse-and-come-back classification on. A bare -32029 from a foreign server proves nothing and is classified as an unknown fault.

What this code does NOT carry is the quota arithmetic: declines on this surface are deliberately uniform, and counters or limits in the message would hand an unauthenticated prober the tenant’s ceilings. The message beside this code is a fixed sentence with no numbers in it.