vesant-sdk 2.0.0-dev.76771da → 2.0.0-dev.9578c07

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 (45) hide show
  1. package/dist/{client-CIEa7xYG.d.mts → client-BwkGrRW9.d.mts} +1 -1
  2. package/dist/{client-BJ87_Vv5.d.ts → client-CqSx0lAG.d.ts} +3 -3
  3. package/dist/{client-IAOGCBfm.d.mts → client-Dq0NMaXT.d.mts} +3 -3
  4. package/dist/{client-Bvp-f05-.d.ts → client-DvobLmsc.d.ts} +1 -1
  5. package/dist/compliance/index.d.mts +4 -4
  6. package/dist/compliance/index.d.ts +4 -4
  7. package/dist/decisions/index.d.mts +1 -1
  8. package/dist/decisions/index.d.ts +1 -1
  9. package/dist/geolocation/index.d.mts +3 -3
  10. package/dist/geolocation/index.d.ts +3 -3
  11. package/dist/index.d.mts +7 -7
  12. package/dist/index.d.ts +7 -7
  13. package/dist/index.js +54 -10
  14. package/dist/index.js.map +1 -1
  15. package/dist/index.mjs +54 -10
  16. package/dist/index.mjs.map +1 -1
  17. package/dist/kyc/core.d.mts +3 -3
  18. package/dist/kyc/core.d.ts +3 -3
  19. package/dist/kyc/core.js +54 -10
  20. package/dist/kyc/core.js.map +1 -1
  21. package/dist/kyc/core.mjs +54 -10
  22. package/dist/kyc/core.mjs.map +1 -1
  23. package/dist/kyc/index.d.mts +253 -21
  24. package/dist/kyc/index.d.ts +253 -21
  25. package/dist/kyc/index.js +54 -10
  26. package/dist/kyc/index.js.map +1 -1
  27. package/dist/kyc/index.mjs +54 -10
  28. package/dist/kyc/index.mjs.map +1 -1
  29. package/dist/react.d.mts +41 -6
  30. package/dist/react.d.ts +41 -6
  31. package/dist/react.js +603 -272
  32. package/dist/react.js.map +1 -1
  33. package/dist/react.mjs +603 -272
  34. package/dist/react.mjs.map +1 -1
  35. package/dist/risk-profile/index.d.mts +3 -3
  36. package/dist/risk-profile/index.d.ts +3 -3
  37. package/dist/scores/index.d.mts +1 -1
  38. package/dist/scores/index.d.ts +1 -1
  39. package/dist/{types-C4Zx0d_u.d.mts → types-BOFaMQxI.d.mts} +1 -1
  40. package/dist/{types-QUCWam16.d.mts → types-CBQRNL-l.d.mts} +10 -3
  41. package/dist/{types-QUCWam16.d.ts → types-CBQRNL-l.d.ts} +10 -3
  42. package/dist/{types-2utj53GK.d.ts → types-UGyDl1fd.d.ts} +1 -1
  43. package/dist/webhooks/index.d.mts +12 -4
  44. package/dist/webhooks/index.d.ts +12 -4
  45. package/package.json +1 -1
package/dist/react.d.ts CHANGED
@@ -1,10 +1,10 @@
1
- import { D as DeviceFingerprintRequest, G as GeolocationClient, i as CipherTextOptions, l as CipherTextResult, W as UseGeolocationOptions, X as UseGeolocationResult, Y as UseLocationCaptureOptions, Z as UseLocationCaptureResult, _ as UseLocationRequestsOptions, $ as UseLocationRequestsResult } from './client-Bvp-f05-.js';
2
- import { e as LoginVerificationResponse, L as LoginVerificationRequest, f as RegistrationVerificationResponse, R as RegistrationVerificationRequest, h as TransactionVerificationResponse, g as TransactionVerificationRequest, C as ComplianceClient } from './client-BJ87_Vv5.js';
1
+ import { D as DeviceFingerprintRequest, G as GeolocationClient, i as CipherTextOptions, l as CipherTextResult, W as UseGeolocationOptions, X as UseGeolocationResult, Y as UseLocationCaptureOptions, Z as UseLocationCaptureResult, _ as UseLocationRequestsOptions, $ as UseLocationRequestsResult } from './client-DvobLmsc.js';
2
+ import { e as LoginVerificationResponse, L as LoginVerificationRequest, f as RegistrationVerificationResponse, R as RegistrationVerificationRequest, h as TransactionVerificationResponse, g as TransactionVerificationRequest, C as ComplianceClient } from './client-CqSx0lAG.js';
3
3
  import { RiskProfileClient } from './risk-profile/index.js';
