vesant-sdk 1.6.6 → 2.0.0-dev.40d1c39
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/README.md +14 -4
- package/dist/client-BJ87_Vv5.d.ts +430 -0
- package/dist/{client-ePzhQKp9.d.mts → client-BolQlL5e.d.mts} +1 -1
- package/dist/{client-ePzhQKp9.d.ts → client-BolQlL5e.d.ts} +1 -1
- package/dist/{client-BlCxjbY2.d.mts → client-Bvp-f05-.d.ts} +7 -7
- package/dist/{client-C_A7QLcB.d.ts → client-CIEa7xYG.d.mts} +7 -7
- package/dist/client-IAOGCBfm.d.mts +430 -0
- package/dist/compliance/index.d.mts +25 -429
- package/dist/compliance/index.d.ts +25 -429
- package/dist/compliance/index.js +137 -58
- package/dist/compliance/index.js.map +1 -1
- package/dist/compliance/index.mjs +137 -59
- package/dist/compliance/index.mjs.map +1 -1
- package/dist/decisions/index.d.mts +2 -2
- package/dist/decisions/index.d.ts +2 -2
- package/dist/decisions/index.js +1 -1
- package/dist/decisions/index.js.map +1 -1
- package/dist/decisions/index.mjs +1 -1
- package/dist/decisions/index.mjs.map +1 -1
- package/dist/geolocation/index.d.mts +4 -4
- package/dist/geolocation/index.d.ts +4 -4
- package/dist/geolocation/index.js +6 -24
- package/dist/geolocation/index.js.map +1 -1
- package/dist/geolocation/index.mjs +6 -24
- package/dist/geolocation/index.mjs.map +1 -1
- package/dist/index.d.mts +14 -71
- package/dist/index.d.ts +14 -71
- package/dist/index.js +190 -237
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +189 -236
- package/dist/index.mjs.map +1 -1
- package/dist/kyc/core.d.mts +4 -4
- package/dist/kyc/core.d.ts +4 -4
- package/dist/kyc/core.js +24 -13
- package/dist/kyc/core.js.map +1 -1
- package/dist/kyc/core.mjs +24 -14
- package/dist/kyc/core.mjs.map +1 -1
- package/dist/kyc/index.d.mts +20 -27
- package/dist/kyc/index.d.ts +20 -27
- package/dist/kyc/index.js +24 -13
- package/dist/kyc/index.js.map +1 -1
- package/dist/kyc/index.mjs +24 -14
- package/dist/kyc/index.mjs.map +1 -1
- package/dist/react.d.mts +6 -6
- package/dist/react.d.ts +6 -6
- package/dist/react.js +18 -5
- package/dist/react.js.map +1 -1
- package/dist/react.mjs +18 -5
- package/dist/react.mjs.map +1 -1
- package/dist/risk-profile/index.d.mts +4 -4
- package/dist/risk-profile/index.d.ts +4 -4
- package/dist/risk-profile/index.js +1 -1
- package/dist/risk-profile/index.js.map +1 -1
- package/dist/risk-profile/index.mjs +1 -1
- package/dist/risk-profile/index.mjs.map +1 -1
- package/dist/scores/index.d.mts +2 -2
- package/dist/scores/index.d.ts +2 -2
- package/dist/scores/index.js +1 -1
- package/dist/scores/index.js.map +1 -1
- package/dist/scores/index.mjs +1 -1
- package/dist/scores/index.mjs.map +1 -1
- package/dist/tax/index.d.mts +6 -41
- package/dist/tax/index.d.ts +6 -41
- package/dist/tax/index.js +1 -36
- package/dist/tax/index.js.map +1 -1
- package/dist/tax/index.mjs +1 -36
- package/dist/tax/index.mjs.map +1 -1
- package/dist/{types-X5Md_dD_.d.ts → types-2utj53GK.d.ts} +2 -2
- package/dist/{types-1RzYeSal.d.mts → types-C4Zx0d_u.d.mts} +2 -2
- package/dist/{types-B4Ezqo7V.d.mts → types-QUCWam16.d.mts} +7 -1
- package/dist/{types-B4Ezqo7V.d.ts → types-QUCWam16.d.ts} +7 -1
- package/dist/webhooks/index.d.mts +181 -2
- package/dist/webhooks/index.d.ts +181 -2
- package/dist/webhooks/index.js +49 -7
- package/dist/webhooks/index.js.map +1 -1
- package/dist/webhooks/index.mjs +49 -7
- package/dist/webhooks/index.mjs.map +1 -1
- package/package.json +16 -13
- package/dist/fraud/index.d.mts +0 -80
- package/dist/fraud/index.d.ts +0 -80
- package/dist/fraud/index.js +0 -606
- package/dist/fraud/index.js.map +0 -1
- package/dist/fraud/index.mjs +0 -604
- package/dist/fraud/index.mjs.map +0 -1
- package/dist/index-B04H4xfJ.d.mts +0 -320
- package/dist/index-CItMPmLL.d.ts +0 -320
|
@@ -1,431 +1,27 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
3
|
-
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
1
|
+
import { B as BlockReason } from '../types-QUCWam16.js';
|
|
2
|
+
export { C as ComplianceClient, a as ComplianceLocationRequestInput, b as ComplianceLocationRequestResult, c as CurrencyRates, D as DEFAULT_CURRENCY_RATES, E as EventVerificationRequest, d as EventVerificationResponse, L as LoginVerificationRequest, e as LoginVerificationResponse, R as RegistrationVerificationRequest, f as RegistrationVerificationResponse, T as TransactionRiskResult, g as TransactionVerificationRequest, h as TransactionVerificationResponse } from '../client-BJ87_Vv5.js';
|
|
3
|
+
export { p as CreateLocationRequestRequest, H as LocationCaptureRequest, I as LocationCaptureResponse, a as LocationRequest, K as LocationRequestChannel, b as LocationRequestFilters, c as LocationRequestListResponse, M as LocationRequestResult, N as LocationRequestStatus, O as LocationShareInfo, R as ResendLocationRequestRequest } from '../client-Bvp-f05-.js';
|
|
4
|
+
import '../risk-profile/index.js';
|
|
5
|
+
import '../client-BolQlL5e.js';
|
|
6
|
+
import '../types-2utj53GK.js';
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
requiresEDD: boolean;
|
|
27
|
-
blockReasons: string[];
|
|
28
|
-
processingTime: number;
|
|
29
|
-
cipherTextValidation?: ValidateCipherTextResponse;
|
|
30
|
-
}
|
|
31
|
-
interface LoginVerificationRequest {
|
|
32
|
-
customerId: string;
|
|
33
|
-
ipAddress: string;
|
|
34
|
-
deviceFingerprint?: DeviceFingerprintRequest;
|
|
35
|
-
cipherText?: string;
|
|
36
|
-
metadata?: Record<string, unknown>;
|
|
37
|
-
}
|
|
38
|
-
interface LoginVerificationResponse {
|
|
39
|
-
allowed: boolean;
|
|
40
|
-
geolocation: LocationVerification;
|
|
41
|
-
profile: CustomerProfile | null;
|
|
42
|
-
requiresStepUp: boolean;
|
|
43
|
-
blockReasons: string[];
|
|
44
|
-
processingTime: number;
|
|
45
|
-
cipherTextValidation?: ValidateCipherTextResponse;
|
|
46
|
-
}
|
|
47
|
-
interface TransactionVerificationRequest {
|
|
48
|
-
customerId: string;
|
|
49
|
-
ipAddress: string;
|
|
50
|
-
amount: number;
|
|
51
|
-
currency: string;
|
|
52
|
-
transactionType?: 'deposit' | 'withdrawal' | 'bet' | 'transfer' | 'payout';
|
|
53
|
-
deviceFingerprint?: DeviceFingerprintRequest;
|
|
54
|
-
cipherText?: string;
|
|
55
|
-
metadata?: Record<string, unknown>;
|
|
56
|
-
}
|
|
57
|
-
interface TransactionVerificationResponse {
|
|
58
|
-
allowed: boolean;
|
|
59
|
-
geolocation: LocationVerification;
|
|
60
|
-
profile: CustomerProfile | null;
|
|
61
|
-
transactionRisk: TransactionRiskResult;
|
|
62
|
-
requiresApproval: boolean;
|
|
63
|
-
blockReasons: string[];
|
|
64
|
-
processingTime: number;
|
|
65
|
-
cipherTextValidation?: ValidateCipherTextResponse;
|
|
66
|
-
}
|
|
67
|
-
interface TransactionRiskResult {
|
|
68
|
-
score: number;
|
|
69
|
-
level: 'low' | 'medium' | 'high' | 'critical';
|
|
70
|
-
factors: string[];
|
|
71
|
-
allowed: boolean;
|
|
72
|
-
requiresManualReview: boolean;
|
|
73
|
-
}
|
|
74
|
-
interface EventVerificationRequest {
|
|
75
|
-
customerId: string;
|
|
76
|
-
ipAddress: string;
|
|
77
|
-
eventType: string;
|
|
78
|
-
deviceFingerprint?: DeviceFingerprintRequest;
|
|
79
|
-
cipherText?: string;
|
|
80
|
-
metadata?: Record<string, unknown>;
|
|
81
|
-
}
|
|
82
|
-
interface EventVerificationResponse {
|
|
83
|
-
allowed: boolean;
|
|
84
|
-
geolocation: LocationVerification;
|
|
85
|
-
blockReasons: string[];
|
|
86
|
-
processingTime: number;
|
|
87
|
-
cipherTextValidation?: ValidateCipherTextResponse;
|
|
88
|
-
}
|
|
89
|
-
interface CurrencyRates {
|
|
90
|
-
[currency: string]: number;
|
|
91
|
-
}
|
|
92
|
-
declare const DEFAULT_CURRENCY_RATES: CurrencyRates;
|
|
8
|
+
declare const sdkReasons: {
|
|
9
|
+
jurisdictionBlocked: (country: string, countryISO: string) => BlockReason;
|
|
10
|
+
jurisdictionNonCompliant: () => BlockReason;
|
|
11
|
+
jurisdictionRegistrationDenied: () => BlockReason;
|
|
12
|
+
jurisdictionRestricted: () => BlockReason;
|
|
13
|
+
riskCriticalLevel: () => BlockReason;
|
|
14
|
+
accountSuspended: () => BlockReason;
|
|
15
|
+
sanctionsMatch: () => BlockReason;
|
|
16
|
+
riskHighLocation: () => BlockReason;
|
|
17
|
+
riskHighCustomer: () => BlockReason;
|
|
18
|
+
ciphertextInvalid: () => BlockReason;
|
|
19
|
+
gpsIPMismatch: () => BlockReason;
|
|
20
|
+
gpsRequired: () => BlockReason;
|
|
21
|
+
transactionHighAmount: (amount: number, currency: string, threshold: number) => BlockReason;
|
|
22
|
+
transactionElevatedAmount: (amount: number, currency: string, threshold: number) => BlockReason;
|
|
23
|
+
transactionJurisdictionLimit: () => BlockReason;
|
|
24
|
+
anonymizationDetected: () => BlockReason;
|
|
25
|
+
};
|
|
93
26
|
|
|
94
|
-
|
|
95
|
-
/** Customer user ID to request location from */
|
|
96
|
-
customerId: string;
|
|
97
|
-
/** Notification channel to use */
|
|
98
|
-
channel: 'sms' | 'email' | 'push';
|
|
99
|
-
/** Reason for requesting location (for compliance/audit) */
|
|
100
|
-
reason: string;
|
|
101
|
-
/** Customer email (required for email channel) */
|
|
102
|
-
email?: string;
|
|
103
|
-
/** Customer phone (required for SMS channel) */
|
|
104
|
-
phone?: string;
|
|
105
|
-
/** Custom expiry time in hours (default: 24) */
|
|
106
|
-
expiryHours?: number;
|
|
107
|
-
}
|
|
108
|
-
interface ComplianceLocationRequestResult {
|
|
109
|
-
/** The created location request */
|
|
110
|
-
request: LocationRequest;
|
|
111
|
-
/** Shareable link for the customer */
|
|
112
|
-
shareLink: string;
|
|
113
|
-
/** Token expiration time */
|
|
114
|
-
tokenExpiry: string;
|
|
115
|
-
/** Customer profile (if available) */
|
|
116
|
-
profile?: CustomerProfile;
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
/**
|
|
120
|
-
* ComplianceClient - Unified Compliance Orchestration
|
|
121
|
-
*
|
|
122
|
-
* Main integration point for casino platforms. Orchestrates geolocation
|
|
123
|
-
* verification with customer risk profiling for complete compliance coverage.
|
|
124
|
-
*
|
|
125
|
-
* SDK is the primary data injection point for compliance verification.
|
|
126
|
-
*/
|
|
127
|
-
|
|
128
|
-
declare class ComplianceClient {
|
|
129
|
-
private geoClient;
|
|
130
|
-
private riskClient;
|
|
131
|
-
private config;
|
|
132
|
-
private logger;
|
|
133
|
-
private currencyRates;
|
|
134
|
-
private _currencyRatesCustomized;
|
|
135
|
-
private _currencyRatesWarned;
|
|
136
|
-
constructor(config: VesantConfig);
|
|
137
|
-
/** Get the underlying GeolocationClient for direct geolocation API access */
|
|
138
|
-
getGeolocationClient(): GeolocationClient;
|
|
139
|
-
/** Get the underlying RiskProfileClient for direct risk profile API access */
|
|
140
|
-
getRiskProfileClient(): RiskProfileClient;
|
|
141
|
-
/**
|
|
142
|
-
* Verify customer registration with automatic profile creation
|
|
143
|
-
*
|
|
144
|
-
* This is the primary integration point for new customer sign-ups.
|
|
145
|
-
* Combines geolocation verification with customer risk profile creation.
|
|
146
|
-
*
|
|
147
|
-
* Important: Profile is only created if geolocation verification passes.
|
|
148
|
-
* This prevents orphaned geolocation records when registration is blocked.
|
|
149
|
-
*
|
|
150
|
-
* @param request - Registration verification request
|
|
151
|
-
* @returns Verification response with profile and compliance status
|
|
152
|
-
*
|
|
153
|
-
* @example
|
|
154
|
-
* ```typescript
|
|
155
|
-
* const result = await sdk.verifyAtRegistration({
|
|
156
|
-
* customerId: 'CUST-12345',
|
|
157
|
-
* fullName: 'John Doe',
|
|
158
|
-
* emailAddress: 'john@example.com',
|
|
159
|
-
* ipAddress: req.ip,
|
|
160
|
-
* deviceFingerprint: getDeviceFingerprint()
|
|
161
|
-
* });
|
|
162
|
-
*
|
|
163
|
-
* if (result.allowed) {
|
|
164
|
-
* // Create account
|
|
165
|
-
* console.log('Profile created:', result.profile);
|
|
166
|
-
* if (result.requiresKYC) {
|
|
167
|
-
* // Redirect to KYC flow
|
|
168
|
-
* }
|
|
169
|
-
* } else {
|
|
170
|
-
* // Block registration
|
|
171
|
-
* console.log('Blocked:', result.blockReasons);
|
|
172
|
-
* }
|
|
173
|
-
* ```
|
|
174
|
-
*/
|
|
175
|
-
verifyAtRegistration(request: RegistrationVerificationRequest, requestOptions?: RequestOptions): Promise<RegistrationVerificationResponse>;
|
|
176
|
-
/**
|
|
177
|
-
* Evaluate if registration should be blocked based on geolocation verification
|
|
178
|
-
*
|
|
179
|
-
* Checks:
|
|
180
|
-
* 1. General compliance status (is_compliant)
|
|
181
|
-
* 2. Explicit block flag (is_blocked)
|
|
182
|
-
* 3. Jurisdiction-specific registration allowance (allow_registration)
|
|
183
|
-
* 4. Risk level thresholds
|
|
184
|
-
*
|
|
185
|
-
* @param geoVerification - Geolocation verification result
|
|
186
|
-
* @returns Array of block reasons (empty if allowed)
|
|
187
|
-
*/
|
|
188
|
-
private evaluateRegistrationBlock;
|
|
189
|
-
/**
|
|
190
|
-
* Validate registration request has all required fields
|
|
191
|
-
*
|
|
192
|
-
* @param request - Registration request to validate
|
|
193
|
-
* @throws ValidationError if required fields are missing or invalid
|
|
194
|
-
*/
|
|
195
|
-
private validateRegistrationRequest;
|
|
196
|
-
/**
|
|
197
|
-
* Validate IP address format (IPv4 or IPv6)
|
|
198
|
-
*/
|
|
199
|
-
private isValidIP;
|
|
200
|
-
/**
|
|
201
|
-
* Validate email address format
|
|
202
|
-
*/
|
|
203
|
-
private isValidEmail;
|
|
204
|
-
private validateLoginRequest;
|
|
205
|
-
private validateTransactionRequest;
|
|
206
|
-
private validateEventRequest;
|
|
207
|
-
/**
|
|
208
|
-
* Verify customer login with profile activity update
|
|
209
|
-
*
|
|
210
|
-
* Verifies geolocation and updates customer profile with latest activity.
|
|
211
|
-
*
|
|
212
|
-
* @param request - Login verification request
|
|
213
|
-
* @returns Verification response with compliance status
|
|
214
|
-
*
|
|
215
|
-
* @example
|
|
216
|
-
* ```typescript
|
|
217
|
-
* const result = await sdk.verifyAtLogin({
|
|
218
|
-
* customerId: 'CUST-12345',
|
|
219
|
-
* ipAddress: req.ip,
|
|
220
|
-
* deviceFingerprint: getDeviceFingerprint()
|
|
221
|
-
* });
|
|
222
|
-
*
|
|
223
|
-
* if (result.allowed) {
|
|
224
|
-
* // Allow login
|
|
225
|
-
* if (result.requiresStepUp) {
|
|
226
|
-
* // Trigger MFA or additional verification
|
|
227
|
-
* }
|
|
228
|
-
* } else {
|
|
229
|
-
* // Block login
|
|
230
|
-
* console.log('Blocked:', result.blockReasons);
|
|
231
|
-
* }
|
|
232
|
-
* ```
|
|
233
|
-
*/
|
|
234
|
-
verifyAtLogin(request: LoginVerificationRequest, requestOptions?: RequestOptions): Promise<LoginVerificationResponse>;
|
|
235
|
-
/**
|
|
236
|
-
* Verify transaction with amount-based risk assessment
|
|
237
|
-
*
|
|
238
|
-
* Combines geolocation verification with transaction amount analysis
|
|
239
|
-
* and customer risk profile for comprehensive transaction screening.
|
|
240
|
-
*
|
|
241
|
-
* @param request - Transaction verification request
|
|
242
|
-
* @returns Verification response with transaction risk assessment
|
|
243
|
-
*
|
|
244
|
-
* @example
|
|
245
|
-
* ```typescript
|
|
246
|
-
* const result = await sdk.verifyAtTransaction({
|
|
247
|
-
* customerId: 'CUST-12345',
|
|
248
|
-
* ipAddress: req.ip,
|
|
249
|
-
* amount: 5000,
|
|
250
|
-
* currency: 'USD',
|
|
251
|
-
* transactionType: 'withdrawal',
|
|
252
|
-
* deviceFingerprint: getDeviceFingerprint()
|
|
253
|
-
* });
|
|
254
|
-
*
|
|
255
|
-
* if (result.allowed) {
|
|
256
|
-
* // Process transaction
|
|
257
|
-
* } else if (result.requiresApproval) {
|
|
258
|
-
* // Queue for manual review
|
|
259
|
-
* } else {
|
|
260
|
-
* // Block transaction
|
|
261
|
-
* console.log('Blocked:', result.blockReasons);
|
|
262
|
-
* }
|
|
263
|
-
* ```
|
|
264
|
-
*/
|
|
265
|
-
verifyAtTransaction(request: TransactionVerificationRequest, requestOptions?: RequestOptions): Promise<TransactionVerificationResponse>;
|
|
266
|
-
/**
|
|
267
|
-
* Generic event verification (for other touchpoints)
|
|
268
|
-
*
|
|
269
|
-
* @param request - Event verification request
|
|
270
|
-
* @returns Verification response
|
|
271
|
-
*/
|
|
272
|
-
verifyEvent(request: EventVerificationRequest, requestOptions?: RequestOptions): Promise<EventVerificationResponse>;
|
|
273
|
-
private shouldUpdateProfile;
|
|
274
|
-
private createProfileFromGeo;
|
|
275
|
-
/**
|
|
276
|
-
* Execute cipherText validation with graceful degradation.
|
|
277
|
-
* Returns undefined if cipherText is not provided or validation fails.
|
|
278
|
-
*/
|
|
279
|
-
private executeCipherTextValidation;
|
|
280
|
-
/**
|
|
281
|
-
* Build a LocationVerification from a ValidateCipherTextResponse.
|
|
282
|
-
* The validate-ciphertext endpoint now returns the full geo-verification data
|
|
283
|
-
* (is_compliant, jurisdiction, geofence_evaluation, record_id, gps_required),
|
|
284
|
-
* so a separate verifyIP call is unnecessary.
|
|
285
|
-
*/
|
|
286
|
-
private buildLocationFromCipherText;
|
|
287
|
-
private calculateTransactionRisk;
|
|
288
|
-
private checkJurisdictionLimits;
|
|
289
|
-
private normalizeToUSD;
|
|
290
|
-
private getRiskLevel;
|
|
291
|
-
private getBlockReasons;
|
|
292
|
-
private getTransactionBlockReasons;
|
|
293
|
-
/**
|
|
294
|
-
* Request live location from a customer
|
|
295
|
-
*
|
|
296
|
-
* Creates a location request and sends a notification to the customer
|
|
297
|
-
* via the specified channel (SMS, email, or push). The customer receives
|
|
298
|
-
* a link to share their location.
|
|
299
|
-
*
|
|
300
|
-
* @param input - Location request details
|
|
301
|
-
* @returns Location request result with share link
|
|
302
|
-
*
|
|
303
|
-
* @example
|
|
304
|
-
* ```typescript
|
|
305
|
-
* // Request location via SMS for transaction verification
|
|
306
|
-
* const result = await sdk.requestCustomerLocation({
|
|
307
|
-
* customerId: 'CUST-12345',
|
|
308
|
-
* channel: 'sms',
|
|
309
|
-
* phone: '+1234567890',
|
|
310
|
-
* reason: 'Verification required for high-value transaction'
|
|
311
|
-
* });
|
|
312
|
-
*
|
|
313
|
-
* console.log('Share link sent:', result.shareLink);
|
|
314
|
-
* console.log('Expires at:', result.tokenExpiry);
|
|
315
|
-
*
|
|
316
|
-
* // Request location via email
|
|
317
|
-
* const emailResult = await sdk.requestCustomerLocation({
|
|
318
|
-
* customerId: 'CUST-12345',
|
|
319
|
-
* channel: 'email',
|
|
320
|
-
* email: 'customer@example.com',
|
|
321
|
-
* reason: 'Account verification',
|
|
322
|
-
* expiryHours: 48
|
|
323
|
-
* });
|
|
324
|
-
* ```
|
|
325
|
-
*/
|
|
326
|
-
requestCustomerLocation(input: ComplianceLocationRequestInput, requestOptions?: RequestOptions): Promise<ComplianceLocationRequestResult>;
|
|
327
|
-
/**
|
|
328
|
-
* Get a specific location request by ID
|
|
329
|
-
*
|
|
330
|
-
* @param requestId - Location request ID
|
|
331
|
-
* @returns Location request details
|
|
332
|
-
*
|
|
333
|
-
* @example
|
|
334
|
-
* ```typescript
|
|
335
|
-
* const request = await sdk.getLocationRequest('req_abc123');
|
|
336
|
-
* console.log('Status:', request.status);
|
|
337
|
-
* if (request.latitude && request.longitude) {
|
|
338
|
-
* console.log('Location captured:', request.latitude, request.longitude);
|
|
339
|
-
* }
|
|
340
|
-
* ```
|
|
341
|
-
*/
|
|
342
|
-
getLocationRequest(requestId: string, requestOptions?: RequestOptions): Promise<LocationRequest>;
|
|
343
|
-
/**
|
|
344
|
-
* List location requests with filters and pagination
|
|
345
|
-
*
|
|
346
|
-
* @param filters - Optional filters
|
|
347
|
-
* @param pagination - Optional pagination
|
|
348
|
-
* @returns Paginated list of location requests
|
|
349
|
-
*
|
|
350
|
-
* @example
|
|
351
|
-
* ```typescript
|
|
352
|
-
* // Get pending requests for a customer
|
|
353
|
-
* const pending = await sdk.listLocationRequests(
|
|
354
|
-
* { status: 'pending', user_id: 'CUST-12345' },
|
|
355
|
-
* { page: 1, limit: 20 }
|
|
356
|
-
* );
|
|
357
|
-
*
|
|
358
|
-
* // Get all completed requests from last week
|
|
359
|
-
* const completed = await sdk.listLocationRequests({
|
|
360
|
-
* status: 'completed',
|
|
361
|
-
* date_from: new Date(Date.now() - 7 * 24 * 60 * 60 * 1000).toISOString()
|
|
362
|
-
* });
|
|
363
|
-
* ```
|
|
364
|
-
*/
|
|
365
|
-
listLocationRequests(filters?: LocationRequestFilters, pagination?: PaginationParams, requestOptions?: RequestOptions): Promise<LocationRequestListResponse>;
|
|
366
|
-
/**
|
|
367
|
-
* Cancel a pending location request
|
|
368
|
-
*
|
|
369
|
-
* @param requestId - Location request ID
|
|
370
|
-
*
|
|
371
|
-
* @example
|
|
372
|
-
* ```typescript
|
|
373
|
-
* await sdk.cancelLocationRequest('req_abc123');
|
|
374
|
-
* ```
|
|
375
|
-
*/
|
|
376
|
-
cancelLocationRequest(requestId: string, requestOptions?: RequestOptions): Promise<void>;
|
|
377
|
-
/**
|
|
378
|
-
* Resend notification for a location request
|
|
379
|
-
*
|
|
380
|
-
* @param requestId - Location request ID
|
|
381
|
-
* @param contact - Contact details (email or phone)
|
|
382
|
-
*
|
|
383
|
-
* @example
|
|
384
|
-
* ```typescript
|
|
385
|
-
* // Resend to a different phone number
|
|
386
|
-
* await sdk.resendLocationRequest('req_abc123', { phone: '+0987654321' });
|
|
387
|
-
*
|
|
388
|
-
* // Resend to email
|
|
389
|
-
* await sdk.resendLocationRequest('req_abc123', { email: 'new@example.com' });
|
|
390
|
-
* ```
|
|
391
|
-
*/
|
|
392
|
-
resendLocationRequest(requestId: string, contact: {
|
|
393
|
-
email?: string;
|
|
394
|
-
phone?: string;
|
|
395
|
-
}, requestOptions?: RequestOptions): Promise<void>;
|
|
396
|
-
/**
|
|
397
|
-
* Validate location request input
|
|
398
|
-
*/
|
|
399
|
-
private validateLocationRequestInput;
|
|
400
|
-
/**
|
|
401
|
-
* Update currency exchange rates
|
|
402
|
-
*
|
|
403
|
-
* Use this to keep currency rates current for accurate transaction risk
|
|
404
|
-
* calculation. Rates should be updated regularly (e.g., daily).
|
|
405
|
-
*
|
|
406
|
-
* @param rates - Currency to USD exchange rates
|
|
407
|
-
*
|
|
408
|
-
* @example
|
|
409
|
-
* ```typescript
|
|
410
|
-
* // Update specific rates
|
|
411
|
-
* sdk.updateCurrencyRates({
|
|
412
|
-
* EUR: 1.08,
|
|
413
|
-
* GBP: 1.25,
|
|
414
|
-
* BTC: 42000, // For crypto support
|
|
415
|
-
* });
|
|
416
|
-
*
|
|
417
|
-
* // Or fetch from external service
|
|
418
|
-
* const rates = await fetchExchangeRates();
|
|
419
|
-
* sdk.updateCurrencyRates(rates);
|
|
420
|
-
* ```
|
|
421
|
-
*/
|
|
422
|
-
updateCurrencyRates(rates: CurrencyRates): void;
|
|
423
|
-
/**
|
|
424
|
-
* Get current currency rates
|
|
425
|
-
*
|
|
426
|
-
* @returns Current currency to USD exchange rates
|
|
427
|
-
*/
|
|
428
|
-
getCurrencyRates(): Readonly<CurrencyRates>;
|
|
429
|
-
}
|
|
430
|
-
|
|
431
|
-
export { ComplianceClient, type ComplianceLocationRequestInput, type ComplianceLocationRequestResult, type CurrencyRates, DEFAULT_CURRENCY_RATES, type EventVerificationRequest, type EventVerificationResponse, LocationRequest, LocationRequestFilters, LocationRequestListResponse, type LoginVerificationRequest, type LoginVerificationResponse, type RegistrationVerificationRequest, type RegistrationVerificationResponse, type TransactionRiskResult, type TransactionVerificationRequest, type TransactionVerificationResponse };
|
|
27
|
+
export { sdkReasons };
|