@cobo/cobo-waas2 1.1.2 → 1.2.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 (125) hide show
  1. package/README.md +16 -3
  2. package/dist/ApiClient.js +1 -1
  3. package/dist/api/OAuthApi.js +16 -15
  4. package/dist/api/TransactionsApi.js +18 -18
  5. package/dist/api/WalletsApi.js +123 -12
  6. package/dist/api/WalletsExchangeWalletApi.js +254 -0
  7. package/dist/api/WalletsMPCWalletsApi.js +8 -8
  8. package/dist/index.js +56 -0
  9. package/dist/model/AddressInfo.js +1 -1
  10. package/dist/model/AddressTransferDestination.js +3 -3
  11. package/dist/model/AddressTransferDestinationAccountOutput.js +2 -2
  12. package/dist/model/AddressTransferDestinationUtxoOutputsInner.js +1 -1
  13. package/dist/model/AssetInfo.js +2 -2
  14. package/dist/model/BabylonStakeExtra.js +9 -0
  15. package/dist/model/CheckAddressValidity200Response.js +2 -2
  16. package/dist/model/CheckAddressesValidity200ResponseInner.js +121 -0
  17. package/dist/model/CheckLoopTransfers200ResponseInner.js +96 -0
  18. package/dist/model/ContractCallDestination.js +1 -1
  19. package/dist/model/CreateStakeActivity.js +14 -1
  20. package/dist/model/CreateStakeActivityExtra.js +6 -0
  21. package/dist/model/CreateTssRequestRequest.js +13 -0
  22. package/dist/model/CreateUnstakeActivity.js +13 -0
  23. package/dist/model/CreateWithdrawActivity.js +13 -0
  24. package/dist/model/CreatedWalletInfo.js +12 -0
  25. package/dist/model/EstimateStakeFee.js +19 -1
  26. package/dist/model/EstimateUnstakeFee.js +18 -0
  27. package/dist/model/EstimateWithdrawFee.js +18 -0
  28. package/dist/model/EvmContractCallDestination.js +1 -1
  29. package/dist/model/ExchangeId.js +5 -0
  30. package/dist/model/ExchangeTransferDestination.js +16 -16
  31. package/dist/model/ExchangeTransferSource.js +14 -14
  32. package/dist/model/GetToken200Response.js +4 -4
  33. package/dist/model/KeyShareHolder.js +13 -0
  34. package/dist/model/ListAssetBalancesForExchangeWallet200Response.js +123 -0
  35. package/dist/model/ListExchanges200ResponseInner.js +122 -0
  36. package/dist/model/ListSupportedAssetsForExchange200Response.js +123 -0
  37. package/dist/model/MPCWalletInfo.js +26 -0
  38. package/dist/model/RefreshToken200Response.js +135 -0
  39. package/dist/model/RefreshTokenRequest.js +2 -2
  40. package/dist/model/SmartContractWalletType.js +2 -2
  41. package/dist/model/SubWalletAssetBalance.js +10 -10
  42. package/dist/model/TSSRequest.js +23 -1
  43. package/dist/model/TSSRequestWebhookEventData.js +263 -0
  44. package/dist/model/TransactionDepositFromWalletSource.js +6 -6
  45. package/dist/model/TransactionDepositToAddressDestination.js +2 -2
  46. package/dist/model/TransactionDepositToWalletDestination.js +9 -9
  47. package/dist/model/TransactionDestination.js +5 -5
  48. package/dist/model/TransactionEvmContractDestination.js +1 -1
  49. package/dist/model/TransactionExchangeWalletSource.js +6 -6
  50. package/dist/model/TransactionMPCWalletSource.js +13 -0
  51. package/dist/model/TransactionSource.js +8 -2
  52. package/dist/model/TransactionSubStatus.js +5 -0
  53. package/dist/model/TransactionTransferToAddressDestinationAccountOutput.js +1 -1
  54. package/dist/model/TransactionTransferToAddressDestinationUtxoOutputsInner.js +1 -1
  55. package/dist/model/TransactionTransferToWalletDestination.js +9 -9
  56. package/dist/model/TransactionWebhookEventData.js +8 -3
  57. package/dist/model/TransferDestination.js +6 -6
  58. package/dist/model/TransferParams.js +2 -2
  59. package/dist/model/TransferSource.js +3 -3
  60. package/dist/model/WalletInfo.js +12 -0
  61. package/dist/model/WebhookEventData.js +49 -15
  62. package/dist/model/WebhookEventDataType.js +7 -2
  63. package/dist/model/WebhookEventType.js +24 -4
  64. package/docs/AddressInfo.md +1 -1
  65. package/docs/AddressTransferDestination.md +2 -2
  66. package/docs/AddressTransferDestinationAccountOutput.md +1 -1
  67. package/docs/AddressTransferDestinationUtxoOutputsInner.md +1 -1
  68. package/docs/AssetInfo.md +1 -1
  69. package/docs/BabylonStakeExtra.md +1 -0
  70. package/docs/CheckAddressValidity200Response.md +1 -1
  71. package/docs/CheckAddressesValidity200ResponseInner.md +10 -0
  72. package/docs/CheckLoopTransfers200ResponseInner.md +10 -0
  73. package/docs/ContractCallDestination.md +1 -1
  74. package/docs/CreateStakeActivity.md +1 -0
  75. package/docs/CreateStakeActivityExtra.md +1 -0
  76. package/docs/CreateTssRequestRequest.md +1 -0
  77. package/docs/CreateUnstakeActivity.md +1 -0
  78. package/docs/CreateWithdrawActivity.md +1 -0
  79. package/docs/CreatedWalletInfo.md +2 -0
  80. package/docs/DevelopersWebhooksApi.md +78 -69
  81. package/docs/EstimateStakeFee.md +1 -0
  82. package/docs/EstimateUnstakeFee.md +1 -0
  83. package/docs/EstimateWithdrawFee.md +1 -0
  84. package/docs/EvmContractCallDestination.md +1 -1
  85. package/docs/ExchangeId.md +2 -0
  86. package/docs/ExchangeTransferDestination.md +2 -2
  87. package/docs/ExchangeTransferSource.md +1 -1
  88. package/docs/GetToken200Response.md +4 -4
  89. package/docs/KeyShareHolder.md +1 -0
  90. package/docs/ListAssetBalancesForExchangeWallet200Response.md +10 -0
  91. package/docs/ListExchanges200ResponseInner.md +10 -0
  92. package/docs/ListSupportedAssetsForExchange200Response.md +10 -0
  93. package/docs/MPCWalletInfo.md +2 -0
  94. package/docs/OAuthApi.md +26 -24
  95. package/docs/RefreshToken200Response.md +13 -0
  96. package/docs/RefreshTokenRequest.md +2 -2
  97. package/docs/SmartContractWalletType.md +1 -1
  98. package/docs/SubWalletAssetBalance.md +2 -2
  99. package/docs/TSSRequest.md +2 -0
  100. package/docs/TSSRequestWebhookEventData.md +29 -0
  101. package/docs/TransactionDepositFromWalletSource.md +1 -1
  102. package/docs/TransactionDepositToAddressDestination.md +1 -1
  103. package/docs/TransactionDepositToWalletDestination.md +2 -2
  104. package/docs/TransactionDestination.md +3 -3
  105. package/docs/TransactionEvmContractDestination.md +1 -1
  106. package/docs/TransactionExchangeWalletSource.md +1 -1
  107. package/docs/TransactionMPCWalletSource.md +1 -0
  108. package/docs/TransactionSource.md +2 -1
  109. package/docs/TransactionSubStatus.md +2 -0
  110. package/docs/TransactionTransferToAddressDestinationAccountOutput.md +1 -1
  111. package/docs/TransactionTransferToAddressDestinationUtxoOutputsInner.md +1 -1
  112. package/docs/TransactionTransferToWalletDestination.md +2 -2
  113. package/docs/TransactionWebhookEventData.md +3 -1
  114. package/docs/TransactionsApi.md +98 -88
  115. package/docs/TransferDestination.md +4 -4
  116. package/docs/TransferParams.md +1 -1
  117. package/docs/TransferSource.md +1 -1
  118. package/docs/WalletInfo.md +2 -0
  119. package/docs/WalletsApi.md +316 -187
  120. package/docs/WalletsExchangeWalletApi.md +230 -0
  121. package/docs/WalletsMPCWalletsApi.md +153 -135
  122. package/docs/WebhookEventData.md +10 -5
  123. package/docs/WebhookEventDataType.md +3 -1
  124. package/docs/WebhookEventType.md +12 -4
  125. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -141,6 +141,18 @@ Object.defineProperty(exports, "CheckAddressValidity200Response", {
141
141
  return _CheckAddressValidity200Response["default"];
142
142
  }
143
143
  });
