← Back to overview

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.

POST /api/v1/journeys Create a new journey
ParameterTypeInRequiredDescription
project_iduuidbodyYesID of the project this journey belongs to
namestringbodyYesJourney name
descriptionstringbodyNoJourney description
prompt_templatestringbodyYesGo text/template prompt with {{.Variables}}
entry_urlstringbodyYesStarting URL for the journey
checkpointsjsonbodyNoCheckpoint definitions for progress tracking
success_criteriajsonbodyNoCriteria to determine journey success
cURL
Response
GET /api/v1/journeys List journeys
ParameterTypeInRequiredDescription
limitintegerqueryNoNumber of results to return (default: 20)
cursoruuidqueryNoCursor for pagination
projectuuidqueryNoFilter by project ID
cURL
Response
GET /api/v1/journeys/{id} Get journey by ID
ParameterTypeInRequiredDescription
iduuidpathYesJourney ID
cURL
Response
PATCH /api/v1/journeys/{id} Update a journey
ParameterTypeInRequiredDescription
iduuidpathYesJourney ID
namestringbodyNoJourney name
descriptionstringbodyNoJourney description
prompt_templatestringbodyNoGo text/template prompt
entry_urlstringbodyNoStarting URL
checkpointsjsonbodyNoCheckpoint definitions
success_criteriajsonbodyNoSuccess criteria
cURL
Response
DELETE /api/v1/journeys/{id} Delete a journey
ParameterTypeInRequiredDescription
iduuidpathYesJourney ID
cURL
Response
POST /api/v1/journeys/{id}/run Run a journey

Creates a new agent from the journey template, rendering the prompt with the supplied variables.

ParameterTypeInRequiredDescription
iduuidpathYesJourney ID
persona_iduuidbodyNoPersona for this run
variablesobjectbodyNoTemplate variables to inject into prompt_template
browser_typestringbodyNoBrowser to use (default: chrome)
record_videobooleanbodyNoRecord a video of the session (default: false)
filesarraybodyNoInitial files for the agent workspace
cURL
Response