export interface ApplicantPreFillParams { firstName?: string; lastName?: string; phonenumber?: string; dateOfBirth?: string; country?: string; nationality?: string; } export interface CreateSessionTokenParams { baseUrl: string; apiKey: string; secretKey: string; /** Numeric tenant ID (ABP projects). Provide this OR clientId. */ tenantId?: number; /** String client ID (non-ABP projects). Provide this OR tenantId. */ clientId?: string; /** * Your system's unique user identifier. The server automatically creates or * finds an applicant matching this ID, so the response always includes `applicantId`. */ externalRefId: string; /** * Workflow key for this session. Together with `externalRefId`, the server * creates or retrieves the applicant assigned to this workflow. */ workflowKey: string; /** * Applicant email address. Required — used when creating the applicant record. */ email: string; /** * When true, the SDK shows the company applicant form instead of individual. * Embedded in the token so the SDK auto-detects the form type. */ isCompany?: boolean; /** * Optional tenant client ID to associate the applicant with a specific * client within the tenant. Maps to `OwnerClientId` on the applicant record. */ tenantClientId?: number; /** * Optional pre-fill data for the applicant (name, phone, etc.). * The applicant is always created; this just seeds initial field values. */ applicant?: ApplicantPreFillParams; /** * Enable payload encryption for SDK requests/responses. * The server generates a random AES-256 key during token creation * and all subsequent API traffic is encrypted with AES-256-CBC. * Defaults to true. */ enableEncryption?: boolean; } export interface SessionTokenResult { accessToken: string; expiresInSeconds: number; /** The applicant ID created/found for this externalRefId + workflowKey combination. */ applicantId: number; /** Base64-encoded AES-256 key. Present when encryption was negotiated. */ encSessionKey?: string; /** Encryption session identifier. Present when encryption was negotiated. */ encSessionId?: string; /** AES-256 encryption key (raw bytes). Decoded from encSessionKey — used by SDK interceptors. */ encryptionKey?: ArrayBuffer; /** Pre-generated Sardin AI session key. Present when the workflow includes a Sardin identity step. */ sardinSessionKey?: string; } /** * Server-side utility to create a short-lived SDK session token. * * Call this from your backend (e.g. a Next.js API route or Express endpoint), * then pass the returned `accessToken` to the frontend SDK via `getAccessToken`. * * The API key and secret never leave your server. */ export declare class VeroComplianceSession { static createToken(params: CreateSessionTokenParams): Promise; } //# sourceMappingURL=session.d.ts.map