@kushki/js 1.36.0 → 1.37.0

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 (76) hide show
  1. package/lib/Kushki.d.ts +17 -2
  2. package/lib/Kushki.js +132 -113
  3. package/lib/KushkiInfo.js +11 -14
  4. package/lib/constant/CreditCardEspecifications.js +2 -2
  5. package/lib/constant/Identifiers.js +21 -21
  6. package/lib/gateway/KushkiGateway.js +161 -276
  7. package/lib/gateway/SiftScience.js +42 -45
  8. package/lib/generic/AurusError.js +12 -28
  9. package/lib/generic/KushkiError.js +15 -33
  10. package/lib/infrastructure/BinCardTypeEnum.js +1 -1
  11. package/lib/infrastructure/CardBrandsEnum.d.ts +5 -0
  12. package/lib/infrastructure/CardBrandsEnum.js +8 -0
  13. package/lib/infrastructure/CognitoErrorEnum.js +1 -1
  14. package/lib/infrastructure/Container.js +41 -75
  15. package/lib/infrastructure/EnvironmentEnum.js +1 -1
  16. package/lib/infrastructure/ErrorEnum.d.ts +2 -1
  17. package/lib/infrastructure/ErrorEnum.js +42 -37
  18. package/lib/infrastructure/HeadersEnum.js +1 -1
  19. package/lib/infrastructure/KPayUserPoolEnum.js +1 -1
  20. package/lib/infrastructure/KpayPaymentKind.js +1 -1
  21. package/lib/infrastructure/PathEnum.js +1 -1
  22. package/lib/infrastructure/PlatformCodeEnum.js +15 -15
  23. package/lib/infrastructure/SiftScienceEnum.js +1 -1
  24. package/lib/infrastructure/StatusCodeEnum.js +1 -1
  25. package/lib/infrastructure/ThreeDSEnum.js +1 -1
  26. package/lib/infrastructure/VisaBrandingResourceUrlEnum.d.ts +2 -2
  27. package/lib/infrastructure/VisaBrandingResourceUrlEnum.js +3 -3
  28. package/lib/lib.js +1 -1
  29. package/lib/libs/MCSensoryBranding/mastercard-sensory-branding.d.ts +21 -0
  30. package/lib/libs/MCSensoryBranding/mastercard-sensory-branding.js +781 -0
  31. package/lib/libs/VisaSensoryBranding/visa-sensory-branding.d.ts +1 -1
  32. package/lib/libs/VisaSensoryBranding/visa-sensory-branding.js +630 -158
  33. package/lib/libs/cardinal/prod.js +10 -10
  34. package/lib/libs/cardinal/staging.js +9 -9
  35. package/lib/repository/IAntiFraud.js +1 -1
  36. package/lib/repository/IAuthService.js +1 -1
  37. package/lib/repository/ICardAsyncService.js +1 -1
  38. package/lib/repository/ICardDynamicService.js +1 -1
  39. package/lib/repository/ICardService.js +1 -1
  40. package/lib/repository/ICardSubscriptionDynamicService.js +1 -1
  41. package/lib/repository/ICashService.js +1 -1
  42. package/lib/repository/ICommissionService.js +1 -1
  43. package/lib/repository/IKPayService.js +1 -1
  44. package/lib/repository/IKushkiGateway.js +1 -1
  45. package/lib/repository/IKushkiService.d.ts +9 -2
  46. package/lib/repository/IKushkiService.js +1 -1
  47. package/lib/repository/IMobileProcessorService.js +1 -1
  48. package/lib/repository/IMultiMerchantService.js +1 -1
  49. package/lib/repository/IPayoutsCashService.js +1 -1
  50. package/lib/repository/IPayoutsTransferService.js +1 -1
  51. package/lib/repository/ISecureService.js +1 -1
  52. package/lib/repository/ISiftScienceService.js +1 -1
  53. package/lib/repository/ITransferService.js +1 -1
  54. package/lib/repository/ITransferSubscriptionService.js +1 -1
  55. package/lib/service/AuthService.js +99 -161
  56. package/lib/service/CardAsyncService.js +19 -26
  57. package/lib/service/CardDynamicService.js +32 -43
  58. package/lib/service/CardService.js +271 -382
  59. package/lib/service/CardSubscriptionDynamicService.js +31 -40
  60. package/lib/service/CashService.js +15 -16
  61. package/lib/service/CommissionService.js +13 -14
  62. package/lib/service/KPayService.js +19 -23
  63. package/lib/service/KushkiService.d.ts +2 -1
  64. package/lib/service/KushkiService.js +48 -33
  65. package/lib/service/MobileProcessorService.js +59 -70
  66. package/lib/service/MultiMerchantService.js +13 -14
  67. package/lib/service/PayoutsCashService.js +15 -16
  68. package/lib/service/PayoutsTransferService.js +17 -18
  69. package/lib/service/SecureService.js +13 -14
  70. package/lib/service/SiftScienceService.js +16 -20
  71. package/lib/service/TransferService.js +21 -36
  72. package/lib/service/TransferSubscriptionsService.js +16 -17
  73. package/lib/service/UtilsService.js +51 -57
  74. package/lib/types/card_branding_request.d.ts +40 -0
  75. package/lib/types/visa_branding_request.d.ts +25 -3
  76. package/package.json +2 -2
