Journeys
Journeys are reusable, parameterized agent templates. Define a prompt template using Go text/template syntax, add checkpoints for progress tracking, and set success criteria — then run the journey repeatedly with different inputs or personas.
Prompt Template
Prompt templates use Go text/template syntax. When a journey is run, the template is rendered with the following variables:
{{.EntryURL}}— the journey's starting URL{{.Persona.Name}}— name of the assigned persona{{.Persona.Description}}— persona description (injected into the system prompt){{.Vars}}— a map of custom variables passed at run time (access individual keys with{{.Vars.key}})
The rendered output becomes the agent's prompt. Standard Go template constructs (if, range, with) are supported.
Checkpoints
Checkpoints are a JSON array of objects, each with a name and description. The verification system uses them to track step-by-step progress through the journey.
[ {"name": "login", "description": "Agent logged in successfully"}, {"name": "add_to_cart", "description": "Added item to cart"} ]During verification, each checkpoint is evaluated in order. Partial progress is reported when some checkpoints pass but others fail.
Success Criteria
Success criteria is a JSON object that defines the conditions for a journey to be considered successful. It is evaluated after all checkpoints have been processed. If omitted, the journey succeeds when all checkpoints pass.
Paste your API key to use the Try it panels below. Don't have one? Create an account.
/api/v1/journeys Create a new journey| Parameter | Type | In | Required | Description |
|---|---|---|---|---|
project_id | uuid | body | Yes | ID of the project this journey belongs to |
name | string | body | Yes | Journey name |
description | string | body | No | Journey description |
prompt_template | string | body | Yes | Go text/template prompt with {{.Variables}} |
entry_url | string | body | Yes | Starting URL for the journey |
checkpoints | json | body | No | Checkpoint definitions for progress tracking |
success_criteria | json | body | No | Criteria to determine journey success |
/api/v1/journeys List journeys| Parameter | Type | In | Required | Description |
|---|---|---|---|---|
limit | integer | query | No | Number of results to return (default: 20) |
cursor | uuid | query | No | Cursor for pagination |
project | uuid | query | No | Filter by project ID |
/api/v1/journeys/{id} Get journey by ID| Parameter | Type | In | Required | Description |
|---|---|---|---|---|
id | uuid | path | Yes | Journey ID |
/api/v1/journeys/{id} Update a journey| Parameter | Type | In | Required | Description |
|---|---|---|---|---|
id | uuid | path | Yes | Journey ID |
name | string | body | No | Journey name |
description | string | body | No | Journey description |
prompt_template | string | body | No | Go text/template prompt |
entry_url | string | body | No | Starting URL |
checkpoints | json | body | No | Checkpoint definitions |
success_criteria | json | body | No | Success criteria |
/api/v1/journeys/{id} Delete a journey| Parameter | Type | In | Required | Description |
|---|---|---|---|---|
id | uuid | path | Yes | Journey ID |
/api/v1/journeys/{id}/run Run a journeyCreates a new agent from the journey template, rendering the prompt with the supplied variables.
| Parameter | Type | In | Required | Description |
|---|---|---|---|---|
id | uuid | path | Yes | Journey ID |
persona_id | uuid | body | No | Persona for this run |
variables | object | body | No | Template variables to inject into prompt_template |
browser_type | string | body | No | Browser to use (default: chrome) |
record_video | boolean | body | No | Record a video of the session (default: false) |
files | array | body | No | Initial files for the agent workspace |