vision

Scan sessions with a saved scanner or an inline question. Poll the returned request for results.

post/api/projects/{project_id}/vision/requests/

Request

  • Base URL: https://us.posthog.com
  • URL: https://us.posthog.com/api/projects/{project_id}/vision/requests/
  • Auth: HTTP bearer

Path parameters

project_idstring required

Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.

Request body

session_idsstring[] required

Session recording IDs to scan, at most 200 per request. Scans start until the in-flight limit or monthly credit quota is reached; the rest are reported as skipped rather than failing the whole request. Duplicates are dropped.

scanner_idstring uuid

A saved scanner to apply to the sessions. Pass this or inline, not both.

idempotency_keystring

Any unique string per logical request, such as a UUID. Sending the same key again returns the first request instead of starting new scans, so a retry after a timeout never charges twice.

referencestring

Your own id for this request, such as a ticket or job id. Returned unchanged.

wait_for_session_endboolean

Hold the scans until every session has been quiet for 35 minutes, so each one is scanned whole. Use it when the sessions may still be recording. A scan of a live session sees only part of it, and its observation can't be replaced later. Sessions still active after 6 hours are scanned as they are.

Response

A request with this idempotency_key already exists. Nothing new was started.

idstring uuid required

Request ID. Poll GET /vision/requests/{id}/ with it.

status'running' | 'completed' required
  • running - Running
  • completed - Completed
scanner_idstring uuid nullable required

The scanner the sessions were scanned with. For an inline question this is a hidden scanner, shared by every request that asks the same question. Null when nothing could start.

referencestring required

The reference sent with the request.

created_atstring date-time required

When the request was made.

Changes

No recorded changes to this operation across all 1 revision of this API.