@incodetech/core 0.0.0-dev-20260407-2c382da → 0.0.0-dev-20260407-ebd92aa

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.
Files changed (114) hide show
  1. package/dist/{BaseWasmProvider--AzPfwOm.esm.js → BaseWasmProvider-CQgeReKV.esm.js} +1 -785
  2. package/dist/MotionSensorProvider-BTDLt08l.esm.js +254 -0
  3. package/dist/OpenViduRecordingProvider-PvkEhhDq.esm.js +87 -0
  4. package/dist/StateMachine-DU1S4Cik.d.ts +2 -0
  5. package/dist/{WasmUtilProvider-BonqBWdj.esm.js → WasmUtilProvider-C45HStLj.esm.js} +1 -1
  6. package/dist/{addressSearch-B8Fo4v9V.esm.js → addressSearch-C5qzDvkN.esm.js} +4 -4
  7. package/dist/antifraud.d.ts +1 -1
  8. package/dist/antifraud.esm.js +3 -3
  9. package/dist/authentication.d.ts +11 -9
  10. package/dist/authentication.esm.js +18 -13
  11. package/dist/{authenticationManager-Bd10YGSO.d.ts → authenticationManager-CXTPgE_2.d.ts} +2 -2
  12. package/dist/{authenticationManager-B4gSCgrO.esm.js → authenticationManager-D4esVx-z.esm.js} +7 -6
  13. package/dist/{backCameraStream-DF_d7hTz.esm.js → backCameraStream-CUo1USCT.esm.js} +2 -2
  14. package/dist/camera.d.ts +16 -0
  15. package/dist/camera.esm.js +5 -0
  16. package/dist/consent.d.ts +52 -52
  17. package/dist/consent.esm.js +3 -3
  18. package/dist/curp-validation.d.ts +5 -5
  19. package/dist/curp-validation.esm.js +3 -3
  20. package/dist/{deepsightLoader-DKgEdLIS.esm.js → deepsightLoader-Bs5jHgca.esm.js} +10 -7
  21. package/dist/deepsightService-C3gQ_9Ml.esm.js +493 -0
  22. package/dist/{deepsightService-Ciu0atv5.d.ts → deepsightService-CyEcAH-I.d.ts} +193 -197
  23. package/dist/device.d.ts +46 -0
  24. package/dist/device.esm.js +106 -0
  25. package/dist/document-capture.d.ts +3 -3
  26. package/dist/document-capture.esm.js +6 -6
  27. package/dist/document-upload.d.ts +4 -4
  28. package/dist/document-upload.esm.js +6 -6
  29. package/dist/ekyb.d.ts +3 -3
  30. package/dist/ekyb.esm.js +9 -9
  31. package/dist/ekyc.d.ts +3 -3
  32. package/dist/ekyc.esm.js +5 -5
  33. package/dist/email.d.ts +3 -3
  34. package/dist/email.esm.js +5 -5
  35. package/dist/{emailManager-CpAwvP3v.esm.js → emailManager-CZ2IGW0g.esm.js} +4 -4
  36. package/dist/{emailManager-BQPIJR_O.d.ts → emailManager-CtA6Tvry.d.ts} +2 -2
  37. package/dist/events-BlVGS-8F.esm.js +472 -0
  38. package/dist/events.d.ts +232 -0
  39. package/dist/events.esm.js +4 -0
  40. package/dist/extensibility.d.ts +15 -13
  41. package/dist/extensibility.esm.js +25 -20
  42. package/dist/face-match.d.ts +1 -1
  43. package/dist/face-match.esm.js +3 -3
  44. package/dist/{faceCaptureManagerFactory-CdwpYykv.d.ts → faceCaptureManagerFactory-Bp_mC9b2.d.ts} +8 -6
  45. package/dist/faceCaptureSetup-DzlTPjT9.esm.js +828 -0
  46. package/dist/flow.d.ts +17 -9
  47. package/dist/flow.esm.js +68 -21
  48. package/dist/{flowCompletionService-TnWijsSw.esm.js → flowCompletionService-N6-xypy-.esm.js} +2 -2
  49. package/dist/{flowServices-CO2sIR3D.esm.js → flowServices-xgqnJ64L.esm.js} +3 -3
  50. package/dist/geolocation.d.ts +2 -2
  51. package/dist/geolocation.esm.js +4 -4
  52. package/dist/getBrowser-B800KRAi.esm.js +41 -0
  53. package/dist/getDeviceClass-BKd2FOAf.esm.js +14 -0
  54. package/dist/government-validation.d.ts +2 -2
  55. package/dist/government-validation.esm.js +4 -4
  56. package/dist/http.d.ts +57 -0
  57. package/dist/http.esm.js +3 -0
  58. package/dist/id.d.ts +11 -10
  59. package/dist/id.esm.js +20 -16
  60. package/dist/{idCaptureManager-IdqsAASp.d.ts → idCaptureManager-Bx298yFC.d.ts} +9 -7
  61. package/dist/{idCaptureManager-DaLU1ug7.esm.js → idCaptureManager-bowLKHEs.esm.js} +75 -58
  62. package/dist/index.d.ts +3 -611
  63. package/dist/index.esm.js +10 -562
  64. package/dist/{lib-i-4qLKdG.esm.js → lib-Cq5Wc-Hd.esm.js} +1 -1
  65. package/dist/mandatory-consent.d.ts +55 -55
  66. package/dist/mandatory-consent.esm.js +3 -3
  67. package/dist/openviduLazy-BdsxPGgp.esm.js +12 -0
  68. package/dist/openviduLazy-NTgGtkeK.esm.js +3 -0
  69. package/dist/permissionServices-CDqkkway.esm.js +50 -0
  70. package/dist/phone.d.ts +3 -3
  71. package/dist/phone.esm.js +5 -5
  72. package/dist/{phoneManager-BAPHSXx8.esm.js → phoneManager-CscgaER2.esm.js} +4 -4
  73. package/dist/{phoneManager-DA8WUJtl.d.ts → phoneManager-DlaiZtwZ.d.ts} +2 -2
  74. package/dist/recordingService-BDx_6XR9.esm.js +1024 -0
  75. package/dist/redirect-to-mobile.d.ts +2 -2
  76. package/dist/redirect-to-mobile.esm.js +4 -4
  77. package/dist/selfie.d.ts +11 -9
  78. package/dist/selfie.esm.js +18 -13
  79. package/dist/{selfieManager-BSkzncsa.esm.js → selfieManager-DVvvlMMf.esm.js} +5 -4
  80. package/dist/{selfieManager-Dft5wZQ_.d.ts → selfieManager-UBgYgVnw.d.ts} +2 -2
  81. package/dist/{session-OglUYC9l.esm.js → session-PLjFj_T3.esm.js} +5 -19
  82. package/dist/session.d.ts +46 -2
  83. package/dist/session.esm.js +7 -4
  84. package/dist/setup-DfinQjIF.d.ts +120 -0
  85. package/dist/setup-fvDWE7f8.esm.js +450 -0
  86. package/dist/signature.d.ts +2 -2
  87. package/dist/signature.esm.js +3 -3
  88. package/dist/{stats-BVigf5Rn.esm.js → stats-BZ1kFW4p.esm.js} +1 -1
  89. package/dist/stats.esm.js +2 -2
  90. package/dist/{types-CiLyvJGb.d.ts → types-DcqFYowa.d.ts} +1 -1
  91. package/dist/{types-D8Y1faI5.d.ts → types-DufUK-_f.d.ts} +1 -1
  92. package/dist/types-UPqCMQKa.d.ts +5 -0
  93. package/dist/{StateMachine-CM_aOfNL.d.ts → warmup-yzJJKXFi.d.ts} +1 -4
  94. package/dist/wasm.d.ts +15 -0
  95. package/dist/wasm.esm.js +10 -0
  96. package/dist/{Manager-C6AGXEq_.esm.js → xstate.esm-BXrcOcSC.esm.js} +103 -507
  97. package/package.json +18 -2
  98. package/dist/StreamCanvasCapture-DkpkIgyL.esm.js +0 -410
  99. package/dist/endpoints-CI5-28jT.esm.js +0 -69
  100. package/dist/faceCaptureSetup-DbXgtcp7.esm.js +0 -1561
  101. package/dist/id-CzDAG_kM.esm.js +0 -0
  102. package/dist/index-BuVKc9bv.d.ts +0 -1
  103. /package/dist/{Actor-By8WNHi-.d.ts → Actor-Cz_KnN47.d.ts} +0 -0
  104. /package/dist/{BrowserEnvironmentProvider-BECjyw3_.esm.js → BrowserEnvironmentProvider--xQUs3sg.esm.js} +0 -0
  105. /package/dist/{BrowserTimerProvider-CIqH6hJp.esm.js → BrowserTimerProvider-CkHEwJFa.esm.js} +0 -0
  106. /package/dist/{Manager-CCT_-HuZ.d.ts → Manager-N01KfnVA.d.ts} +0 -0
  107. /package/dist/{api-C2uzxrpN.esm.js → api-CyI8qTie.esm.js} +0 -0
  108. /package/dist/{browserSimulation-DYAk0Ipe.esm.js → browserSimulation-yzDdWSBf.esm.js} +0 -0
  109. /package/dist/{camera-6XJdOeBF.d.ts → camera-BcVDCZxW.d.ts} +0 -0
  110. /package/dist/{camera-DAuRUvnp.esm.js → camera-CsT06Zqy.esm.js} +0 -0
  111. /package/dist/{chunk-D6hkk-hd.esm.js → chunk-BcQWkoAq.esm.js} +0 -0
  112. /package/dist/{displayErrors-CGJwvrTl.d.ts → displayErrors-C0mf2glb.d.ts} +0 -0
  113. /package/dist/{flowCompletionService-BOd4Rk8n.d.ts → flowCompletionService-Dloh6J8n.d.ts} +0 -0
  114. /package/dist/{platform-DdhkonXk.esm.js → platform-Dcuv6w60.esm.js} +0 -0