@@ -2,40 +2,24 @@
2
2
  /**
3
3
  * Generic Aurus Error Class resolver
4
4
  */
5
- var __extends = (this && this.__extends) || (function () {
6
- var extendStatics = function (d, b) {
7
- extendStatics = Object.setPrototypeOf ||
8
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
9
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
10
- return extendStatics(d, b);
11
- };
12
- return function (d, b) {
13
- extendStatics(d, b);
14
- function __() { this.constructor = d; }
15
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
16
- };
17
- })();
18
- exports.__esModule = true;
5
+ Object.defineProperty(exports, "__esModule", { value: true });
19
6
  exports.AurusError = void 0;
20
7
  /**
21
8
  * AurusError Generic captured error.
22
9
  */
23
- var AurusError = /** @class */ (function (_super) {
24
- __extends(AurusError, _super);
10
+ class AurusError extends Error {
25
11
  // istanbul ignore next
26
- function AurusError(code, message) {
27
- var _this = _super.call(this, "AURUS" + code) /* istanbul ignore next: TODO: reporter is failing */ || this;
28
- _this.code = code;
29
- _this._message = message;
30
- Object.setPrototypeOf(_this, AurusError.prototype);
31
- return _this;
12
+ constructor(code, message) {
13
+ super(`AURUS${code}`) /* istanbul ignore next: TODO: reporter is failing */;
14
+ this.code = code;
15
+ this._message = message;
16
+ Object.setPrototypeOf(this, AurusError.prototype);
32
17
  }
33
- AurusError.prototype.getMessage = function () {
18
+ getMessage() {
34
19
  return this._message;
35
- };
36
- AurusError.prototype.getStatusCode = function () {
20
+ }
21
+ getStatusCode() {
37
22
  return 400;
38
- };
39
- return AurusError;
40
- }(Error));
23
+ }
24
+ }
41
25
  exports.AurusError = AurusError;
@@ -1,44 +1,26 @@
1
1
  "use strict";
2
- var __extends = (this && this.__extends) || (function () {
3
- var extendStatics = function (d, b) {
4
- extendStatics = Object.setPrototypeOf ||
5
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
7
- return extendStatics(d, b);
8
- };
9
- return function (d, b) {
10
- extendStatics(d, b);
11
- function __() { this.constructor = d; }
12
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
13
- };
14
- })();
15
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
16
3
  exports.KushkiError = void 0;
17
4
  /**
18
5
  * KushkiError Generic captured error.
19
6
  */
20
- var KushkiError = /** @class */ (function (_super) {
21
- __extends(KushkiError, _super);
22
- function KushkiError(error, message) {
23
- if (message === void 0) { message = null; }
24
- var _this = this;
25
- var prefix = "K";
26
- var code = "" + prefix + error.code.replace("E", "");
27
- /* istanbul ignore next: TODO: reporter is failing */ _this = _super.call(this, code) || this;
28
- _this.code = code;
29
- _this._customMessage = message;
30
- _this._error = error;
31
- Object.setPrototypeOf(_this, KushkiError.prototype);
32
- return _this;
7
+ class KushkiError extends Error {
8
+ constructor(error, message = null) {
9
+ const prefix = "K";
10
+ const code = `${prefix}${error.code.replace("E", "")}`;
11
+ /* istanbul ignore next: TODO: reporter is failing */ super(code);
12
+ this.code = code;
13
+ this._customMessage = message;
14
+ this._error = error;
15
+ Object.setPrototypeOf(this, KushkiError.prototype);
33
16
  }
34
- KushkiError.prototype.getMessage = function () {
17
+ getMessage() {
35
18
  if (this._customMessage !== null)
36
19
  return this._customMessage;
37
20
  return this._error.message;
38
- };
39
- KushkiError.prototype.getStatusCode = function () {
21
+ }
22
+ getStatusCode() {
40
23
  return this._error.statusCode;
41
- };
42
- return KushkiError;
43
- }(Error));
24
+ }
25
+ }
44
26
  exports.KushkiError = KushkiError;
@@ -2,7 +2,7 @@
2
2
  /**
3
3
  * BinInfo cardType Enum
4
4
  */
5
- exports.__esModule = true;
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.BinCardTypeEnum = void 0;
7
7
  var BinCardTypeEnum;
8
8
  (function (BinCardTypeEnum) {
@@ -0,0 +1,5 @@
1
+ /* tslint:disable:all */
2
+ export declare enum CardBrandsEnum {
3
+ VISA = "visa",
4
+ MASTERCARD = "mastercard"
5
+ }
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CardBrandsEnum = void 0;
4
+ var CardBrandsEnum;
5
+ (function (CardBrandsEnum) {
6
+ CardBrandsEnum["VISA"] = "visa";
7
+ CardBrandsEnum["MASTERCARD"] = "mastercard";
8
+ })(CardBrandsEnum = exports.CardBrandsEnum || (exports.CardBrandsEnum = {}));
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.CognitoErrorEnum = void 0;
4
4
  var CognitoErrorEnum;
5
5
  (function (CognitoErrorEnum) {
@@ -1,84 +1,50 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.CONTAINER = void 0;
4
4
  /**
5
5
  * Container
6
6
  */
7
- var Identifiers_1 = require("./../../lib/constant/Identifiers");
8
- var KushkiGateway_1 = require("./../../lib/gateway/KushkiGateway");
9
- var SiftScience_1 = require("./../../lib/gateway/SiftScience");
10
- var inversify_1 = require("inversify");
11
- var AuthService_1 = require("./../../lib/service/AuthService");
12
- var CardAsyncService_1 = require("./../../lib/service/CardAsyncService");
13
- var CardDynamicService_1 = require("./../../lib/service/CardDynamicService");
14
- var CardService_1 = require("./../../lib/service/CardService");
15
- var CardSubscriptionDynamicService_1 = require("./../../lib/service/CardSubscriptionDynamicService");
16
- var CashService_1 = require("./../../lib/service/CashService");
17
- var CommissionService_1 = require("./../../lib/service/CommissionService");
18
- var KPayService_1 = require("./../../lib/service/KPayService");
19
- var KushkiService_1 = require("./../../lib/service/KushkiService");
20
- var MobileProcessorService_1 = require("./../../lib/service/MobileProcessorService");
21
- var MultiMerchantService_1 = require("./../../lib/service/MultiMerchantService");
22
- var PayoutsCashService_1 = require("./../../lib/service/PayoutsCashService");
23
- var PayoutsTransferService_1 = require("./../../lib/service/PayoutsTransferService");
24
- var SecureService_1 = require("./../../lib/service/SecureService");
25
- var SiftScienceService_1 = require("./../../lib/service/SiftScienceService");
26
- var TransferService_1 = require("./../../lib/service/TransferService");
27
- var TransferSubscriptionsService_1 = require("./../../lib/service/TransferSubscriptionsService");
28
- var CONTAINER = new inversify_1.Container();
7
+ const Identifiers_1 = require("./../../lib/constant/Identifiers");
8
+ const KushkiGateway_1 = require("./../../lib/gateway/KushkiGateway");
9
+ const SiftScience_1 = require("./../../lib/gateway/SiftScience");
10
+ const inversify_1 = require("inversify");
11
+ const AuthService_1 = require("./../../lib/service/AuthService");
12
+ const CardAsyncService_1 = require("./../../lib/service/CardAsyncService");
13
+ const CardDynamicService_1 = require("./../../lib/service/CardDynamicService");
14
+ const CardService_1 = require("./../../lib/service/CardService");
15
+ const CardSubscriptionDynamicService_1 = require("./../../lib/service/CardSubscriptionDynamicService");
16
+ const CashService_1 = require("./../../lib/service/CashService");
17
+ const CommissionService_1 = require("./../../lib/service/CommissionService");
18
+ const KPayService_1 = require("./../../lib/service/KPayService");
19
+ const KushkiService_1 = require("./../../lib/service/KushkiService");
20
+ const MobileProcessorService_1 = require("./../../lib/service/MobileProcessorService");
21
+ const MultiMerchantService_1 = require("./../../lib/service/MultiMerchantService");
22
+ const PayoutsCashService_1 = require("./../../lib/service/PayoutsCashService");
23
+ const PayoutsTransferService_1 = require("./../../lib/service/PayoutsTransferService");
24
+ const SecureService_1 = require("./../../lib/service/SecureService");
25
+ const SiftScienceService_1 = require("./../../lib/service/SiftScienceService");
26
+ const TransferService_1 = require("./../../lib/service/TransferService");
27
+ const TransferSubscriptionsService_1 = require("./../../lib/service/TransferSubscriptionsService");
28
+ const CONTAINER = new inversify_1.Container();
29
29
  exports.CONTAINER = CONTAINER;
30
30
  // Service
31
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.AuthService).toFactory(function (context) { return function () {
32
- return new AuthService_1.AuthService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
33
- }; });
34
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardService).toFactory(function (context) { return function (regional) {
35
- return new CardService_1.CardService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AuthService)(regional), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional));
36
- }; });
37
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.CashService).toFactory(function (context) { return function (regional) {
38
- return new CashService_1.CashService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional));
39
- }; });
40
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardDynamicService).toFactory(function (context) { return function () {
41
- return new CardDynamicService_1.CardDynamicService(context.container.get(Identifiers_1.IDENTIFIERS.CardService)(), context.container.get(Identifiers_1.IDENTIFIERS.CardAsyncService)());
42
- }; });
43
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardSubscriptionDynamicService).toFactory(function (context) { return function () {
44
- return new CardSubscriptionDynamicService_1.CardSubscriptionDynamicService(context.container.get(Identifiers_1.IDENTIFIERS.CardService)(), context.container.get(Identifiers_1.IDENTIFIERS.CardAsyncService)());
45
- }; });
46
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.MobileProcessorService).toFactory(function (context) { return function () {
47
- return new MobileProcessorService_1.MobileProcessorService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
48
- }; });
49
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.KushkiService).toFactory(function (context) { return function (_regional) {
50
- return new KushkiService_1.KushkiService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
51
- }; });
52
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.TransferService).toFactory(function (context) { return function (regional) {
53
- return new TransferService_1.TransferService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional));
54
- }; });
55
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.SecureService).toFactory(function (context) { return function () {
56
- return new SecureService_1.SecureService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
57
- }; });
58
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.MultiMerchantService).toFactory(function (context) { return function () {
59
- return new MultiMerchantService_1.MultiMerchantService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
60
- }; });
61
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.CommissionService).toFactory(function (context) { return function () {
62
- return new CommissionService_1.CommissionService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
63
- }; });
64
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardAsyncService).toFactory(function (context) { return function () {
65
- return new CardAsyncService_1.CardAsyncService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
66
- }; });
67
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.PayoutsCashService).toFactory(function (context) { return function (regional) {
68
- return new PayoutsCashService_1.PayoutsCashService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional));
69
- }; });
70
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.TransferSubscriptionService).toFactory(function (context) { return function (regional) {
71
- return new TransferSubscriptionsService_1.TransferSubscriptionsService(context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional), context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
72
- }; });
73
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.PayoutsTransferService).toFactory(function (context) { return function (regional) {
74
- return new PayoutsTransferService_1.PayoutsTransferService(context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional), context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway));
75
- }; });
76
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.KPayService).toFactory(function (context) { return function (regional) {
77
- return new KPayService_1.KPayService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AuthService)(regional));
78
- }; });
79
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.SiftScienceService).toFactory(function (context) { return function (regional) {
80
- return new SiftScienceService_1.SiftScienceService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional));
81
- }; });
31
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.AuthService).toFactory((context) => () => new AuthService_1.AuthService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
32
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardService).toFactory((context) => (regional) => new CardService_1.CardService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AuthService)(regional), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional)));
33
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.CashService).toFactory((context) => (regional) => new CashService_1.CashService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional)));
34
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardDynamicService).toFactory((context) => () => new CardDynamicService_1.CardDynamicService(context.container.get(Identifiers_1.IDENTIFIERS.CardService)(), context.container.get(Identifiers_1.IDENTIFIERS.CardAsyncService)()));
35
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardSubscriptionDynamicService).toFactory((context) => () => new CardSubscriptionDynamicService_1.CardSubscriptionDynamicService(context.container.get(Identifiers_1.IDENTIFIERS.CardService)(), context.container.get(Identifiers_1.IDENTIFIERS.CardAsyncService)()));
36
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.MobileProcessorService).toFactory((context) => () => new MobileProcessorService_1.MobileProcessorService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
37
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.KushkiService).toFactory((context) => (_regional) => new KushkiService_1.KushkiService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
38
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.TransferService).toFactory((context) => (regional) => new TransferService_1.TransferService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional)));
39
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.SecureService).toFactory((context) => () => new SecureService_1.SecureService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
40
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.MultiMerchantService).toFactory((context) => () => new MultiMerchantService_1.MultiMerchantService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
41
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.CommissionService).toFactory((context) => () => new CommissionService_1.CommissionService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
42
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.CardAsyncService).toFactory((context) => () => new CardAsyncService_1.CardAsyncService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
43
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.PayoutsCashService).toFactory((context) => (regional) => new PayoutsCashService_1.PayoutsCashService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional)));
44
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.TransferSubscriptionService).toFactory((context) => (regional) => new TransferSubscriptionsService_1.TransferSubscriptionsService(context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional), context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
45
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.PayoutsTransferService).toFactory((context) => (regional) => new PayoutsTransferService_1.PayoutsTransferService(context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional), context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway)));
46
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.KPayService).toFactory((context) => (regional) => new KPayService_1.KPayService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AuthService)(regional)));
47
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.SiftScienceService).toFactory((context) => (regional) => new SiftScienceService_1.SiftScienceService(context.container.get(Identifiers_1.IDENTIFIERS.KushkiGateway), context.container.get(Identifiers_1.IDENTIFIERS.AntiFraud)(regional)));
82
48
  // Gateway
