All calls go to
https://app.sahlfinancial.com/api with Authorization: Bearer <key>. The default environment is sandbox. Send X-Sahl-Environment: production for a live request (or ?environment=production on the query). Production needs your workspace to be approved for Production API calls (see Go live). These routes also accept a console session: reviewers and admins write, every role reads.
The applicant never calls these routes. They use the link, which is their only credential.
Create a request
The 201 answer:
url is returned only by create (201) and by resend. Sahl stores a SHA-256 of the link’s token, never the token, so keep the URL or call resend. Applicant contact details come back masked.
Idempotency
A request is unique per workspace, environment andreference while it is open (pending, opened or submitted). Creating again for the same reference returns the open request with HTTP 200, "url": null, "existing": true and "email_sent": false. Send "force_new": true to supersede it: the old link is revoked and a new request is created.
Errors on create
Statuses
A document inside a request has its own status:
missing (nothing uploaded), received (uploaded, being read), readable or unreadable. No extracted value is returned by these routes and none is shown to the applicant. You read the result on the case in the console, under the reference.
Read, list, revoke, resend
- List takes
reference,status(one of the six above, else 422invalid_status),environment,limit(1 to 200, default 50) andoffset. It answers{"items": [...], "total", "limit", "offset"}. - Get answers the same object as create, without
url. Once the request iscompletedit addsresultwithrisk_levelandscore_band(a range such as600-699) of the case. - Revoke is idempotent on a revoked request. A
completedorexpiredrequest answers 409not_revocable. - Resend mints a new link, so the old one stops working, and emails it unless you send
{"send_email": false}. Only forpendingandopenedrequests (409not_resendableotherwise). At most 3 resends per request (429resend_limit) and one a minute (429rate_limitedwithRetry-After).send_email: trueneeds an applicant email (422email_required). - A request the list or a get finds past its date is marked
expiredand therequest.expiredevent is sent. - An unknown id, or another workspace’s, answers 404
not_found.
The applicant’s link
url is https://app.sahlfinancial.com/r/<token>. The page shows your workspace name and logo, the documents asked for, your reason, the expiry date and the privacy notice that names your workspace as the data controller. The applicant:
- Opens the link. The request becomes
opened. - Accepts the privacy notice (consent). In Production the page may ask the applicant to complete a short verification challenge first. No file is taken before consent: an upload without it answers 403
consent_required. - Uploads each document. PDF, JPEG, PNG, TIFF or WebP, up to 30 MB per file, up to 5 files per document type and 30 files per request. A file that was not asked for answers 422
document_type_not_requested. - Submits. A submit with nothing uploaded answers 409
no_documents. The request becomessubmitted, andcompletedwhen every document is read.
not_found (“This link is not valid.”), so nothing can be learned by trying links. In Sandbox, the applicant can upload specimen documents only, as everywhere else.
Embed the page in an iframe
Create the request with"channel": "embed" and show the returned url:
PATCH /v1/tenants/current/request-settings:
widget_frame_origins: up to 20httpsorigins, with no path, no wildcard and no credentials. The server sendsContent-Security-Policy: frame-ancestors 'self' <your origins>on the page’s routes. An empty list lets any https site frame it.request_reply_to: an email address, ornull, used as the reply-to of the request email.
window.postMessage. The message carries no personal data, only the event type, the request status and the type and status of each document:
type is one of sahl.request.opened, sahl.request.document_uploaded, sahl.request.submitted and sahl.request.error. The page cannot know your origin, so always check event.origin and event.data.source:
GET, is the source of truth.
Webhooks
Subscribe an endpoint torequest.opened, request.submitted, request.completed and request.expired (see Webhook endpoints). Deliveries are signed like every other Sahl event. Payloads carry ids, your reference and statuses, never a name, an email, a phone number, a file name or a document value.
request.opened, request.submitted and request.expired have the same shape without risk_level and score_band. missing lists the types never uploaded. request.opened is sent on the first open only. request.completed is sent once, when the request is submitted and every requested document is read or has failed.
send_email: true Sahl emails the link from <your workspace name> via Sahl <no-reply@sahlfinancial.com>, with your request_reply_to as the reply-to. The email is in the request’s locale and carries the link, the expiry date, your reason, the data controller and a privacy line. It carries no document content. Sahl does not send from your own domain today. The answer’s email_sent says whether the email left; email_sent_at records when.
Document type keys
Use these keys indocuments. They are stable.
The applicant sees each label in the request’s language. Any other key is a 422 that lists the known ones.