@nexeraid/identity-schemas 2.87.0-dev → 2.88.0-dev

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 (38) hide show
  1. package/dist/{CoinMarketCap.schema-0eb79b31.cjs.prod.cjs → CoinMarketCap.schema-20fb43b4.cjs.prod.cjs} +2 -2
  2. package/dist/{CoinMarketCap.schema-92a79ab4.esm.mjs → CoinMarketCap.schema-2522156d.esm.mjs} +2 -2
  3. package/dist/{CoinMarketCap.schema-84c8a41f.cjs.dev.cjs → CoinMarketCap.schema-b5d9d48a.cjs.dev.cjs} +2 -2
  4. package/dist/declarations/src/identity/scenario.schema.d.ts +49 -49
  5. package/dist/declarations/src/identity/scenario.schema.d.ts.map +1 -1
  6. package/dist/declarations/src/identity-ids.schema.d.ts +6 -6
  7. package/dist/declarations/src/identity-ids.schema.d.ts.map +1 -1
  8. package/dist/declarations/src/tag.schema.d.ts +10 -3
  9. package/dist/declarations/src/tag.schema.d.ts.map +1 -1
  10. package/dist/{identity-api.schema-aeb16160.cjs.prod.cjs → identity-api.schema-25a40938.cjs.prod.cjs} +83 -124
  11. package/dist/{identity-api.schema-827b2a5a.cjs.dev.cjs → identity-api.schema-4670c94c.cjs.dev.cjs} +83 -124
  12. package/dist/{identity-api.schema-56adcbaf.esm.mjs → identity-api.schema-bdf74232.esm.mjs} +84 -111
  13. package/dist/nexeraid-identity-schemas.cjs.dev.cjs +19 -8
  14. package/dist/nexeraid-identity-schemas.cjs.prod.cjs +19 -8
  15. package/dist/nexeraid-identity-schemas.esm.mjs +17 -8
  16. package/dist/package.json +1 -1
  17. package/dist/{tfhe-utilities-1f40b92c.esm.mjs → tfhe-utilities-9a4bc5f6.esm.mjs} +2 -2
  18. package/dist/{tfhe-utilities-3bdff509.cjs.prod.cjs → tfhe-utilities-be752443.cjs.prod.cjs} +2 -2
  19. package/dist/{tfhe-utilities-adeee443.cjs.dev.cjs → tfhe-utilities-d05b2a83.cjs.dev.cjs} +2 -2
  20. package/dist/{vault.schema-adc69a50.esm.mjs → vault.schema-06c7ebc0.esm.mjs} +3 -3
  21. package/dist/{vault.schema-71f81a22.cjs.prod.cjs → vault.schema-771644cb.cjs.prod.cjs} +4 -4
  22. package/dist/{vault.schema-dae54fc4.cjs.dev.cjs → vault.schema-94ffd2d8.cjs.dev.cjs} +4 -4
  23. package/identity/dist/nexeraid-identity-schemas-identity.cjs.dev.cjs +2 -2
  24. package/identity/dist/nexeraid-identity-schemas-identity.cjs.prod.cjs +2 -2
  25. package/identity/dist/nexeraid-identity-schemas-identity.esm.mjs +2 -2
  26. package/package.json +1 -1
  27. package/providers/dist/nexeraid-identity-schemas-providers.cjs.dev.cjs +3 -3
  28. package/providers/dist/nexeraid-identity-schemas-providers.cjs.prod.cjs +3 -3
  29. package/providers/dist/nexeraid-identity-schemas-providers.esm.mjs +3 -3
  30. package/vault/dist/nexeraid-identity-schemas-vault.cjs.dev.cjs +1 -1
  31. package/vault/dist/nexeraid-identity-schemas-vault.cjs.prod.cjs +1 -1
  32. package/vault/dist/nexeraid-identity-schemas-vault.esm.mjs +1 -1
  33. package/verifiable-credentials/dist/nexeraid-identity-schemas-verifiable-credentials.cjs.dev.cjs +3 -3
  34. package/verifiable-credentials/dist/nexeraid-identity-schemas-verifiable-credentials.cjs.prod.cjs +3 -3
  35. package/verifiable-credentials/dist/nexeraid-identity-schemas-verifiable-credentials.esm.mjs +3 -3
  36. package/webhooks/dist/nexeraid-identity-schemas-webhooks.cjs.dev.cjs +48 -21
  37. package/webhooks/dist/nexeraid-identity-schemas-webhooks.cjs.prod.cjs +48 -21
  38. package/webhooks/dist/nexeraid-identity-schemas-webhooks.esm.mjs +31 -5
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var zod = require('zod');
4
- var vault_schema = require('./vault.schema-71f81a22.cjs.prod.cjs');
4
+ var vault_schema = require('./vault.schema-771644cb.cjs.prod.cjs');
5
5
 
