Create an embed session
Creates a session for an embedded view and returns its iframe url.
Call this from your backend with your API key. Put url in the src of an iframe on one of the origins pages. The URL carries a short-lived token in its fragment: treat it as a secret, and create a new session for each person and each visit.
A review session binds one extraction run (exr_…) with unit per_document and 1 to 20 of its documents. In write mode the person can edit and approve values. webhook then receives each save and approval.
A transcript or document session binds one ready file, in read mode. transcript needs a transcribed audio file. document needs a PDF, an office file with a preview, or an image.
The session ends at expiresAt: the earliest of now plus ttl and the run expiry. Call DELETE /v1/embeds/{id} to end it sooner.
Authentication
Bearer authentication of the form Bearer <token>, where token is your auth token.
Request
The exact origins of the pages that frame the view, such as https://app.example.com. No path, no wildcard, no trailing slash.
The embedded view. review shows the results of an extraction run. transcript shows an audio file with its speaker transcript. document shows a PDF, an office file preview or an image. transcript and document are read only.
The extraction run (exr_…) to review.
The file to show (transcript and document views).
The space of file (transcript and document views). The default is the files of /v1/files.
write lets the person edit and approve the values.
Where to deliver this run's events, given one of two ways.
{ "url": "…" }— a one-off https endpoint for this run only.{ "id": "whe_…" }— a saved endpoint fromPOST /v1/webhooks. Runs hold the reference, so pausing or re-pointing that endpoint applies to this run too.
Deliveries are at-least-once and signed — dedupe on eventId and verify against GET /v1/webhooks/jwks.json.
Arbitrary JSON you attach to the run and get back on every read of it.
Use it to carry your own identifiers — an order number, a customer id — so a webhook or a polled run reconciles without a lookup table. Capped at 10 KB serialized.
Session lifetime in seconds (60 to 28800). The session also ends when the run expires.
Response
The session, with the iframe url.
The iframe src. It carries the session token in its fragment: treat it as a secret.