Agent
Submit Input Response
ModelsExpand Collapse
A Server-Sent Event from /v1/automate. Typed discriminated union keyed on event.
A Server-Sent Event from /v1/automate. Typed discriminated union keyed on event.
class V1AutomateEventAIGeneration: …Envelope for the “ai:generation” event from /v1/automate.
Envelope for the “ai:generation” event from /v1/automate.
data: V1AutomateEventAIGenerationDataEvent data when AI generation occurs
Event data when AI generation occurs
messages: Optional[List[V1AutomateEventAIGenerationDataMessage]]
class V1AutomateEventAIGenerationDataMessageSystem: …A system message. It can contain system information.
Note: using the “system” part of the prompt is strongly preferred to increase the resilience against prompt injection attacks, and because not all providers support several system messages.
A system message. It can contain system information.
Note: using the “system” part of the prompt is strongly preferred to increase the resilience against prompt injection attacks, and because not all providers support several system messages.
class V1AutomateEventAIGenerationDataMessageUser: …A user message. It can contain text or a combination of text and images.
A user message. It can contain text or a combination of text and images.
content: Union[str, List[V1AutomateEventAIGenerationDataMessageUserContentUnionMember1]]Content of a user message. It can be a string or an array of text and image parts.
Content of a user message. It can be a string or an array of text and image parts.
List[V1AutomateEventAIGenerationDataMessageUserContentUnionMember1]
class V1AutomateEventAIGenerationDataMessageUserContentUnionMember1Text: …Text content part of a prompt. It contains a string of text.
Text content part of a prompt. It contains a string of text.
class V1AutomateEventAIGenerationDataMessageUserContentUnionMember1Image: …Image content part of a prompt. It contains an image.
Image content part of a prompt. It contains an image.
image: V1AutomateEventAIGenerationDataMessageUserContentUnionMember1ImageImageImage data. Can either be:
- data: a base64-encoded string, a Uint8Array, an ArrayBuffer, or a Buffer
- URL: a URL that points to the image
Image data. Can either be:
- data: a base64-encoded string, a Uint8Array, an ArrayBuffer, or a Buffer
- URL: a URL that points to the image
class V1AutomateEventAIGenerationDataMessageUserContentUnionMember1File: …File content part of a prompt. It contains a file.
File content part of a prompt. It contains a file.
data: V1AutomateEventAIGenerationDataMessageUserContentUnionMember1FileDataFile data. Can either be:
- data: a base64-encoded string, a Uint8Array, an ArrayBuffer, or a Buffer
- URL: a URL that points to the image
File data. Can either be:
- data: a base64-encoded string, a Uint8Array, an ArrayBuffer, or a Buffer
- URL: a URL that points to the image
class V1AutomateEventAIGenerationDataMessageAssistant: …An assistant message. It can contain text, tool calls, or a combination of text and tool calls.
An assistant message. It can contain text, tool calls, or a combination of text and tool calls.
content: Union[str, List[V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1]]Content of an assistant message. It can be a string or an array of text, image, reasoning, redacted reasoning, and tool call parts.
Content of an assistant message. It can be a string or an array of text, image, reasoning, redacted reasoning, and tool call parts.
List[V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1]
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1Text: …Text content part of a prompt. It contains a string of text.
Text content part of a prompt. It contains a string of text.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1File: …File content part of a prompt. It contains a file.
File content part of a prompt. It contains a file.
data: V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1FileDataFile data. Can either be:
- data: a base64-encoded string, a Uint8Array, an ArrayBuffer, or a Buffer
- URL: a URL that points to the image
File data. Can either be:
- data: a base64-encoded string, a Uint8Array, an ArrayBuffer, or a Buffer
- URL: a URL that points to the image
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1Reasoning: …Reasoning content part of a prompt. It contains a reasoning.
Reasoning content part of a prompt. It contains a reasoning.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolCall: …Tool call content part of a prompt. It contains a tool call (usually generated by the AI model).
Tool call content part of a prompt. It contains a tool call (usually generated by the AI model).
Arguments of the tool call. This is a JSON-serializable object that matches the tool’s input schema.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResult: …Tool result content part of a prompt. It contains the result of the tool call with the matching ID.
Tool result content part of a prompt. It contains the result of the tool call with the matching ID.
output: V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputResult of the tool call. This is a JSON-serializable object.
Result of the tool call. This is a JSON-serializable object.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputText: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputJson: …
value: Union[str, float, bool, 3 more]A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputExecutionDenied: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputErrorText: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputErrorJson: …
value: Union[str, float, bool, 3 more]A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContent: …
value: List[V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValue]
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueText: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueMedia: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueFileData: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueFileURL: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueFileID: …
file_id: Union[str, Dict[str, str]]ID of the file.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
ID of the file.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueImageData: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueImageURL: …
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueImageFileID: …
file_id: Union[str, Dict[str, str]]Image that is referenced using a provider file id.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
Image that is referenced using a provider file id.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
class V1AutomateEventAIGenerationDataMessageAssistantContentUnionMember1ToolResultOutputContentValueCustom: …
class V1AutomateEventAIGenerationDataMessageTool: …A tool message. It contains the result of one or more tool calls.
A tool message. It contains the result of one or more tool calls.
content: List[V1AutomateEventAIGenerationDataMessageToolContent]Content of a tool message. It is an array of tool result parts.
Content of a tool message. It is an array of tool result parts.
class V1AutomateEventAIGenerationDataMessageToolContentToolResult: …Tool result content part of a prompt. It contains the result of the tool call with the matching ID.
Tool result content part of a prompt. It contains the result of the tool call with the matching ID.
output: V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputResult of the tool call. This is a JSON-serializable object.
Result of the tool call. This is a JSON-serializable object.
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputText: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputJson: …
value: Union[str, float, bool, 3 more]A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputExecutionDenied: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputErrorText: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputErrorJson: …
value: Union[str, float, bool, 3 more]A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
A JSON value can be a string, number, boolean, object, array, or null. JSON values can be serialized and deserialized by the JSON.stringify and JSON.parse methods.
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContent: …
value: List[V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValue]
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueText: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueFileData: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueFileURL: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueFileID: …
file_id: Union[str, Dict[str, str]]ID of the file.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
ID of the file.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueImageData: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueImageURL: …
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueImageFileID: …
file_id: Union[str, Dict[str, str]]Image that is referenced using a provider file id.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
Image that is referenced using a provider file id.
If you use multiple providers, you need to specify the provider specific ids using the Record option. The key is the provider name, e.g. ‘openai’ or ‘anthropic’.
class V1AutomateEventAIGenerationDataMessageToolContentToolResultOutputContentValueCustom: …
class V1AutomateEventAIGenerationError: …Envelope for the “ai:generation:error” event from /v1/automate.
Envelope for the “ai:generation:error” event from /v1/automate.
class V1AutomateEventBrowserActionCompleted: …Envelope for the “browser:action_completed” event from /v1/automate.
Envelope for the “browser:action_completed” event from /v1/automate.
class V1AutomateEventBrowserActionStarted: …Envelope for the “browser:action_started” event from /v1/automate.
Envelope for the “browser:action_started” event from /v1/automate.
class V1AutomateEventBrowserNavigated: …Envelope for the “browser:navigated” event from /v1/automate.
Envelope for the “browser:navigated” event from /v1/automate.
class V1AutomateEventBrowserReconnected: …Envelope for the “browser:reconnected” event from /v1/automate.
Envelope for the “browser:reconnected” event from /v1/automate.
class V1AutomateEventBrowserScreenshotCaptured: …Envelope for the “browser:screenshot_captured” event from /v1/automate.
Envelope for the “browser:screenshot_captured” event from /v1/automate.
class V1AutomateEventBrowserScreenshotCapturedImage: …Envelope for the “browser:screenshot_captured_image” event from /v1/automate.
Envelope for the “browser:screenshot_captured_image” event from /v1/automate.
class V1AutomateEventCdpEndpointConnected: …Envelope for the “cdp:endpoint_connected” event from /v1/automate.
Envelope for the “cdp:endpoint_connected” event from /v1/automate.
class V1AutomateEventCdpEndpointCycle: …Envelope for the “cdp:endpoint_cycle” event from /v1/automate.
Envelope for the “cdp:endpoint_cycle” event from /v1/automate.
class V1AutomateEventComplete: …Envelope for the “complete” event from /v1/automate.
Envelope for the “complete” event from /v1/automate.
data: V1AutomateEventCompleteDataPayload for the complete stream event. Structurally identical to TaskExecutionResult from webAgent.ts — the complete event’s data is the agent’s final TaskExecutionResult, stringified onto the SSE stream.
Payload for the complete stream event. Structurally identical to TaskExecutionResult from webAgent.ts — the complete event’s data is the agent’s final TaskExecutionResult, stringified onto the SSE stream.
class V1AutomateEventError: …Envelope for the “error” event from /v1/automate.
Envelope for the “error” event from /v1/automate.
data: V1AutomateEventErrorDataPayload for the top-level error stream event. Emitted when an uncaught error escapes the task runner. Mirrors ErrorResponse from the server package’s taskRunner.ts — kept structurally aligned so schema and runtime stay consistent. Distinct from agent-level error events like ai:generation:error and task:validation_error, which are emitted through the normal event emitter during the agent loop.
Payload for the top-level error stream event. Emitted when an uncaught error escapes the task runner. Mirrors ErrorResponse from the server package’s taskRunner.ts — kept structurally aligned so schema and runtime stay consistent. Distinct from agent-level error events like ai:generation:error and task:validation_error, which are emitted through the normal event emitter during the agent loop.
class V1AutomateEventInteractiveFormDataError: …Envelope for the “interactive:form_data:error” event from /v1/automate.
Envelope for the “interactive:form_data:error” event from /v1/automate.
data: V1AutomateEventInteractiveFormDataErrorDataEvent data when form validation fails and the agent re-requests data. Carries both the error context and the fields that need new values. Callers respond to this the same way as a request event.
Event data when form validation fails and the agent re-requests data. Carries both the error context and the fields that need new values. Callers respond to this the same way as a request event.
class V1AutomateEventInteractiveFormDataRequest: …Envelope for the “interactive:form_data:request” event from /v1/automate.
Envelope for the “interactive:form_data:request” event from /v1/automate.
class V1AutomateEventSystemDebugCompression: …Envelope for the “system:debug_compression” event from /v1/automate.
Envelope for the “system:debug_compression” event from /v1/automate.
class V1AutomateEventSystemDebugMessage: …Envelope for the “system:debug_message” event from /v1/automate.
Envelope for the “system:debug_message” event from /v1/automate.
class V1AutomateEventTaskMetricsIncremental: …Envelope for the “task:metrics_incremental” event from /v1/automate.
Envelope for the “task:metrics_incremental” event from /v1/automate.
class V1AutomateEventTaskSetup: …Envelope for the “task:setup” event from /v1/automate.
Envelope for the “task:setup” event from /v1/automate.
class V1AutomateEventTaskTraceContext: …Envelope for the “task:trace_context” event from /v1/automate.
Envelope for the “task:trace_context” event from /v1/automate.
class V1AutomateEventTaskValidated: …Envelope for the “task:validated” event from /v1/automate.
Envelope for the “task:validated” event from /v1/automate.
A Server-Sent Event from /v1/research. Typed discriminated union keyed on event.
A Server-Sent Event from /v1/research. Typed discriminated union keyed on event.
class V1ResearchEventAnalyzingEnd: …Envelope for the “analyzing:end” event from /v1/research.
Envelope for the “analyzing:end” event from /v1/research.
class V1ResearchEventComplete: …Envelope for the “complete” event from /v1/research.
Envelope for the “complete” event from /v1/research.
data: V1ResearchEventCompleteDatacomplete - Research finished successfully
complete - Research finished successfully
metadata: V1ResearchEventCompleteDataMetadataResearch metadata
Note: citedPages, gapEvaluations, outline, and judgments are optional to support fast mode, which skips these phases for maximum speed.
Research metadata
Note: citedPages, gapEvaluations, outline, and judgments are optional to support fast mode, which skips these phases for maximum speed.
mode: Literal["fast", "balanced", "deep", 2 more]Research mode determines depth, thinking budget, and quality controls
Modes (in order of cost/thoroughness):
- fast: Quick answers with minimal validation (~$2, 1 iteration, no judge)
- balanced: Standard research with moderate depth (~$8, 3 iterations, Flash models, no judge)
- deep: Thorough research with judge review (~$15, 5 iterations, Flash models, with judge)
- max: Maximum quality with Pro models (~$40, 5 iterations, Pro models, with judge)
- ultra: Ultimate tier - all Pro models, 10 iterations (expensive, for when accuracy is paramount)
Research mode determines depth, thinking budget, and quality controls
Modes (in order of cost/thoroughness):
- fast: Quick answers with minimal validation (~$2, 1 iteration, no judge)
- balanced: Standard research with moderate depth (~$8, 3 iterations, Flash models, no judge)
- deep: Thorough research with judge review (~$15, 5 iterations, Flash models, with judge)
- max: Maximum quality with Pro models (~$40, 5 iterations, Pro models, with judge)
- ultra: Ultimate tier - all Pro models, 10 iterations (expensive, for when accuracy is paramount)
cited_pages: Optional[List[V1ResearchEventCompleteDataMetadataCitedPage]]Pages cited in the report, ordered by first citation appearance
Pages cited in the report, ordered by first citation appearance
gap_evaluations: Optional[List[V1ResearchEventCompleteDataMetadataGapEvaluation]]
Based on unanswered/partial questions, what specific information is still needed?
question_assessments: List[V1ResearchEventCompleteDataMetadataGapEvaluationQuestionAssessment]Assessment of each research question’s status and findings
Assessment of each research question’s status and findings
research_coverage: Literal["Light", "Moderate", "Solid", "Comprehensive"]Research coverage level - assesses quality across all questions.
Hierarchy: Light < Moderate < Solid < Comprehensive
- Light: Basic info on some questions, most need more depth → Continue
- Moderate: Multiple questions answered, some remain partial → Continue
- Solid: Most questions well-answered with validated sources → Sufficient to stop
- Comprehensive: All questions thoroughly answered, exceptional depth → Definitely stop
Research coverage level - assesses quality across all questions.
Hierarchy: Light < Moderate < Solid < Comprehensive
- Light: Basic info on some questions, most need more depth → Continue
- Moderate: Multiple questions answered, some remain partial → Continue
- Solid: Most questions well-answered with validated sources → Sufficient to stop
- Comprehensive: All questions thoroughly answered, exceptional depth → Definitely stop
Explicit decision: should research continue with another iteration?
- Considers: how many questions unanswered/partial, coverage for mode, remaining iterations
- Drives query generation: true → generate queries, false → stop researching
metrics: Optional[V1ResearchEventCompleteDataMetadataMetrics]Complete research metrics
Complete research metrics
phases: Dict[str, V1ResearchEventCompleteDataMetadataMetricsPhases]Phase timings with duration in milliseconds
Phase timings with duration in milliseconds
class V1ResearchEventError: …Envelope for the “error” event from /v1/research.
Envelope for the “error” event from /v1/research.
class V1ResearchEventEvaluatingEnd: …Envelope for the “evaluating:end” event from /v1/research.
Envelope for the “evaluating:end” event from /v1/research.
class V1ResearchEventFollowingEnd: …Envelope for the “following:end” event from /v1/research.
Envelope for the “following:end” event from /v1/research.
class V1ResearchEventIterationEnd: …Envelope for the “iteration:end” event from /v1/research.
Envelope for the “iteration:end” event from /v1/research.
class V1ResearchEventPrefetchingStart: …Envelope for the “prefetching:start” event from /v1/research.
Envelope for the “prefetching:start” event from /v1/research.