83
49
  CONTAINER.bind(Identifiers_1.IDENTIFIERS.KushkiGateway).to(KushkiGateway_1.KushkiGateway);
84
- CONTAINER.bind(Identifiers_1.IDENTIFIERS.AntiFraud).toFactory(function () { return function (regional) { return new SiftScience_1.SiftScience(regional); }; });
50
+ CONTAINER.bind(Identifiers_1.IDENTIFIERS.AntiFraud).toFactory(() => (regional) => new SiftScience_1.SiftScience(regional));
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.EnvironmentEnum = void 0;
4
4
  /**
5
5
  * Environment enum file
@@ -19,6 +19,7 @@ export declare enum ErrorCode {
19
19
  E013 = "E013",
20
20
  E014 = "E014",
21
21
  E015 = "E015",
22
- E016 = "E016"
22
+ E016 = "E016",
23
+ E017 = "E017"
23
24
  }
24
25
  export declare const ERRORS: KushkiErrors;
@@ -1,8 +1,7 @@
1
1
  "use strict";
2
- var _a;
3
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
4
3
  exports.ERRORS = exports.ErrorCode = void 0;
5
- var StatusCodeEnum_1 = require("./../../lib/infrastructure/StatusCodeEnum");
4
+ const StatusCodeEnum_1 = require("./../../lib/infrastructure/StatusCodeEnum");
6
5
  var ErrorCode;
7
6
  (function (ErrorCode) {
8
7
  ErrorCode["E001"] = "E001";
@@ -21,86 +20,92 @@ var ErrorCode;
21
20
  ErrorCode["E014"] = "E014";
22
21
  ErrorCode["E015"] = "E015";
23
22
  ErrorCode["E016"] = "E016";
23
+ ErrorCode["E017"] = "E017";
24
24
  })(ErrorCode = exports.ErrorCode || (exports.ErrorCode = {}));
25
- exports.ERRORS = (_a = {},
26
- _a[ErrorCode.E001] = {
25
+ exports.ERRORS = {
26
+ [ErrorCode.E001]: {
27
27
  code: ErrorCode.E001,
28
28
  message: "El cuerpo de la petición es inválido.",
29
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
29
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
30
30
  },
31
- _a[ErrorCode.E002] = {
31
+ [ErrorCode.E002]: {
32
32
  code: ErrorCode.E002,
33
33
  message: "Ha ocurrido un error inesperado.",
34
- statusCode: StatusCodeEnum_1.StatusCodeEnum.InternalServerError
34
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.InternalServerError,
35
35
  },
36
- _a[ErrorCode.E003] = {
36
+ [ErrorCode.E003]: {
37
37
  code: ErrorCode.E003,
38
38
  message: "La tarjeta no permite realizar pagos diferidos.",
39
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
39
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
40
40
  },
41
- _a[ErrorCode.E004] = {
41
+ [ErrorCode.E004]: {
42
42
  code: ErrorCode.E004,
43
43
  message: "Id de comercio no válido.",
44
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
44
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
45
45
  },
46
- _a[ErrorCode.E005] = {
46
+ [ErrorCode.E005]: {
47
47
  code: ErrorCode.E005,
48
48
  message: "El número de tarjeta no es válido.",
49
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
49
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
50
50
  },
51
- _a[ErrorCode.E006] = {
51
+ [ErrorCode.E006]: {
52
52
  code: ErrorCode.E006,
53
53
  message: "Error de validación apple pay.",
54
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
54
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
55
55
  },
56
- _a[ErrorCode.E007] = {
56
+ [ErrorCode.E007]: {
57
57
  code: ErrorCode.E007,
58
58
  message: "Error al iniciar sesión.",
59
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
59
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
60
60
  },
61
- _a[ErrorCode.E008] = {
61
+ [ErrorCode.E008]: {
62
62
  code: ErrorCode.E008,
63
63
  message: "Código incorrecto, ingresar nuevamente.",
64
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
64
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
65
65
  },
66
- _a[ErrorCode.E009] = {
66
+ [ErrorCode.E009]: {
67
67
  code: ErrorCode.E009,
68
68
  message: "Error al validar sesión.",
69
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
69
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
70
70
  },
71
- _a[ErrorCode.E010] = {
71
+ [ErrorCode.E010]: {
72
72
  code: ErrorCode.E010,
73
73
  message: "Es necesaria la verificación de autenticación del usuario.",
74
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
74
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
75
75
  },
76
- _a[ErrorCode.E011] = {
76
+ [ErrorCode.E011]: {
77
77
  code: ErrorCode.E011,
78
78
  message: "Sesión no disponible.",
79
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
79
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
80
80
  },
81
- _a[ErrorCode.E012] = {
81
+ [ErrorCode.E012]: {
82
82
  code: ErrorCode.E012,
83
83
  message: "Campos 3DS inválidos",
84
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
84
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
85
85
  },
86
- _a[ErrorCode.E013] = {
86
+ [ErrorCode.E013]: {
87
87
  code: ErrorCode.E013,
88
88
  message: "Comercio no tiene activo 3DS",
89
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
89
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
90
90
  },
91
- _a[ErrorCode.E014] = {
91
+ [ErrorCode.E014]: {
92
92
  code: ErrorCode.E014,
93
93
  message: "Longitud de tarjeta inválida",
94
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
94
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
95
95
  },
96
- _a[ErrorCode.E015] = {
96
+ [ErrorCode.E015]: {
97
97
  code: ErrorCode.E015,
98
98
  message: "Configuración de credenciales Sift inválidas",
99
- statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest
99
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
100
100
  },
101
- _a[ErrorCode.E016] = {
101
+ [ErrorCode.E016]: {
102
102
  code: ErrorCode.E016,
103
103
  message: "Error al generar animación.",
104
- statusCode: StatusCodeEnum_1.StatusCodeEnum.InternalServerError
104
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.InternalServerError,
105
105
  },
106
- _a);
106
+ [ErrorCode.E017]: {
107
+ code: ErrorCode.E017,
108
+ message: "Marca de tarjeta inválida.",
109
+ statusCode: StatusCodeEnum_1.StatusCodeEnum.BadRequest,
110
+ },
111
+ };
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.HeadersEnum = void 0;
4
4
  /**
5
5
  * Headers enum file
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.KPayUserPoolEnum = void 0;
4
4
  var KPayUserPoolEnum;
5
5
  (function (KPayUserPoolEnum) {
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.KpayPaymentKind = void 0;
4
4
  var KpayPaymentKind;
5
5
  (function (KpayPaymentKind) {
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.PathEnum = void 0;
4
4
  /**
5
5
  * Path enum file
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.PLATFORMS = exports.PlatformCodeEnum = void 0;
4
4
  var PlatformCodeEnum;
5
5
  (function (PlatformCodeEnum) {
@@ -20,54 +20,54 @@ var PlatformCodeEnum;
20
20
  exports.PLATFORMS = {
21
21
  KP001: {
22
22
  platformId: "KP001",
23
- platformName: "API"
23
+ platformName: "API",
24
24
  },
25
25
  KP002: {
26
26
  platformId: "KP002",
27
- platformName: "KUSHKIJS"
27
+ platformName: "KUSHKIJS",
28
28
  },
29
29
  KP003: {
30
30
  platformId: "KP003",
31
- platformName: "ANDROID"
31
+ platformName: "ANDROID",
32
32
  },
33
33
  KP004: {
34
34
  platformId: "KP004",
35
- platformName: "IOS"
35
+ platformName: "IOS",
36
36
  },
37
37
  KP005: {
38
38
  platformId: "KP005",
39
- platformName: "SMARTLINKS"
39
+ platformName: "SMARTLINKS",
40
40
  },
41
41
  KP006: {
42
42
  platformId: "KP006",
43
- platformName: "KAJITA"
43
+ platformName: "KAJITA",
44
44
  },
45
45
  KP007: {
46
46
  platformId: "KP007",
47
- platformName: "CAJITA"
47
+ platformName: "CAJITA",
48
48
  },
49
49
  KP008: {
50
50
  platformId: "KP008",
51
- platformName: "VTEX"
51
+ platformName: "VTEX",
52
52
  },
53
53
  KP009: {
54
54
  platformId: "KP009",
55
- platformName: "MAGENTO"
55
+ platformName: "MAGENTO",
56
56
  },
57
57
  KP010: {
58
58
  platformId: "KP010",
59
- platformName: "PRESTASHOP"
59
+ platformName: "PRESTASHOP",
60
60
  },
61
61
  KP011: {
62
62
  platformId: "KP011",
63
- platformName: "WOOCOMERCE"
63
+ platformName: "WOOCOMERCE",
64
64
  },
65
65
  KP012: {
66
66
  platformId: "KP012",
67
- platformName: "SHOPIFY"
67
+ platformName: "SHOPIFY",
68
68
  },
69
69
  KP013: {
70
70
  platformId: "KP013",
71
- platformName: "WEBCHECKOUT"
72
- }
71
+ platformName: "WEBCHECKOUT",
72
+ },
73
73
  };
@@ -2,7 +2,7 @@
2
2
  /**
3
3
  * SiftScienceEnum
4
4
  */