6
6
  var CredentialSchemas = {
7
7
  ProofOfResidence: vault_schema.ProofOfResidenceCredentialSubjectSchema,
@@ -386,120 +386,13 @@ function oldCredentialPathToDataLink(path, credentialType) {
386
386
  };
387
387
  }
388
388
 
389
- // Risk Score
390
- var RiskScoreTypes = ["Low", "Medium", "High", "No risk"];
391
- var RiskScoreType = zod.z["enum"](RiskScoreTypes);
392
- // Customer Type
393
- var CustomerTypes = ["Individual", "Company"];
394
- var CustomerType = zod.z["enum"](CustomerTypes);
395
- // KYC Onboarding Level
396
- var KycOnboardingLevels = ["Sign-up", "AML screening", "KYC", "Questionaire", "Onboarded"];
397
- var KycOnboardingLevel = zod.z["enum"](KycOnboardingLevels);
398
- // KYB Onboarding Level
399
- var KybOnboardingLevels = ["Onboarding", "KYB", "Onboarded"];
400
- var KybOnboardingLevel = zod.z["enum"](KybOnboardingLevels);
401
- var CustomerOnboardingLevels = [].concat(KycOnboardingLevels, KybOnboardingLevels);
402
- var CustomerOnboardingLevel = zod.z["enum"](CustomerOnboardingLevels);
403
- // Customer Status
404
- var CustomerStatuses = ["Active", "Rejected", "Dormant", "To be reviewed", "Failed", "Escalated", "Terminated", "No status"];
405
- var CustomerStatus = zod.z["enum"](CustomerStatuses);
406
- var BasicCustomerContactInformation = zod.z.object({
407
- email: zod.z.string().email(),
408
- phone: zod.z.string().min(4),
409
- twitter: zod.z.string(),
410
- discord: zod.z.string(),
411
- telegram: zod.z.string()
412
- }).partial();
413
- var CUSTOMERS_CHARTS = ["totalCustomers", "onboarded", "active", "dormant", "rejected", "topCountriesByCustomersCount", "customersRiskLevel", "customersByStatus", "trendOfStatusesOverTime"];
414
- var CustomersChartType = zod.z["enum"](CUSTOMERS_CHARTS);
415
- var CUSTOMER_TABLE_COLUMNS = ["selected", "wallets", "type", "country_of_residence", "risk_score", "onboarding_level", "open_alerts_count", "status", "date_onboarded"];
416
- var CustomerTableColumn = zod.z["enum"](CUSTOMER_TABLE_COLUMNS);
417
- var CUSTOMER_AUTOMATION_REASONS = {
418
- "rule-engine": {
419
- fail: "Rules engine verification failed",
420
- pass: "Rules engine verification passed"
421
- },
422
- kyc: {
423
- green: {
424
- "final": "Passed KYC"
425
- },
426
- yellow: {
427
- retry: "User rejected by the KYC provider with possibility to retry",
428
- fail: "User rejected by the KYC provider"
429
- },
430
- red: {
431
- retry: "User rejected by the KYC provider with possibility to retry",
432
- fail: "User rejected by the KYC provider"
433
- }
434
- },
435
- kyb: {
436
- green: {
437
- "final": "Passed KYB"
438
- },
439
- yellow: {
440
- retry: "Company rejected by the KYB provider with possibility to retry",
441
- fail: "Company rejected by the KYB provider"
442
- },
443
- red: {
444
- retry: "Company rejected by the KYB provider with possibility to retry",
445
- fail: "Company rejected by the KYB provider"
446
- },
447
- beneficiaryOnToBeReviewState: "One or more beneficiaries are on 'To be reviewed' state"
448
- },
449
- "aml-screening": {
450
- fail: "AML screening hits received during onboarding",
451
- ongoingMonitoringFail: "AML screening hits received during ongoing monitoring",
452
- pass: "Passed AML screening"
453
- },
454
- offchain_zkp: {
455
- fail: "Offchain ZKP verification failed",
456
- pass: "Offchain ZKP verification passed"
457
- },
458
- tfhe: {
459
- fail: "TFHE verification failed",
460
- pass: "TFHE verification passed"
461
- }
462
- };
463
- var CustomerPersonalInformation = zod.z.object({
464
- age: zod.z.number().optional(),
465
- nationality: vault_schema.ISO3CountryCode.optional(),
466
- residence: vault_schema.ISO3CountryCode.optional()
467
- });
468
-
469
- // Alert Statuses
470
- var AlertStatuses = ["Open", "Under Investigation", "Pending", "Closed", "Escalated"];
471
- var AlertStatus = zod.z["enum"](AlertStatuses);
472
- // Alert Types
473
- var AlertTypes = ["AML Screening", "IP Screening", "Email Screening", "KYC Drop-off", "Onchain Monitoring", "Fraud", "Transaction Monitoring", "Duplicate", "Individual Monitoring"];
474
- var AlertType = zod.z["enum"](AlertTypes);
475
- // Alert Severities
476
- var AlertSeverities = ["Low", "Medium", "High"];
477
- var AlertSeverity = zod.z["enum"](AlertSeverities);
478
- // Alert Categories
479
- var AlertCategories = ["Onboarding", "Ongoing monitoring"];
480
- var AlertCategory = zod.z["enum"](AlertCategories);
481
- var ALERT_CHART_TYPES = ["total", "new", "opened", "closed", "inProgress", "unassigned", "escalated", "overdue", "avgClosureTime", "ageOfOldest", "alertTrendsOverTime", "alertsByType", "ageOfOpenAlerts", "alertsPerOfficer", "alertsSeverity"];
482
- var AlertChartType = zod.z["enum"](ALERT_CHART_TYPES);
483
- var ALERT_TABLE_COLUMNS = ["selected", "createdAt", "overdue", "id", "severity", "type", "description", "assignedTo", "country", "status"];
484
- var AlertTableColumn = zod.z["enum"](ALERT_TABLE_COLUMNS);
485
- var UserInfoForDuplicate = zod.z.object({
486
- customerId: vault_schema.UuidString,
487
- customerInfo: zod.z.string().nullish(),
488
- profilePicture: zod.z.string().nullish(),
489
- idDocumentUrl: zod.z.string().nullish()
490
- });
491
- var DuplicateData = zod.z.object({
492
- original: UserInfoForDuplicate,
493
- duplicate: UserInfoForDuplicate
494
- });
495
-
496
- var SCENARIO_ACTION_TYPES = ["SET_CUSTOMER_RISK_LEVEL", "SET_CUSTOMER_STATUS", "SET_ALERT_RISK_LEVEL", "SET_TRANSACTION_RISK_LEVEL", "SET_TRANSACTION_STATUS", "ASSIGN_COMPLIANCE_OFFICER", "CREATE_ALERT"];
389
+ var SCENARIO_ACTION_TYPES = ["SET_CUSTOMER_RISK_LEVEL", "SET_CUSTOMER_STATUS", "SET_ALERT_RISK_LEVEL", "SET_TRANSACTION_RISK_LEVEL", "SET_TRANSACTION_STATUS", "ASSIGN_COMPLIANCE_OFFICER", "CREATE_ALERT", "ASSIGN_TAG"];
497
390
  var ActionType = zod.z["enum"](SCENARIO_ACTION_TYPES);
