@cobo/cobo-waas2 1.22.0 → 1.23.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 (142) hide show
  1. package/README.md +39 -14
  2. package/dist/ApiClient.js +1 -1
  3. package/dist/api/AddressBooksApi.js +200 -21
  4. package/dist/api/AutoSweepApi.js +26 -26
  5. package/dist/api/ComplianceApi.js +214 -0
  6. package/dist/api/PaymentApi.js +16 -16
  7. package/dist/api/TokenizationApi.js +2 -2
  8. package/dist/api/TransactionsApi.js +16 -16
  9. package/dist/api/WalletsApi.js +4 -4
  10. package/dist/api/WalletsMPCWalletsApi.js +2 -2
  11. package/dist/index.js +105 -7
  12. package/dist/model/AddressBook.js +12 -12
  13. package/dist/model/AddressesEventData.js +8 -3
  14. package/dist/model/ApprovalDetail.js +4 -4
  15. package/dist/model/ApprovalResult.js +6 -11
  16. package/dist/model/ApprovalTemplate.js +4 -4
  17. package/dist/model/ApprovalTransactionResult.js +8 -8
  18. package/dist/model/ApprovalUserDetail.js +95 -24
  19. package/dist/model/AutoSweepTask.js +9 -9
  20. package/dist/model/BalanceUpdateInfoEventData.js +8 -3
  21. package/dist/model/ChainInfo.js +14 -1
  22. package/dist/model/ChainsEventData.js +8 -3
  23. package/dist/model/ComplianceDispositionUpdateEventData.js +321 -0
  24. package/dist/model/CreateAddressBookParam.js +165 -0
  25. package/dist/model/CreateAddressBooks201Response.js +107 -0
  26. package/dist/model/CreateAddressBooksParam.js +128 -0
  27. package/dist/model/CreateAutoSweepTask.js +5 -5
  28. package/dist/model/CreateCustodialWalletParams.js +1 -1
  29. package/dist/model/CreateExchangeWalletParams.js +2 -2
  30. package/dist/model/CreateMerchantRequest.js +1 -1
  31. package/dist/model/CreateMpcWalletParams.js +2 -2
  32. package/dist/model/CreatePaymentOrderRequest.js +3 -3
  33. package/dist/model/CreateRefundRequest.js +2 -2
  34. package/dist/model/CreateSafeWalletParams.js +1 -1
  35. package/dist/model/CreateSettlement.js +1 -1
  36. package/dist/model/CreateSmartContractWalletParams.js +1 -1
  37. package/dist/model/CreateSweepToAddress.js +1 -1
  38. package/dist/model/CreateWalletParams.js +1 -1
  39. package/dist/model/DeleteAddressBookById201Response.js +106 -0
  40. package/dist/model/DispositionEventData.js +170 -0
  41. package/dist/model/DispositionQueryResponse.js +146 -0
  42. package/dist/model/DispositionResponse.js +122 -0
  43. package/dist/model/DispositionStatus.js +116 -0
  44. package/dist/model/DispositionType.js +66 -0
  45. package/dist/model/IsolateDisposition.js +167 -0
  46. package/dist/model/MPCVaultEventData.js +8 -3
  47. package/dist/model/Merchant.js +1 -1
  48. package/dist/model/MerchantBalance.js +7 -7
  49. package/dist/model/OrgInfo.js +9 -0
  50. package/dist/model/PaymentAddressUpdateEventData.js +8 -3
  51. package/dist/model/PaymentOrderEventData.js +8 -3
  52. package/dist/model/PaymentRefundEventData.js +8 -3
  53. package/dist/model/PaymentSettlementEvent.js +8 -3
  54. package/dist/model/PaymentTransactionEventData.js +8 -3
  55. package/dist/model/PaymentWalletBalance.js +6 -6
  56. package/dist/model/PspBalance.js +7 -7
  57. package/dist/model/ReceivedAmountPerAddress.js +5 -5
  58. package/dist/model/RefundDisposition.js +167 -0
  59. package/dist/model/RoleDetail.js +41 -6
  60. package/dist/model/SuspendedTokenEventData.js +8 -3
  61. package/dist/model/SweepToAddress.js +1 -1
  62. package/dist/model/TSSRequestWebhookEventData.js +8 -3
  63. package/dist/model/TokenListingEventData.js +8 -3
  64. package/dist/model/TokensEventData.js +8 -3
  65. package/dist/model/TransactionWebhookEventData.js +8 -3
  66. package/dist/model/UnfreezeDisposition.js +111 -0
  67. package/dist/model/UpdateAddressBookParam.js +150 -0
  68. package/dist/model/UpdateMerchantByIdRequest.js +1 -1
  69. package/dist/model/WalletInfoEventData.js +8 -3
  70. package/dist/model/WebhookEventData.js +62 -10
  71. package/dist/model/WebhookEventDataType.js +7 -2
  72. package/dist/model/WebhookEventType.js +5 -0
  73. package/docs/AddressBook.md +7 -7
  74. package/docs/AddressBooksApi.md +218 -8
  75. package/docs/AddressesEventData.md +3 -1
  76. package/docs/ApprovalDetail.md +3 -3
  77. package/docs/ApprovalResult.md +3 -5
  78. package/docs/ApprovalTemplate.md +3 -3
  79. package/docs/ApprovalTransactionResult.md +4 -4
  80. package/docs/ApprovalUserDetail.md +15 -9
  81. package/docs/AutoSweepApi.md +18 -18
  82. package/docs/AutoSweepTask.md +5 -5
  83. package/docs/BalanceUpdateInfoEventData.md +3 -1
  84. package/docs/ChainInfo.md +2 -1
  85. package/docs/ChainsEventData.md +3 -1
  86. package/docs/ComplianceApi.md +218 -0
  87. package/docs/ComplianceDispositionUpdateEventData.md +56 -0
  88. package/docs/CreateAddressBookParam.md +13 -0
  89. package/docs/CreateAddressBooks201Response.md +9 -0
  90. package/docs/CreateAddressBooksParam.md +9 -0
  91. package/docs/CreateAutoSweepTask.md +2 -2
  92. package/docs/CreateCustodialWalletParams.md +1 -1
  93. package/docs/CreateExchangeWalletParams.md +1 -1
  94. package/docs/CreateMerchantRequest.md +1 -1
  95. package/docs/CreateMpcWalletParams.md +1 -1
  96. package/docs/CreatePaymentOrderRequest.md +2 -2
  97. package/docs/CreateRefundRequest.md +1 -1
  98. package/docs/CreateSafeWalletParams.md +1 -1
  99. package/docs/CreateSettlement.md +1 -1
  100. package/docs/CreateSmartContractWalletParams.md +1 -1
  101. package/docs/CreateWalletParams.md +1 -1
  102. package/docs/DeleteAddressBookById201Response.md +9 -0
  103. package/docs/DispositionEventData.md +14 -0
  104. package/docs/DispositionQueryResponse.md +12 -0
  105. package/docs/DispositionResponse.md +10 -0
  106. package/docs/DispositionStatus.md +34 -0
  107. package/docs/DispositionType.md +14 -0
  108. package/docs/IsolateDisposition.md +13 -0
  109. package/docs/MPCVaultEventData.md +3 -1
  110. package/docs/Merchant.md +1 -1
  111. package/docs/MerchantBalance.md +6 -6
  112. package/docs/OrgInfo.md +1 -0
  113. package/docs/PaymentAddressUpdateEventData.md +3 -1
  114. package/docs/PaymentApi.md +10 -10
  115. package/docs/PaymentOrderEventData.md +3 -1
  116. package/docs/PaymentRefundEventData.md +3 -1
  117. package/docs/PaymentSettlementEvent.md +3 -1
  118. package/docs/PaymentTransactionEventData.md +3 -1
  119. package/docs/PaymentWalletBalance.md +5 -5
  120. package/docs/PspBalance.md +6 -6
  121. package/docs/ReceivedAmountPerAddress.md +2 -2
  122. package/docs/RefundDisposition.md +13 -0
  123. package/docs/RoleDetail.md +4 -1
  124. package/docs/SuspendedTokenEventData.md +3 -1
  125. package/docs/TSSRequestWebhookEventData.md +3 -1
  126. package/docs/TokenListingEventData.md +3 -1
  127. package/docs/TokenizationApi.md +2 -2
  128. package/docs/TokensEventData.md +3 -1
  129. package/docs/TransactionWebhookEventData.md +3 -1
  130. package/docs/TransactionsApi.md +10 -10
  131. package/docs/UnfreezeDisposition.md +9 -0
  132. package/docs/UpdateAddressBookParam.md +12 -0
  133. package/docs/UpdateMerchantByIdRequest.md +1 -1
  134. package/docs/WalletInfoEventData.md +3 -1
  135. package/docs/WalletsApi.md +2 -2
  136. package/docs/WalletsMPCWalletsApi.md +1 -1
  137. package/docs/WebhookEventData.md +8 -2
  138. package/docs/WebhookEventDataType.md +3 -1
  139. package/docs/WebhookEventType.md +2 -0
  140. package/package.json +1 -1
  141. package/dist/model/ApprovalShowInfo.js +0 -140
  142. package/docs/ApprovalShowInfo.md +0 -13