5
- exports.__esModule = true;
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.SiftScienceEnum = void 0;
7
7
  var SiftScienceEnum;
8
8
  (function (SiftScienceEnum) {
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.StatusCodeEnum = void 0;
4
4
  /**
5
5
  * HTTP Status code enum
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ThreeDSEnum = void 0;
4
4
  var ThreeDSEnum;
5
5
  (function (ThreeDSEnum) {
@@ -3,6 +3,6 @@
3
3
  * VisaBrandingResourceUrlEnum enum file
4
4
  */
5
5
  export declare enum VisaBrandingResourceUrlEnum {
6
- visaBrandingResourcesDev = "https://kushki-static-dev.s3.amazonaws.com/visa-sensory-branding",
7
- visaBrandingResourcesProd = "https://kushki-static.s3.amazonaws.com/visa-sensory-branding"
6
+ DEV = "https://kushki-static-dev.s3.amazonaws.com/visa-sensory-branding/v2",
7
+ PROD = "https://kushki-static.s3.amazonaws.com/visa-sensory-branding/v2"
8
8
  }
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
- exports.__esModule = true;
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VisaBrandingResourceUrlEnum = void 0;
4
4
  /**
5
5
  * VisaBrandingResourceUrlEnum enum file
6
6
  */
7
7
  var VisaBrandingResourceUrlEnum;
8
8
  (function (VisaBrandingResourceUrlEnum) {
9
- VisaBrandingResourceUrlEnum["visaBrandingResourcesDev"] = "https://kushki-static-dev.s3.amazonaws.com/visa-sensory-branding";
10
- VisaBrandingResourceUrlEnum["visaBrandingResourcesProd"] = "https://kushki-static.s3.amazonaws.com/visa-sensory-branding";
9
+ VisaBrandingResourceUrlEnum["DEV"] = "https://kushki-static-dev.s3.amazonaws.com/visa-sensory-branding/v2";
10
+ VisaBrandingResourceUrlEnum["PROD"] = "https://kushki-static.s3.amazonaws.com/visa-sensory-branding/v2";
11
11
  })(VisaBrandingResourceUrlEnum = exports.VisaBrandingResourceUrlEnum || (exports.VisaBrandingResourceUrlEnum = {}));
package/lib/lib.js CHANGED
@@ -14,5 +14,5 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
14
14
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p);
16
16
  };
17
- exports.__esModule = true;
17
+ Object.defineProperty(exports, "__esModule", { value: true });
18
18
  __exportStar(require("./Kushki"), exports);
@@ -0,0 +1,21 @@
1
+ /* tslint:disable:all */
2
+ export declare class MCSonic extends HTMLElement {
3
+ constructor();
4
+ connectedCallback(): void;
5
+ disconnectedCallback(): void;
6
+ static get observedAttributes(): string[];
7
+ set type(value: string | null);
8
+ get type(): string | null;
9
+ set clearBackground(value: boolean);
10
+ get clearBackground(): boolean;
11
+ attributeChangedCallback(name: any, oldValue: any, newValue: any): void;
12
+ play(): void;
13
+ _updateRendering(): void;
14
+ _createDOMStructure(): void;
15
+ _loadAudio(): void;
16
+ _playAudio(): void;
17
+ _addStyle(): void;
18
+ _setBackground(): void;
19
+ _resize(): void;
20
+ _updateAnimation(): void;
21
+ }