498
391
  var ACTION_TRIGGERS = ["ON_TRUE", "ON_FALSE", "ALWAYS"];
499
392
  var ActionTrigger = zod.z["enum"](ACTION_TRIGGERS);
500
393
  var ACTION_STATUSES = ["ENABLED", "DISABLED"];
501
394
  var ActionStatus = zod.z["enum"](ACTION_STATUSES);
502
- var ActionValue = zod.z.union([RiskScoreType, CustomerStatus, vault_schema.TransactionReviewStatus, AlertType]);
395
+ var ActionValue = zod.z.string();
503
396
  var ScenarioTypes = ["PrivacyPreservingMonitoring", "IndividualMonitoring", "TransactionMonitoring", "TFHE" // TODO integrate TFHE verification
504
397
  ];
505
398
  var ScenarioType = zod.z["enum"](ScenarioTypes);
@@ -945,6 +838,86 @@ var GetTxAuthSigResponseTezos = zod.z.object({
945
838
  var HostRequestMessage = zod.z.union([GetCredentialsRequest, PolygonIdRequest, StartFlowRequest, IsVerifiedRequest, GetTxAuthSigRequest, GetTxAuthSigRequestTezos]);
946
839
  var IdentityResponseMessage = zod.z.union([GetCredentialsResponse, PolygonIdResponse, IsVerifiedResponse, GetTxAuthSigResponse, GetTxAuthSigResponseTezos]);
947
840
 
841
+ // Risk Score
842
+ var RiskScoreTypes = ["Low", "Medium", "High", "No risk"];
843
+ var RiskScoreType = zod.z["enum"](RiskScoreTypes);
844
+ // Customer Type
845
+ var CustomerTypes = ["Individual", "Company"];
846
+ var CustomerType = zod.z["enum"](CustomerTypes);
847
+ // KYC Onboarding Level
848
+ var KycOnboardingLevels = ["Sign-up", "AML screening", "KYC", "Questionaire", "Onboarded"];
849
+ var KycOnboardingLevel = zod.z["enum"](KycOnboardingLevels);
850
+ // KYB Onboarding Level
851
+ var KybOnboardingLevels = ["Onboarding", "KYB", "Onboarded"];
852
+ var KybOnboardingLevel = zod.z["enum"](KybOnboardingLevels);
853
+ var CustomerOnboardingLevels = [].concat(KycOnboardingLevels, KybOnboardingLevels);
854
+ var CustomerOnboardingLevel = zod.z["enum"](CustomerOnboardingLevels);
855
+ // Customer Status
856
+ var CustomerStatuses = ["Active", "Rejected", "Dormant", "To be reviewed", "Failed", "Escalated", "Terminated", "No status"];
857
+ var CustomerStatus = zod.z["enum"](CustomerStatuses);
858
+ var BasicCustomerContactInformation = zod.z.object({
859
+ email: zod.z.string().email(),
860
+ phone: zod.z.string().min(4),
861
+ twitter: zod.z.string(),
862
+ discord: zod.z.string(),
863
+ telegram: zod.z.string()
864
+ }).partial();
865
+ var CUSTOMERS_CHARTS = ["totalCustomers", "onboarded", "active", "dormant", "rejected", "topCountriesByCustomersCount", "customersRiskLevel", "customersByStatus", "trendOfStatusesOverTime"];
866
+ var CustomersChartType = zod.z["enum"](CUSTOMERS_CHARTS);
867
+ var CUSTOMER_TABLE_COLUMNS = ["selected", "wallets", "type", "country_of_residence", "risk_score", "onboarding_level", "open_alerts_count", "status", "date_onboarded"];
868
+ var CustomerTableColumn = zod.z["enum"](CUSTOMER_TABLE_COLUMNS);
869
+ var CUSTOMER_AUTOMATION_REASONS = {
870
+ "rule-engine": {
871
+ fail: "Rules engine verification failed",
872
+ pass: "Rules engine verification passed"
873
+ },
874
+ kyc: {
875
+ green: {
876
+ "final": "Passed KYC"
877
+ },
878
+ yellow: {
879
+ retry: "User rejected by the KYC provider with possibility to retry",
880
+ fail: "User rejected by the KYC provider"
881
+ },
882
+ red: {
883
+ retry: "User rejected by the KYC provider with possibility to retry",
884
+ fail: "User rejected by the KYC provider"
885
+ }
886
+ },
887
+ kyb: {
888
+ green: {
889
+ "final": "Passed KYB"
890
+ },
891
+ yellow: {
892
+ retry: "Company rejected by the KYB provider with possibility to retry",
893
+ fail: "Company rejected by the KYB provider"
894
+ },
895
+ red: {
896
+ retry: "Company rejected by the KYB provider with possibility to retry",
897
+ fail: "Company rejected by the KYB provider"
898
+ },
899
+ beneficiaryOnToBeReviewState: "One or more beneficiaries are on 'To be reviewed' state"
900
+ },
901
+ "aml-screening": {
902
+ fail: "AML screening hits received during onboarding",
903
+ ongoingMonitoringFail: "AML screening hits received during ongoing monitoring",
904
+ pass: "Passed AML screening"
905
+ },
906
+ offchain_zkp: {
907
+ fail: "Offchain ZKP verification failed",
908
+ pass: "Offchain ZKP verification passed"
909
+ },
910
+ tfhe: {
911
+ fail: "TFHE verification failed",
912
+ pass: "TFHE verification passed"
913
+ }
914
+ };
915
+ var CustomerPersonalInformation = zod.z.object({
916
+ age: zod.z.number().optional(),
917
+ nationality: vault_schema.ISO3CountryCode.optional(),
918
+ residence: vault_schema.ISO3CountryCode.optional()
919
+ });
920
+
948
921
  /**
949
922
  * Wallet challenge parameters
950
923
  */
@@ -1171,8 +1144,6 @@ var VerifyWalletChallengeRequest = WalletSignatureResponse.and(zod.z.object({
1171
1144
 
1172
1145
  exports.ACTION_STATUSES = ACTION_STATUSES;
1173
1146
  exports.ACTION_TRIGGERS = ACTION_TRIGGERS;
1174
- exports.ALERT_CHART_TYPES = ALERT_CHART_TYPES;
1175
- exports.ALERT_TABLE_COLUMNS = ALERT_TABLE_COLUMNS;
1176
1147
  exports.ARRAY_OPERATORS = ARRAY_OPERATORS;
1177
1148
  exports.AUTHORIZATION_REQUEST_MESSAGE_TYPES = AUTHORIZATION_REQUEST_MESSAGE_TYPES;
1178
1149
  exports.AVAILABLE_FLOWS = AVAILABLE_FLOWS;
@@ -1182,16 +1153,6 @@ exports.ActionStatus = ActionStatus;
1182
1153
  exports.ActionTrigger = ActionTrigger;
1183
1154
  exports.ActionType = ActionType;
1184
1155
  exports.ActionValue = ActionValue;
1185
- exports.AlertCategories = AlertCategories;
1186
- exports.AlertCategory = AlertCategory;
1187
- exports.AlertChartType = AlertChartType;
1188
- exports.AlertSeverities = AlertSeverities;
1189
- exports.AlertSeverity = AlertSeverity;
1190
- exports.AlertStatus = AlertStatus;
1191
- exports.AlertStatuses = AlertStatuses;
1192
- exports.AlertTableColumn = AlertTableColumn;
1193
- exports.AlertType = AlertType;
1194
- exports.AlertTypes = AlertTypes;
1195
1156
  exports.AllCredentialValues = AllCredentialValues;
1196
1157
  exports.AllScenarioExecutionAuthorizationData = AllScenarioExecutionAuthorizationData;
1197
1158
  exports.AnyTxAuthDataSignatureResponse = AnyTxAuthDataSignatureResponse;
@@ -1242,7 +1203,6 @@ exports.CustomersChartType = CustomersChartType;
1242
1203
  exports.DATE_OPERATORS = DATE_OPERATORS;
1243
1204
  exports.DataAvailableOnStart = DataAvailableOnStart;
1244
1205
  exports.DateOperator = DateOperator;
1245
- exports.DuplicateData = DuplicateData;
1246
1206
  exports.Eip155TxAuthInputJsSdk = Eip155TxAuthInputJsSdk;
1247
1207
  exports.ExecuteQueryResponse = ExecuteQueryResponse;
1248
1208
  exports.ExtendedTezosTxAuthDataSignatureResponse = ExtendedTezosTxAuthDataSignatureResponse;
@@ -1369,7 +1329,6 @@ exports.TxAuthDataSignatureGatingRequest = TxAuthDataSignatureGatingRequest;
1369
1329
  exports.TxAuthDataSignatureResponse = TxAuthDataSignatureResponse;
1370
1330
  exports.TxAuthInput = TxAuthInput;
1371
1331
  exports.TxSignatureResponse = TxSignatureResponse;
1372
- exports.UserInfoForDuplicate = UserInfoForDuplicate;
1373
1332
  exports.VerifiableCredential = VerifiableCredential;
1374
1333
  exports.VerificationOutput = VerificationOutput;
1375
1334
  exports.VerificationSessionStatus = VerificationSessionStatus;
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var zod = require('zod');
4
- var vault_schema = require('./vault.schema-dae54fc4.cjs.dev.cjs');
4
+ var vault_schema = require('./vault.schema-94ffd2d8.cjs.dev.cjs');
5
5
 
6
6
  var CredentialSchemas = {
7
7
  ProofOfResidence: vault_schema.ProofOfResidenceCredentialSubjectSchema,
@@ -386,120 +386,13 @@ function oldCredentialPathToDataLink(path, credentialType) {
386
386
  };
387
387
  }
388
388
 
389
- // Risk Score
390
- var RiskScoreTypes = ["Low", "Medium", "High", "No risk"];
391
- var RiskScoreType = zod.z["enum"](RiskScoreTypes);
392
- // Customer Type
393
- var CustomerTypes = ["Individual", "Company"];
394
- var CustomerType = zod.z["enum"](CustomerTypes);
395
- // KYC Onboarding Level
396
- var KycOnboardingLevels = ["Sign-up", "AML screening", "KYC", "Questionaire", "Onboarded"];
397
- var KycOnboardingLevel = zod.z["enum"](KycOnboardingLevels);
398
- // KYB Onboarding Level
399
- var KybOnboardingLevels = ["Onboarding", "KYB", "Onboarded"];
400
- var KybOnboardingLevel = zod.z["enum"](KybOnboardingLevels);
401
- var CustomerOnboardingLevels = [].concat(KycOnboardingLevels, KybOnboardingLevels);
402
- var CustomerOnboardingLevel = zod.z["enum"](CustomerOnboardingLevels);
403
- // Customer Status
404
- var CustomerStatuses = ["Active", "Rejected", "Dormant", "To be reviewed", "Failed", "Escalated", "Terminated", "No status"];
405
- var CustomerStatus = zod.z["enum"](CustomerStatuses);
406
- var BasicCustomerContactInformation = zod.z.object({
407
- email: zod.z.string().email(),
408
- phone: zod.z.string().min(4),
409
- twitter: zod.z.string(),
410
- discord: zod.z.string(),
411
- telegram: zod.z.string()
412
- }).partial();
413
- var CUSTOMERS_CHARTS = ["totalCustomers", "onboarded", "active", "dormant", "rejected", "topCountriesByCustomersCount", "customersRiskLevel", "customersByStatus", "trendOfStatusesOverTime"];
414
- var CustomersChartType = zod.z["enum"](CUSTOMERS_CHARTS);
415
- var CUSTOMER_TABLE_COLUMNS = ["selected", "wallets", "type", "country_of_residence", "risk_score", "onboarding_level", "open_alerts_count", "status", "date_onboarded"];
416
- var CustomerTableColumn = zod.z["enum"](CUSTOMER_TABLE_COLUMNS);
417
- var CUSTOMER_AUTOMATION_REASONS = {
418
- "rule-engine": {
419
- fail: "Rules engine verification failed",
420
- pass: "Rules engine verification passed"
421
- },
422
- kyc: {
423
- green: {
424
- "final": "Passed KYC"
425
- },
426
- yellow: {
427
- retry: "User rejected by the KYC provider with possibility to retry",
428
- fail: "User rejected by the KYC provider"
429
- },
430
- red: {
431
- retry: "User rejected by the KYC provider with possibility to retry",
432
- fail: "User rejected by the KYC provider"
433
- }
434
- },
435
- kyb: {
436
- green: {
437
- "final": "Passed KYB"
438
- },
439
- yellow: {
440
- retry: "Company rejected by the KYB provider with possibility to retry",
441
- fail: "Company rejected by the KYB provider"
442
- },
443
- red: {
444
- retry: "Company rejected by the KYB provider with possibility to retry",
445
- fail: "Company rejected by the KYB provider"
446
- },
447
- beneficiaryOnToBeReviewState: "One or more beneficiaries are on 'To be reviewed' state"
448
- },
449
- "aml-screening": {
450
- fail: "AML screening hits received during onboarding",
451
- ongoingMonitoringFail: "AML screening hits received during ongoing monitoring",
452
- pass: "Passed AML screening"
453
- },
454
- offchain_zkp: {
455
- fail: "Offchain ZKP verification failed",
456
- pass: "Offchain ZKP verification passed"
457
- },
458
- tfhe: {
459
- fail: "TFHE verification failed",
460
- pass: "TFHE verification passed"
461
- }
462
- };
463
- var CustomerPersonalInformation = zod.z.object({
464
- age: zod.z.number().optional(),
465
- nationality: vault_schema.ISO3CountryCode.optional(),
466
- residence: vault_schema.ISO3CountryCode.optional()
467
- });
468
-
469
- // Alert Statuses
470
- var AlertStatuses = ["Open", "Under Investigation", "Pending", "Closed", "Escalated"];
471
- var AlertStatus = zod.z["enum"](AlertStatuses);
472
- // Alert Types
473
- var AlertTypes = ["AML Screening", "IP Screening", "Email Screening", "KYC Drop-off", "Onchain Monitoring", "Fraud", "Transaction Monitoring", "Duplicate", "Individual Monitoring"];
474
- var AlertType = zod.z["enum"](AlertTypes);
475
- // Alert Severities
476
- var AlertSeverities = ["Low", "Medium", "High"];
477
- var AlertSeverity = zod.z["enum"](AlertSeverities);
478
- // Alert Categories
479
- var AlertCategories = ["Onboarding", "Ongoing monitoring"];
480
- var AlertCategory = zod.z["enum"](AlertCategories);
481
- var ALERT_CHART_TYPES = ["total", "new", "opened", "closed", "inProgress", "unassigned", "escalated", "overdue", "avgClosureTime", "ageOfOldest", "alertTrendsOverTime", "alertsByType", "ageOfOpenAlerts", "alertsPerOfficer", "alertsSeverity"];
482
- var AlertChartType = zod.z["enum"](ALERT_CHART_TYPES);
483
- var ALERT_TABLE_COLUMNS = ["selected", "createdAt", "overdue", "id", "severity", "type", "description", "assignedTo", "country", "status"];
484
- var AlertTableColumn = zod.z["enum"](ALERT_TABLE_COLUMNS);
485
- var UserInfoForDuplicate = zod.z.object({
486
- customerId: vault_schema.UuidString,
487
- customerInfo: zod.z.string().nullish(),
488
- profilePicture: zod.z.string().nullish(),
489
- idDocumentUrl: zod.z.string().nullish()
490
- });
491
- var DuplicateData = zod.z.object({
492
- original: UserInfoForDuplicate,
493
- duplicate: UserInfoForDuplicate
494
- });
495
-
496
- var SCENARIO_ACTION_TYPES = ["SET_CUSTOMER_RISK_LEVEL", "SET_CUSTOMER_STATUS", "SET_ALERT_RISK_LEVEL", "SET_TRANSACTION_RISK_LEVEL", "SET_TRANSACTION_STATUS", "ASSIGN_COMPLIANCE_OFFICER", "CREATE_ALERT"];
389
+ var SCENARIO_ACTION_TYPES = ["SET_CUSTOMER_RISK_LEVEL", "SET_CUSTOMER_STATUS", "SET_ALERT_RISK_LEVEL", "SET_TRANSACTION_RISK_LEVEL", "SET_TRANSACTION_STATUS", "ASSIGN_COMPLIANCE_OFFICER", "CREATE_ALERT", "ASSIGN_TAG"];
497
390
  var ActionType = zod.z["enum"](SCENARIO_ACTION_TYPES);
498
391
  var ACTION_TRIGGERS = ["ON_TRUE", "ON_FALSE", "ALWAYS"];
499
392
  var ActionTrigger = zod.z["enum"](ACTION_TRIGGERS);
500
393
  var ACTION_STATUSES = ["ENABLED", "DISABLED"];
501
394
  var ActionStatus = zod.z["enum"](ACTION_STATUSES);
502
- var ActionValue = zod.z.union([RiskScoreType, CustomerStatus, vault_schema.TransactionReviewStatus, AlertType]);
395
+ var ActionValue = zod.z.string();
503
396
  var ScenarioTypes = ["PrivacyPreservingMonitoring", "IndividualMonitoring", "TransactionMonitoring", "TFHE" // TODO integrate TFHE verification
504
397
  ];
505
398
  var ScenarioType = zod.z["enum"](ScenarioTypes);
@@ -945,6 +838,86 @@ var GetTxAuthSigResponseTezos = zod.z.object({
945
838
  var HostRequestMessage = zod.z.union([GetCredentialsRequest, PolygonIdRequest, StartFlowRequest, IsVerifiedRequest, GetTxAuthSigRequest, GetTxAuthSigRequestTezos]);
946
839
  var IdentityResponseMessage = zod.z.union([GetCredentialsResponse, PolygonIdResponse, IsVerifiedResponse, GetTxAuthSigResponse, GetTxAuthSigResponseTezos]);
947
840
 
841
+ // Risk Score
842
+ var RiskScoreTypes = ["Low", "Medium", "High", "No risk"];
843
+ var RiskScoreType = zod.z["enum"](RiskScoreTypes);
844
+ // Customer Type
845
+ var CustomerTypes = ["Individual", "Company"];
846
+ var CustomerType = zod.z["enum"](CustomerTypes);
847
+ // KYC Onboarding Level
848
+ var KycOnboardingLevels = ["Sign-up", "AML screening", "KYC", "Questionaire", "Onboarded"];
849
+ var KycOnboardingLevel = zod.z["enum"](KycOnboardingLevels);
850
+ // KYB Onboarding Level
851
+ var KybOnboardingLevels = ["Onboarding", "KYB", "Onboarded"];
852
+ var KybOnboardingLevel = zod.z["enum"](KybOnboardingLevels);
853
+ var CustomerOnboardingLevels = [].concat(KycOnboardingLevels, KybOnboardingLevels);
854
+ var CustomerOnboardingLevel = zod.z["enum"](CustomerOnboardingLevels);
855
+ // Customer Status
856
+ var CustomerStatuses = ["Active", "Rejected", "Dormant", "To be reviewed", "Failed", "Escalated", "Terminated", "No status"];
857
+ var CustomerStatus = zod.z["enum"](CustomerStatuses);
858
+ var BasicCustomerContactInformation = zod.z.object({
859
+ email: zod.z.string().email(),
860
+ phone: zod.z.string().min(4),
861
+ twitter: zod.z.string(),
862
+ discord: zod.z.string(),
863
+ telegram: zod.z.string()
864
+ }).partial();
865
+ var CUSTOMERS_CHARTS = ["totalCustomers", "onboarded", "active", "dormant", "rejected", "topCountriesByCustomersCount", "customersRiskLevel", "customersByStatus", "trendOfStatusesOverTime"];
866
+ var CustomersChartType = zod.z["enum"](CUSTOMERS_CHARTS);
867
+ var CUSTOMER_TABLE_COLUMNS = ["selected", "wallets", "type", "country_of_residence", "risk_score", "onboarding_level", "open_alerts_count", "status", "date_onboarded"];
868
+ var CustomerTableColumn = zod.z["enum"](CUSTOMER_TABLE_COLUMNS);
869
+ var CUSTOMER_AUTOMATION_REASONS = {
870
+ "rule-engine": {
871
+ fail: "Rules engine verification failed",
872
+ pass: "Rules engine verification passed"
873
+ },
874
+ kyc: {
875
+ green: {
876
+ "final": "Passed KYC"
877
+ },
878
+ yellow: {
879
+ retry: "User rejected by the KYC provider with possibility to retry",
880
+ fail: "User rejected by the KYC provider"
881
+ },
882
+ red: {
883
+ retry: "User rejected by the KYC provider with possibility to retry",
884
+ fail: "User rejected by the KYC provider"
885
+ }
886
+ },
887
+ kyb: {
888
+ green: {
889
+ "final": "Passed KYB"
890
+ },
891
+ yellow: {
892
+ retry: "Company rejected by the KYB provider with possibility to retry",
893
+ fail: "Company rejected by the KYB provider"
894
+ },
895
+ red: {
896
+ retry: "Company rejected by the KYB provider with possibility to retry",
897
+ fail: "Company rejected by the KYB provider"
898
+ },
899
+ beneficiaryOnToBeReviewState: "One or more beneficiaries are on 'To be reviewed' state"
900
+ },
901
+ "aml-screening": {
902
+ fail: "AML screening hits received during onboarding",
903
+ ongoingMonitoringFail: "AML screening hits received during ongoing monitoring",
904
+ pass: "Passed AML screening"
905
+ },
906
+ offchain_zkp: {
907
+ fail: "Offchain ZKP verification failed",
908
+ pass: "Offchain ZKP verification passed"
909
+ },
910
+ tfhe: {
911
+ fail: "TFHE verification failed",
912
+ pass: "TFHE verification passed"
913
+ }
914
+ };
915
+ var CustomerPersonalInformation = zod.z.object({
916
+ age: zod.z.number().optional(),
917
+ nationality: vault_schema.ISO3CountryCode.optional(),
918
+ residence: vault_schema.ISO3CountryCode.optional()
919
+ });
920
+
948
921
  /**
949
922
  * Wallet challenge parameters
950
923
  */
@@ -1171,8 +1144,6 @@ var VerifyWalletChallengeRequest = WalletSignatureResponse.and(zod.z.object({
1171
1144
 
1172
1145
  exports.ACTION_STATUSES = ACTION_STATUSES;
1173
1146
  exports.ACTION_TRIGGERS = ACTION_TRIGGERS;
1174
- exports.ALERT_CHART_TYPES = ALERT_CHART_TYPES;
1175
- exports.ALERT_TABLE_COLUMNS = ALERT_TABLE_COLUMNS;
1176
1147
  exports.ARRAY_OPERATORS = ARRAY_OPERATORS;
1177
1148
  exports.AUTHORIZATION_REQUEST_MESSAGE_TYPES = AUTHORIZATION_REQUEST_MESSAGE_TYPES;
1178
1149
  exports.AVAILABLE_FLOWS = AVAILABLE_FLOWS;
@@ -1182,16 +1153,6 @@ exports.ActionStatus = ActionStatus;
1182
1153
  exports.ActionTrigger = ActionTrigger;
1183
1154
  exports.ActionType = ActionType;
1184
1155
  exports.ActionValue = ActionValue;
1185
- exports.AlertCategories = AlertCategories;
1186
- exports.AlertCategory = AlertCategory;
1187
- exports.AlertChartType = AlertChartType;
1188
- exports.AlertSeverities = AlertSeverities;
1189
- exports.AlertSeverity = AlertSeverity;
1190
- exports.AlertStatus = AlertStatus;
1191
- exports.AlertStatuses = AlertStatuses;
1192
- exports.AlertTableColumn = AlertTableColumn;
1193
- exports.AlertType = AlertType;
1194
- exports.AlertTypes = AlertTypes;
1195
1156
  exports.AllCredentialValues = AllCredentialValues;
1196
1157
  exports.AllScenarioExecutionAuthorizationData = AllScenarioExecutionAuthorizationData;
1197
1158
  exports.AnyTxAuthDataSignatureResponse = AnyTxAuthDataSignatureResponse;
@@ -1242,7 +1203,6 @@ exports.CustomersChartType = CustomersChartType;
1242
1203
  exports.DATE_OPERATORS = DATE_OPERATORS;
1243
1204
  exports.DataAvailableOnStart = DataAvailableOnStart;
1244
1205
  exports.DateOperator = DateOperator;
1245
- exports.DuplicateData = DuplicateData;
1246
1206
  exports.Eip155TxAuthInputJsSdk = Eip155TxAuthInputJsSdk;
1247
1207
  exports.ExecuteQueryResponse = ExecuteQueryResponse;
1248
1208
  exports.ExtendedTezosTxAuthDataSignatureResponse = ExtendedTezosTxAuthDataSignatureResponse;
@@ -1369,7 +1329,6 @@ exports.TxAuthDataSignatureGatingRequest = TxAuthDataSignatureGatingRequest;
1369
1329
  exports.TxAuthDataSignatureResponse = TxAuthDataSignatureResponse;
1370
1330
  exports.TxAuthInput = TxAuthInput;
1371
1331
  exports.TxSignatureResponse = TxSignatureResponse;
1372
- exports.UserInfoForDuplicate = UserInfoForDuplicate;
1373
1332
  exports.VerifiableCredential = VerifiableCredential;
1374
1333
  exports.VerificationOutput = VerificationOutput;
1375
1334
  exports.VerificationSessionStatus = VerificationSessionStatus;