Vision
For instructions on how to authenticate to use this endpoint, see API overview.
Endpoints
GET | |
POST | |
GET | |
PATCH | |
DELETE | |
POST | |
GET | |
GET | |
GET | |
GET | |
POST | |
POST | |
DELETE | |
POST | |
GET | |
GET | |
POST | |
GET | |
PATCH | |
DELETE |
List all vision actions
CRUD for Replay Vision actions — scheduled "and then…" automations over a scanner's observations.
Required API key scopes
vision_action:readQuery parameters
- limitinteger
- offsetinteger
- scannerstring
Response
Example request
GET /api /projects /:project_id /vision /actionsExample response
Status 200
Create vision actions
CRUD for Replay Vision actions — scheduled "and then…" automations over a scanner's observations.
Required API key scopes
vision_action:writesession_recording:readRequest parameters
- namestring
- scannerstring
- enabledboolean
- is_scanner_digestboolean
- trigger_type
- mode
- trigger_config
- selection
- synthesis_config
- alert_config
- delivery_configarray
Response
Example request
POST /api /projects /:project_id /vision /actionsExample response
Status 201
Retrieve vision actions
CRUD for Replay Vision actions — scheduled "and then…" automations over a scanner's observations.
Required API key scopes
vision_action:readPath parameters
- idstring
Response
Example request
GET /api /projects /:project_id /vision /actions /:idExample response
Status 200
Update vision actions
CRUD for Replay Vision actions — scheduled "and then…" automations over a scanner's observations.
Required API key scopes
vision_action:writesession_recording:readPath parameters
- idstring
Request parameters
- namestring
- scannerstring
- enabledboolean
- is_scanner_digestboolean
- trigger_type
- mode
- trigger_config
- selection
- synthesis_config
- alert_config
- delivery_configarray
Response
Example request
PATCH /api /projects /:project_id /vision /actions /:idExample response
Status 200
Delete vision actions
CRUD for Replay Vision actions — scheduled "and then…" automations over a scanner's observations.
Required API key scopes
vision_action:writePath parameters
- idstring
Example request
DELETE /api /projects /:project_id /vision /actions /:idExample response
Status 204 No response body
Create vision actions run
Run this summary now, without waiting for its schedule — synthesizes a group summary over the observations since the last summary (or the last 24h). The recurring schedule is untouched: the engine advances next_run_at only at scheduled claim time, never in the run itself.
Required API key scopes
vision_action:writesession_recording:readPath parameters
- idstring
Response
Example request
POST /api /projects /:project_id /vision /actions /:id /runExample response
Status 202
List all vision actions runs
Read-only run history for a single vision action (nested under /vision/actions/{action_id}/runs/).
Required API key scopes
vision_action:readsession_recording:readPath parameters
- vision_action_idstring
Query parameters
- limitinteger
- offsetinteger
Response
Example request
GET /api /projects /:project_id /vision /actions /:vision_action_id /runsExample response
Status 200
Retrieve vision actions runs
Read-only run history for a single vision action (nested under /vision/actions/{action_id}/runs/).
Required API key scopes
vision_action:readsession_recording:readPath parameters
- idstring
- vision_action_idstring
Response
Example request
GET /api /projects /:project_id /vision /actions /:vision_action_id /runs /:idExample response
Status 200
List all vision observations
Read-only access to a session's observations across every scanner the caller can read, for the replay-page dock.
Required API key scopes
replay_scanner:readsession_recording:readQuery parameters
- limitinteger
- offsetinteger
- order_bystringOne of:
"-completed_at""-created_at""-label""-recording_subject_email""-result_confidence""-result_score""-result_verdict""-scanner_version""-started_at""-status""completed_at""created_at""label""recording_subject_email""result_confidence""result_score""result_verdict""scanner_version""started_at""status" - session_idstring
Response
Example request
GET /api /projects /:project_id /vision /observationsExample response
Status 200
Retrieve vision observations
Retrieve one observation. Any list filters passed along (status, tags, order_by, …) scope the previous_observation_id/next_observation_id navigation to the matching, identically-ordered set — so prev/next from a filtered table stays within that filtered list.
Required API key scopes
replay_scanner:readsession_recording:readPath parameters
- idstring
Query parameters
- date_fromstring
- date_tostring
- labeledstring
- order_bystringOne of:
"-completed_at""-created_at""-label""-recording_subject_email""-result_confidence""-result_score""-result_verdict""-scanner_version""-started_at""-status""completed_at""created_at""label""recording_subject_email""result_confidence""result_score""result_verdict""scanner_version""started_at""status" - recording_subjectstring
- session_idstring
- statusstring
- tagsstring
- triggered_bystring
- verdictstring
Response
Example request
GET /api /projects /:project_id /vision /observations /:idExample response
Status 200
Create vision observations create task
Create a PostHog Task from this observation's finding so it can be triaged and fixed. Title and description are derived from the scanner and its result. Record-only: this does not start the coding agent. Idempotent per observation: once a task exists, repeat calls return its id with a 200 instead of creating a duplicate.
Required API key scopes
replay_scanner:writesession_recording:readtask:writePath parameters
- idstring
Response
Example request
POST /api /projects /:project_id /vision /observations /:id /create_taskExample response
Status 200
Status 201
Create vision observations label
Set or update the observation's shared label: whether the scanner scored the session correctly, plus optional feedback on what it got wrong. One label per observation, shared across the team; these labels feed prompt improvement. Requires editor access to the scanner.
Required API key scopes
replay_scanner:writesession_recording:readPath parameters
- idstring
Request parameters
- is_correctboolean
- feedbackstringDefault:
Response
Example request
POST /api /projects /:project_id /vision /observations /:id /labelExample response
Status 200
Delete vision observations label
Remove the observation's shared label. Requires editor access to the scanner.
Required API key scopes
replay_scanner:writesession_recording:readPath parameters
- idstring
Example request
DELETE /api /projects /:project_id /vision /observations /:id /labelExample response
Status 204 No response body
Create vision observations retry
Delete a failed observation and re-run its scanner on the same recording. Returns 202 with the workflow handle.
Required API key scopes
replay_scanner:writesession_recording:readPath parameters
- idstring
Response
Example request
POST /api /projects /:project_id /vision /observations /:id /retryExample response
Status 202
Retrieve environment vision quota
Required API key scopes
replay_scanner:readResponse
Example request
GET /api /projects /:project_id /vision /quotaExample response
Status 200
List all vision scanners
CRUD for Replay Vision scanners.
Required API key scopes
replay_scanner:readQuery parameters
- created_bystring
- emits_signalsboolean
- enabledstring
- limitinteger
- offsetinteger
- order_bystringOne of:
"-created_at""-created_by""-credits_this_month""-enabled""-name""-sampling_rate""-scanner_type""-updated_at""created_at""created_by""credits_this_month""enabled""name""sampling_rate""scanner_type""updated_at" - scanner_typestring
- searchstring
Response
Example request
GET /api /projects /:project_id /vision /scannersExample response
Status 200
Create vision scanners
CRUD for Replay Vision scanners.
Required API key scopes
replay_scanner:writesession_recording:readRequest parameters
- namestring
- descriptionstring
- scanner_type
- scanner_config
- query
- sampling_ratenumber
- sampling_mode
- provider
- model
- enabledboolean
- emits_signalsboolean
Response
Example request
POST /api /projects /:project_id /vision /scannersExample response
Status 201
Retrieve vision scanners
CRUD for Replay Vision scanners.
Required API key scopes
replay_scanner:readPath parameters
- idstring
Response
Example request
GET /api /projects /:project_id /vision /scanners /:idExample response
Status 200
Update vision scanners
CRUD for Replay Vision scanners.
Required API key scopes
replay_scanner:writesession_recording:readPath parameters
- idstring
Request parameters
- namestring
- descriptionstring
- scanner_type
- scanner_config
- query
- sampling_ratenumber
- sampling_mode
- provider
- model
- enabledboolean
- emits_signalsboolean
Response
Example request
PATCH /api /projects /:project_id /vision /scanners /:idExample response
Status 200
Delete vision scanners
CRUD for Replay Vision scanners.
Required API key scopes
replay_scanner:writePath parameters
- idstring
Example request
DELETE /api /projects /:project_id /vision /scanners /:id