4
- import { C as CustomerProfile } from './types-2utj53GK.js';
5
- import { KycClient, UseKycAlertsOptions, UseKycAlertsResult, UseKycOverviewOptions, UseKycOverviewResult, UseKycPreferencesResult, UseKycRequestsOptions, UseKycRequestsResult, UseKycSubmissionOptions, UseKycSubmissionResult, CheckKycStatusResponse } from './kyc/index.js';
4
+ import { C as CustomerProfile } from './types-UGyDl1fd.js';
5
+ import { KycClient, UseKycAlertsOptions, UseKycAlertsResult, UseKycOverviewOptions, UseKycOverviewResult, UseKycPreferencesResult, UseKycRequestsOptions, UseKycRequestsResult, UseKycSubmissionOptions, UseKycSubmissionResult, CreateReuseKycSessionRequest, CreateReuseKycSessionResponse, ReuseKycCallback } from './kyc/index.js';
6
6
  import './client-BolQlL5e.js';
7
- import './types-QUCWam16.js';
7
+ import './types-CBQRNL-l.js';
8
8
 
9
9
  /**
10
10
  * Detect browser information from user agent.
@@ -507,8 +507,43 @@ declare function getStatusColor(status: string): string;
507
507
  * @returns CSS color class or hex color
508
508
  */
509
509
  declare function getRiskColor(risk: string): string;
510
+ /**
511
+ * Hook for the Re-Use KYC face-capture flow.
512
+ *
513
+ * Returns helpers that cover both mobile (direct capture) and desktop
514
+ * (QR + polling) modes. Device detection happens here on the client —
515
+ * the server accepts submissions from any User-Agent.
516
+ *
517
+ * - `startSession(req)` — POST /face/session. Inspect `is_required` first;
518
+ * skip the modal entirely when it's `false`.
519
+ * - `verifyFace(session, opts?)` — mount FaceCaptureModal and resolve once
520
+ * the user reaches a terminal state (accepted / declined-after-max /
521
+ * cancelled). The modal handles the device picker, QR handoff,
522
+ * selfie capture, retries within the configured `max_attempts`, and
523
+ * surfacing of the decline reason — all without unmounting in between.
524
+ * - `runFlow(req, opts?)` — convenience wrapper: `startSession` then
525
+ * `verifyFace`, with a short-circuit when `is_required` is false.
526
+ */
510
527
  declare function useReuseKYCSubmission(client: KycClient): {
511
- verifyFace: (reference: string, token: string) => Promise<CheckKycStatusResponse | null>;
528
+ startSession: (request: CreateReuseKycSessionRequest) => Promise<CreateReuseKycSessionResponse>;
529
+ verifyFace: (session: CreateReuseKycSessionResponse, opts?: {
530
+ defaultDevice?: "ask" | "this" | "mobile";
531
+ renderQR?: (payload: string) => React.ReactNode;
532
+ }) => Promise<ReuseKycCallback | null>;
533
+ runFlow: (request: CreateReuseKycSessionRequest, opts?: {
534
+ defaultDevice?: "ask" | "this" | "mobile";
535
+ renderQR?: (payload: string) => React.ReactNode;
536
+ }) => Promise<{
537
+ kind: "not_required";
538
+ session: CreateReuseKycSessionResponse;
539
+ } | {
540
+ kind: "cancelled";
541
+ session: CreateReuseKycSessionResponse;
542
+ } | {
543
+ kind: "completed";
544
+ session: CreateReuseKycSessionResponse;
545
+ result: ReuseKycCallback;
546
+ }>;
512
547
  };
513
548
 
514
549
  export { type UseCustomerProfileOptions, type UseCustomerProfileResult, UseGeolocationOptions, UseGeolocationResult, UseKycAlertsOptions, UseKycAlertsResult, UseKycOverviewOptions, UseKycOverviewResult, UseKycPreferencesResult, UseKycRequestsOptions, UseKycRequestsResult, UseKycSubmissionOptions, UseKycSubmissionResult, UseLocationCaptureOptions, UseLocationCaptureResult, UseLocationRequestsOptions, UseLocationRequestsResult, type UseLoginVerificationOptions, type UseLoginVerificationResult, type UseRegistrationOptions, type UseRegistrationResult, type UseTransactionVerificationOptions, type UseTransactionVerificationResult, createDeviceFingerprint, fileToBase64, formatKycStatus, getBrowserInfo, getRiskColor, getStatusColor, isValidFileSize, isValidFileType, useCipherText, useCustomerProfile, useGeolocation, useKycAlerts, useKycOverview, useKycPreferences, useKycRequests, useKycSubmission, useLocationCapture, useLocationRequests, useLoginVerification, useRegistration, useReuseKYCSubmission, useTransactionVerification };