POST https://api.alentra.app/v1/sessions · Auth: Bearer API keyHeaders
string
required
Bearer YOUR_API_KEYstring
Optional. A repeat with the same key returns the original session instead of creating
a duplicate. Reuse does not compare payloads; use a new key for each logical run.
Body
string
required
The id of a live workflow whose access mode is API only. Inline
steps[] are
rejected; edit and publish the workflow in the dashboard instead.object
Up to 50 string-valued keys (key up to 40 characters, value up to 500). Use this for
caller-owned correlation context such as
order_id or case_id. It is returned in
signed webhooks and authenticated session reads, and never shown to the signer.string
An
https URL. Renders a “Return to {host}” button on the hosted page after
completion; it never causes an automatic redirect.integer
Session TTL in seconds (60–86400). Defaults to the standard cap.
Signing documents
If the published workflow containssign, use multipart/form-data. Send
workflow_id as a form field and each document as one named file part. Alentra injects
those document ids into this session’s immutable workflow snapshot, hashes the exact
bytes, and presents those bytes to the signer. The reusable workflow stores no files.
Response
string
The session id, e.g.
sess_abc123.string
created.string
The hosted page URL to hand the user.
string
ISO 8601 expiry timestamp.
string
The workflow used for this run.
integer
The immutable published revision snapshotted by the session.
Errors
400 missing workflow id / inline steps / invalid metadata or files · 401 bad key
or archived/frozen business · 402 insufficient balance · 409 workflow not live or
wrong launch mode · 422 no webhook configured. See Errors.