144
+ Object.defineProperty(exports, "CheckAddressesValidity200ResponseInner", {
145
+ enumerable: true,
146
+ get: function get() {
147
+ return _CheckAddressesValidity200ResponseInner["default"];
148
+ }
149
+ });
150
+ Object.defineProperty(exports, "CheckLoopTransfers200ResponseInner", {
151
+ enumerable: true,
152
+ get: function get() {
153
+ return _CheckLoopTransfers200ResponseInner["default"];
154
+ }
155
+ });
144
156
  Object.defineProperty(exports, "CoboSafeDelegate", {
145
157
  enumerable: true,
146
158
  get: function get() {
@@ -609,6 +621,18 @@ Object.defineProperty(exports, "ListAddresses200Response", {
609
621
  return _ListAddresses200Response["default"];
610
622
  }
611
623
  });
624
+ Object.defineProperty(exports, "ListAssetBalancesForExchangeWallet200Response", {
625
+ enumerable: true,
626
+ get: function get() {
627
+ return _ListAssetBalancesForExchangeWallet200Response["default"];
628
+ }
629
+ });
630
+ Object.defineProperty(exports, "ListExchanges200ResponseInner", {
631
+ enumerable: true,
632
+ get: function get() {
633
+ return _ListExchanges200ResponseInner["default"];
634
+ }
635
+ });
612
636
  Object.defineProperty(exports, "ListKeyShareHolderGroups200Response", {
613
637
  enumerable: true,
614
638
  get: function get() {
@@ -627,6 +651,12 @@ Object.defineProperty(exports, "ListMpcVaults200Response", {
627
651
  return _ListMpcVaults200Response["default"];
628
652
  }
629
653
  });
654
+ Object.defineProperty(exports, "ListSupportedAssetsForExchange200Response", {
655
+ enumerable: true,
656
+ get: function get() {
657
+ return _ListSupportedAssetsForExchange200Response["default"];
658
+ }
659
+ });
630
660
  Object.defineProperty(exports, "ListSupportedChains200Response", {
631
661
  enumerable: true,
632
662
  get: function get() {
@@ -837,6 +867,12 @@ Object.defineProperty(exports, "PoolSummary", {
837
867
  return _PoolSummary["default"];
838
868
  }
839
869
  });
870
+ Object.defineProperty(exports, "RefreshToken200Response", {
871
+ enumerable: true,
872
+ get: function get() {
873
+ return _RefreshToken200Response["default"];
874
+ }
875
+ });
840
876
  Object.defineProperty(exports, "RefreshTokenRequest", {
841
877
  enumerable: true,
842
878
  get: function get() {
@@ -963,6 +999,12 @@ Object.defineProperty(exports, "TSSRequestType", {
963
999
  return _TSSRequestType["default"];
964
1000
  }
965
1001
  });
1002
+ Object.defineProperty(exports, "TSSRequestWebhookEventData", {
1003
+ enumerable: true,
1004
+ get: function get() {
1005
+ return _TSSRequestWebhookEventData["default"];
1006
+ }
1007
+ });
966
1008
  Object.defineProperty(exports, "TokenBalance", {
967
1009
  enumerable: true,
968
1010
  get: function get() {
@@ -1437,6 +1479,12 @@ Object.defineProperty(exports, "WalletsApi", {
1437
1479
  return _WalletsApi["default"];
1438
1480
  }
1439
1481
  });
1482
+ Object.defineProperty(exports, "WalletsExchangeWalletApi", {
1483
+ enumerable: true,
1484
+ get: function get() {
1485
+ return _WalletsExchangeWalletApi["default"];
1486
+ }
1487
+ });
1440
1488
  Object.defineProperty(exports, "WalletsMPCWalletsApi", {
1441
1489
  enumerable: true,
1442
1490
  get: function get() {
@@ -1515,6 +1563,8 @@ var _BaseEstimateStakingFee = _interopRequireDefault(require("./model/BaseEstima
1515
1563
  var _BaseStakeExtra = _interopRequireDefault(require("./model/BaseStakeExtra"));
1516
1564
  var _ChainInfo = _interopRequireDefault(require("./model/ChainInfo"));
1517
1565
  var _CheckAddressValidity200Response = _interopRequireDefault(require("./model/CheckAddressValidity200Response"));
1566
+ var _CheckAddressesValidity200ResponseInner = _interopRequireDefault(require("./model/CheckAddressesValidity200ResponseInner"));
1567
+ var _CheckLoopTransfers200ResponseInner = _interopRequireDefault(require("./model/CheckLoopTransfers200ResponseInner"));
1518
1568
  var _CoboSafeDelegate = _interopRequireDefault(require("./model/CoboSafeDelegate"));
1519
1569
  var _CoboSafeDelegateType = _interopRequireDefault(require("./model/CoboSafeDelegateType"));
1520
1570
  var _ContractCallDestination = _interopRequireDefault(require("./model/ContractCallDestination"));
@@ -1591,9 +1641,12 @@ var _KeyShareHolderGroupType = _interopRequireDefault(require("./model/KeyShareH
1591
1641
  var _KeyShareHolderStatus = _interopRequireDefault(require("./model/KeyShareHolderStatus"));
1592
1642
  var _KeyShareHolderType = _interopRequireDefault(require("./model/KeyShareHolderType"));
1593
1643
  var _ListAddresses200Response = _interopRequireDefault(require("./model/ListAddresses200Response"));
1644
+ var _ListAssetBalancesForExchangeWallet200Response = _interopRequireDefault(require("./model/ListAssetBalancesForExchangeWallet200Response"));
1645
+ var _ListExchanges200ResponseInner = _interopRequireDefault(require("./model/ListExchanges200ResponseInner"));
1594
1646
  var _ListKeyShareHolderGroups200Response = _interopRequireDefault(require("./model/ListKeyShareHolderGroups200Response"));
1595
1647
  var _ListMpcProjects200Response = _interopRequireDefault(require("./model/ListMpcProjects200Response"));
1596
1648
  var _ListMpcVaults200Response = _interopRequireDefault(require("./model/ListMpcVaults200Response"));
1649
+ var _ListSupportedAssetsForExchange200Response = _interopRequireDefault(require("./model/ListSupportedAssetsForExchange200Response"));
1597
1650
  var _ListSupportedChains200Response = _interopRequireDefault(require("./model/ListSupportedChains200Response"));
1598
1651
  var _ListSupportedTokens200Response = _interopRequireDefault(require("./model/ListSupportedTokens200Response"));
1599
1652
  var _ListTokenBalancesForAddress200Response = _interopRequireDefault(require("./model/ListTokenBalancesForAddress200Response"));
@@ -1628,6 +1681,7 @@ var _Pagination = _interopRequireDefault(require("./model/Pagination"));
1628
1681
  var _PoolDetails = _interopRequireDefault(require("./model/PoolDetails"));
1629
1682
  var _PoolDetailsAllOfValidatorsInfo = _interopRequireDefault(require("./model/PoolDetailsAllOfValidatorsInfo"));
1630
1683
  var _PoolSummary = _interopRequireDefault(require("./model/PoolSummary"));
1684
+ var _RefreshToken200Response = _interopRequireDefault(require("./model/RefreshToken200Response"));
1631
1685
  var _RefreshTokenRequest = _interopRequireDefault(require("./model/RefreshTokenRequest"));
1632
1686
  var _ReplaceType = _interopRequireDefault(require("./model/ReplaceType"));
1633
1687
  var _RetryWebhookEventById201Response = _interopRequireDefault(require("./model/RetryWebhookEventById201Response"));
@@ -1649,6 +1703,7 @@ var _TSSGroups = _interopRequireDefault(require("./model/TSSGroups"));
1649
1703
  var _TSSRequest = _interopRequireDefault(require("./model/TSSRequest"));
1650
1704
  var _TSSRequestStatus = _interopRequireDefault(require("./model/TSSRequestStatus"));
1651
1705
  var _TSSRequestType = _interopRequireDefault(require("./model/TSSRequestType"));
1706
+ var _TSSRequestWebhookEventData = _interopRequireDefault(require("./model/TSSRequestWebhookEventData"));
1652
1707
  var _TokenBalance = _interopRequireDefault(require("./model/TokenBalance"));
1653
1708
  var _TokenBalanceBalance = _interopRequireDefault(require("./model/TokenBalanceBalance"));
1654
1709
  var _TokenInfo = _interopRequireDefault(require("./model/TokenInfo"));
@@ -1738,5 +1793,6 @@ var _DevelopersWebhooksApi = _interopRequireDefault(require("./api/DevelopersWeb
1738
1793
  var _OAuthApi = _interopRequireDefault(require("./api/OAuthApi"));
1739
1794
  var _TransactionsApi = _interopRequireDefault(require("./api/TransactionsApi"));
1740
1795
  var _WalletsApi = _interopRequireDefault(require("./api/WalletsApi"));
1796
+ var _WalletsExchangeWalletApi = _interopRequireDefault(require("./api/WalletsExchangeWalletApi"));
1741
1797
  var _WalletsMPCWalletsApi = _interopRequireDefault(require("./api/WalletsMPCWalletsApi"));
1742
1798
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
@@ -156,7 +156,7 @@ AddressInfo.prototype['chain_id'] = undefined;
156
156
  AddressInfo.prototype['memo'] = undefined;
157
157
 
158
158
  /**
159
- * The derivation path of the address. This property applies to MPC Wallets only.
159
+ * The derivation path of the address. This property applies to MPC Wallets only. To learn the meaning of each level in the path, see [Path levels](https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki#path-levels).
160
160
  * @member {String} path
161
161
  */
162
162
  AddressInfo.prototype['path'] = undefined;
@@ -34,7 +34,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
34
34
  var AddressTransferDestination = /*#__PURE__*/function () {
35
35
  /**
36
36
  * Constructs a new <code>AddressTransferDestination</code>.
37
- * The information about the transaction destination type &#x60;Address&#x60;. Specify either the &#x60;account_output&#x60; property or the &#x60;utxo_outputs&#x60; property. Only MPC Wallets as the transaction source can transfer tokens to multiple addresses by using the &#x60;utxo_outputs&#x60; property.
37
+ * The information about the transaction destination type &#x60;Address&#x60;. Specify either the &#x60;account_output&#x60; property or the &#x60;utxo_outputs&#x60; property. You can transfer tokens to multiple addresses only if you use MPC Wallets as the transaction source. You should use the &#x60;utxo_outputs&#x60; property to specify the destination addresses.
38
38
  * @alias module:model/AddressTransferDestination
39
39
  * @param destination_type {module:model/TransferDestinationType}
40
40
  */
@@ -171,13 +171,13 @@ AddressTransferDestination.prototype['utxo_outputs'] = undefined;
171
171
  AddressTransferDestination.prototype['change_address'] = undefined;
172
172
 
173
173
  /**
174
- * Whether the transaction request must be executed as a Loop transfer. For more information about Loop, see [Loop's website](https://loop.top/). - `true`: The transaction request must be executed as a Loop transfer. - `false`: The transaction request may not be executed as a Loop transfer.
174
+ * Whether the transaction request must be executed as a Loop transfer. For more information about Loop, see [Loop's website](https://loop.top/). - `true`: The transaction request must be executed as a Loop transfer. - `false`: The transaction request may not be executed as a Loop transfer. <Note>Please do not set both `force_internal` and `force_internal` as `true`.</Note>
175
175
  * @member {Boolean} force_internal
176
176
  */
177
177
  AddressTransferDestination.prototype['force_internal'] = undefined;
178
178
 
179
179
  /**
180
- * Whether the transaction request must not be executed as a Loop transfer. For more information about Loop, see [Loop's website](https://loop.top/). - `true`: The transaction request must not be executed as a Loop transfer. - `false`: The transaction request can be executed as a Loop transfer.
180
+ * Whether the transaction request must not be executed as a Loop transfer. For more information about Loop, see [Loop's website](https://loop.top/). - `true`: The transaction request must not be executed as a Loop transfer. - `false`: The transaction request can be executed as a Loop transfer. <Note>Please do not set both `force_internal` and `force_internal` as `true`.</Note>
181
181
  * @member {Boolean} force_external
182
182
  */
183
183
  AddressTransferDestination.prototype['force_external'] = undefined;
@@ -33,7 +33,7 @@ var AddressTransferDestinationAccountOutput = /*#__PURE__*/function () {
33
33
  * Constructs a new <code>AddressTransferDestinationAccountOutput</code>.
34
34
  * @alias module:model/AddressTransferDestinationAccountOutput
35
35
  * @param address {String} The destination address.
36
- * @param amount {String} The quantity of the token in the transaction. For example, if you trade 1.5 ETH, then the value is `1.5`.
36
+ * @param amount {String} The transfer amount. For example, if you trade 1.5 ETH, then the value is `1.5`.
37
37
  */
38
38
  function AddressTransferDestinationAccountOutput(address, amount) {
39
39
  _classCallCheck(this, AddressTransferDestinationAccountOutput);
@@ -131,7 +131,7 @@ AddressTransferDestinationAccountOutput.prototype['address'] = undefined;
131
131
  AddressTransferDestinationAccountOutput.prototype['memo'] = undefined;
132
132
 
133
133
  /**
134
- * The quantity of the token in the transaction. For example, if you trade 1.5 ETH, then the value is `1.5`.
134
+ * The transfer amount. For example, if you trade 1.5 ETH, then the value is `1.5`.
135
135
  * @member {String} amount
136
136
  */
137
137
  AddressTransferDestinationAccountOutput.prototype['amount'] = undefined;
@@ -123,7 +123,7 @@ AddressTransferDestinationUtxoOutputsInner.RequiredProperties = ["address"];
123
123
  AddressTransferDestinationUtxoOutputsInner.prototype['address'] = undefined;
124
124
 
125
125
  /**
126
- * The quantity of the token in the transaction. For example, if you trade 1.5 ETH, then the value is `1.5`.
126
+ * The transfer amount. For example, if you trade 1.5 ETH, then the value is `1.5`.
127
127
  * @member {String} amount
128
128
  */
129
129
  AddressTransferDestinationUtxoOutputsInner.prototype['amount'] = undefined;
@@ -33,7 +33,7 @@ var AssetInfo = /*#__PURE__*/function () {
33
33
  * Constructs a new <code>AssetInfo</code>.
34
34
  * The asset information.
35
35
  * @alias module:model/AssetInfo
36
- * @param asset_id {String} (This concept applies to Exchange Wallets only) The asset ID. An asset ID is the unique identifier of the asset held within your linked exchange account.
36
+ * @param asset_id {String} The asset ID. An asset ID is the unique identifier of the asset held within your linked exchange account.
37
37
  */
38
38
  function AssetInfo(asset_id) {
39
39
  _classCallCheck(this, AssetInfo);
@@ -125,7 +125,7 @@ var AssetInfo = /*#__PURE__*/function () {
125
125
  AssetInfo.RequiredProperties = ["asset_id"];
126
126
 
127
127
  /**
128
- * (This concept applies to Exchange Wallets only) The asset ID. An asset ID is the unique identifier of the asset held within your linked exchange account.
128
+ * The asset ID. An asset ID is the unique identifier of the asset held within your linked exchange account.
129
129
  * @member {String} asset_id
130
130
  */
131
131
  AssetInfo.prototype['asset_id'] = undefined;
@@ -80,6 +80,9 @@ var BabylonStakeExtra = /*#__PURE__*/function () {
80
80
  if (data.hasOwnProperty('stake_block_time')) {
81
81
  obj['stake_block_time'] = _ApiClient["default"].convertToType(data['stake_block_time'], 'Number');
82
82
  }
83
+ if (data.hasOwnProperty('only_sign')) {
84
+ obj['only_sign'] = _ApiClient["default"].convertToType(data['only_sign'], 'Boolean');
85
+ }
83
86
  }
84
87
  return obj;
85
88
  }
@@ -134,6 +137,12 @@ BabylonStakeExtra.prototype['finality_provider_public_key'] = undefined;
134
137
  */
135
138
  BabylonStakeExtra.prototype['stake_block_time'] = undefined;
136
139
 
140
+ /**
141
+ * Whether to only sign transactions. Default is `false`, if set to `true`, the transaction will not be submitted to the blockchain automatically. You can call `Broadcast transactions` to submit the transaction to the blockchain, Or you can find the signed raw_tx by `Get transaction information` and broadcast it yourself.
142
+ * @member {Boolean} only_sign
143
+ */
144
+ BabylonStakeExtra.prototype['only_sign'] = undefined;
145
+
137
146
  // Implement BaseStakeExtra interface:
138
147
  /**
139
148
  * @member {module:model/StakingPoolType} pool_type
@@ -32,7 +32,7 @@ var CheckAddressValidity200Response = /*#__PURE__*/function () {
32
32
  /**
33
33
  * Constructs a new <code>CheckAddressValidity200Response</code>.
34
34
  * @alias module:model/CheckAddressValidity200Response
35
- * @param validity {Boolean} Whether the address is valid. - `true`: The address is valid. - `false`: the address is invalid.
35
+ * @param validity {Boolean} Whether the address is valid. - `true`: The address is valid. - `false`: The address is invalid.
36
36
  */
37
37
  function CheckAddressValidity200Response(validity) {
38
38
  _classCallCheck(this, CheckAddressValidity200Response);
@@ -99,7 +99,7 @@ var CheckAddressValidity200Response = /*#__PURE__*/function () {
99
99
  CheckAddressValidity200Response.RequiredProperties = ["validity"];
100
100
 
101
101
  /**
102
- * Whether the address is valid. - `true`: The address is valid. - `false`: the address is invalid.
102
+ * Whether the address is valid. - `true`: The address is valid. - `false`: The address is invalid.
103
103
  * @member {Boolean} validity
104
104
  */
105
105
  CheckAddressValidity200Response.prototype['validity'] = undefined;
@@ -0,0 +1,121 @@
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: support@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 CheckAddressesValidity200ResponseInner model module.
29
+ * @module model/CheckAddressesValidity200ResponseInner
30
+ */
31
+ var CheckAddressesValidity200ResponseInner = /*#__PURE__*/function () {
32
+ /**
33
+ * Constructs a new <code>CheckAddressesValidity200ResponseInner</code>.
34
+ * @alias module:model/CheckAddressesValidity200ResponseInner
35
+ * @param address {String} The wallet address.
36
+ * @param validity {Boolean} Whether the address is valid. - `true`: The address is valid. - `false`: The address is invalid.
37
+ */
38
+ function CheckAddressesValidity200ResponseInner(address, validity) {
39
+ _classCallCheck(this, CheckAddressesValidity200ResponseInner);
40
+ CheckAddressesValidity200ResponseInner.initialize(this, address, validity);
41
+ }
42
+
43
+ /**
44
+ * Initializes the fields of this object.
45
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
46
+ * Only for internal use.
47
+ */
48
+ return _createClass(CheckAddressesValidity200ResponseInner, null, [{
49
+ key: "initialize",
50
+ value: function initialize(obj, address, validity) {
51
+ obj['address'] = address;
52
+ obj['validity'] = validity;
53
+ }
54
+
55
+ /**
56
+ * Constructs a <code>CheckAddressesValidity200ResponseInner</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/CheckAddressesValidity200ResponseInner} obj Optional instance to populate.
60
+ * @return {module:model/CheckAddressesValidity200ResponseInner} The populated <code>CheckAddressesValidity200ResponseInner</code> instance.
61
+ */
62
+ }, {
63
+ key: "constructFromObject",
64
+ value: function constructFromObject(data, obj) {
65
+ if (data) {
66
+ obj = obj || new CheckAddressesValidity200ResponseInner();
67
+ if (data.hasOwnProperty('address')) {
68
+ obj['address'] = _ApiClient["default"].convertToType(data['address'], 'String');
69
+ }
70
+ if (data.hasOwnProperty('validity')) {
71
+ obj['validity'] = _ApiClient["default"].convertToType(data['validity'], 'Boolean');
72
+ }
73
+ }
74
+ return obj;
75
+ }
76
+
77
+ /**
78
+ * Validates the JSON data with respect to <code>CheckAddressesValidity200ResponseInner</code>.
79
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
80
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>CheckAddressesValidity200ResponseInner</code>.
81
+ */
82
+ }, {
83
+ key: "validateJSON",
84
+ value: function validateJSON(data) {
85
+ // check to make sure all required properties are present in the JSON string
86
+ var _iterator = _createForOfIteratorHelper(CheckAddressesValidity200ResponseInner.RequiredProperties),
87
+ _step;
88
+ try {
89
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
90
+ var property = _step.value;
91
+ if (!data.hasOwnProperty(property)) {
92
+ throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
93
+ }
94
+ }
95
+ // ensure the json data is a string
96
+ } catch (err) {
97
+ _iterator.e(err);
98
+ } finally {
99
+ _iterator.f();
100
+ }
101
+ if (data['address'] && !(typeof data['address'] === 'string' || data['address'] instanceof String)) {
102
+ throw new Error("Expected the field `address` to be a primitive type in the JSON string but got " + data['address']);
103
+ }
104
+ return true;
105
+ }
106
+ }]);
107
+ }();
108
+ CheckAddressesValidity200ResponseInner.RequiredProperties = ["address", "validity"];
109
+
110
+ /**
111
+ * The wallet address.
112
+ * @member {String} address
113
+ */
114
+ CheckAddressesValidity200ResponseInner.prototype['address'] = undefined;
115
+
116
+ /**
117
+ * Whether the address is valid. - `true`: The address is valid. - `false`: The address is invalid.
118
+ * @member {Boolean} validity
119
+ */
120
+ CheckAddressesValidity200ResponseInner.prototype['validity'] = undefined;
121
+ var _default = exports["default"] = CheckAddressesValidity200ResponseInner;
@@ -0,0 +1,96 @@
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 _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
11
+ 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); } }
12
+ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
13
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
14
+ 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); } /**
15
+ * Cobo Wallet as a Service 2.0
16
+ *
17
+ * Contact: support@cobo.com
18
+ *
19
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
20
+ * https://openapi-generator.tech
21
+ * Do not edit the class manually.
22
+ *
23
+ */
24
+ /**
25
+ * The CheckLoopTransfers200ResponseInner model module.
26
+ * @module model/CheckLoopTransfers200ResponseInner
27
+ */
28
+ var CheckLoopTransfers200ResponseInner = /*#__PURE__*/function () {
29
+ /**
30
+ * Constructs a new <code>CheckLoopTransfers200ResponseInner</code>.
31
+ * @alias module:model/CheckLoopTransfers200ResponseInner
32
+ */
33
+ function CheckLoopTransfers200ResponseInner() {
34
+ _classCallCheck(this, CheckLoopTransfers200ResponseInner);
35
+ CheckLoopTransfers200ResponseInner.initialize(this);
36
+ }
37
+
38
+ /**
39
+ * Initializes the fields of this object.
40
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
41
+ * Only for internal use.
42
+ */
43
+ return _createClass(CheckLoopTransfers200ResponseInner, null, [{
44
+ key: "initialize",
45
+ value: function initialize(obj) {}
46
+
47
+ /**
48
+ * Constructs a <code>CheckLoopTransfers200ResponseInner</code> from a plain JavaScript object, optionally creating a new instance.
49
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
50
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
51
+ * @param {module:model/CheckLoopTransfers200ResponseInner} obj Optional instance to populate.
52
+ * @return {module:model/CheckLoopTransfers200ResponseInner} The populated <code>CheckLoopTransfers200ResponseInner</code> instance.
53
+ */
54
+ }, {
55
+ key: "constructFromObject",
56
+ value: function constructFromObject(data, obj) {
57
+ if (data) {
58
+ obj = obj || new CheckLoopTransfers200ResponseInner();
59
+ if (data.hasOwnProperty('address')) {
60
+ obj['address'] = _ApiClient["default"].convertToType(data['address'], 'String');
61
+ }
62
+ if (data.hasOwnProperty('is_loop')) {
63
+ obj['is_loop'] = _ApiClient["default"].convertToType(data['is_loop'], 'Boolean');
64
+ }
65
+ }
66
+ return obj;
67
+ }
68
+
69
+ /**
70
+ * Validates the JSON data with respect to <code>CheckLoopTransfers200ResponseInner</code>.
71
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
72
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>CheckLoopTransfers200ResponseInner</code>.
73
+ */
74
+ }, {
75
+ key: "validateJSON",
76
+ value: function validateJSON(data) {
77
+ // ensure the json data is a string
78
+ if (data['address'] && !(typeof data['address'] === 'string' || data['address'] instanceof String)) {
79
+ throw new Error("Expected the field `address` to be a primitive type in the JSON string but got " + data['address']);
80
+ }
81
+ return true;
82
+ }
83
+ }]);
84
+ }();
85
+ /**
86
+ * The wallet address.
87
+ * @member {String} address
88
+ */
89
+ CheckLoopTransfers200ResponseInner.prototype['address'] = undefined;
90
+
91
+ /**
92
+ * Whether the transaction from the given source wallet to the destination address can be executed as a Loop transfer. - `true`: The transaction can be executed as a Loop transfer. - `false`: The transaction cannot be executed as a Loop transfer.
93
+ * @member {Boolean} is_loop
94
+ */
95
+ CheckLoopTransfers200ResponseInner.prototype['is_loop'] = undefined;
96
+ var _default = exports["default"] = CheckLoopTransfers200ResponseInner;
@@ -135,7 +135,7 @@ ContractCallDestination.prototype['destination_type'] = undefined;
135
135
  ContractCallDestination.prototype['address'] = undefined;
136
136
 
137
137
  /**
138
- * The quantity of the token in the transaction. For example, if you trade 1.5 ETH, then the value is `1.5`.
138
+ * The transfer amount. For example, if you trade 1.5 ETH, then the value is `1.5`.
139
139
  * @member {String} value
140
140
  */
141
141
  ContractCallDestination.prototype['value'] = undefined;
@@ -71,6 +71,9 @@ var CreateStakeActivity = /*#__PURE__*/function () {
71
71
  value: function constructFromObject(data, obj) {
72
72
  if (data) {
73
73
  obj = obj || new CreateStakeActivity();
74
+ if (data.hasOwnProperty('request_id')) {
75
+ obj['request_id'] = _ApiClient["default"].convertToType(data['request_id'], 'String');
76
+ }
74
77
  if (data.hasOwnProperty('source')) {
75
78
  obj['source'] = _StakingSource["default"].constructFromObject(data['source']);
76
79
  }
@@ -108,12 +111,16 @@ var CreateStakeActivity = /*#__PURE__*/function () {
108
111
  throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
109
112
  }
110
113
  }
111
- // validate the optional field `source`
114
+ // ensure the json data is a string
112
115
  } catch (err) {
113
116
  _iterator.e(err);
114
117
  } finally {
115
118
  _iterator.f();
116
119
  }
120
+ if (data['request_id'] && !(typeof data['request_id'] === 'string' || data['request_id'] instanceof String)) {
121
+ throw new Error("Expected the field `request_id` to be a primitive type in the JSON string but got " + data['request_id']);
122
+ }
123
+ // validate the optional field `source`
117
124
  if (data['source']) {
118
125
  // data not null
119
126
  if (!!_StakingSource["default"].validateJSON) {
@@ -148,6 +155,12 @@ var CreateStakeActivity = /*#__PURE__*/function () {
148
155
  }();
149
156
  CreateStakeActivity.RequiredProperties = ["pool_id", "amount", "fee", "extra"];
150
157
 
158
+ /**
159
+ * The request ID that is used to track a request. The request ID is provided by you and must be unique within your organization.
160
+ * @member {String} request_id
161
+ */
162
+ CreateStakeActivity.prototype['request_id'] = undefined;
163
+
151
164
  /**
152
165
  * @member {module:model/StakingSource} source
153
166
  */
@@ -172,6 +172,12 @@ CreateStakeActivityExtra.prototype['finality_provider_public_key'] = undefined;
172
172
  */
173
173
  CreateStakeActivityExtra.prototype['stake_block_time'] = undefined;
174
174
 
175
+ /**
176
+ * Whether to only sign transactions. Default is `false`, if set to `true`, the transaction will not be submitted to the blockchain automatically. You can call `Broadcast transactions` to submit the transaction to the blockchain, Or you can find the signed raw_tx by `Get transaction information` and broadcast it yourself.
177
+ * @member {Boolean} only_sign
178
+ */
179
+ CreateStakeActivityExtra.prototype['only_sign'] = undefined;
180
+
175
181
  /**
176
182
  * The operator address.
177
183
  * @member {String} operator
@@ -75,6 +75,9 @@ var CreateTssRequestRequest = /*#__PURE__*/function () {
75
75
  if (data.hasOwnProperty('source_key_share_holder_group')) {
76
76
  obj['source_key_share_holder_group'] = _SourceGroup["default"].constructFromObject(data['source_key_share_holder_group']);
77
77
  }
78
+ if (data.hasOwnProperty('description')) {
79
+ obj['description'] = _ApiClient["default"].convertToType(data['description'], 'String');
80
+ }
78
81
  }
79
82
  return obj;
80
83
  }
@@ -113,6 +116,10 @@ var CreateTssRequestRequest = /*#__PURE__*/function () {
113
116
  _SourceGroup["default"].validateJSON(data['source_key_share_holder_group']);
114
117
  }
115
118
  }
119
+ // ensure the json data is a string
120
+ if (data['description'] && !(typeof data['description'] === 'string' || data['description'] instanceof String)) {
121
+ throw new Error("Expected the field `description` to be a primitive type in the JSON string but got " + data['description']);
122
+ }
116
123
  return true;
117
124
  }
118
125
  }]);
@@ -134,4 +141,10 @@ CreateTssRequestRequest.prototype['target_key_share_holder_group_id'] = undefine
134
141
  * @member {module:model/SourceGroup} source_key_share_holder_group
135
142
  */
136
143
  CreateTssRequestRequest.prototype['source_key_share_holder_group'] = undefined;
144
+
145
+ /**
146
+ * The description of the TSS request.
147
+ * @member {String} description
148
+ */
149
+ CreateTssRequestRequest.prototype['description'] = undefined;
137
150
  var _default = exports["default"] = CreateTssRequestRequest;
@@ -63,6 +63,9 @@ var CreateUnstakeActivity = /*#__PURE__*/function () {
63
63
  value: function constructFromObject(data, obj) {
64
64
  if (data) {
65
65
  obj = obj || new CreateUnstakeActivity();
66
+ if (data.hasOwnProperty('request_id')) {
67
+ obj['request_id'] = _ApiClient["default"].convertToType(data['request_id'], 'String');
68
+ }
66
69
  if (data.hasOwnProperty('staking_id')) {
67
70
  obj['staking_id'] = _ApiClient["default"].convertToType(data['staking_id'], 'String');
68
71
  }
@@ -100,6 +103,10 @@ var CreateUnstakeActivity = /*#__PURE__*/function () {
100
103
  } finally {
101
104
  _iterator.f();
102
105
  }
106
+ if (data['request_id'] && !(typeof data['request_id'] === 'string' || data['request_id'] instanceof String)) {
107
+ throw new Error("Expected the field `request_id` to be a primitive type in the JSON string but got " + data['request_id']);
108
+ }
109
+ // ensure the json data is a string
103
110
  if (data['staking_id'] && !(typeof data['staking_id'] === 'string' || data['staking_id'] instanceof String)) {
104
111
  throw new Error("Expected the field `staking_id` to be a primitive type in the JSON string but got " + data['staking_id']);
105
112
  }
@@ -120,6 +127,12 @@ var CreateUnstakeActivity = /*#__PURE__*/function () {
120
127
  }();
121
128
  CreateUnstakeActivity.RequiredProperties = ["staking_id"];
122
129
 
130
+ /**
131
+ * The request ID that is used to track a request. The request ID is provided by you and must be unique within your organization.
132
+ * @member {String} request_id
133
+ */
134
+ CreateUnstakeActivity.prototype['request_id'] = undefined;
135
+
123
136
  /**
124
137
  * The id of the related staking.
125
138
  * @member {String} staking_id
@@ -65,6 +65,9 @@ var CreateWithdrawActivity = /*#__PURE__*/function () {
65
65
  value: function constructFromObject(data, obj) {
66
66
  if (data) {
67
67
  obj = obj || new CreateWithdrawActivity();
68
+ if (data.hasOwnProperty('request_id')) {
69
+ obj['request_id'] = _ApiClient["default"].convertToType(data['request_id'], 'String');
70
+ }
68
71
  if (data.hasOwnProperty('staking_id')) {
69
72
  obj['staking_id'] = _ApiClient["default"].convertToType(data['staking_id'], 'String');
70
73
  }
@@ -105,6 +108,10 @@ var CreateWithdrawActivity = /*#__PURE__*/function () {
105
108
  } finally {
106
109
  _iterator.f();
107
110
  }
111
+ if (data['request_id'] && !(typeof data['request_id'] === 'string' || data['request_id'] instanceof String)) {
112
+ throw new Error("Expected the field `request_id` to be a primitive type in the JSON string but got " + data['request_id']);
113
+ }
114
+ // ensure the json data is a string
108
115
  if (data['staking_id'] && !(typeof data['staking_id'] === 'string' || data['staking_id'] instanceof String)) {
109
116
  throw new Error("Expected the field `staking_id` to be a primitive type in the JSON string but got " + data['staking_id']);
110
117
  }
@@ -129,6 +136,12 @@ var CreateWithdrawActivity = /*#__PURE__*/function () {
129
136
  }();
130
137
  CreateWithdrawActivity.RequiredProperties = ["staking_id", "fee"];
131
138
 
139
+ /**
140
+ * The request ID that is used to track a request. The request ID is provided by you and must be unique within your organization.
141
+ * @member {String} request_id
142
+ */
143
+ CreateWithdrawActivity.prototype['request_id'] = undefined;
144
+
132
145
  /**
133
146
  * The id of the related staking.
134
147
  * @member {String} staking_id