@@ -1,5 +1,5 @@
1
- import "./Actor-By8WNHi-.js";
2
- import { t as Manager } from "./Manager-CCT_-HuZ.js";
1
+ import { t as Manager } from "./Manager-N01KfnVA.js";
2
+ import "./Actor-Cz_KnN47.js";
3
3
 
4
4
  //#region src/modules/redirect-to-mobile/types.d.ts
5
5
  type RedirectToMobileConfig = {
@@ -1,7 +1,7 @@
1
- import { t as api } from "./api-C2uzxrpN.esm.js";
2
- import { C as createActor, S as fromPromise, b as assign, r as eventModuleNames, s as createManagerInstrumentation, t as createManager, x as fromCallback, y as setup } from "./Manager-C6AGXEq_.esm.js";
3
- import { t as endpoints } from "./endpoints-CI5-28jT.esm.js";
4
- import { t as BrowserTimerProvider } from "./BrowserTimerProvider-CIqH6hJp.esm.js";
1
+ import { t as api } from "./api-CyI8qTie.esm.js";
2
+ import { _ as endpoints, n as eventModuleNames, o as createManagerInstrumentation } from "./events-BlVGS-8F.esm.js";
3
+ import { a as createActor, i as fromPromise, n as assign, o as createManager, r as fromCallback, t as setup } from "./xstate.esm-BXrcOcSC.esm.js";
4
+ import { t as BrowserTimerProvider } from "./BrowserTimerProvider-CkHEwJFa.esm.js";
5
5
 
6
6
  //#region ../infra/src/url/urlUtils.ts
7
7
  function getUrlSearchParam(url, param) {
package/dist/selfie.d.ts CHANGED
@@ -1,10 +1,12 @@
1
- import "./StateMachine-CM_aOfNL.js";
2
- import "./Actor-By8WNHi-.js";
3
- import { c as PermissionResult, l as PermissionStatus, t as DeepsightService } from "./deepsightService-Ciu0atv5.js";
4
- import { t as CameraStream } from "./camera-6XJdOeBF.js";
5
- import "./types-CiLyvJGb.js";
6
- import "./types-D8Y1faI5.js";
7
- import "./Manager-CCT_-HuZ.js";
8
- import { a as SelfieMachine, d as SelfieConfig, o as selfieMachine, v as DetectionStatus, y as FaceErrorCode } from "./faceCaptureManagerFactory-CdwpYykv.js";
9
- import { a as ProcessFaceResponse, n as SelfieState, o as processFace, r as createSelfieManager, t as SelfieManager } from "./selfieManager-Dft5wZQ_.js";
1
+ import "./warmup-yzJJKXFi.js";
2
+ import "./Manager-N01KfnVA.js";
3
+ import "./Actor-Cz_KnN47.js";
4
+ import "./StateMachine-DU1S4Cik.js";
5
+ import { a as SelfieMachine, d as SelfieConfig, o as selfieMachine, v as DetectionStatus, y as FaceErrorCode } from "./faceCaptureManagerFactory-Bp_mC9b2.js";
6
+ import { t as CameraStream } from "./camera-BcVDCZxW.js";
7
+ import "./types-DcqFYowa.js";
8
+ import "./types-DufUK-_f.js";
9
+ import { t as DeepsightService } from "./deepsightService-CyEcAH-I.js";
10
+ import { n as PermissionStatus, t as PermissionResult } from "./types-UPqCMQKa.js";
11
+ import { a as ProcessFaceResponse, n as SelfieState, o as processFace, r as createSelfieManager, t as SelfieManager } from "./selfieManager-UBgYgVnw.js";
10
12
  export { type CameraStream, type DeepsightService, type DetectionStatus, type FaceErrorCode, type PermissionResult, type PermissionStatus, type ProcessFaceResponse, type SelfieConfig, type SelfieMachine, type SelfieManager, type SelfieState, createSelfieManager, processFace, selfieMachine };
@@ -1,15 +1,20 @@
1
- import "./platform-DdhkonXk.esm.js";
2
- import "./BaseWasmProvider--AzPfwOm.esm.js";
3
- import "./StreamCanvasCapture-DkpkIgyL.esm.js";
4
- import "./browserSimulation-DYAk0Ipe.esm.js";
5
- import "./api-C2uzxrpN.esm.js";
6
- import "./Manager-C6AGXEq_.esm.js";
7
- import "./endpoints-CI5-28jT.esm.js";
8
- import "./camera-DAuRUvnp.esm.js";
9
- import "./stats-BVigf5Rn.esm.js";
10
- import "./backCameraStream-DF_d7hTz.esm.js";
11
- import "./WasmUtilProvider-BonqBWdj.esm.js";
12
- import { n as processFace } from "./faceCaptureSetup-DbXgtcp7.esm.js";
13
- import { r as selfieMachine, t as createSelfieManager } from "./selfieManager-BSkzncsa.esm.js";
1
+ import "./BaseWasmProvider-CQgeReKV.esm.js";
2
+ import "./WasmUtilProvider-C45HStLj.esm.js";
3
+ import "./api-CyI8qTie.esm.js";
4
+ import "./events-BlVGS-8F.esm.js";
5
+ import "./browserSimulation-yzDdWSBf.esm.js";
6
+ import "./xstate.esm-BXrcOcSC.esm.js";
7
+ import "./faceCaptureSetup-DzlTPjT9.esm.js";
8
+ import { l as processFace } from "./recordingService-BDx_6XR9.esm.js";
9
+ import "./deepsightService-C3gQ_9Ml.esm.js";
10
+ import "./camera-CsT06Zqy.esm.js";
11
+ import "./getBrowser-B800KRAi.esm.js";
12
+ import "./stats-BZ1kFW4p.esm.js";
13
+ import "./MotionSensorProvider-BTDLt08l.esm.js";
14
+ import "./permissionServices-CDqkkway.esm.js";
15
+ import "./platform-Dcuv6w60.esm.js";
16
+ import "./backCameraStream-CUo1USCT.esm.js";
17
+ import "./getDeviceClass-BKd2FOAf.esm.js";
18
+ import { r as selfieMachine, t as createSelfieManager } from "./selfieManager-DVvvlMMf.esm.js";
14
19
 
15
20
  export { createSelfieManager, processFace, selfieMachine };
@@ -1,7 +1,8 @@
1
- import { f as BrowserStorageProvider } from "./StreamCanvasCapture-DkpkIgyL.esm.js";
2
- import { C as createActor, S as fromPromise, b as assign, r as eventModuleNames } from "./Manager-C6AGXEq_.esm.js";
3
- import { t as WasmUtilProvider } from "./WasmUtilProvider-BonqBWdj.esm.js";
4
- import { a as createFaceCaptureManagerFromActor, i as FACE_ERROR_CODES, n as processFace, r as uploadSelfie, t as faceCaptureMachine } from "./faceCaptureSetup-DbXgtcp7.esm.js";
1
+ import { t as WasmUtilProvider } from "./WasmUtilProvider-C45HStLj.esm.js";
2
+ import { n as eventModuleNames } from "./events-BlVGS-8F.esm.js";
3
+ import { a as createActor, i as fromPromise, n as assign } from "./xstate.esm-BXrcOcSC.esm.js";
4
+ import { n as createFaceCaptureManagerFromActor, t as faceCaptureMachine } from "./faceCaptureSetup-DzlTPjT9.esm.js";
5
+ import { l as processFace, u as uploadSelfie, v as FACE_ERROR_CODES, y as BrowserStorageProvider } from "./recordingService-BDx_6XR9.esm.js";
5
6
 
6
7
  //#region src/modules/selfie/selfieErrorUtils.ts
7
8
  const FACE_ERROR_CODE_VALUES = Object.values(FACE_ERROR_CODES);
@@ -1,5 +1,5 @@
1
- import { t as Manager } from "./Manager-CCT_-HuZ.js";
2
- import { i as SelfieActor, n as FaceCaptureManagerState, r as CreateSelfieActorOptions, t as FaceCaptureManager } from "./faceCaptureManagerFactory-CdwpYykv.js";
1
+ import { t as Manager } from "./Manager-N01KfnVA.js";
2
+ import { i as SelfieActor, n as FaceCaptureManagerState, r as CreateSelfieActorOptions, t as FaceCaptureManager } from "./faceCaptureManagerFactory-Bp_mC9b2.js";
3
3
 
4
4
  //#region src/modules/selfie/selfieUploadService.d.ts
5
5
  type ProcessFaceImageType = 'selfie' | 'videoSelfie';
@@ -1,8 +1,7 @@
1
- import { t as isBrowserSimulation } from "./browserSimulation-DYAk0Ipe.esm.js";
2
- import { n as getApi, t as api } from "./api-C2uzxrpN.esm.js";
3
- import { h as addEvent } from "./Manager-C6AGXEq_.esm.js";
4
- import { t as endpoints } from "./endpoints-CI5-28jT.esm.js";
5
- import { t as BrowserEnvironmentProvider } from "./BrowserEnvironmentProvider-BECjyw3_.esm.js";
1
+ import { n as getApi, t as api } from "./api-CyI8qTie.esm.js";
2
+ import { _ as endpoints, m as addEvent } from "./events-BlVGS-8F.esm.js";
3
+ import { t as BrowserEnvironmentProvider } from "./BrowserEnvironmentProvider--xQUs3sg.esm.js";
4
+ import { t as isBrowserSimulation } from "./browserSimulation-yzDdWSBf.esm.js";
6
5
 
7
6
  //#region src/internal/session/sessionService.ts
8
7
  /**
@@ -3090,13 +3089,6 @@ async function initializeSession(options = {}) {
3090
3089
  return sessionInitPromise;
3091
3090
  }
3092
3091
  /**
3093
- * Gets the cached feature configuration.
3094
- * Returns undefined if session hasn't been initialized.
3095
- */
3096
- function getSessionFeatures() {
3097
- return cachedFeatures ?? void 0;
3098
- }
3099
- /**
3100
3092
  * Gets the cached disableIpify flag.
3101
3093
  * Returns false if session hasn't been initialized.
3102
3094
  */
@@ -3107,12 +3099,6 @@ function getSessionFingerprintResult() {
3107
3099
  return cachedFingerprintResult;
3108
3100
  }
3109
3101
  /**
3110
- * Checks if the session has been initialized.
3111
- */
3112
- function isSessionInitialized() {
3113
- return sessionInitialized;
3114
- }
3115
- /**
3116
3102
  * Resets session initialization state.
3117
3103
  * Useful for testing or when starting a new session.
3118
3104
  */
@@ -3127,4 +3113,4 @@ function resetSessionInit() {
3127
3113
  }
3128
3114
 
3129
3115
  //#endregion
3130
- export { isSessionInitialized as a, FingerprintProvider as c, initializeSession as i, getDeviceFingerprintInfo as l, getSessionFeatures as n, resetSessionInit as o, getSessionFingerprintResult as r, IpifyProvider as s, getDisableIpify as t, createSession as u };
3116
+ export { IpifyProvider as a, createSession as c, resetSessionInit as i, getSessionFingerprintResult as n, FingerprintProvider as o, initializeSession as r, getDeviceFingerprintInfo as s, getDisableIpify as t };
package/dist/session.d.ts CHANGED
@@ -1,2 +1,46 @@
1
- import { n as GetFinishStatusFn, r as getFinishStatus, t as FinishStatus } from "./flowCompletionService-BOd4Rk8n.js";
2
- export { type FinishStatus, type GetFinishStatusFn, getFinishStatus };
1
+ import { n as GetFinishStatusFn, r as getFinishStatus, t as FinishStatus } from "./flowCompletionService-Dloh6J8n.js";
2
+
3
+ //#region src/internal/session/sessionService.d.ts
4
+ type CreateSessionOptions = {
5
+ /** The configuration/flow ID from the Incode dashboard */
6
+ configurationId: string;
7
+ /** External ID to associate with this session */
8
+ externalId?: string;
9
+ /** External customer ID */
10
+ externalCustomerId?: string;
11
+ /** Language for the session (e.g., 'en-US', 'es-MX') */
12
+ language?: string;
13
+ /** Custom fields to attach to the session */
14
+ customFields?: Record<string, unknown>;
15
+ /** UUID for continuing an existing session */
16
+ uuid?: string;
17
+ /** Interview ID for continuing an existing interview */
18
+ interviewId?: string;
19
+ };
20
+ type Session = {
21
+ token: string;
22
+ interviewId: string;
23
+ uuid?: string;
24
+ regulationType?: string;
25
+ showMandatoryConsent?: boolean;
26
+ };
27
+ /**
28
+ * Creates a new onboarding session.
29
+ *
30
+ * @param apiKey - The API key from the Incode dashboard
31
+ * @param options - Session creation options
32
+ * @param signal - Optional AbortSignal for request cancellation
33
+ * @returns The created session with token
34
+ *
35
+ * @example
36
+ * ```ts
37
+ * const session = await createSession('your-api-key', {
38
+ * configurationId: 'your-flow-id',
39
+ * language: 'en-US',
40
+ * });
41
+ * console.log(session.token); // Use this token for subsequent API calls
42
+ * ```
43
+ */
44
+ declare function createSession(apiKey: string, options: CreateSessionOptions, signal?: AbortSignal): Promise<Session>;
45
+ //#endregion
46
+ export { type CreateSessionOptions, type FinishStatus, type GetFinishStatusFn, type Session, createSession, getFinishStatus };
@@ -1,5 +1,8 @@
1
- import "./api-C2uzxrpN.esm.js";
2
- import "./endpoints-CI5-28jT.esm.js";
3
- import { t as getFinishStatus } from "./flowCompletionService-TnWijsSw.esm.js";
1
+ import "./api-CyI8qTie.esm.js";
2
+ import "./events-BlVGS-8F.esm.js";
3
+ import { c as createSession } from "./session-PLjFj_T3.esm.js";
4
+ import "./BrowserEnvironmentProvider--xQUs3sg.esm.js";
5
+ import "./browserSimulation-yzDdWSBf.esm.js";
6
+ import { t as getFinishStatus } from "./flowCompletionService-N6-xypy-.esm.js";
4
7
 
5
- export { getFinishStatus };
8
+ export { createSession, getFinishStatus };
@@ -0,0 +1,120 @@
1
+ import { n as WasmPipeline } from "./warmup-yzJJKXFi.js";
2
+
3
+ //#region src/setup.d.ts
4
+
5
+ /**
6
+ * WASM warmup configuration. Path fields are optional; omitted values resolve to the Incode CDN defaults.
7
+ */
8
+ type WasmConfig = {
9
+ /** Path to the WASM binary */
10
+ wasmPath?: string;
11
+ /** Path to the SIMD-optimized WASM binary (optional) */
12
+ wasmSimdPath?: string;
13
+ /** Path to the WASM glue code */
14
+ glueCodePath?: string;
15
+ /** Whether to use SIMD optimizations (default: true) */
16
+ useSimd?: boolean;
17
+ /** Which pipelines to preload models for */
18
+ pipelines?: WasmPipeline[];
19
+ /**
20
+ * Base path for ML model files. Models will be loaded from `${modelsBasePath}/${modelFileName}`.
21
+ * If not provided, models are expected in a 'models' subdirectory relative to the WASM binary.
22
+ */
23
+ modelsBasePath?: string;
24
+ };
25
+ /**
26
+ * Configuration options for the SDK setup.
27
+ */
28
+ type SetupOptions = {
29
+ /** The base URL for the API. When omitted, no HTTP client is created — useful when all API actors are overridden via .provide(). */
30
+ apiURL?: string;
31
+ /** The session token for API requests (optional - can be set later or omitted for createSession calls) */
32
+ token?: string;
33
+ /** Custom headers to include in all requests */
34
+ customHeaders?: Record<string, string>;
35
+ /** Request timeout in milliseconds */
36
+ timeout?: number;
37
+ /**
38
+ * WASM warmup config.
39
+ * - Omit (default): loads automatically from the Incode CDN using the SDK's built-in version.
40
+ * - `false`: opt out of WASM entirely.
41
+ * - Object: override paths for self-hosting or a specific version.
42
+ */
43
+ wasm?: WasmConfig | false;
44
+ /** Optional hosting app identifier for fingerprint tracking */
45
+ hostingApp?: string;
46
+ };
47
+ /**
48
+ * Initializes the SDK with the provided configuration.
49
+ * Must be called before using any SDK functionality.
50
+ *
51
+ * WASM loads automatically from the Incode CDN unless explicitly disabled or overridden.
52
+ *
53
+ * @param options - Configuration options for the SDK
54
+ *
55
+ * @example
56
+ * ```ts
57
+ * import { setup } from '@incodetech/core';
58
+ *
59
+ * // Zero-config: WASM loads automatically from CDN
60
+ * await setup({ apiURL: 'https://api.incode.com', token: 'session-token' });
61
+ *
62
+ * // Opt out of WASM
63
+ * await setup({ apiURL: 'https://api.incode.com', token: 'session-token', wasm: false });
64
+ *
65
+ * // Self-hosted / custom version (full or partial path overrides)
66
+ * await setup({
67
+ * apiURL: 'https://api.incode.com',
68
+ * token: 'session-token',
69
+ * wasm: {
70
+ * wasmPath: '/my-cdn/webLib.wasm',
71
+ * glueCodePath: '/my-cdn/webLib.js',
72
+ * },
73
+ * });
74
+ *
75
+ * // Partial override: only models path, rest from CDN
76
+ * await setup({
77
+ * apiURL: 'https://api.incode.com',
78
+ * token: 'session-token',
79
+ * wasm: { modelsBasePath: 'https://my-cdn/models' },
80
+ * });
81
+ *
82
+ * // Sessionless setup (all API actors overridden via .provide())
83
+ * await setup({
84
+ * wasm: {
85
+ * wasmPath: '/wasm/ml-wasm.wasm',
86
+ * glueCodePath: '/wasm/ml-wasm.js',
87
+ * pipelines: ['selfie'],
88
+ * },
89
+ * });
90
+ * ```
91
+ */
92
+ declare function setup(options: SetupOptions): Promise<void>;
93
+ /**
94
+ * Sets the WASM configuration without performing warmup.
95
+ * Useful when WASM warmup is handled separately (e.g., conditionally based on flow).
96
+ *
97
+ * @param config - WASM configuration to store
98
+ */
99
+ declare function setWasmConfig(config: WasmConfig): void;
100
+ /**
101
+ * Initializes WasmUtilProvider with the stored WASM configuration.
102
+ * Should be called after warmupWasm() completes when using conditional warmup.
103
+ * This ensures image encryption works properly.
104
+ *
105
+ * @param config - Optional WASM configuration. If not provided, uses the stored config from setWasmConfig().
106
+ * @throws Error if no config is provided and none is stored
107
+ */
108
+ declare function initializeWasmUtil(config?: WasmConfig): Promise<void>;
109
+ /**
110
+ * Checks if the SDK has been configured.
111
+ *
112
+ * @returns true if setup() has been called, false otherwise
113
+ */
114
+ declare function isConfigured(): boolean;
115
+ /**
116
+ * Resets the SDK configuration. Useful for testing.
117
+ */
118
+ declare function reset(): void;
119
+ //#endregion
120
+ export { reset as a, isConfigured as i, WasmConfig as n, setWasmConfig as o, initializeWasmUtil as r, setup as s, SetupOptions as t };