Skip to main content
Run an agent task within the current browser session. The agent will perform the task autonomously, starting from the current page state.

Usage

Request

string
required
The task for the agent to execute.Example: Fill out the contact form and submit it
int
The upper limit on the number of steps the agent can take during task execution. The range is from 2 to 128. Default: 32.Example: 64
dict
If provided, enforces a structured output schema. It should be a dictionary describing a JSON schema. Default: None.Example:
string
Navigate to this URL before executing the task. If not provided, the task starts from the current page.Example: https://example.com/contact
dict
A dictionary containing variables or parameters that will be passed to the agent.Example: {"username": "test_user", "email": "test@example.com"}

Response

Returns an object with the following attributes.
any
The task output returned by the agent. If response_model was provided, this will conform to the specified schema.
float
The number of credits used for this task. 1 credit corresponds to $0.01.
float
The duration in seconds taken to perform the task.

Examples

Basic task:
With structured output:
With metadata:
Chaining multiple tasks:
Pro Tip: Use response_model to have the agent report whether each task succeeded before moving to the next one. This prevents your workflow from continuing blindly when something went wrong.