@@ -0,0 +1,128 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _CreateAddressBookParam = _interopRequireDefault(require("./CreateAddressBookParam"));
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
10
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
11
+ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
12
+ function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
13
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
14
+ function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
15
+ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
16
+ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
17
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
18
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /**
19
+ * Cobo Wallet as a Service 2.0
20
+ *
21
+ * Contact: help@cobo.com
22
+ *
23
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
24
+ * https://openapi-generator.tech
25
+ * Do not edit the class manually.
26
+ *
27
+ */
28
+ /**
29
+ * The CreateAddressBooksParam model module.
30
+ * @module model/CreateAddressBooksParam
31
+ */
32
+ var CreateAddressBooksParam = /*#__PURE__*/function () {
33
+ /**
34
+ * Constructs a new <code>CreateAddressBooksParam</code>.
35
+ * The request body to add addresses in batches to your Address Book.
36
+ * @alias module:model/CreateAddressBooksParam
37
+ * @param address_books {Array.<module:model/CreateAddressBookParam>}
38
+ */
39
+ function CreateAddressBooksParam(address_books) {
40
+ _classCallCheck(this, CreateAddressBooksParam);
41
+ CreateAddressBooksParam.initialize(this, address_books);
42
+ }
43
+
44
+ /**
45
+ * Initializes the fields of this object.
46
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
47
+ * Only for internal use.
48
+ */
49
+ return _createClass(CreateAddressBooksParam, null, [{
50
+ key: "initialize",
51
+ value: function initialize(obj, address_books) {
52
+ obj['address_books'] = address_books;
53
+ }
54
+
55
+ /**
56
+ * Constructs a <code>CreateAddressBooksParam</code> from a plain JavaScript object, optionally creating a new instance.
57
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
58
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
59
+ * @param {module:model/CreateAddressBooksParam} obj Optional instance to populate.
60
+ * @return {module:model/CreateAddressBooksParam} The populated <code>CreateAddressBooksParam</code> instance.
61
+ */
62
+ }, {
63
+ key: "constructFromObject",
64
+ value: function constructFromObject(data, obj) {
65
+ if (data) {
66
+ obj = obj || new CreateAddressBooksParam();
67
+ if (data.hasOwnProperty('address_books')) {
68
+ obj['address_books'] = _ApiClient["default"].convertToType(data['address_books'], [_CreateAddressBookParam["default"]]);
69
+ }
70
+ }
71
+ return obj;
72
+ }
73
+
74
+ /**
75
+ * Validates the JSON data with respect to <code>CreateAddressBooksParam</code>.
76
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
77
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>CreateAddressBooksParam</code>.
78
+ */
79
+ }, {
80
+ key: "validateJSON",
81
+ value: function validateJSON(data) {
82
+ // check to make sure all required properties are present in the JSON string
83
+ var _iterator = _createForOfIteratorHelper(CreateAddressBooksParam.RequiredProperties),
84
+ _step;
85
+ try {
86
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
87
+ var property = _step.value;
88
+ if (!data.hasOwnProperty(property)) {
89
+ throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
90
+ }
91
+ }
92
+ } catch (err) {
93
+ _iterator.e(err);
94
+ } finally {
95
+ _iterator.f();
96
+ }
97
+ if (data['address_books']) {
98
+ // data not null
99
+ // ensure the json data is an array
100
+ if (!Array.isArray(data['address_books'])) {
101
+ throw new Error("Expected the field `address_books` to be an array in the JSON data but got " + data['address_books']);
102
+ }
103
+ // validate the optional field `address_books` (array)
104
+ var _iterator2 = _createForOfIteratorHelper(data['address_books']),
105
+ _step2;
106
+ try {
107
+ for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
108
+ var item = _step2.value;
109
+ _CreateAddressBookParam["default"].validateJSON(item);
110
+ }
111
+ } catch (err) {
112
+ _iterator2.e(err);
113
+ } finally {
114
+ _iterator2.f();
115
+ }
116
+ ;
117
+ }
118
+ return true;
119
+ }
120
+ }]);
121
+ }();
122
+ CreateAddressBooksParam.RequiredProperties = ["address_books"];
123
+
124
+ /**
125
+ * @member {Array.<module:model/CreateAddressBookParam>} address_books
126
+ */
127
+ CreateAddressBooksParam.prototype['address_books'] = undefined;
128
+ var _default = exports["default"] = CreateAddressBooksParam;
@@ -31,10 +31,10 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
31
31
  var CreateAutoSweepTask = /*#__PURE__*/function () {
32
32
  /**
33
33
  * Constructs a new <code>CreateAutoSweepTask</code>.
34
- * The sweep to address information.
34
+ * Wallet and token information required to create an auto-sweep task.
35
35
  * @alias module:model/CreateAutoSweepTask
36
- * @param wallet_id {String} The wallet ID.
37
- * @param token_id {String} The token ID of the swept token. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
36
+ * @param wallet_id {String} ID of the wallet where the token will be swept.
37
+ * @param token_id {String} ID of the token to be swept. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
38
38
  */
39
39
  function CreateAutoSweepTask(wallet_id, token_id) {
40
40
  _classCallCheck(this, CreateAutoSweepTask);
@@ -113,13 +113,13 @@ var CreateAutoSweepTask = /*#__PURE__*/function () {
113
113
  CreateAutoSweepTask.RequiredProperties = ["wallet_id", "token_id"];
114
114
 
115
115
  /**
116
- * The wallet ID.
116
+ * ID of the wallet where the token will be swept.
117
117
  * @member {String} wallet_id
118
118
  */
119
119
  CreateAutoSweepTask.prototype['wallet_id'] = undefined;
120
120
 
121
121
  /**
122
- * The token ID of the swept token. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
122
+ * ID of the token to be swept. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
123
123
  * @member {String} token_id
124
124
  */
125
125
  CreateAutoSweepTask.prototype['token_id'] = undefined;
@@ -135,7 +135,7 @@ CreateCustodialWalletParams.prototype['wallet_type'] = undefined;
135
135
  CreateCustodialWalletParams.prototype['wallet_subtype'] = undefined;
136
136
 
137
137
  /**
138
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
138
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
139
139
  * @member {Boolean} enable_auto_sweep
140
140
  */
141
141
  CreateCustodialWalletParams.prototype['enable_auto_sweep'] = undefined;
@@ -197,7 +197,7 @@ CreateExchangeWalletParams.prototype['wallet_type'] = undefined;
197
197
  CreateExchangeWalletParams.prototype['wallet_subtype'] = undefined;
198
198
 
199
199
  /**
200
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
200
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
201
201
  * @member {Boolean} enable_auto_sweep
202
202
  */
203
203
  CreateExchangeWalletParams.prototype['enable_auto_sweep'] = undefined;
@@ -264,7 +264,7 @@ _CreateCustodialWalletParams["default"].prototype['wallet_type'] = undefined;
264
264
  */
265
265
  _CreateCustodialWalletParams["default"].prototype['wallet_subtype'] = undefined;
266
266
  /**
267
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
267
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
268
268
  * @member {Boolean} enable_auto_sweep
269
269
  */
270
270
  _CreateCustodialWalletParams["default"].prototype['enable_auto_sweep'] = undefined;
@@ -131,7 +131,7 @@ CreateMerchantRequest.prototype['name'] = undefined;
131
131
  CreateMerchantRequest.prototype['wallet_id'] = undefined;
132
132
 
133
133
  /**
134
- * The developer fee rate applied to this merchant. Expressed as a string in decimal format where \"0.1\" represents 10%. This fee is deducted from the payment amount and only applies to top-up transactions.
134
+ * The developer fee rate applied to this merchant. Expressed as a string in decimal format where \"0.1\" represents 10%. This fee is deducted from the payment amount and only applies to top-up transactions. If you are a merchant (directly serving the payer), you do not need to configure the developer fee rate.
135
135
  * @member {String} developer_fee_rate
136
136
  */
137
137
  CreateMerchantRequest.prototype['developer_fee_rate'] = undefined;
@@ -147,7 +147,7 @@ CreateMpcWalletParams.prototype['wallet_type'] = undefined;
147
147
  CreateMpcWalletParams.prototype['wallet_subtype'] = undefined;
148
148
 
149
149
  /**
150
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
150
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
151
151
  * @member {Boolean} enable_auto_sweep
152
152
  */
153
153
  CreateMpcWalletParams.prototype['enable_auto_sweep'] = undefined;
@@ -173,7 +173,7 @@ _CreateCustodialWalletParams["default"].prototype['wallet_type'] = undefined;
173
173
  */
174
174
  _CreateCustodialWalletParams["default"].prototype['wallet_subtype'] = undefined;
175
175
  /**
176
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
176
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
177
177
  * @member {Boolean} enable_auto_sweep
178
178
  */
179
179
  _CreateCustodialWalletParams["default"].prototype['enable_auto_sweep'] = undefined;
@@ -35,7 +35,7 @@ var CreatePaymentOrderRequest = /*#__PURE__*/function () {
35
35
  * @param merchant_id {String} The merchant ID.
36
36
  * @param token_id {String} The ID of the cryptocurrency used for payment. Supported values: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
37
37
  * @param order_amount {String} The base amount of the order, excluding the developer fee (specified in `fee_amount`), in the currency specified by `currency`. If `currency` is not specified, the amount is in the cryptocurrency specified by `token_id`. Values must be greater than `0` and contain two decimal places.
38
- * @param fee_amount {String} The developer fee for the order, in the currency specified by `currency`. If `currency` is not specified, the fee is in the cryptocurrency specified by `token_id`. The developer fee is added to the base amount (`order_amount`) to determine the final charge. For example: - Base amount (`order_amount`): \"100.00\" - Developer fee (`fee_amount`): \"2.00\" - Total charged to customer: \"102.00\" Values must be greater than 0 and contain two decimal places.
38
+ * @param fee_amount {String} The developer fee for the order, in the currency specified by `currency`. If `currency` is not specified, the fee is in the cryptocurrency specified by `token_id`. If you are a merchant directly serving payers, set this field to `0`. Developer fees are only relevant for platforms like payment service providers (PSPs) that charge fees to their downstream merchants. The developer fee is added to the base amount (`order_amount`) to determine the final charge. For example: - Base amount (`order_amount`): \"100.00\" - Developer fee (`fee_amount`): \"2.00\" - Total charged to customer: \"102.00\" Values can contain up to two decimal places.
39
39
  * @param psp_order_code {String} A unique reference code assigned by you as a developer to identify this order in your system. This code must be unique across all orders in your system. The code should have a maximum length of 128 characters.
40
40
  */
41
41
  function CreatePaymentOrderRequest(merchant_id, token_id, order_amount, fee_amount, psp_order_code) {
@@ -184,7 +184,7 @@ CreatePaymentOrderRequest.prototype['currency'] = '';
184
184
  CreatePaymentOrderRequest.prototype['order_amount'] = undefined;
185
185
 
186
186
  /**
187
- * The developer fee for the order, in the currency specified by `currency`. If `currency` is not specified, the fee is in the cryptocurrency specified by `token_id`. The developer fee is added to the base amount (`order_amount`) to determine the final charge. For example: - Base amount (`order_amount`): \"100.00\" - Developer fee (`fee_amount`): \"2.00\" - Total charged to customer: \"102.00\" Values must be greater than 0 and contain two decimal places.
187
+ * The developer fee for the order, in the currency specified by `currency`. If `currency` is not specified, the fee is in the cryptocurrency specified by `token_id`. If you are a merchant directly serving payers, set this field to `0`. Developer fees are only relevant for platforms like payment service providers (PSPs) that charge fees to their downstream merchants. The developer fee is added to the base amount (`order_amount`) to determine the final charge. For example: - Base amount (`order_amount`): \"100.00\" - Developer fee (`fee_amount`): \"2.00\" - Total charged to customer: \"102.00\" Values can contain up to two decimal places.
188
188
  * @member {String} fee_amount
189
189
  */
190
190
  CreatePaymentOrderRequest.prototype['fee_amount'] = undefined;
@@ -202,7 +202,7 @@ CreatePaymentOrderRequest.prototype['merchant_order_code'] = undefined;
202
202
  CreatePaymentOrderRequest.prototype['psp_order_code'] = undefined;
203
203
 
204
204
  /**
205
- * The number of seconds until the pay-in order expires, counted from when the request is sent. For example, if set to `1800`, the order will expire in 30 minutes. After expiration: - The order status becomes final and cannot be changed - The `received_token_amount` field will no longer be updated - Funds received after expiration will be categorized as late payments and can only be settled from the developer balance. - A late payment will trigger a `transactionLate` webhook event.
205
+ * The number of seconds until the pay-in order expires, counted from when the request is sent. For example, if set to `1800`, the order will expire in 30 minutes. Must be greater than zero and cannot exceed 3 hours (10800 seconds). After expiration: - The order status becomes final and cannot be changed - The `received_token_amount` field will no longer be updated - Funds received after expiration will be categorized as late payments and can only be settled from the developer balance. - A late payment will trigger a `transactionLate` webhook event.
206
206
  * @member {Number} expired_in
207
207
  * @default 1800
208
208
  */
@@ -34,7 +34,7 @@ var CreateRefundRequest = /*#__PURE__*/function () {
34
34
  * Constructs a new <code>CreateRefundRequest</code>.
35
35
  * @alias module:model/CreateRefundRequest
36
36
  * @param request_id {String} The request ID that is used to track a refund request. The request ID is provided by you and must be unique.
37
- * @param payable_amount {String} The amount to refund in cryptocurrency. The amount must be a positive integer with up to two decimal places.
37
+ * @param payable_amount {String} The amount to refund in cryptocurrency. The amount must be a positive number and can have up to two decimal places
38
38
  * @param token_id {String} The ID of the cryptocurrency used for refund. Supported values: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
39
39
  * @param refund_type {module:model/RefundType}
40
40
  */
@@ -177,7 +177,7 @@ CreateRefundRequest.prototype['request_id'] = undefined;
177
177
  CreateRefundRequest.prototype['merchant_id'] = undefined;
178
178
 
179
179
  /**
180
- * The amount to refund in cryptocurrency. The amount must be a positive integer with up to two decimal places.
180
+ * The amount to refund in cryptocurrency. The amount must be a positive number and can have up to two decimal places
181
181
  * @member {String} payable_amount
182
182
  */
183
183
  CreateRefundRequest.prototype['payable_amount'] = undefined;
@@ -184,7 +184,7 @@ CreateSafeWalletParams.prototype['wallet_type'] = undefined;
184
184
  CreateSafeWalletParams.prototype['wallet_subtype'] = undefined;
185
185
 
186
186
  /**
187
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
187
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
188
188
  * @member {Boolean} enable_auto_sweep
189
189
  */
190
190
  CreateSafeWalletParams.prototype['enable_auto_sweep'] = undefined;
@@ -163,7 +163,7 @@ CreateSettlement.prototype['token_id'] = undefined;
163
163
  CreateSettlement.prototype['currency'] = undefined;
164
164
 
165
165
  /**
166
- * The settlement amount. When settling merchant balance from orders (`acquiring_type` is `Order` and `settlement_type` is `Merchant`), do not specify this field as the settlement amount will be automatically calculated based on the order amounts. - If `payout_channel` is set to `Crypto`, this represents the settlement amount in the specified cryptocurrency. - If `payout_channel` is set to `OffRamp`, this represents the settlement amount in the specified fiat currency.
166
+ * The amount of cryptocurrency to be settled. When settling merchant balance from orders (`acquiring_type` is `Order` and `settlement_type` is `Merchant`), do not specify this field as the amount will be automatically calculated based on the order amounts.
167
167
  * @member {String} amount
168
168
  */
169
169
  CreateSettlement.prototype['amount'] = undefined;
@@ -164,7 +164,7 @@ CreateSmartContractWalletParams.prototype['wallet_type'] = undefined;
164
164
  CreateSmartContractWalletParams.prototype['wallet_subtype'] = undefined;
165
165
 
166
166
  /**
167
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
167
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
168
168
  * @member {Boolean} enable_auto_sweep
169
169
  */
170
170
  CreateSmartContractWalletParams.prototype['enable_auto_sweep'] = undefined;
@@ -31,7 +31,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
31
31
  var CreateSweepToAddress = /*#__PURE__*/function () {
32
32
  /**
33
33
  * Constructs a new <code>CreateSweepToAddress</code>.
34
- * The information of create sweep to address.
34
+ * Information of the new sweep-to address to be created.
35
35
  * @alias module:model/CreateSweepToAddress
36
36
  * @param wallet_id {String} The wallet ID.
37
37
  * @param chain_id {String} The chain ID, which is the unique identifier of a blockchain. You can retrieve the IDs of all the chains you can use by calling [List enabled chains](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-chains).
@@ -219,7 +219,7 @@ CreateWalletParams.prototype['wallet_type'] = undefined;
219
219
  CreateWalletParams.prototype['wallet_subtype'] = undefined;
220
220
 
221
221
  /**
222
- * Enable the auto sweep feature for the wallet. This parameter only applies to MPC and Web3 wallets.
222
+ * Enable the auto-sweep feature for the wallet. This parameter only applies to MPC Wallets and Web3 Wallets.
223
223
  * @member {Boolean} enable_auto_sweep
224
224
  */
225
225
  CreateWalletParams.prototype['enable_auto_sweep'] = undefined;
@@ -0,0 +1,106 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
9
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
10
+ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
11
+ function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
12
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
13
+ function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
14
+ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
15
+ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
16
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
17
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /**
18
+ * Cobo Wallet as a Service 2.0
19
+ *
20
+ * Contact: help@cobo.com
21
+ *
22
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
23
+ * https://openapi-generator.tech
24
+ * Do not edit the class manually.
25
+ *
26
+ */
27
+ /**
28
+ * The DeleteAddressBookById201Response model module.
29
+ * @module model/DeleteAddressBookById201Response
30
+ */
31
+ var DeleteAddressBookById201Response = /*#__PURE__*/function () {
32
+ /**
33
+ * Constructs a new <code>DeleteAddressBookById201Response</code>.
34
+ * @alias module:model/DeleteAddressBookById201Response
35
+ * @param submitted {Boolean} Whether the request to delete the Address Book entry (record) has been successfully submitted. - `true`: The request has been successfully submitted. - `false`: The request has not been submitted.
36
+ */
37
+ function DeleteAddressBookById201Response(submitted) {
38
+ _classCallCheck(this, DeleteAddressBookById201Response);
39
+ DeleteAddressBookById201Response.initialize(this, submitted);
40
+ }
41
+
42
+ /**
43
+ * Initializes the fields of this object.
44
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
45
+ * Only for internal use.
46
+ */
47
+ return _createClass(DeleteAddressBookById201Response, null, [{
48
+ key: "initialize",
49
+ value: function initialize(obj, submitted) {
50
+ obj['submitted'] = submitted;
51
+ }
52
+
53
+ /**
54
+ * Constructs a <code>DeleteAddressBookById201Response</code> from a plain JavaScript object, optionally creating a new instance.
55
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
56
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
57
+ * @param {module:model/DeleteAddressBookById201Response} obj Optional instance to populate.
58
+ * @return {module:model/DeleteAddressBookById201Response} The populated <code>DeleteAddressBookById201Response</code> instance.
59
+ */
60
+ }, {
61
+ key: "constructFromObject",
62
+ value: function constructFromObject(data, obj) {
63
+ if (data) {
64
+ obj = obj || new DeleteAddressBookById201Response();
65
+ if (data.hasOwnProperty('submitted')) {
66
+ obj['submitted'] = _ApiClient["default"].convertToType(data['submitted'], 'Boolean');
67
+ }
68
+ }
69
+ return obj;
70
+ }
71
+
72
+ /**
73
+ * Validates the JSON data with respect to <code>DeleteAddressBookById201Response</code>.
74
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
75
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>DeleteAddressBookById201Response</code>.
76
+ */
77
+ }, {
78
+ key: "validateJSON",
79
+ value: function validateJSON(data) {
80
+ // check to make sure all required properties are present in the JSON string
81
+ var _iterator = _createForOfIteratorHelper(DeleteAddressBookById201Response.RequiredProperties),
82
+ _step;
83
+ try {
84
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
85
+ var property = _step.value;
86
+ if (!data.hasOwnProperty(property)) {
87
+ throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
88
+ }
89
+ }
90
+ } catch (err) {
91
+ _iterator.e(err);
92
+ } finally {
93
+ _iterator.f();
94
+ }
95
+ return true;
96
+ }
97
+ }]);
98
+ }();
99
+ DeleteAddressBookById201Response.RequiredProperties = ["submitted"];
100
+
101
+ /**
102
+ * Whether the request to delete the Address Book entry (record) has been successfully submitted. - `true`: The request has been successfully submitted. - `false`: The request has not been submitted.
103
+ * @member {Boolean} submitted
104
+ */
105
+ DeleteAddressBookById201Response.prototype['submitted'] = undefined;
106
+ var _default = exports["default"] = DeleteAddressBookById201Response;
@@ -0,0 +1,170 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _DispositionStatus = _interopRequireDefault(require("./DispositionStatus"));
9
+ var _DispositionType = _interopRequireDefault(require("./DispositionType"));
10
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
11
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
12
+ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
13
+ function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
14
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
15
+ function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
16
+ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
17
+ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
18
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
19
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /**
20
+ * Cobo Wallet as a Service 2.0
21
+ *
22
+ * Contact: help@cobo.com
23
+ *
24
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
25
+ * https://openapi-generator.tech
26
+ * Do not edit the class manually.
27
+ *
28
+ */
29
+ /**
30
+ * The DispositionEventData model module.
31
+ * @module model/DispositionEventData
32
+ */
33
+ var DispositionEventData = /*#__PURE__*/function () {
34
+ /**
35
+ * Constructs a new <code>DispositionEventData</code>.
36
+ * The disposition information about a transaction.
37
+ * @alias module:model/DispositionEventData
38
+ * @param transaction_id {String} The transaction ID.
39
+ * @param disposition_type {module:model/DispositionType}
40
+ * @param disposition_status {module:model/DispositionStatus}
41
+ * @param updated_timestamp {Number} The time when the disposition was updated, in Unix timestamp format, measured in milliseconds.
42
+ */
43
+ function DispositionEventData(transaction_id, disposition_type, disposition_status, updated_timestamp) {
44
+ _classCallCheck(this, DispositionEventData);
45
+ DispositionEventData.initialize(this, transaction_id, disposition_type, disposition_status, updated_timestamp);
46
+ }
47
+
48
+ /**
49
+ * Initializes the fields of this object.
50
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
51
+ * Only for internal use.
52
+ */
53
+ return _createClass(DispositionEventData, null, [{
54
+ key: "initialize",
55
+ value: function initialize(obj, transaction_id, disposition_type, disposition_status, updated_timestamp) {
56
+ obj['transaction_id'] = transaction_id;
57
+ obj['disposition_type'] = disposition_type;
58
+ obj['disposition_status'] = disposition_status;
59
+ obj['updated_timestamp'] = updated_timestamp;
60
+ }
61
+
62
+ /**
63
+ * Constructs a <code>DispositionEventData</code> from a plain JavaScript object, optionally creating a new instance.
64
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
65
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
66
+ * @param {module:model/DispositionEventData} obj Optional instance to populate.
67
+ * @return {module:model/DispositionEventData} The populated <code>DispositionEventData</code> instance.
68
+ */
69
+ }, {
70
+ key: "constructFromObject",
71
+ value: function constructFromObject(data, obj) {
72
+ if (data) {
73
+ obj = obj || new DispositionEventData();
74
+ if (data.hasOwnProperty('transaction_id')) {
75
+ obj['transaction_id'] = _ApiClient["default"].convertToType(data['transaction_id'], 'String');
76
+ }
77
+ if (data.hasOwnProperty('disposition_type')) {
78
+ obj['disposition_type'] = _DispositionType["default"].constructFromObject(data['disposition_type']);
79
+ }
80
+ if (data.hasOwnProperty('disposition_status')) {
81
+ obj['disposition_status'] = _DispositionStatus["default"].constructFromObject(data['disposition_status']);
82
+ }
83
+ if (data.hasOwnProperty('destination_address')) {
84
+ obj['destination_address'] = _ApiClient["default"].convertToType(data['destination_address'], 'String');
85
+ }
86
+ if (data.hasOwnProperty('disposition_amount')) {
87
+ obj['disposition_amount'] = _ApiClient["default"].convertToType(data['disposition_amount'], 'String');
88
+ }
89
+ if (data.hasOwnProperty('updated_timestamp')) {
90
+ obj['updated_timestamp'] = _ApiClient["default"].convertToType(data['updated_timestamp'], 'Number');
91
+ }
92
+ }
93
+ return obj;
94
+ }
95
+
96
+ /**
97
+ * Validates the JSON data with respect to <code>DispositionEventData</code>.
98
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
99
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>DispositionEventData</code>.
100
+ */
101
+ }, {
102
+ key: "validateJSON",
103
+ value: function validateJSON(data) {
104
+ // check to make sure all required properties are present in the JSON string
105
+ var _iterator = _createForOfIteratorHelper(DispositionEventData.RequiredProperties),
106
+ _step;
107
+ try {
108
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
109
+ var property = _step.value;
110
+ if (!data.hasOwnProperty(property)) {
111
+ throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
112
+ }
113
+ }
114
+ // ensure the json data is a string
115
+ } catch (err) {
116
+ _iterator.e(err);
117
+ } finally {
118
+ _iterator.f();
119
+ }
120
+ if (data['transaction_id'] && !(typeof data['transaction_id'] === 'string' || data['transaction_id'] instanceof String)) {
121
+ throw new Error("Expected the field `transaction_id` to be a primitive type in the JSON string but got " + data['transaction_id']);
122
+ }
123
+ // ensure the json data is a string
124
+ if (data['destination_address'] && !(typeof data['destination_address'] === 'string' || data['destination_address'] instanceof String)) {
125
+ throw new Error("Expected the field `destination_address` to be a primitive type in the JSON string but got " + data['destination_address']);
126
+ }
127
+ // ensure the json data is a string
128
+ if (data['disposition_amount'] && !(typeof data['disposition_amount'] === 'string' || data['disposition_amount'] instanceof String)) {
129
+ throw new Error("Expected the field `disposition_amount` to be a primitive type in the JSON string but got " + data['disposition_amount']);
130
+ }
131
+ return true;
132
+ }
133
+ }]);
134
+ }();
135
+ DispositionEventData.RequiredProperties = ["transaction_id", "disposition_type", "disposition_status", "updated_timestamp"];
136
+
137
+ /**
138
+ * The transaction ID.
139
+ * @member {String} transaction_id
140
+ */
141
+ DispositionEventData.prototype['transaction_id'] = undefined;
142
+
143
+ /**
144
+ * @member {module:model/DispositionType} disposition_type
145
+ */
146
+ DispositionEventData.prototype['disposition_type'] = undefined;
147
+
148
+ /**
149
+ * @member {module:model/DispositionStatus} disposition_status
150
+ */
151
+ DispositionEventData.prototype['disposition_status'] = undefined;
152
+
153
+ /**
154
+ * The blockchain address to receive the refunded/isolated funds.
155
+ * @member {String} destination_address
156
+ */
157
+ DispositionEventData.prototype['destination_address'] = undefined;
158
+
159
+ /**
160
+ * The amount to be refunded/isolated from the original transaction, specified as a numeric string. This value cannot exceed the total amount of the original transaction.
161
+ * @member {String} disposition_amount
162
+ */
163
+ DispositionEventData.prototype['disposition_amount'] = undefined;
164
+
165
+ /**
166
+ * The time when the disposition was updated, in Unix timestamp format, measured in milliseconds.
167
+ * @member {Number} updated_timestamp
168
+ */
169
+ DispositionEventData.prototype['updated_timestamp'] = undefined;
170
+ var _default = exports["default"] = DispositionEventData;