@sekyro/web 0.1.0-rc.18 → 0.1.0-rc.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/README.md +1 -2
- package/dist/{capture-session-doc-IE5VPYWC.js → capture-session-doc-VXWWQEP4.js} +1 -1
- package/dist/{capture-session-v3-Dxus1Se9.d.ts → capture-session-v3-CFSVWYzi.d.ts} +13 -2
- package/dist/{capture-session-v3-DyUA2uCL.d.cts → capture-session-v3-Cs4yV3HJ.d.cts} +13 -2
- package/dist/chunk-4GJXUVZK.js +1 -0
- package/dist/chunk-5Y3UST3W.js +1 -0
- package/dist/{chunk-JDTZK3A7.js → chunk-64V55KD7.js} +1 -1
- package/dist/chunk-6K4D3U6Q.js +1 -0
- package/dist/chunk-CQ7SKLMC.js +1 -0
- package/dist/{chunk-DNB3R4PI.js → chunk-JUEOHNVW.js} +1 -1
- package/dist/chunk-L45YTRJJ.js +1 -0
- package/dist/chunk-PLH6ZR6J.js +1 -0
- package/dist/chunk-RNJA5GDF.js +1 -0
- package/dist/chunk-ZO6IHP2I.js +1 -0
- package/dist/chunk-ZPXL26BF.js +1 -0
- package/dist/client/index.cjs +1 -1
- package/dist/client/index.d.cts +4 -4
- package/dist/client/index.d.ts +4 -4
- package/dist/client/index.js +1 -1
- package/dist/core/index.cjs +1 -1
- package/dist/core/index.d.cts +3 -3
- package/dist/core/index.d.ts +3 -3
- package/dist/core/index.js +1 -1
- package/dist/create-document-capture-FVSQPUF6.js +1 -0
- package/dist/create-portrait-capture-INDCF65X.js +1 -0
- package/dist/{create-verification-DiH7QRdv.d.cts → create-verification-1BrMZqPJ.d.cts} +67 -15
- package/dist/{create-verification-C_fx3n4A.d.ts → create-verification-CuoYJ3kj.d.ts} +67 -15
- package/dist/{icao-gate-5FzqyitT.d.ts → icao-gate-BSbyqLUh.d.ts} +25 -9
- package/dist/{icao-gate-C-lfjEpH.d.cts → icao-gate-D-wePfoV.d.cts} +25 -9
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +6 -6
- package/dist/index.d.ts +6 -6
- package/dist/index.js +1 -1
- package/dist/internal/index.cjs +1 -1
- package/dist/internal/index.d.cts +6 -6
- package/dist/internal/index.d.ts +6 -6
- package/dist/internal/index.js +1 -1
- package/dist/plan-runner-WEUIMCYU.js +1 -0
- package/dist/{types-CKgMWVnP.d.cts → types-DPl0hsmI.d.cts} +29 -5
- package/dist/{types-CKgMWVnP.d.ts → types-DPl0hsmI.d.ts} +29 -5
- package/package.json +1 -1
- package/sbom.cdx.json +7 -7
- package/dist/chunk-2BFYVMUU.js +0 -1
- package/dist/chunk-D42NBRSV.js +0 -1
- package/dist/chunk-G2HL2ZWH.js +0 -1
- package/dist/chunk-G6MU3B5V.js +0 -1
- package/dist/chunk-KBKCYDZQ.js +0 -1
- package/dist/chunk-OG4QAJ3M.js +0 -1
- package/dist/chunk-SVNAHPQU.js +0 -1
- package/dist/chunk-VCUOPQFA.js +0 -1
- package/dist/chunk-ZMO2ZQAS.js +0 -1
- package/dist/create-document-capture-35HFVNC3.js +0 -1
- package/dist/create-portrait-capture-53XBURNT.js +0 -1
- package/dist/plan-runner-YXTOSPDP.js +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { b as Detector } from './detect-worker-DclNxkZT.cjs';
|
|
2
|
-
import { A as AcceptedDocumentType,
|
|
3
|
-
import { i as CaptureState$1, f as CaptureSessionV3Events, g as CaptureSessionV3Options, c as CaptureErrorKind$1, p as DeviceClass, b as CaptureArtifacts, I as V3GateQuality, O as V3TelemetryEvent } from './capture-session-v3-
|
|
4
|
-
import { c as IcaoGateSummary, d as IcaoGateUpdate, P as Point, e as Box, j as IcaoFrameObservation, N as HostedClient, k as IcaoGate } from './icao-gate-
|
|
2
|
+
import { A as AcceptedDocumentType, a5 as NationalEidOption, au as StepSection, t as HostedBranding, ag as PlanSectionView, ad as PlanChoiceKind, n as ContactChannel, l as CheckReason, an as RetakeHint, $ as IdentityMethod, E as EidAfterPass, a0 as IdentitySummarySource, J as HostedIcaoPolicy, a9 as PhoneCountryRule, _ as IcaoReportEntry, Z as IcaoCaptureTuning, H as HostedSessionView, W as HostedStepView, ah as PlanStepView, j as CaptureMode, aq as ScreenRampReport, k as CaptureProvenance, S as ScreenRampColour, ar as SessionFailureReason, i as AgeEstimationReason, aw as VerificationLevel, av as VerificationAssurance, a4 as MethodChoiceView, b as CameraUnavailableCause, c as CaptureIssueReport, am as ResolvedCaptureMode, Y as HostedVoiceView, ao as ScreenRampChallenge, aA as PersonMask, aB as AttestationInput, f as CheckType, ak as PortraitIcaoInput } from './types-DPl0hsmI.cjs';
|
|
3
|
+
import { i as CaptureState$1, f as CaptureSessionV3Events, g as CaptureSessionV3Options, c as CaptureErrorKind$1, p as DeviceClass, b as CaptureArtifacts, a4 as EngineErrorDetail, I as V3GateQuality, O as V3TelemetryEvent } from './capture-session-v3-Cs4yV3HJ.cjs';
|
|
4
|
+
import { c as IcaoGateSummary, d as IcaoGateUpdate, P as Point, e as Box, j as IcaoFrameObservation, N as HostedClient, k as IcaoGate } from './icao-gate-D-wePfoV.cjs';
|
|
5
5
|
|
|
6
6
|
declare const ISSUER_CODES: readonly string[];
|
|
7
7
|
|
|
@@ -321,6 +321,12 @@ interface DocumentSnapshot extends StepAttempts {
|
|
|
321
321
|
side: "recto" | "verso";
|
|
322
322
|
acceptedSides: ("recto" | "verso")[];
|
|
323
323
|
documents: AcceptedDocumentsLike;
|
|
324
|
+
/**
|
|
325
|
+
* Age check (selfie): `true` when the session reached this document because the selfie could not settle the
|
|
326
|
+
* person's age (`age_estimation` failed with `age_uncertain` or `age_unavailable`); show the step-up line
|
|
327
|
+
* (`doc.ageStepUp`). Absent otherwise.
|
|
328
|
+
*/
|
|
329
|
+
ageStepUp?: true;
|
|
324
330
|
}
|
|
325
331
|
interface LivenessSnapshot extends StepAttempts {
|
|
326
332
|
/**
|
|
@@ -666,7 +672,7 @@ interface PortraitCaptureHandle {
|
|
|
666
672
|
on<K extends keyof PortraitCaptureEvents>(event: K, handler: (payload: PortraitCaptureEvents[K]) => void): () => void;
|
|
667
673
|
/**
|
|
668
674
|
* Who films the face: a portrait step's handle follows the session (`HostedSessionView.capture.mode`); a standalone
|
|
669
|
-
* {@link createPortraitCapture} is always `self` (the front camera, no switch).
|
|
675
|
+
* {@link createPortraitCapture} is always `self` (the front camera, no switch). Never `choice`.
|
|
670
676
|
*/
|
|
671
677
|
readonly captureMode: CaptureMode;
|
|
672
678
|
/** The camera of the live stream (as its track reports it, else as requested); `'user'` before the first start. */
|
|
@@ -769,7 +775,10 @@ interface CapturedArtifacts {
|
|
|
769
775
|
* The upright requirement applies to phones only. Always set by the SDK.
|
|
770
776
|
*/
|
|
771
777
|
formFactor?: "phone" | "tablet" | "desktop";
|
|
772
|
-
/**
|
|
778
|
+
/**
|
|
779
|
+
* The capture mode the attempt ran in ({@link LivenessCaptureHandle.captureMode}): `self` or `assisted`, never
|
|
780
|
+
* `choice`. Always set by the SDK.
|
|
781
|
+
*/
|
|
773
782
|
mode?: CaptureMode;
|
|
774
783
|
/**
|
|
775
784
|
* Liveness v7 §4.4: the screen ramp rendered against the session's issued challenge, stamped on the clip's own
|
|
@@ -784,6 +793,23 @@ interface CapturedArtifacts {
|
|
|
784
793
|
type CaptureEngineId = "v1" | "v3";
|
|
785
794
|
/** Camera / engine failure kinds — collapsed to the public six. */
|
|
786
795
|
type CaptureErrorKind = "permission" | "notfound" | "inuse" | "insecure" | "unsupported" | "generic";
|
|
796
|
+
/** The capture step that was running when a capture failed. */
|
|
797
|
+
type CaptureErrorPhase = "preflight" | "acquiring" | "models" | "recording" | "keyframes" | "upload";
|
|
798
|
+
/**
|
|
799
|
+
* What the public {@link CaptureErrorKind} leaves out, for diagnostics. Never personal data: `name` is the thrown
|
|
800
|
+
* error's `name` only (a class or DOMException name such as `NotReadableError`, never its message), letters only and
|
|
801
|
+
* at most 40 characters.
|
|
802
|
+
*/
|
|
803
|
+
interface CaptureErrorDetail {
|
|
804
|
+
/** The thrown error's `name`, when the failure threw one. */
|
|
805
|
+
name?: string;
|
|
806
|
+
phase: CaptureErrorPhase;
|
|
807
|
+
/**
|
|
808
|
+
* The engine's own kind before the public collapse (`models`, `recorder`, `cliptoolarge`, `overconstrained`,
|
|
809
|
+
* `generic`, or a public kind unchanged).
|
|
810
|
+
*/
|
|
811
|
+
engineKind?: string;
|
|
812
|
+
}
|
|
787
813
|
/** Camera / engine failure payload (`on('error')`). */
|
|
788
814
|
interface CaptureError {
|
|
789
815
|
kind: CaptureErrorKind;
|
|
@@ -792,6 +818,8 @@ interface CaptureError {
|
|
|
792
818
|
* HTTPS) and `unsupported` (the browser cannot capture at all).
|
|
793
819
|
*/
|
|
794
820
|
retryable: boolean;
|
|
821
|
+
/** Where and how the capture failed, when the engine knows. */
|
|
822
|
+
detail?: CaptureErrorDetail;
|
|
795
823
|
}
|
|
796
824
|
|
|
797
825
|
/**
|
|
@@ -857,9 +885,10 @@ interface LivenessCaptureHandle {
|
|
|
857
885
|
/**
|
|
858
886
|
* Who films the face. A handle from {@link Verification.liveness} follows the
|
|
859
887
|
* session (`HostedSessionView.capture.mode`, set in the flow; `self` until
|
|
860
|
-
* the view is known
|
|
888
|
+
* the view is known; under `choice` the person's pick, `self` until
|
|
889
|
+
* {@link Verification.chooseCaptureMode}); a standalone {@link createLivenessCapture} is always
|
|
861
890
|
* `self`. In `self` the front camera is forced and {@link LivenessCaptureHandle.switchCamera}
|
|
862
|
-
* does nothing; `assisted` opens the back camera by default and may switch.
|
|
891
|
+
* does nothing; `assisted` opens the back camera by default and may switch. Never `choice`.
|
|
863
892
|
*/
|
|
864
893
|
readonly captureMode: CaptureMode;
|
|
865
894
|
/**
|
|
@@ -1088,6 +1117,13 @@ interface Verification {
|
|
|
1088
1117
|
* records it under the same reason. Omit it when unknown.
|
|
1089
1118
|
*/
|
|
1090
1119
|
reportCameraUnavailable?(cause?: CameraUnavailableCause): Promise<void>;
|
|
1120
|
+
/**
|
|
1121
|
+
* 2026-11-04: record a capture failure the page showed on the session (`POST /hosted/capture-issue`), for
|
|
1122
|
+
* diagnosis. Fire-and-forget: never throws, never changes the session, never bills, never counts as an attempt.
|
|
1123
|
+
* Sends at most one report per distinct (check, attempt, kind, name, phase); `formFactor` is filled in when absent.
|
|
1124
|
+
* Optional so custom / older `Verification` implementations stay valid.
|
|
1125
|
+
*/
|
|
1126
|
+
reportCaptureIssue?(issue: CaptureIssueReport): void;
|
|
1091
1127
|
/**
|
|
1092
1128
|
* The session's pending liveness step must be captured on a phone
|
|
1093
1129
|
* (`HostedStepView.requiresMobile`, profile v2 step 4 automatic decisions)
|
|
@@ -1100,13 +1136,26 @@ interface Verification {
|
|
|
1100
1136
|
mobileRequired?(): Promise<boolean>;
|
|
1101
1137
|
/**
|
|
1102
1138
|
* Who films the face in this session (`HostedSessionView.capture.mode`, a
|
|
1103
|
-
* flow setting): `self` (the person, front camera)
|
|
1104
|
-
* back camera)
|
|
1105
|
-
*
|
|
1139
|
+
* flow setting): `self` (the person, front camera), `assisted` (an agent,
|
|
1140
|
+
* back camera) or `choice` (the person picks; show a picker before the first
|
|
1141
|
+
* camera step and call {@link Verification.chooseCaptureMode}). Once picked,
|
|
1142
|
+
* resolves to the pick for the rest of the session. Bootstraps the hosted
|
|
1143
|
+
* view when needed; `self` when the bootstrap fails or the verification was
|
|
1144
|
+
* destroyed. Never rejects.
|
|
1106
1145
|
* Optional so custom / older `Verification` implementations stay valid:
|
|
1107
1146
|
* treat an absent member as `self`.
|
|
1108
1147
|
*/
|
|
1109
1148
|
captureMode?(): Promise<CaptureMode>;
|
|
1149
|
+
/**
|
|
1150
|
+
* Under `choice`: record the person's pick. It holds for the whole session (in
|
|
1151
|
+
* memory, for this `Verification`), so the portrait camera does not ask again;
|
|
1152
|
+
* the liveness and portrait cameras run in it and `input.capture.mode` sends it.
|
|
1153
|
+
* Ignored when the session's mode is not `choice`.
|
|
1154
|
+
* Optional so custom / older `Verification` implementations stay valid.
|
|
1155
|
+
*/
|
|
1156
|
+
chooseCaptureMode?(mode: ResolvedCaptureMode): void;
|
|
1157
|
+
/** The pick made with {@link Verification.chooseCaptureMode}, `null` before it. */
|
|
1158
|
+
readonly captureChoice?: ResolvedCaptureMode | null;
|
|
1110
1159
|
/**
|
|
1111
1160
|
* The session is a returning-user session (`HostedSessionView.returning`,
|
|
1112
1161
|
* profile v2 step 5): the person verified before and only confirms it is
|
|
@@ -1394,9 +1443,10 @@ declare function createLivenessCaptureInternal(options: LivenessCaptureOptions,
|
|
|
1394
1443
|
rankKeyframes?: () => boolean,
|
|
1395
1444
|
/**
|
|
1396
1445
|
* Who films the face (spec 2026-10-28 §4.3): createVerification reads the session's `capture.mode`, read at every
|
|
1397
|
-
* start and switch
|
|
1446
|
+
* start and switch, resolved through the person's pick under `choice` (never `choice` itself). Absent (a capture
|
|
1447
|
+
* bound to no session) → `self`.
|
|
1398
1448
|
*/
|
|
1399
|
-
captureMode?: () =>
|
|
1449
|
+
captureMode?: () => ResolvedCaptureMode,
|
|
1400
1450
|
/**
|
|
1401
1451
|
* Liveness v7 §4.4: the session's screen-ramp challenge (`capture.liveness.screenRamp`), read when the recording
|
|
1402
1452
|
* starts. The engine gets it only for a `self` capture with a `ramp` listener bound (the host paints); absent (a
|
|
@@ -2327,9 +2377,11 @@ interface CaptureSessionDocEvents {
|
|
|
2327
2377
|
* the stage's message + reticle channel. Deduped on state key. */
|
|
2328
2378
|
feedback: DocFeedbackState;
|
|
2329
2379
|
artifacts: DocArtifacts;
|
|
2380
|
+
/** `detail`: where the attempt failed and the thrown error's name (never its message). */
|
|
2330
2381
|
error: {
|
|
2331
2382
|
kind: CaptureErrorKind$1;
|
|
2332
2383
|
retryable: boolean;
|
|
2384
|
+
detail?: EngineErrorDetail;
|
|
2333
2385
|
};
|
|
2334
2386
|
/**
|
|
2335
2387
|
* Offer the manual shutter ({@link CaptureSessionDoc.captureNow}) — the safety
|
|
@@ -2905,14 +2957,14 @@ declare function createPortraitCaptureInternal(options: PortraitCaptureOptions,
|
|
|
2905
2957
|
* Who films the face (spec 2026-10-28 §4.3): the portrait step reads the session's `capture.mode` at every start
|
|
2906
2958
|
* and switch, as the liveness capture does. Absent (a standalone capture) → `self`: the front camera only.
|
|
2907
2959
|
*/
|
|
2908
|
-
captureMode?: () =>
|
|
2960
|
+
captureMode?: () => ResolvedCaptureMode): PortraitCaptureController;
|
|
2909
2961
|
|
|
2910
2962
|
/**
|
|
2911
2963
|
* The client surface the flow needs — `HostedClient` or a test fake. D8: the
|
|
2912
2964
|
* live-camera capture proof methods are optional (a fake / an older bridge
|
|
2913
2965
|
* without them presigns without a proof).
|
|
2914
2966
|
*/
|
|
2915
|
-
type HostedClientLike = Pick<HostedClient, "getSession" | "recordConsent" | "choose" | "presign" | "uploadToSpaces" | "completeMedia" | "submitCheck"> & Partial<Pick<HostedClient, "presignCapture" | "armCapture">> & Partial<Pick<HostedClient, "confirmIdentity" | "identityPortrait">> & Partial<Pick<HostedClient, "reportCameraUnavailable">>;
|
|
2967
|
+
type HostedClientLike = Pick<HostedClient, "getSession" | "recordConsent" | "choose" | "presign" | "uploadToSpaces" | "completeMedia" | "submitCheck"> & Partial<Pick<HostedClient, "presignCapture" | "armCapture">> & Partial<Pick<HostedClient, "confirmIdentity" | "identityPortrait">> & Partial<Pick<HostedClient, "reportCameraUnavailable">> & Partial<Pick<HostedClient, "reportCaptureIssue">>;
|
|
2916
2968
|
/** The presign policy allowlist for `kind: 'clip'` (media.policy.ts mirror). */
|
|
2917
2969
|
declare const CLIP_MIME_ALLOWLIST: readonly string[];
|
|
2918
2970
|
/** Same-key transport replays AFTER the first try, and the pause between them. */
|
|
@@ -3128,4 +3180,4 @@ declare function createVerification(options: VerificationOptions): Verification;
|
|
|
3128
3180
|
/** {@link createVerification} with construction seams (tests / Sekyro AI-internal hosts). */
|
|
3129
3181
|
declare function createVerificationInternal(options: VerificationOptions, internals: VerificationInternals): Verification;
|
|
3130
3182
|
|
|
3131
|
-
export { type
|
|
3183
|
+
export { type LivePhotoPlan as $, type AcceptedDocumentsLike as A, type DocumentGuideMeasure as B, type CameraFacing as C, type DocumentCaptureOptions as D, type DocumentLiveMrzOptions as E, type DocumentMrzUpdate as F, type DocumentPoint as G, type DocumentQuad as H, type DocumentReticle as I, type DocumentScanPhase as J, type DocumentScanUpdate as K, type DocumentSide as L, type DocumentSnapshot as M, type DocumentStepHandle as N, type EidSnapshot as O, type PortraitCaptureOptions as P, type EidStepHandle as Q, type EmailOtpSnapshot as R, type EmailOtpStepHandle as S, type EmailSource as T, type GateHint as U, type GateUpdate as V, ISSUER_CODES as W, type IdentitySummarySnapshot as X, type IdentitySummaryStepHandle as Y, type InLaneSwitch as Z, type LivePhotoGateUpdate as _, type DocumentCaptureHandle as a, subscribeLivenessAssets as a$, type LivenessAssetsStatus as a0, type LivenessCaptureEvents as a1, type LivenessCaptureHandle as a2, type LivenessCaptureOptions as a3, type LivenessSnapshot as a4, type LivenessStartOptions as a5, type LivenessStepHandle as a6, type MethodSnapshot as a7, type MethodStepHandle as a8, type MobileRequiredSnapshot as a9, type StepSnapshot as aA, type UnsupportedReason as aB, type UnsupportedSnapshot as aC, type UnsupportedStepHandle as aD, type Verification as aE, type VerificationBusy as aF, type VerificationEvents as aG, type VerificationLocale as aH, type VerificationOptions as aI, type VerificationResult as aJ, type VerificationStatus as aK, type VerificationStep as aL, WEB_IDENTITY_METHODS as aM, acceptedIssuers as aN, acceptedTypesFor as aO, cameraUnavailableCauseOf as aP, createLivenessCapture as aQ, createVerification as aR, deriveStep as aS, flagOf as aT, getLivenessAssetsStatus as aU, laneOf as aV, otherOptions as aW, preloadLivenessAssets as aX, releaseLivenessAssets as aY, resolveAcceptedDocuments as aZ, sectionOf as a_, type MobileRequiredStepHandle as aa, type OtpChannel as ab, type OtpNumberSource as ac, PLATFORM_UNSUPPORTED as ad, type PhoneOtpSnapshot as ae, type PhoneOtpStepHandle as af, type PlanChoiceSnapshot as ag, type PortraitCaptureEvents as ah, type PortraitCaptureState as ai, type PortraitGateUpdate as aj, type PortraitSnapshot as ak, type PortraitStartOptions as al, type PortraitStepHandle as am, type PreloadLivenessAssetsOptions as an, type ProcessingSnapshot as ao, type ProcessingStepHandle as ap, type ReasonCode as aq, type RegistrySnapshot as ar, type RegistrySource as as, type RegistryStepHandle as at, type ResultDisplay as au, type ResultSnapshot as av, type ResultStepHandle as aw, type SdkFailureReason as ax, type StepAttempts as ay, type StepContext as az, type PortraitCaptureHandle as b, FLIP_FILL_MIN as b$, type DocCatalogEntry as b0, type LiveMrzTuning as b1, type TextLockTuning as b2, type OcrEngineClient as b3, type DocAssistReport as b4, type ReadyInfo as b5, type LoadFailure as b6, type OcrEngineOptions as b7, type SubmitRuntime as b8, type HostedClientLike as b9, type DocAssistEngine as bA, type DocAssistTick as bB, type DocCameraTuning as bC, type DocCaptureReport as bD, type DocCaptureVia as bE, type DocChecksPayload as bF, type DocEngineLike as bG, DocFeedbackAggregator as bH, type DocFeedbackKey as bI, type DocFeedbackState as bJ, type DocFormat as bK, type DocFrameAnalysis as bL, type DocFrameMeasures as bM, type DocGateQuality as bN, type DocGateThresholds as bO, type DocGateTick as bP, type DocGateTickInput as bQ, DocGateV1 as bR, type DocQuad as bS, type DocQuadPoint as bT, type DocShutterReason as bU, type DocShutterTuning as bV, type DocSide as bW, type DocumentCaptureController as bX, type DocumentCaptureInternals as bY, EMPTY_GUIDE_METRICS as bZ, type EncodedDocument as b_, ANALYSIS_LONG_EDGE as ba, ASPECT_BANDS as bb, AttestationError as bc, BLUR_REFUSE_SHARPNESS_MAX as bd, type BlurStatus as be, CAPTURE_CANDIDATE_SPACING_MS as bf, CAPTURE_EXTRA_CANDIDATES as bg, CLIP_MIME_ALLOWLIST as bh, type CaptureEngine as bi, CaptureSessionDoc as bj, type CaptureSessionDocEvents as bk, type CaptureSessionDocOptions as bl, DOC_ANALYSIS_DEFAULTS as bm, DOC_BLACK_FRAME_LUMA as bn, DOC_BLACK_FRAME_TICKS as bo, DOC_CADENCE_HZ as bp, DOC_CAMERA_TUNING_DEFAULTS as bq, DOC_CATALOG as br, DOC_DETECT_WIDTH as bs, DOC_FEEDBACK_STATES as bt, DOC_FIRST_FRAME_MS as bu, DOC_GATE_V1_DEFAULTS as bv, DOC_SHUTTER_DEFAULTS as bw, type DeviceReadHint as bx, type DocArtifacts as by, DocAssist as bz, type CaptureChannel as c, analyzeDocFrame as c$, FLIP_GAP_MS as c0, FLIP_TIMEOUT_MS as c1, type FocusCaps as c2, type FramingStatus as c3, GUIDE_LOCK_DEFAULTS as c4, type GlareStatus as c5, type GrabbedFrame as c6, type GuideBlocker as c7, GuideLock as c8, type GuideLockTick as c9, type LivenessFlowOutcome as cA, MANUAL_SHUTTER_MS as cB, MR_DOC_CATALOG as cC, NO_REPORT_MS as cD, type OpenDocCameraDeps as cE, PORTRAIT_JPEG_QUALITY as cF, PRELOAD_BLAZE_INIT_TIMEOUT_MS as cG, PRELOAD_BUDGET_MS as cH, PROCESSING_POLL_DELAY_MS as cI, PROCESSING_POLL_MAX as cJ, type PortraitCaptureController as cK, type PortraitCaptureInternals as cL, REGISTRY_RETRY_DELAY_MS as cM, type ReticleType as cN, SAME_FACE_MAX_DROPS as cO, type ScanEvent as cP, type ScanLayout as cQ, type ScanNotice as cR, type ScanPhase as cS, type ScanReport as cT, type ScanSide as cU, type ScanState as cV, type SubmitExecutor as cW, TEXT_LOCK_DEFAULTS as cX, TRANSPORT_REPLAY_ATTEMPTS as cY, TRANSPORT_REPLAY_DELAY_MS as cZ, type VerificationInternals as c_, type GuideLockTuning as ca, type GuideMetrics as cb, type GuideRect as cc, INFERENCE_RETRY_ATTEMPTS as cd, INFERENCE_RETRY_DEFAULT_S as ce, LANDMARKER_MODEL as cf, LENS_STORAGE_KEY as cg, LENS_TRY_MAX as ch, LIVE_MRZ_DEFAULTS as ci, LIVE_PHOTO_IDLE_MS as cj, LIVE_PHOTO_MAX_HZ as ck, type LandmarkedFace as cl, type LandmarkerLike as cm, type LensKind as cn, type LensSource as co, type LightingStatus as cp, type LiveMrzCapture as cq, type LiveMrzState as cr, type LivePhotoGate as cs, type LivePhotoKit as ct, type LivePhotoKitInternals as cu, type LivePhotoKitOptions as cv, type LivePhotoStill as cw, type LivenessCaptureInternalHandle as cx, type LivenessCaptureInternals as cy, type LivenessFlowDeps as cz, type CaptureEngineId as d, analyzeGuide as d0, aspectBand as d1, aspectFits as d2, buildDeviceReadHint as d3, coverPointToVideo as d4, createDocumentCaptureInternal as d5, createFaceLandmarker as d6, createLivePhotoKit as d7, createLivenessCaptureInternal as d8, createPortraitCaptureInternal as d9, readStoredLens as dA, resetLivenessAssetsForTests as dB, resolveDocCameraTuning as dC, resolveDocShutterTuning as dD, resolveGuideLockTuning as dE, runLivenessFlow as dF, runSubmission as dG, scannerFormatFor as dH, setPreloadLoaderForTests as dI, settledHint as dJ, singleShotFocusAt as dK, specularFraction as dL, supportsFocusMode as dM, warmDocDetector as dN, writeStoredLens as dO, createVerificationInternal as da, docZoomFor as db, encodeDocumentImage as dc, facesOf as dd, feedbackVoteOf as de, focusOk as df, guideQuad as dg, guideRegionInFrame as dh, initialScanState as di, lensKindOf as dj, mapEngineState as dk, mapErrorKind as dl, mapGuidanceHint as dm, nextScanState as dn, observe as dp, openDocCamera as dq, passportBandOf as dr, portraitMatchStep as ds, preloadedDetectorFactory as dt, quadAreaFrac as du, quadBounds as dv, quadIou as dw, quadTiltRatio as dx, randomUuid as dy, rankBackCameras as dz, type CaptureError as e, type CaptureErrorDetail as f, type CaptureErrorKind as g, type CaptureErrorPhase as h, type CaptureState as i, type CapturedArtifacts as j, type CapturedDocument as k, type CapturedPortrait as l, type ChoiceOptionSnapshot as m, type ChoiceSnapshot as n, type ChoiceStepHandle as o, type ContactChoiceSnapshot as p, type ContactChoiceStepHandle as q, DEFAULT_API_ORIGIN as r, DOCUMENT_TYPE_ORDER as s, type DeriveStepEnv as t, type DocumentCaptureEvents as u, type DocumentCaptureState as v, type DocumentFeedback as w, type DocumentFeedbackKey as x, type DocumentGateUpdate as y, type DocumentGuide as z };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { b as Detector } from './detect-worker-DclNxkZT.js';
|
|
2
|
-
import { A as AcceptedDocumentType,
|
|
3
|
-
import { i as CaptureState$1, f as CaptureSessionV3Events, g as CaptureSessionV3Options, c as CaptureErrorKind$1, p as DeviceClass, b as CaptureArtifacts, I as V3GateQuality, O as V3TelemetryEvent } from './capture-session-v3-
|
|
4
|
-
import { c as IcaoGateSummary, d as IcaoGateUpdate, P as Point, e as Box, j as IcaoFrameObservation, N as HostedClient, k as IcaoGate } from './icao-gate-
|
|
2
|
+
import { A as AcceptedDocumentType, a5 as NationalEidOption, au as StepSection, t as HostedBranding, ag as PlanSectionView, ad as PlanChoiceKind, n as ContactChannel, l as CheckReason, an as RetakeHint, $ as IdentityMethod, E as EidAfterPass, a0 as IdentitySummarySource, J as HostedIcaoPolicy, a9 as PhoneCountryRule, _ as IcaoReportEntry, Z as IcaoCaptureTuning, H as HostedSessionView, W as HostedStepView, ah as PlanStepView, j as CaptureMode, aq as ScreenRampReport, k as CaptureProvenance, S as ScreenRampColour, ar as SessionFailureReason, i as AgeEstimationReason, aw as VerificationLevel, av as VerificationAssurance, a4 as MethodChoiceView, b as CameraUnavailableCause, c as CaptureIssueReport, am as ResolvedCaptureMode, Y as HostedVoiceView, ao as ScreenRampChallenge, aA as PersonMask, aB as AttestationInput, f as CheckType, ak as PortraitIcaoInput } from './types-DPl0hsmI.js';
|
|
3
|
+
import { i as CaptureState$1, f as CaptureSessionV3Events, g as CaptureSessionV3Options, c as CaptureErrorKind$1, p as DeviceClass, b as CaptureArtifacts, a4 as EngineErrorDetail, I as V3GateQuality, O as V3TelemetryEvent } from './capture-session-v3-CFSVWYzi.js';
|
|
4
|
+
import { c as IcaoGateSummary, d as IcaoGateUpdate, P as Point, e as Box, j as IcaoFrameObservation, N as HostedClient, k as IcaoGate } from './icao-gate-BSbyqLUh.js';
|
|
5
5
|
|
|
6
6
|
declare const ISSUER_CODES: readonly string[];
|
|
7
7
|
|
|
@@ -321,6 +321,12 @@ interface DocumentSnapshot extends StepAttempts {
|
|
|
321
321
|
side: "recto" | "verso";
|
|
322
322
|
acceptedSides: ("recto" | "verso")[];
|
|
323
323
|
documents: AcceptedDocumentsLike;
|
|
324
|
+
/**
|
|
325
|
+
* Age check (selfie): `true` when the session reached this document because the selfie could not settle the
|
|
326
|
+
* person's age (`age_estimation` failed with `age_uncertain` or `age_unavailable`); show the step-up line
|
|
327
|
+
* (`doc.ageStepUp`). Absent otherwise.
|
|
328
|
+
*/
|
|
329
|
+
ageStepUp?: true;
|
|
324
330
|
}
|
|
325
331
|
interface LivenessSnapshot extends StepAttempts {
|
|
326
332
|
/**
|
|
@@ -666,7 +672,7 @@ interface PortraitCaptureHandle {
|
|
|
666
672
|
on<K extends keyof PortraitCaptureEvents>(event: K, handler: (payload: PortraitCaptureEvents[K]) => void): () => void;
|
|
667
673
|
/**
|
|
668
674
|
* Who films the face: a portrait step's handle follows the session (`HostedSessionView.capture.mode`); a standalone
|
|
669
|
-
* {@link createPortraitCapture} is always `self` (the front camera, no switch).
|
|
675
|
+
* {@link createPortraitCapture} is always `self` (the front camera, no switch). Never `choice`.
|
|
670
676
|
*/
|
|
671
677
|
readonly captureMode: CaptureMode;
|
|
672
678
|
/** The camera of the live stream (as its track reports it, else as requested); `'user'` before the first start. */
|
|
@@ -769,7 +775,10 @@ interface CapturedArtifacts {
|
|
|
769
775
|
* The upright requirement applies to phones only. Always set by the SDK.
|
|
770
776
|
*/
|
|
771
777
|
formFactor?: "phone" | "tablet" | "desktop";
|
|
772
|
-
/**
|
|
778
|
+
/**
|
|
779
|
+
* The capture mode the attempt ran in ({@link LivenessCaptureHandle.captureMode}): `self` or `assisted`, never
|
|
780
|
+
* `choice`. Always set by the SDK.
|
|
781
|
+
*/
|
|
773
782
|
mode?: CaptureMode;
|
|
774
783
|
/**
|
|
775
784
|
* Liveness v7 §4.4: the screen ramp rendered against the session's issued challenge, stamped on the clip's own
|
|
@@ -784,6 +793,23 @@ interface CapturedArtifacts {
|
|
|
784
793
|
type CaptureEngineId = "v1" | "v3";
|
|
785
794
|
/** Camera / engine failure kinds — collapsed to the public six. */
|
|
786
795
|
type CaptureErrorKind = "permission" | "notfound" | "inuse" | "insecure" | "unsupported" | "generic";
|
|
796
|
+
/** The capture step that was running when a capture failed. */
|
|
797
|
+
type CaptureErrorPhase = "preflight" | "acquiring" | "models" | "recording" | "keyframes" | "upload";
|
|
798
|
+
/**
|
|
799
|
+
* What the public {@link CaptureErrorKind} leaves out, for diagnostics. Never personal data: `name` is the thrown
|
|
800
|
+
* error's `name` only (a class or DOMException name such as `NotReadableError`, never its message), letters only and
|
|
801
|
+
* at most 40 characters.
|
|
802
|
+
*/
|
|
803
|
+
interface CaptureErrorDetail {
|
|
804
|
+
/** The thrown error's `name`, when the failure threw one. */
|
|
805
|
+
name?: string;
|
|
806
|
+
phase: CaptureErrorPhase;
|
|
807
|
+
/**
|
|
808
|
+
* The engine's own kind before the public collapse (`models`, `recorder`, `cliptoolarge`, `overconstrained`,
|
|
809
|
+
* `generic`, or a public kind unchanged).
|
|
810
|
+
*/
|
|
811
|
+
engineKind?: string;
|
|
812
|
+
}
|
|
787
813
|
/** Camera / engine failure payload (`on('error')`). */
|
|
788
814
|
interface CaptureError {
|
|
789
815
|
kind: CaptureErrorKind;
|
|
@@ -792,6 +818,8 @@ interface CaptureError {
|
|
|
792
818
|
* HTTPS) and `unsupported` (the browser cannot capture at all).
|
|
793
819
|
*/
|
|
794
820
|
retryable: boolean;
|
|
821
|
+
/** Where and how the capture failed, when the engine knows. */
|
|
822
|
+
detail?: CaptureErrorDetail;
|
|
795
823
|
}
|
|
796
824
|
|
|
797
825
|
/**
|
|
@@ -857,9 +885,10 @@ interface LivenessCaptureHandle {
|
|
|
857
885
|
/**
|
|
858
886
|
* Who films the face. A handle from {@link Verification.liveness} follows the
|
|
859
887
|
* session (`HostedSessionView.capture.mode`, set in the flow; `self` until
|
|
860
|
-
* the view is known
|
|
888
|
+
* the view is known; under `choice` the person's pick, `self` until
|
|
889
|
+
* {@link Verification.chooseCaptureMode}); a standalone {@link createLivenessCapture} is always
|
|
861
890
|
* `self`. In `self` the front camera is forced and {@link LivenessCaptureHandle.switchCamera}
|
|
862
|
-
* does nothing; `assisted` opens the back camera by default and may switch.
|
|
891
|
+
* does nothing; `assisted` opens the back camera by default and may switch. Never `choice`.
|
|
863
892
|
*/
|
|
864
893
|
readonly captureMode: CaptureMode;
|
|
865
894
|
/**
|
|
@@ -1088,6 +1117,13 @@ interface Verification {
|
|
|
1088
1117
|
* records it under the same reason. Omit it when unknown.
|
|
1089
1118
|
*/
|
|
1090
1119
|
reportCameraUnavailable?(cause?: CameraUnavailableCause): Promise<void>;
|
|
1120
|
+
/**
|
|
1121
|
+
* 2026-11-04: record a capture failure the page showed on the session (`POST /hosted/capture-issue`), for
|
|
1122
|
+
* diagnosis. Fire-and-forget: never throws, never changes the session, never bills, never counts as an attempt.
|
|
1123
|
+
* Sends at most one report per distinct (check, attempt, kind, name, phase); `formFactor` is filled in when absent.
|
|
1124
|
+
* Optional so custom / older `Verification` implementations stay valid.
|
|
1125
|
+
*/
|
|
1126
|
+
reportCaptureIssue?(issue: CaptureIssueReport): void;
|
|
1091
1127
|
/**
|
|
1092
1128
|
* The session's pending liveness step must be captured on a phone
|
|
1093
1129
|
* (`HostedStepView.requiresMobile`, profile v2 step 4 automatic decisions)
|
|
@@ -1100,13 +1136,26 @@ interface Verification {
|
|
|
1100
1136
|
mobileRequired?(): Promise<boolean>;
|
|
1101
1137
|
/**
|
|
1102
1138
|
* Who films the face in this session (`HostedSessionView.capture.mode`, a
|
|
1103
|
-
* flow setting): `self` (the person, front camera)
|
|
1104
|
-
* back camera)
|
|
1105
|
-
*
|
|
1139
|
+
* flow setting): `self` (the person, front camera), `assisted` (an agent,
|
|
1140
|
+
* back camera) or `choice` (the person picks; show a picker before the first
|
|
1141
|
+
* camera step and call {@link Verification.chooseCaptureMode}). Once picked,
|
|
1142
|
+
* resolves to the pick for the rest of the session. Bootstraps the hosted
|
|
1143
|
+
* view when needed; `self` when the bootstrap fails or the verification was
|
|
1144
|
+
* destroyed. Never rejects.
|
|
1106
1145
|
* Optional so custom / older `Verification` implementations stay valid:
|
|
1107
1146
|
* treat an absent member as `self`.
|
|
1108
1147
|
*/
|
|
1109
1148
|
captureMode?(): Promise<CaptureMode>;
|
|
1149
|
+
/**
|
|
1150
|
+
* Under `choice`: record the person's pick. It holds for the whole session (in
|
|
1151
|
+
* memory, for this `Verification`), so the portrait camera does not ask again;
|
|
1152
|
+
* the liveness and portrait cameras run in it and `input.capture.mode` sends it.
|
|
1153
|
+
* Ignored when the session's mode is not `choice`.
|
|
1154
|
+
* Optional so custom / older `Verification` implementations stay valid.
|
|
1155
|
+
*/
|
|
1156
|
+
chooseCaptureMode?(mode: ResolvedCaptureMode): void;
|
|
1157
|
+
/** The pick made with {@link Verification.chooseCaptureMode}, `null` before it. */
|
|
1158
|
+
readonly captureChoice?: ResolvedCaptureMode | null;
|
|
1110
1159
|
/**
|
|
1111
1160
|
* The session is a returning-user session (`HostedSessionView.returning`,
|
|
1112
1161
|
* profile v2 step 5): the person verified before and only confirms it is
|
|
@@ -1394,9 +1443,10 @@ declare function createLivenessCaptureInternal(options: LivenessCaptureOptions,
|
|
|
1394
1443
|
rankKeyframes?: () => boolean,
|
|
1395
1444
|
/**
|
|
1396
1445
|
* Who films the face (spec 2026-10-28 §4.3): createVerification reads the session's `capture.mode`, read at every
|
|
1397
|
-
* start and switch
|
|
1446
|
+
* start and switch, resolved through the person's pick under `choice` (never `choice` itself). Absent (a capture
|
|
1447
|
+
* bound to no session) → `self`.
|
|
1398
1448
|
*/
|
|
1399
|
-
captureMode?: () =>
|
|
1449
|
+
captureMode?: () => ResolvedCaptureMode,
|
|
1400
1450
|
/**
|
|
1401
1451
|
* Liveness v7 §4.4: the session's screen-ramp challenge (`capture.liveness.screenRamp`), read when the recording
|
|
1402
1452
|
* starts. The engine gets it only for a `self` capture with a `ramp` listener bound (the host paints); absent (a
|
|
@@ -2327,9 +2377,11 @@ interface CaptureSessionDocEvents {
|
|
|
2327
2377
|
* the stage's message + reticle channel. Deduped on state key. */
|
|
2328
2378
|
feedback: DocFeedbackState;
|
|
2329
2379
|
artifacts: DocArtifacts;
|
|
2380
|
+
/** `detail`: where the attempt failed and the thrown error's name (never its message). */
|
|
2330
2381
|
error: {
|
|
2331
2382
|
kind: CaptureErrorKind$1;
|
|
2332
2383
|
retryable: boolean;
|
|
2384
|
+
detail?: EngineErrorDetail;
|
|
2333
2385
|
};
|
|
2334
2386
|
/**
|
|
2335
2387
|
* Offer the manual shutter ({@link CaptureSessionDoc.captureNow}) — the safety
|
|
@@ -2905,14 +2957,14 @@ declare function createPortraitCaptureInternal(options: PortraitCaptureOptions,
|
|
|
2905
2957
|
* Who films the face (spec 2026-10-28 §4.3): the portrait step reads the session's `capture.mode` at every start
|
|
2906
2958
|
* and switch, as the liveness capture does. Absent (a standalone capture) → `self`: the front camera only.
|
|
2907
2959
|
*/
|
|
2908
|
-
captureMode?: () =>
|
|
2960
|
+
captureMode?: () => ResolvedCaptureMode): PortraitCaptureController;
|
|
2909
2961
|
|
|
2910
2962
|
/**
|
|
2911
2963
|
* The client surface the flow needs — `HostedClient` or a test fake. D8: the
|
|
2912
2964
|
* live-camera capture proof methods are optional (a fake / an older bridge
|
|
2913
2965
|
* without them presigns without a proof).
|
|
2914
2966
|
*/
|
|
2915
|
-
type HostedClientLike = Pick<HostedClient, "getSession" | "recordConsent" | "choose" | "presign" | "uploadToSpaces" | "completeMedia" | "submitCheck"> & Partial<Pick<HostedClient, "presignCapture" | "armCapture">> & Partial<Pick<HostedClient, "confirmIdentity" | "identityPortrait">> & Partial<Pick<HostedClient, "reportCameraUnavailable">>;
|
|
2967
|
+
type HostedClientLike = Pick<HostedClient, "getSession" | "recordConsent" | "choose" | "presign" | "uploadToSpaces" | "completeMedia" | "submitCheck"> & Partial<Pick<HostedClient, "presignCapture" | "armCapture">> & Partial<Pick<HostedClient, "confirmIdentity" | "identityPortrait">> & Partial<Pick<HostedClient, "reportCameraUnavailable">> & Partial<Pick<HostedClient, "reportCaptureIssue">>;
|
|
2916
2968
|
/** The presign policy allowlist for `kind: 'clip'` (media.policy.ts mirror). */
|
|
2917
2969
|
declare const CLIP_MIME_ALLOWLIST: readonly string[];
|
|
2918
2970
|
/** Same-key transport replays AFTER the first try, and the pause between them. */
|
|
@@ -3128,4 +3180,4 @@ declare function createVerification(options: VerificationOptions): Verification;
|
|
|
3128
3180
|
/** {@link createVerification} with construction seams (tests / Sekyro AI-internal hosts). */
|
|
3129
3181
|
declare function createVerificationInternal(options: VerificationOptions, internals: VerificationInternals): Verification;
|
|
3130
3182
|
|
|
3131
|
-
export { type
|
|
3183
|
+
export { type LivePhotoPlan as $, type AcceptedDocumentsLike as A, type DocumentGuideMeasure as B, type CameraFacing as C, type DocumentCaptureOptions as D, type DocumentLiveMrzOptions as E, type DocumentMrzUpdate as F, type DocumentPoint as G, type DocumentQuad as H, type DocumentReticle as I, type DocumentScanPhase as J, type DocumentScanUpdate as K, type DocumentSide as L, type DocumentSnapshot as M, type DocumentStepHandle as N, type EidSnapshot as O, type PortraitCaptureOptions as P, type EidStepHandle as Q, type EmailOtpSnapshot as R, type EmailOtpStepHandle as S, type EmailSource as T, type GateHint as U, type GateUpdate as V, ISSUER_CODES as W, type IdentitySummarySnapshot as X, type IdentitySummaryStepHandle as Y, type InLaneSwitch as Z, type LivePhotoGateUpdate as _, type DocumentCaptureHandle as a, subscribeLivenessAssets as a$, type LivenessAssetsStatus as a0, type LivenessCaptureEvents as a1, type LivenessCaptureHandle as a2, type LivenessCaptureOptions as a3, type LivenessSnapshot as a4, type LivenessStartOptions as a5, type LivenessStepHandle as a6, type MethodSnapshot as a7, type MethodStepHandle as a8, type MobileRequiredSnapshot as a9, type StepSnapshot as aA, type UnsupportedReason as aB, type UnsupportedSnapshot as aC, type UnsupportedStepHandle as aD, type Verification as aE, type VerificationBusy as aF, type VerificationEvents as aG, type VerificationLocale as aH, type VerificationOptions as aI, type VerificationResult as aJ, type VerificationStatus as aK, type VerificationStep as aL, WEB_IDENTITY_METHODS as aM, acceptedIssuers as aN, acceptedTypesFor as aO, cameraUnavailableCauseOf as aP, createLivenessCapture as aQ, createVerification as aR, deriveStep as aS, flagOf as aT, getLivenessAssetsStatus as aU, laneOf as aV, otherOptions as aW, preloadLivenessAssets as aX, releaseLivenessAssets as aY, resolveAcceptedDocuments as aZ, sectionOf as a_, type MobileRequiredStepHandle as aa, type OtpChannel as ab, type OtpNumberSource as ac, PLATFORM_UNSUPPORTED as ad, type PhoneOtpSnapshot as ae, type PhoneOtpStepHandle as af, type PlanChoiceSnapshot as ag, type PortraitCaptureEvents as ah, type PortraitCaptureState as ai, type PortraitGateUpdate as aj, type PortraitSnapshot as ak, type PortraitStartOptions as al, type PortraitStepHandle as am, type PreloadLivenessAssetsOptions as an, type ProcessingSnapshot as ao, type ProcessingStepHandle as ap, type ReasonCode as aq, type RegistrySnapshot as ar, type RegistrySource as as, type RegistryStepHandle as at, type ResultDisplay as au, type ResultSnapshot as av, type ResultStepHandle as aw, type SdkFailureReason as ax, type StepAttempts as ay, type StepContext as az, type PortraitCaptureHandle as b, FLIP_FILL_MIN as b$, type DocCatalogEntry as b0, type LiveMrzTuning as b1, type TextLockTuning as b2, type OcrEngineClient as b3, type DocAssistReport as b4, type ReadyInfo as b5, type LoadFailure as b6, type OcrEngineOptions as b7, type SubmitRuntime as b8, type HostedClientLike as b9, type DocAssistEngine as bA, type DocAssistTick as bB, type DocCameraTuning as bC, type DocCaptureReport as bD, type DocCaptureVia as bE, type DocChecksPayload as bF, type DocEngineLike as bG, DocFeedbackAggregator as bH, type DocFeedbackKey as bI, type DocFeedbackState as bJ, type DocFormat as bK, type DocFrameAnalysis as bL, type DocFrameMeasures as bM, type DocGateQuality as bN, type DocGateThresholds as bO, type DocGateTick as bP, type DocGateTickInput as bQ, DocGateV1 as bR, type DocQuad as bS, type DocQuadPoint as bT, type DocShutterReason as bU, type DocShutterTuning as bV, type DocSide as bW, type DocumentCaptureController as bX, type DocumentCaptureInternals as bY, EMPTY_GUIDE_METRICS as bZ, type EncodedDocument as b_, ANALYSIS_LONG_EDGE as ba, ASPECT_BANDS as bb, AttestationError as bc, BLUR_REFUSE_SHARPNESS_MAX as bd, type BlurStatus as be, CAPTURE_CANDIDATE_SPACING_MS as bf, CAPTURE_EXTRA_CANDIDATES as bg, CLIP_MIME_ALLOWLIST as bh, type CaptureEngine as bi, CaptureSessionDoc as bj, type CaptureSessionDocEvents as bk, type CaptureSessionDocOptions as bl, DOC_ANALYSIS_DEFAULTS as bm, DOC_BLACK_FRAME_LUMA as bn, DOC_BLACK_FRAME_TICKS as bo, DOC_CADENCE_HZ as bp, DOC_CAMERA_TUNING_DEFAULTS as bq, DOC_CATALOG as br, DOC_DETECT_WIDTH as bs, DOC_FEEDBACK_STATES as bt, DOC_FIRST_FRAME_MS as bu, DOC_GATE_V1_DEFAULTS as bv, DOC_SHUTTER_DEFAULTS as bw, type DeviceReadHint as bx, type DocArtifacts as by, DocAssist as bz, type CaptureChannel as c, analyzeDocFrame as c$, FLIP_GAP_MS as c0, FLIP_TIMEOUT_MS as c1, type FocusCaps as c2, type FramingStatus as c3, GUIDE_LOCK_DEFAULTS as c4, type GlareStatus as c5, type GrabbedFrame as c6, type GuideBlocker as c7, GuideLock as c8, type GuideLockTick as c9, type LivenessFlowOutcome as cA, MANUAL_SHUTTER_MS as cB, MR_DOC_CATALOG as cC, NO_REPORT_MS as cD, type OpenDocCameraDeps as cE, PORTRAIT_JPEG_QUALITY as cF, PRELOAD_BLAZE_INIT_TIMEOUT_MS as cG, PRELOAD_BUDGET_MS as cH, PROCESSING_POLL_DELAY_MS as cI, PROCESSING_POLL_MAX as cJ, type PortraitCaptureController as cK, type PortraitCaptureInternals as cL, REGISTRY_RETRY_DELAY_MS as cM, type ReticleType as cN, SAME_FACE_MAX_DROPS as cO, type ScanEvent as cP, type ScanLayout as cQ, type ScanNotice as cR, type ScanPhase as cS, type ScanReport as cT, type ScanSide as cU, type ScanState as cV, type SubmitExecutor as cW, TEXT_LOCK_DEFAULTS as cX, TRANSPORT_REPLAY_ATTEMPTS as cY, TRANSPORT_REPLAY_DELAY_MS as cZ, type VerificationInternals as c_, type GuideLockTuning as ca, type GuideMetrics as cb, type GuideRect as cc, INFERENCE_RETRY_ATTEMPTS as cd, INFERENCE_RETRY_DEFAULT_S as ce, LANDMARKER_MODEL as cf, LENS_STORAGE_KEY as cg, LENS_TRY_MAX as ch, LIVE_MRZ_DEFAULTS as ci, LIVE_PHOTO_IDLE_MS as cj, LIVE_PHOTO_MAX_HZ as ck, type LandmarkedFace as cl, type LandmarkerLike as cm, type LensKind as cn, type LensSource as co, type LightingStatus as cp, type LiveMrzCapture as cq, type LiveMrzState as cr, type LivePhotoGate as cs, type LivePhotoKit as ct, type LivePhotoKitInternals as cu, type LivePhotoKitOptions as cv, type LivePhotoStill as cw, type LivenessCaptureInternalHandle as cx, type LivenessCaptureInternals as cy, type LivenessFlowDeps as cz, type CaptureEngineId as d, analyzeGuide as d0, aspectBand as d1, aspectFits as d2, buildDeviceReadHint as d3, coverPointToVideo as d4, createDocumentCaptureInternal as d5, createFaceLandmarker as d6, createLivePhotoKit as d7, createLivenessCaptureInternal as d8, createPortraitCaptureInternal as d9, readStoredLens as dA, resetLivenessAssetsForTests as dB, resolveDocCameraTuning as dC, resolveDocShutterTuning as dD, resolveGuideLockTuning as dE, runLivenessFlow as dF, runSubmission as dG, scannerFormatFor as dH, setPreloadLoaderForTests as dI, settledHint as dJ, singleShotFocusAt as dK, specularFraction as dL, supportsFocusMode as dM, warmDocDetector as dN, writeStoredLens as dO, createVerificationInternal as da, docZoomFor as db, encodeDocumentImage as dc, facesOf as dd, feedbackVoteOf as de, focusOk as df, guideQuad as dg, guideRegionInFrame as dh, initialScanState as di, lensKindOf as dj, mapEngineState as dk, mapErrorKind as dl, mapGuidanceHint as dm, nextScanState as dn, observe as dp, openDocCamera as dq, passportBandOf as dr, portraitMatchStep as ds, preloadedDetectorFactory as dt, quadAreaFrac as du, quadBounds as dv, quadIou as dw, quadTiltRatio as dx, randomUuid as dy, rankBackCameras as dz, type CaptureError as e, type CaptureErrorDetail as f, type CaptureErrorKind as g, type CaptureErrorPhase as h, type CaptureState as i, type CapturedArtifacts as j, type CapturedDocument as k, type CapturedPortrait as l, type ChoiceOptionSnapshot as m, type ChoiceSnapshot as n, type ChoiceStepHandle as o, type ContactChoiceSnapshot as p, type ContactChoiceStepHandle as q, DEFAULT_API_ORIGIN as r, DOCUMENT_TYPE_ORDER as s, type DeriveStepEnv as t, type DocumentCaptureEvents as u, type DocumentCaptureState as v, type DocumentFeedback as w, type DocumentFeedbackKey as x, type DocumentGateUpdate as y, type DocumentGuide as z };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { H as HostedSessionView, C as ConsentLocale, a as HostedConsentView, b as CameraUnavailableCause, I as IdentityConfirmDecision, M as MediaKind, P as PresignUploadResult,
|
|
1
|
+
import { H as HostedSessionView, C as ConsentLocale, a as HostedConsentView, b as CameraUnavailableCause, c as CaptureIssueReport, I as IdentityConfirmDecision, M as MediaKind, P as PresignUploadResult, d as CaptureContext, e as CompleteMediaResult, f as CheckType, g as CheckInputByType, h as IcaoCriterion, B as BackgroundUniformity, R as ResolvedIcaoTuning } from './types-DPl0hsmI.js';
|
|
2
2
|
|
|
3
3
|
interface Point {
|
|
4
4
|
x: number;
|
|
@@ -122,10 +122,11 @@ interface HostedClientOptions {
|
|
|
122
122
|
/** Per-request timeout for API calls (NOT the Spaces PUT). Default 30 000 ms. */
|
|
123
123
|
requestTimeoutMs?: number;
|
|
124
124
|
/**
|
|
125
|
-
* Tuning for the
|
|
126
|
-
*
|
|
127
|
-
*
|
|
128
|
-
*
|
|
125
|
+
* Tuning for the automatic retry on 409 `idempotency_in_progress` (a
|
|
126
|
+
* concurrent identical request is mid-flight server-side; the real response
|
|
127
|
+
* lands once it finishes). `attempts` counts retries AFTER the first try.
|
|
128
|
+
* Defaults: 5 × 400 ms. (The other automatic retry, once on a 503
|
|
129
|
+
* `server_busy` / `request_timeout`, is not tunable.)
|
|
129
130
|
*/
|
|
130
131
|
inProgressRetry?: {
|
|
131
132
|
attempts?: number;
|
|
@@ -156,8 +157,12 @@ interface HostedClientOptions {
|
|
|
156
157
|
* `GET /hosted/session` (token-addressed) and lazily bootstraps it when a
|
|
157
158
|
* `:id` route is called first.
|
|
158
159
|
*
|
|
159
|
-
*
|
|
160
|
-
* `idempotency_in_progress
|
|
160
|
+
* Two automatic retries only: bounded short-delay retry on 409
|
|
161
|
+
* `idempotency_in_progress`, and ONE retry after `Retry-After` (capped at 3 s)
|
|
162
|
+
* on a 503 `server_busy` / `request_timeout` for the calls that are safe to
|
|
163
|
+
* repeat: the reads (`getSession`, `identityPortrait`), the naturally
|
|
164
|
+
* idempotent writes (`recordConsent`, `choose`) and `submitCheck` with an
|
|
165
|
+
* idempotency key. Everything else — including 429 with its parsed
|
|
161
166
|
* `retryAfterSeconds` — is surfaced to the page to handle.
|
|
162
167
|
*/
|
|
163
168
|
/**
|
|
@@ -177,6 +182,8 @@ declare class HostedClient {
|
|
|
177
182
|
/** D8: prefetched capture nonces (`armCapture`), each with its local expiry. */
|
|
178
183
|
private captureNonces;
|
|
179
184
|
private captureFetch;
|
|
185
|
+
/** Capture issues already reported (see reportCaptureIssue). */
|
|
186
|
+
private readonly reportedIssues;
|
|
180
187
|
constructor(opts: HostedClientOptions);
|
|
181
188
|
/** Token-addressed bootstrap — the hosted page's first call. Caches the sessionId. */
|
|
182
189
|
getSession(): Promise<HostedSessionView>;
|
|
@@ -193,6 +200,13 @@ declare class HostedClient {
|
|
|
193
200
|
* `cause` (2026-10-30) says why (`denied` | `no_camera`); omitted, the body stays `{}` and nothing is recorded.
|
|
194
201
|
*/
|
|
195
202
|
reportCameraUnavailable(cause?: CameraUnavailableCause): Promise<HostedSessionView>;
|
|
203
|
+
/**
|
|
204
|
+
* 2026-11-04: record a capture failure the page showed (`POST /hosted/capture-issue`, 204) so it can be diagnosed
|
|
205
|
+
* later. Fire-and-forget: never rejects, and every failure is swallowed. At most one report per distinct
|
|
206
|
+
* (check, attempt, kind, name, phase); a repeat resolves without a call. `name` is re-sanitised (letters only, at most
|
|
207
|
+
* 40 characters) and `engineKind` kept only when it is a lower-case code of at most 32 characters.
|
|
208
|
+
*/
|
|
209
|
+
reportCaptureIssue(issue: CaptureIssueReport): Promise<void>;
|
|
196
210
|
/**
|
|
197
211
|
* Pick an option of the current choice (Sekyro flows §7.4): `plan.choice`'s
|
|
198
212
|
* `nodeId` and one of its option ids. Returns the updated hosted view —
|
|
@@ -288,8 +302,10 @@ declare class HostedClient {
|
|
|
288
302
|
* `{code, message}` → {@link HostedApiError} on non-2xx. EVERY failure is
|
|
289
303
|
* typed: a rejected fetch → `network_error`, the timeout → `timeout`, an
|
|
290
304
|
* unparseable 2xx body → `unknown_error` — the page never sees a raw
|
|
291
|
-
* TypeError/DOMException.
|
|
292
|
-
*
|
|
305
|
+
* TypeError/DOMException. Automatic retries: 409 `idempotency_in_progress`
|
|
306
|
+
* (bounded, short delay), and ONE retry of a 503 `server_busy` /
|
|
307
|
+
* `request_timeout` after its `Retry-After` (capped at 3 s) when the call is
|
|
308
|
+
* safe to repeat: every GET, and a POST that sets `busyRetry`.
|
|
293
309
|
*/
|
|
294
310
|
private api;
|
|
295
311
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { H as HostedSessionView, C as ConsentLocale, a as HostedConsentView, b as CameraUnavailableCause, I as IdentityConfirmDecision, M as MediaKind, P as PresignUploadResult,
|
|
1
|
+
import { H as HostedSessionView, C as ConsentLocale, a as HostedConsentView, b as CameraUnavailableCause, c as CaptureIssueReport, I as IdentityConfirmDecision, M as MediaKind, P as PresignUploadResult, d as CaptureContext, e as CompleteMediaResult, f as CheckType, g as CheckInputByType, h as IcaoCriterion, B as BackgroundUniformity, R as ResolvedIcaoTuning } from './types-DPl0hsmI.cjs';
|
|
2
2
|
|
|
3
3
|
interface Point {
|
|
4
4
|
x: number;
|
|
@@ -122,10 +122,11 @@ interface HostedClientOptions {
|
|
|
122
122
|
/** Per-request timeout for API calls (NOT the Spaces PUT). Default 30 000 ms. */
|
|
123
123
|
requestTimeoutMs?: number;
|
|
124
124
|
/**
|
|
125
|
-
* Tuning for the
|
|
126
|
-
*
|
|
127
|
-
*
|
|
128
|
-
*
|
|
125
|
+
* Tuning for the automatic retry on 409 `idempotency_in_progress` (a
|
|
126
|
+
* concurrent identical request is mid-flight server-side; the real response
|
|
127
|
+
* lands once it finishes). `attempts` counts retries AFTER the first try.
|
|
128
|
+
* Defaults: 5 × 400 ms. (The other automatic retry, once on a 503
|
|
129
|
+
* `server_busy` / `request_timeout`, is not tunable.)
|
|
129
130
|
*/
|
|
130
131
|
inProgressRetry?: {
|
|
131
132
|
attempts?: number;
|
|
@@ -156,8 +157,12 @@ interface HostedClientOptions {
|
|
|
156
157
|
* `GET /hosted/session` (token-addressed) and lazily bootstraps it when a
|
|
157
158
|
* `:id` route is called first.
|
|
158
159
|
*
|
|
159
|
-
*
|
|
160
|
-
* `idempotency_in_progress
|
|
160
|
+
* Two automatic retries only: bounded short-delay retry on 409
|
|
161
|
+
* `idempotency_in_progress`, and ONE retry after `Retry-After` (capped at 3 s)
|
|
162
|
+
* on a 503 `server_busy` / `request_timeout` for the calls that are safe to
|
|
163
|
+
* repeat: the reads (`getSession`, `identityPortrait`), the naturally
|
|
164
|
+
* idempotent writes (`recordConsent`, `choose`) and `submitCheck` with an
|
|
165
|
+
* idempotency key. Everything else — including 429 with its parsed
|
|
161
166
|
* `retryAfterSeconds` — is surfaced to the page to handle.
|
|
162
167
|
*/
|
|
163
168
|
/**
|
|
@@ -177,6 +182,8 @@ declare class HostedClient {
|
|
|
177
182
|
/** D8: prefetched capture nonces (`armCapture`), each with its local expiry. */
|
|
178
183
|
private captureNonces;
|
|
179
184
|
private captureFetch;
|
|
185
|
+
/** Capture issues already reported (see reportCaptureIssue). */
|
|
186
|
+
private readonly reportedIssues;
|
|
180
187
|
constructor(opts: HostedClientOptions);
|
|
181
188
|
/** Token-addressed bootstrap — the hosted page's first call. Caches the sessionId. */
|
|
182
189
|
getSession(): Promise<HostedSessionView>;
|
|
@@ -193,6 +200,13 @@ declare class HostedClient {
|
|
|
193
200
|
* `cause` (2026-10-30) says why (`denied` | `no_camera`); omitted, the body stays `{}` and nothing is recorded.
|
|
194
201
|
*/
|
|
195
202
|
reportCameraUnavailable(cause?: CameraUnavailableCause): Promise<HostedSessionView>;
|
|
203
|
+
/**
|
|
204
|
+
* 2026-11-04: record a capture failure the page showed (`POST /hosted/capture-issue`, 204) so it can be diagnosed
|
|
205
|
+
* later. Fire-and-forget: never rejects, and every failure is swallowed. At most one report per distinct
|
|
206
|
+
* (check, attempt, kind, name, phase); a repeat resolves without a call. `name` is re-sanitised (letters only, at most
|
|
207
|
+
* 40 characters) and `engineKind` kept only when it is a lower-case code of at most 32 characters.
|
|
208
|
+
*/
|
|
209
|
+
reportCaptureIssue(issue: CaptureIssueReport): Promise<void>;
|
|
196
210
|
/**
|
|
197
211
|
* Pick an option of the current choice (Sekyro flows §7.4): `plan.choice`'s
|
|
198
212
|
* `nodeId` and one of its option ids. Returns the updated hosted view —
|
|
@@ -288,8 +302,10 @@ declare class HostedClient {
|
|
|
288
302
|
* `{code, message}` → {@link HostedApiError} on non-2xx. EVERY failure is
|
|
289
303
|
* typed: a rejected fetch → `network_error`, the timeout → `timeout`, an
|
|
290
304
|
* unparseable 2xx body → `unknown_error` — the page never sees a raw
|
|
291
|
-
* TypeError/DOMException.
|
|
292
|
-
*
|
|
305
|
+
* TypeError/DOMException. Automatic retries: 409 `idempotency_in_progress`
|
|
306
|
+
* (bounded, short delay), and ONE retry of a 503 `server_busy` /
|
|
307
|
+
* `request_timeout` after its `Retry-After` (capped at 3 s) when the call is
|
|
308
|
+
* safe to repeat: every GET, and a POST that sets `busyRetry`.
|
|
293
309
|
*/
|
|
294
310
|
private api;
|
|
295
311
|
}
|