createVerification(options)
string
required
Session token minted by your backend. Never an API key.
HTMLElement
required
The element the flow mounts into.
string
default:"/api/v1/verification"
Endpoint prefix. Set it when Idesify is on another origin, or when you proxy the API through your own domain.
string
BCP-47 tag. Sets
Accept-Language so the server localizes its copy, and selects the SDK’s own dictionary. Built-in: en, es, pt, matched on the primary subtag and falling back to en."light" | "dark" | "system"
default:"system"
Color scheme for the bundled UI.
system follows prefers-color-scheme and re-resolves live when the user flips it.string
Brand accent, as any CSS color. Overrides the dashboard theme in both light and dark, so you can brand the flow without changing dashboard settings.
UISlots
White-label hooks.
labels overrides SDK-owned strings per key; renderTerminal replaces the result screen entirely.VerificationCallbacks
onStep, onProgress, onComplete, onError, onExpire.boolean
default:"false"
Skip the intro screen and begin immediately. The intro screen’s language picker and theme toggle are skipped too, so pass the
language and colorScheme you want.InitInput
Only needed if you self-host the engine binary as a separate asset instead of using the inlined default.
boolean
default:"false"
Developer only. Overlays raw detection geometry and a numeric pose readout on the capture screens.
VerificationController
The emitter events are
step, progress, complete, error, and expire — the same signals as the callbacks, if you prefer subscribing over passing an options object.
Callbacks
onComplete is the only authoritative signal. onStep and onProgress describe what the user is doing, not what the server concluded — never gate business logic on them.The capture experience
These behaviors ship in the bundled UI and need no configuration:- Press feedback. Primary buttons show an inline spinner on click and disable their siblings, so a tap cannot be double-fired while the next screen prepares.
- Cropped review. After each document capture the review screen shows only the detected document, not the whole camera frame. This is preview-only and does not change what is submitted.
- Screen transitions. A light fade and rise between screens; camera previews fade only, to avoid video layout shift. All of it honors
prefers-reduced-motion. - Attribution. A subtle “Powered by Idesify” mark sits at the bottom of every screen. It is localized and overridable through
slots.labels.powered_by.
Theming
The dashboard theme drives the palette. The SDK resolves the effective colors and writes them as--idv-* CSS custom properties on the flow root.
accentapplies in both light and dark. Neutral surface tokens come from the active mode’s base palette.colorSchemepicks light or dark, defaulting to the OS preference.- The camera viewfinder uses the ID-1 card aspect ratio with a
coverpreview and a dimmed mask outside the frame.
slots.labels for per-string copy, supply slots.renderTerminal to own the result screen, or set the --idv-* variables yourself on the container.