Submit tool outputs for a paused generation
POST/api/v1/agents/:agent_id/generate/:generation_id/tool-outputs
Resumes a generation that was paused due to client tool calls. Provide tool outputs for each pending tool call.
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 413
- 429
- 500
- 502
Generation result after resuming
Bad Request
Unauthorized
Forbidden
Agent or generation not found
The generation is not paused on client tool calls (GENERATION_NOT_AWAITING_TOOL_OUTPUTS): it never paused, or its outputs were already submitted. Each pause accepts outputs once.
REQUEST_REJECTED — the request body is over the size the body parser accepts
QUOTA_EXCEEDED — a requests quota on the calling API key or its project is spent for the window; Retry-After says when it reopens
Response Headers
Seconds until the quota window admits a request again
Unexpected server error — INTERNAL_ERROR, with the raw message never forwarded
Upstream AI provider error (AI_PROVIDER_ERROR); model output that does not satisfy the agent's output_schema (OUTPUT_SCHEMA_VALIDATION_FAILED); or a model that wrote a tool invocation out as plain assistant text instead of calling the tool (TEXT_ENCODED_TOOL_CALL — meta.tool_name names the tool). The resumed generation is recorded failed.