@cobo/cobo-waas2 1.2.0 → 1.3.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.
- package/README.md +41 -9
- package/dist/ApiClient.js +2 -2
- package/dist/PreRequestScript.js +640 -0
- package/dist/api/DevelopersWebhooksApi.js +1 -1
- package/dist/api/OAuthApi.js +5 -5
- package/dist/api/StakingsApi.js +538 -0
- package/dist/api/TransactionsApi.js +111 -9
- package/dist/api/WalletsApi.js +1 -60
- package/dist/api/WalletsExchangeWalletApi.js +5 -5
- package/dist/api/WalletsMPCWalletsApi.js +1 -1
- package/dist/index.js +154 -0
- package/dist/model/Activity.js +21 -12
- package/dist/model/ActivityAction.js +1 -1
- package/dist/model/ActivityInitiator.js +8 -8
- package/dist/model/ActivityStatus.js +1 -1
- package/dist/model/ActivityTimeline.js +4 -2
- package/dist/model/ActivityType.js +1 -16
- package/dist/model/AddressEncoding.js +1 -1
- package/dist/model/AddressInfo.js +40 -1
- package/dist/model/AddressTransferDestination.js +2 -2
- package/dist/model/AddressTransferDestinationAccountOutput.js +3 -3
- package/dist/model/AddressTransferDestinationUtxoOutputsInner.js +2 -2
- package/dist/model/AmountDetailsInner.js +1 -14
- package/dist/model/AmountStatus.js +1 -1
- package/dist/model/AssetBalance.js +1 -1
- package/dist/model/AssetInfo.js +1 -1
- package/dist/model/BabylonStakeExtra.js +10 -10
- package/dist/model/BabylonStakingExtra.js +175 -0
- package/dist/model/BabylonValidator.js +35 -15
- package/dist/model/BaseContractCallSource.js +2 -2
- package/dist/model/BaseEstimateStakingFee.js +1 -1
- package/dist/model/BaseStakeExtra.js +2 -2
- package/dist/model/BaseStakeSource.js +137 -0
- package/dist/model/BookkeepingRecord.js +243 -0
- package/dist/model/BookkeepingSummary.js +150 -0
- package/dist/model/BroadcastSignedTransactions201ResponseInner.js +125 -0
- package/dist/model/BroadcastSignedTransactionsRequest.js +87 -0
- package/dist/model/ChainInfo.js +10 -1
- package/dist/model/CheckAddressValidity200Response.js +1 -1
- package/dist/model/CheckAddressesValidity200ResponseInner.js +1 -1
- package/dist/model/CheckLoopTransfers200ResponseInner.js +2 -2
- package/dist/model/CoboSafeDelegate.js +28 -3
- package/dist/model/CoboSafeDelegateType.js +1 -1
- package/dist/model/ContractCallDestination.js +25 -4
- package/dist/model/ContractCallDestinationType.js +1 -1
- package/dist/model/ContractCallParams.js +1 -1
- package/dist/model/ContractCallSource.js +42 -5
- package/dist/model/ContractCallSourceType.js +1 -1
- package/dist/model/CreateAddressRequest.js +1 -1
- package/dist/model/CreateCustodialWalletParams.js +1 -1
- package/dist/model/CreateExchangeWalletParams.js +1 -1
- package/dist/model/CreateKeyShareHolder.js +1 -1
- package/dist/model/CreateKeyShareHolderGroupRequest.js +1 -1
- package/dist/model/CreateMpcProjectRequest.js +1 -1
- package/dist/model/CreateMpcVaultRequest.js +1 -1
- package/dist/model/CreateMpcWalletParams.js +1 -1
- package/dist/model/CreateSafeWalletParams.js +1 -1
- package/dist/model/CreateSmartContractWalletParams.js +24 -3
- package/dist/model/CreateStakeActivity.js +5 -5
- package/dist/model/CreateStakeActivity201Response.js +123 -0
- package/dist/model/CreateStakeActivityExtra.js +37 -60
- package/dist/model/CreateStakeActivityRequest.js +246 -0
- package/dist/model/CreateTransferTransaction201Response.js +1 -1
- package/dist/model/CreateTssRequestRequest.js +1 -1
- package/dist/model/CreateUnstakeActivity.js +4 -4
- package/dist/model/CreateUnstakeActivityRequest.js +200 -0
- package/dist/model/CreateWalletParams.js +52 -7
- package/dist/model/CreateWebhookEndpointRequest.js +1 -1
- package/dist/model/CreateWithdrawActivity.js +5 -5
- package/dist/model/CreateWithdrawActivityRequest.js +220 -0
- package/dist/model/CreatedWalletInfo.js +52 -7
- package/dist/model/CurveType.js +1 -1
- package/dist/model/CustodialTransferSource.js +2 -2
- package/dist/model/CustodialWalletInfo.js +1 -1
- package/dist/model/DeleteKeyShareHolderGroupById201Response.js +1 -1
- package/dist/model/DeleteWalletById201Response.js +1 -1
- package/dist/model/EigenLayerLstStakeExtra.js +2 -2
- package/dist/model/EigenLayerNativeStakeExtra.js +1 -1
- package/dist/model/EigenlayerValidator.js +1 -1
- package/dist/model/ErrorResponse.js +1 -1
- package/dist/model/EstimateContractCallFeeParams.js +1 -1
- package/dist/model/EstimateFeeParams.js +38 -5
- package/dist/model/EstimateFeeRequestType.js +1 -1
- package/dist/model/EstimateStakeFee.js +7 -7
- package/dist/model/EstimateTransferFeeParams.js +1 -1
- package/dist/model/EstimateUnstakeFee.js +6 -6
- package/dist/model/EstimateWithdrawFee.js +8 -8
- package/dist/model/EstimatedEvmEip1559Fee.js +1 -1
- package/dist/model/EstimatedEvmEip1559FeeSlow.js +1 -1
- package/dist/model/EstimatedEvmLegacyFee.js +1 -1
- package/dist/model/EstimatedEvmLegacyFeeSlow.js +1 -1
- package/dist/model/EstimatedFee.js +66 -9
- package/dist/model/EstimatedFixedFee.js +1 -1
- package/dist/model/EstimatedUtxoFee.js +1 -1
- package/dist/model/EstimatedUtxoFeeSlow.js +1 -1
- package/dist/model/EvmContractCallDestination.js +9 -5
- package/dist/model/EvmEIP191MessageSignDestination.js +2 -2
- package/dist/model/EvmEIP712MessageSignDestination.js +2 -2
- package/dist/model/EvmEip1559FeeBasePrice.js +1 -1
- package/dist/model/EvmEip1559FeeRate.js +1 -1
- package/dist/model/EvmLegacyFeeBasePrice.js +1 -1
- package/dist/model/EvmLegacyFeeRate.js +1 -1
- package/dist/model/ExchangeId.js +1 -1
- package/dist/model/ExchangeTransferDestination.js +4 -4
- package/dist/model/ExchangeTransferSource.js +2 -2
- package/dist/model/ExchangeWalletInfo.js +1 -1
- package/dist/model/ExtendedTokenInfo.js +37 -1
- package/dist/model/FeeAmount.js +1 -1
- package/dist/model/FeeGasLimit.js +1 -1
- package/dist/model/FeeRate.js +66 -9
- package/dist/model/FeeType.js +1 -1
- package/dist/model/FixedFeeRate.js +1 -1
- package/dist/model/GetStakingEstimationFee201Response.js +109 -0
- package/dist/model/GetStakingEstimationFeeRequest.js +256 -0
- package/dist/model/GetToken200Response.js +1 -1
- package/dist/model/GetToken4XXResponse.js +1 -1
- package/dist/model/KeyShareHolder.js +1 -1
- package/dist/model/KeyShareHolderGroup.js +1 -1
- package/dist/model/KeyShareHolderGroupStatus.js +1 -1
- package/dist/model/KeyShareHolderGroupType.js +1 -1
- package/dist/model/KeyShareHolderStatus.js +1 -1
- package/dist/model/KeyShareHolderType.js +1 -1
- package/dist/model/ListAddresses200Response.js +1 -1
- package/dist/model/ListAssetBalancesForExchangeWallet200Response.js +1 -1
- package/dist/model/ListExchanges200ResponseInner.js +1 -1
- package/dist/model/ListKeyShareHolderGroups200Response.js +1 -1
- package/dist/model/ListMpcProjects200Response.js +1 -1
- package/dist/model/ListMpcVaults200Response.js +1 -1
- package/dist/model/ListStakingActivities200Response.js +123 -0
- package/dist/model/ListStakingPools200Response.js +123 -0
- package/dist/model/ListStakings200Response.js +123 -0
- package/dist/model/ListSupportedAssetsForExchange200Response.js +1 -1
- package/dist/model/ListSupportedChains200Response.js +1 -1
- package/dist/model/ListSupportedTokens200Response.js +1 -1
- package/dist/model/ListTokenBalancesForAddress200Response.js +1 -1
- package/dist/model/ListTransactions200Response.js +1 -1
- package/dist/model/ListTssRequests200Response.js +1 -1
- package/dist/model/ListUtxos200Response.js +1 -1
- package/dist/model/ListWallets200Response.js +1 -1
- package/dist/model/ListWebhookEndpoints200Response.js +1 -1
- package/dist/model/ListWebhookEventDefinitions200ResponseInner.js +1 -1
- package/dist/model/ListWebhookEventLogs200Response.js +1 -1
- package/dist/model/ListWebhookEvents200Response.js +1 -1
- package/dist/model/LockUtxos201Response.js +1 -1
- package/dist/model/LockUtxosRequest.js +1 -1
- package/dist/model/LockUtxosRequestUtxosInner.js +1 -1
- package/dist/model/MPCDelegate.js +1 -1
- package/dist/model/MPCProject.js +1 -1
- package/dist/model/MPCVault.js +1 -1
- package/dist/model/MPCVaultType.js +1 -1
- package/dist/model/MPCWalletInfo.js +1 -1
- package/dist/model/MaxFeeAmount.js +1 -1
- package/dist/model/MaxTransferableValue.js +1 -1
- package/dist/model/MessageSignDestination.js +38 -5
- package/dist/model/MessageSignDestinationType.js +1 -1
- package/dist/model/MessageSignParams.js +1 -1
- package/dist/model/MessageSignSource.js +28 -3
- package/dist/model/MessageSignSourceType.js +1 -1
- package/dist/model/MpcContractCallSource.js +1 -1
- package/dist/model/MpcMessageSignSource.js +1 -1
- package/dist/model/MpcSigningGroup.js +1 -1
- package/dist/model/MpcStakeSource.js +156 -0
- package/dist/model/MpcTransferSource.js +2 -2
- package/dist/model/Pagination.js +1 -1
- package/dist/model/PoolDetails.js +27 -27
- package/dist/model/PoolDetailsAllOfValidatorsInfo.js +45 -40
- package/dist/model/PoolSummary.js +14 -14
- package/dist/model/RawMessageSignDestination.js +122 -0
- package/dist/model/RefreshToken200Response.js +1 -1
- package/dist/model/RefreshTokenRequest.js +1 -1
- package/dist/model/ReplaceType.js +1 -1
- package/dist/model/RetryWebhookEventById201Response.js +1 -1
- package/dist/model/RootPubkey.js +1 -1
- package/dist/model/SafeContractCallSource.js +2 -2
- package/dist/model/SafeTransferSource.js +2 -2
- package/dist/model/SafeWallet.js +1 -1
- package/dist/model/SmartContractInitiator.js +1 -1
- package/dist/model/SmartContractWalletInfo.js +24 -3
- package/dist/model/SmartContractWalletOperationType.js +1 -1
- package/dist/model/SmartContractWalletType.js +1 -1
- package/dist/model/SourceGroup.js +1 -1
- package/dist/model/StakeSourceType.js +56 -0
- package/dist/model/StakingPoolType.js +1 -11
- package/dist/model/StakingSource.js +39 -46
- package/dist/model/Stakings.js +35 -63
- package/dist/model/StakingsExtra.js +182 -0
- package/dist/model/StakingsValidatorInfo.js +7 -2
- package/dist/model/SubWalletAssetBalance.js +1 -1
- package/dist/model/TSSGroups.js +1 -1
- package/dist/model/TSSRequest.js +1 -1
- package/dist/model/TSSRequestStatus.js +1 -1
- package/dist/model/TSSRequestType.js +1 -1
- package/dist/model/TSSRequestWebhookEventData.js +1 -1
- package/dist/model/TokenBalance.js +1 -1
- package/dist/model/TokenBalanceBalance.js +1 -1
- package/dist/model/TokenInfo.js +27 -1
- package/dist/model/Transaction.js +1 -1
- package/dist/model/TransactionApprover.js +1 -1
- package/dist/model/TransactionBlockInfo.js +1 -1
- package/dist/model/TransactionCustodialAssetWalletSource.js +2 -2
- package/dist/model/TransactionDepositFromAddressSource.js +2 -2
- package/dist/model/TransactionDepositFromLoopSource.js +2 -2
- package/dist/model/TransactionDepositFromWalletSource.js +2 -2
- package/dist/model/TransactionDepositToAddressDestination.js +4 -4
- package/dist/model/TransactionDepositToWalletDestination.js +4 -4
- package/dist/model/TransactionDestination.js +110 -17
- package/dist/model/TransactionDestinationType.js +1 -1
- package/dist/model/TransactionDetail.js +1 -1
- package/dist/model/TransactionDetails.js +1 -1
- package/dist/model/TransactionEvmContractDestination.js +9 -5
- package/dist/model/TransactionEvmEip1559Fee.js +2 -2
- package/dist/model/TransactionEvmLegacyFee.js +2 -2
- package/dist/model/TransactionExchangeWalletSource.js +2 -2
- package/dist/model/TransactionFee.js +66 -9
- package/dist/model/TransactionFeeStationWalletSource.js +1 -1
- package/dist/model/TransactionFixedFee.js +2 -2
- package/dist/model/TransactionInitiatorType.js +1 -1
- package/dist/model/TransactionMPCWalletSource.js +2 -2
- package/dist/model/TransactionMessageSignEIP191Destination.js +2 -2
- package/dist/model/TransactionMessageSignEIP712Destination.js +2 -2
- package/dist/model/TransactionRawTxInfo.js +1 -1
- package/dist/model/TransactionRbf.js +1 -1
- package/dist/model/TransactionRbfSource.js +28 -3
- package/dist/model/TransactionReplacement.js +1 -1
- package/dist/model/TransactionRequestEvmEip1559Fee.js +2 -2
- package/dist/model/TransactionRequestEvmLegacyFee.js +2 -2
- package/dist/model/TransactionRequestFee.js +66 -9
- package/dist/model/TransactionRequestFixedFee.js +2 -2
- package/dist/model/TransactionRequestUtxoFee.js +2 -2
- package/dist/model/TransactionResend.js +1 -1
- package/dist/model/TransactionResult.js +24 -3
- package/dist/model/TransactionResultType.js +1 -1
- package/dist/model/TransactionSignatureResult.js +1 -1
- package/dist/model/TransactionSigner.js +1 -1
- package/dist/model/TransactionSmartContractSafeWalletSource.js +2 -2
- package/dist/model/TransactionSource.js +116 -15
- package/dist/model/TransactionSourceType.js +1 -1
- package/dist/model/TransactionStatus.js +1 -1
- package/dist/model/TransactionSubStatus.js +1 -1
- package/dist/model/TransactionTimeline.js +1 -1
- package/dist/model/TransactionTokeApproval.js +37 -1
- package/dist/model/TransactionTokenAmount.js +1 -1
- package/dist/model/TransactionTransferToAddressDestination.js +2 -2
- package/dist/model/TransactionTransferToAddressDestinationAccountOutput.js +2 -2
- package/dist/model/TransactionTransferToAddressDestinationUtxoOutputsInner.js +2 -2
- package/dist/model/TransactionTransferToWalletDestination.js +4 -4
- package/dist/model/TransactionType.js +11 -1
- package/dist/model/TransactionUtxo.js +1 -1
- package/dist/model/TransactionUtxoFee.js +2 -2
- package/dist/model/TransactionWebhookEventData.js +1 -1
- package/dist/model/TransferDestination.js +39 -6
- package/dist/model/TransferDestinationType.js +1 -1
- package/dist/model/TransferParams.js +1 -1
- package/dist/model/TransferSource.js +74 -9
- package/dist/model/UTXO.js +1 -1
- package/dist/model/UpdateCustodialWalletParams.js +1 -1
- package/dist/model/UpdateExchangeWalletParams.js +1 -1
- package/dist/model/UpdateGroupAction.js +1 -1
- package/dist/model/UpdateKeyShareHolderGroupByIdRequest.js +1 -1
- package/dist/model/UpdateMpcProjectByIdRequest.js +1 -1
- package/dist/model/UpdateMpcVaultByIdRequest.js +1 -1
- package/dist/model/UpdateMpcWalletParams.js +1 -1
- package/dist/model/UpdateSmartContractWalletParams.js +1 -1
- package/dist/model/UpdateWalletParams.js +66 -9
- package/dist/model/UpdateWebhookEndpointByIdRequest.js +1 -1
- package/dist/model/UtxoFeeBasePrice.js +1 -1
- package/dist/model/UtxoFeeRate.js +1 -1
- package/dist/model/WalletBalanceSnapshot.js +120 -0
- package/dist/model/WalletBalanceSnapshotRecord.js +163 -0
- package/dist/model/WalletInfo.js +66 -9
- package/dist/model/WalletSubtype.js +1 -1
- package/dist/model/WalletType.js +1 -1
- package/dist/model/WebhookEndpoint.js +1 -1
- package/dist/model/WebhookEndpointStatus.js +1 -1
- package/dist/model/WebhookEvent.js +1 -1
- package/dist/model/WebhookEventData.js +38 -5
- package/dist/model/WebhookEventDataType.js +1 -1
- package/dist/model/WebhookEventLog.js +1 -1
- package/dist/model/WebhookEventStatus.js +1 -1
- package/dist/model/WebhookEventType.js +1 -1
- package/docs/Activity.md +9 -8
- package/docs/ActivityInitiator.md +1 -1
- package/docs/ActivityTimeline.md +3 -3
- package/docs/ActivityType.md +0 -6
- package/docs/AddressInfo.md +3 -0
- package/docs/AddressTransferDestinationAccountOutput.md +1 -1
- package/docs/AddressTransferDestinationUtxoOutputsInner.md +1 -1
- package/docs/AmountDetailsInner.md +0 -1
- package/docs/BabylonStakeExtra.md +3 -3
- package/docs/BabylonStakingExtra.md +14 -0
- package/docs/BabylonValidator.md +6 -5
- package/docs/BaseStakeSource.md +11 -0
- package/docs/BookkeepingRecord.md +19 -0
- package/docs/BookkeepingSummary.md +12 -0
- package/docs/BroadcastSignedTransactions201ResponseInner.md +10 -0
- package/docs/BroadcastSignedTransactionsRequest.md +9 -0
- package/docs/ChainInfo.md +1 -0
- package/docs/CheckLoopTransfers200ResponseInner.md +1 -1
- package/docs/ContractCallDestination.md +1 -1
- package/docs/CreateStakeActivity.md +2 -2
- package/docs/CreateStakeActivity201Response.md +10 -0
- package/docs/CreateStakeActivityExtra.md +3 -5
- package/docs/CreateStakeActivityRequest.md +15 -0
- package/docs/CreateUnstakeActivity.md +2 -2
- package/docs/CreateUnstakeActivityRequest.md +13 -0
- package/docs/CreateWithdrawActivity.md +3 -3
- package/docs/CreateWithdrawActivityRequest.md +14 -0
- package/docs/EigenLayerLstStakeExtra.md +1 -1
- package/docs/EstimateStakeFee.md +2 -2
- package/docs/EstimateUnstakeFee.md +2 -2
- package/docs/EstimateWithdrawFee.md +3 -3
- package/docs/EvmContractCallDestination.md +1 -1
- package/docs/ExchangeTransferDestination.md +1 -1
- package/docs/ExtendedTokenInfo.md +2 -0
- package/docs/GetStakingEstimationFee201Response.md +11 -0
- package/docs/GetStakingEstimationFeeRequest.md +17 -0
- package/docs/ListStakingActivities200Response.md +10 -0
- package/docs/ListStakingPools200Response.md +10 -0
- package/docs/ListStakings200Response.md +10 -0
- package/docs/MpcStakeSource.md +11 -0
- package/docs/OAuthApi.md +2 -2
- package/docs/PoolDetails.md +13 -13
- package/docs/PoolDetailsAllOfValidatorsInfo.md +6 -6
- package/docs/PoolSummary.md +6 -6
- package/docs/RawMessageSignDestination.md +10 -0
- package/docs/StakeSourceType.md +10 -0
- package/docs/StakingPoolType.md +0 -4
- package/docs/StakingSource.md +1 -3
- package/docs/Stakings.md +10 -13
- package/docs/StakingsApi.md +570 -0
- package/docs/StakingsExtra.md +14 -0
- package/docs/StakingsValidatorInfo.md +5 -5
- package/docs/TokenInfo.md +2 -0
- package/docs/TransactionDepositToAddressDestination.md +1 -1
- package/docs/TransactionDepositToWalletDestination.md +1 -1
- package/docs/TransactionDestination.md +2 -2
- package/docs/TransactionEvmContractDestination.md +1 -1
- package/docs/TransactionTokeApproval.md +2 -0
- package/docs/TransactionTransferToAddressDestinationAccountOutput.md +1 -1
- package/docs/TransactionTransferToAddressDestinationUtxoOutputsInner.md +1 -1
- package/docs/TransactionTransferToWalletDestination.md +1 -1
- package/docs/TransactionType.md +4 -0
- package/docs/TransactionsApi.md +110 -2
- package/docs/TransferDestination.md +1 -1
- package/docs/WalletBalanceSnapshot.md +10 -0
- package/docs/WalletBalanceSnapshotRecord.md +13 -0
- package/docs/WalletsApi.md +0 -55
- package/docs/WalletsExchangeWalletApi.md +2 -2
- package/package.json +2 -2
|
@@ -17,7 +17,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
17
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
18
|
* Cobo Wallet as a Service 2.0
|
|
19
19
|
*
|
|
20
|
-
* Contact:
|
|
20
|
+
* Contact: help@cobo.com
|
|
21
21
|
*
|
|
22
22
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
23
23
|
* https://openapi-generator.tech
|
|
@@ -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 transfer amount. For example, if you trade 1.5
|
|
36
|
+
* @param amount {String} The transfer amount. For example, if you trade 1.5 BTC, 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 transfer amount. For example, if you trade 1.5
|
|
134
|
+
* The transfer amount. For example, if you trade 1.5 BTC, then the value is `1.5`.
|
|
135
135
|
* @member {String} amount
|
|
136
136
|
*/
|
|
137
137
|
AddressTransferDestinationAccountOutput.prototype['amount'] = undefined;
|
|
@@ -17,7 +17,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
17
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
18
|
* Cobo Wallet as a Service 2.0
|
|
19
19
|
*
|
|
20
|
-
* Contact:
|
|
20
|
+
* Contact: help@cobo.com
|
|
21
21
|
*
|
|
22
22
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
23
23
|
* https://openapi-generator.tech
|
|
@@ -123,7 +123,7 @@ AddressTransferDestinationUtxoOutputsInner.RequiredProperties = ["address"];
|
|
|
123
123
|
AddressTransferDestinationUtxoOutputsInner.prototype['address'] = undefined;
|
|
124
124
|
|
|
125
125
|
/**
|
|
126
|
-
* The transfer amount. For example, if you trade 1.5
|
|
126
|
+
* The transfer amount. For example, if you trade 1.5 BTC, then the value is `1.5`.
|
|
127
127
|
* @member {String} amount
|
|
128
128
|
*/
|
|
129
129
|
AddressTransferDestinationUtxoOutputsInner.prototype['amount'] = undefined;
|
|
@@ -18,7 +18,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
18
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
19
|
* Cobo Wallet as a Service 2.0
|
|
20
20
|
*
|
|
21
|
-
* Contact:
|
|
21
|
+
* Contact: help@cobo.com
|
|
22
22
|
*
|
|
23
23
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
24
24
|
* https://openapi-generator.tech
|
|
@@ -71,9 +71,6 @@ var AmountDetailsInner = /*#__PURE__*/function () {
|
|
|
71
71
|
if (data.hasOwnProperty('amount')) {
|
|
72
72
|
obj['amount'] = _ApiClient["default"].convertToType(data['amount'], 'String');
|
|
73
73
|
}
|
|
74
|
-
if (data.hasOwnProperty('activity_id')) {
|
|
75
|
-
obj['activity_id'] = _ApiClient["default"].convertToType(data['activity_id'], 'String');
|
|
76
|
-
}
|
|
77
74
|
}
|
|
78
75
|
return obj;
|
|
79
76
|
}
|
|
@@ -105,10 +102,6 @@ var AmountDetailsInner = /*#__PURE__*/function () {
|
|
|
105
102
|
if (data['amount'] && !(typeof data['amount'] === 'string' || data['amount'] instanceof String)) {
|
|
106
103
|
throw new Error("Expected the field `amount` to be a primitive type in the JSON string but got " + data['amount']);
|
|
107
104
|
}
|
|
108
|
-
// ensure the json data is a string
|
|
109
|
-
if (data['activity_id'] && !(typeof data['activity_id'] === 'string' || data['activity_id'] instanceof String)) {
|
|
110
|
-
throw new Error("Expected the field `activity_id` to be a primitive type in the JSON string but got " + data['activity_id']);
|
|
111
|
-
}
|
|
112
105
|
return true;
|
|
113
106
|
}
|
|
114
107
|
}]);
|
|
@@ -125,10 +118,4 @@ AmountDetailsInner.prototype['status'] = undefined;
|
|
|
125
118
|
* @member {String} amount
|
|
126
119
|
*/
|
|
127
120
|
AmountDetailsInner.prototype['amount'] = undefined;
|
|
128
|
-
|
|
129
|
-
/**
|
|
130
|
-
* The related staking activity ID.
|
|
131
|
-
* @member {String} activity_id
|
|
132
|
-
*/
|
|
133
|
-
AmountDetailsInner.prototype['activity_id'] = undefined;
|
|
134
121
|
var _default = exports["default"] = AmountDetailsInner;
|
|
@@ -15,7 +15,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
15
15
|
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); } /**
|
|
16
16
|
* Cobo Wallet as a Service 2.0
|
|
17
17
|
*
|
|
18
|
-
* Contact:
|
|
18
|
+
* Contact: help@cobo.com
|
|
19
19
|
*
|
|
20
20
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
21
21
|
* https://openapi-generator.tech
|
|
@@ -18,7 +18,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
18
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
19
|
* Cobo Wallet as a Service 2.0
|
|
20
20
|
*
|
|
21
|
-
* Contact:
|
|
21
|
+
* Contact: help@cobo.com
|
|
22
22
|
*
|
|
23
23
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
24
24
|
* https://openapi-generator.tech
|
package/dist/model/AssetInfo.js
CHANGED
|
@@ -17,7 +17,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
17
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
18
|
* Cobo Wallet as a Service 2.0
|
|
19
19
|
*
|
|
20
|
-
* Contact:
|
|
20
|
+
* Contact: help@cobo.com
|
|
21
21
|
*
|
|
22
22
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
23
23
|
* https://openapi-generator.tech
|
|
@@ -19,7 +19,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
19
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
20
|
* Cobo Wallet as a Service 2.0
|
|
21
21
|
*
|
|
22
|
-
* Contact:
|
|
22
|
+
* Contact: help@cobo.com
|
|
23
23
|
*
|
|
24
24
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
25
25
|
* https://openapi-generator.tech
|
|
@@ -36,8 +36,8 @@ var BabylonStakeExtra = /*#__PURE__*/function () {
|
|
|
36
36
|
* @alias module:model/BabylonStakeExtra
|
|
37
37
|
* @implements module:model/BaseStakeExtra
|
|
38
38
|
* @param pool_type {module:model/StakingPoolType}
|
|
39
|
-
* @param finality_provider_public_key {String} The public key of finality provider.
|
|
40
|
-
* @param stake_block_time {Number} The
|
|
39
|
+
* @param finality_provider_public_key {String} The public key of the finality provider.
|
|
40
|
+
* @param stake_block_time {Number} The number of blocks that need to be processed before the locked tokens are unlocked and become accessible.
|
|
41
41
|
*/
|
|
42
42
|
function BabylonStakeExtra(pool_type, finality_provider_public_key, stake_block_time) {
|
|
43
43
|
_classCallCheck(this, BabylonStakeExtra);
|
|
@@ -80,8 +80,8 @@ 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('
|
|
84
|
-
obj['
|
|
83
|
+
if (data.hasOwnProperty('auto_broadcast')) {
|
|
84
|
+
obj['auto_broadcast'] = _ApiClient["default"].convertToType(data['auto_broadcast'], 'Boolean');
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
87
|
return obj;
|
|
@@ -126,22 +126,22 @@ BabylonStakeExtra.RequiredProperties = ["pool_type", "finality_provider_public_k
|
|
|
126
126
|
BabylonStakeExtra.prototype['pool_type'] = undefined;
|
|
127
127
|
|
|
128
128
|
/**
|
|
129
|
-
* The public key of finality provider.
|
|
129
|
+
* The public key of the finality provider.
|
|
130
130
|
* @member {String} finality_provider_public_key
|
|
131
131
|
*/
|
|
132
132
|
BabylonStakeExtra.prototype['finality_provider_public_key'] = undefined;
|
|
133
133
|
|
|
134
134
|
/**
|
|
135
|
-
* The
|
|
135
|
+
* The number of blocks that need to be processed before the locked tokens are unlocked and become accessible.
|
|
136
136
|
* @member {Number} stake_block_time
|
|
137
137
|
*/
|
|
138
138
|
BabylonStakeExtra.prototype['stake_block_time'] = undefined;
|
|
139
139
|
|
|
140
140
|
/**
|
|
141
|
-
* Whether to
|
|
142
|
-
* @member {Boolean}
|
|
141
|
+
* Whether to automatically broadcast the transaction. The default value is `true`. - `true`: Automatically broadcast the transaction. - `false`: The transaction will not be submitted to the blockchain automatically. You can call [Broadcast signed transactions](/v2/api-references/transactions/broadcast-signed-transactions) to broadcast the transaction to the blockchain, or retrieve the signed raw transaction data `raw_tx` by calling [Get transaction information](/v2/api-references/transactions/get-transaction-information) and broadcast it yourself.
|
|
142
|
+
* @member {Boolean} auto_broadcast
|
|
143
143
|
*/
|
|
144
|
-
BabylonStakeExtra.prototype['
|
|
144
|
+
BabylonStakeExtra.prototype['auto_broadcast'] = undefined;
|
|
145
145
|
|
|
146
146
|
// Implement BaseStakeExtra interface:
|
|
147
147
|
/**
|
|
@@ -0,0 +1,175 @@
|
|
|
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 _BaseStakeExtra = _interopRequireDefault(require("./BaseStakeExtra"));
|
|
9
|
+
var _StakingPoolType = _interopRequireDefault(require("./StakingPoolType"));
|
|
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 BabylonStakingExtra model module.
|
|
31
|
+
* @module model/BabylonStakingExtra
|
|
32
|
+
*/
|
|
33
|
+
var BabylonStakingExtra = /*#__PURE__*/function () {
|
|
34
|
+
/**
|
|
35
|
+
* Constructs a new <code>BabylonStakingExtra</code>.
|
|
36
|
+
* @alias module:model/BabylonStakingExtra
|
|
37
|
+
* @implements module:model/BaseStakeExtra
|
|
38
|
+
* @param pool_type {module:model/StakingPoolType}
|
|
39
|
+
* @param pos_chain {String} The Proof-of-Stake (PoS) chain.
|
|
40
|
+
*/
|
|
41
|
+
function BabylonStakingExtra(pool_type, pos_chain) {
|
|
42
|
+
_classCallCheck(this, BabylonStakingExtra);
|
|
43
|
+
_BaseStakeExtra["default"].initialize(this, pool_type);
|
|
44
|
+
BabylonStakingExtra.initialize(this, pool_type, pos_chain);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Initializes the fields of this object.
|
|
49
|
+
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
|
50
|
+
* Only for internal use.
|
|
51
|
+
*/
|
|
52
|
+
return _createClass(BabylonStakingExtra, null, [{
|
|
53
|
+
key: "initialize",
|
|
54
|
+
value: function initialize(obj, pool_type, pos_chain) {
|
|
55
|
+
obj['pool_type'] = pool_type;
|
|
56
|
+
obj['pos_chain'] = pos_chain;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Constructs a <code>BabylonStakingExtra</code> from a plain JavaScript object, optionally creating a new instance.
|
|
61
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
62
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
63
|
+
* @param {module:model/BabylonStakingExtra} obj Optional instance to populate.
|
|
64
|
+
* @return {module:model/BabylonStakingExtra} The populated <code>BabylonStakingExtra</code> instance.
|
|
65
|
+
*/
|
|
66
|
+
}, {
|
|
67
|
+
key: "constructFromObject",
|
|
68
|
+
value: function constructFromObject(data, obj) {
|
|
69
|
+
if (data) {
|
|
70
|
+
obj = obj || new BabylonStakingExtra();
|
|
71
|
+
_BaseStakeExtra["default"].constructFromObject(data, obj);
|
|
72
|
+
if (data.hasOwnProperty('pool_type')) {
|
|
73
|
+
obj['pool_type'] = _StakingPoolType["default"].constructFromObject(data['pool_type']);
|
|
74
|
+
}
|
|
75
|
+
if (data.hasOwnProperty('pos_chain')) {
|
|
76
|
+
obj['pos_chain'] = _ApiClient["default"].convertToType(data['pos_chain'], 'String');
|
|
77
|
+
}
|
|
78
|
+
if (data.hasOwnProperty('unlock_timestamp')) {
|
|
79
|
+
obj['unlock_timestamp'] = _ApiClient["default"].convertToType(data['unlock_timestamp'], 'Number');
|
|
80
|
+
}
|
|
81
|
+
if (data.hasOwnProperty('unlock_block_height')) {
|
|
82
|
+
obj['unlock_block_height'] = _ApiClient["default"].convertToType(data['unlock_block_height'], 'Number');
|
|
83
|
+
}
|
|
84
|
+
if (data.hasOwnProperty('stake_address')) {
|
|
85
|
+
obj['stake_address'] = _ApiClient["default"].convertToType(data['stake_address'], 'String');
|
|
86
|
+
}
|
|
87
|
+
if (data.hasOwnProperty('unbond_address')) {
|
|
88
|
+
obj['unbond_address'] = _ApiClient["default"].convertToType(data['unbond_address'], 'String');
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
return obj;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* Validates the JSON data with respect to <code>BabylonStakingExtra</code>.
|
|
96
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
97
|
+
* @return {boolean} to indicate whether the JSON data is valid with respect to <code>BabylonStakingExtra</code>.
|
|
98
|
+
*/
|
|
99
|
+
}, {
|
|
100
|
+
key: "validateJSON",
|
|
101
|
+
value: function validateJSON(data) {
|
|
102
|
+
// check to make sure all required properties are present in the JSON string
|
|
103
|
+
var _iterator = _createForOfIteratorHelper(BabylonStakingExtra.RequiredProperties),
|
|
104
|
+
_step;
|
|
105
|
+
try {
|
|
106
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
107
|
+
var property = _step.value;
|
|
108
|
+
if (!data.hasOwnProperty(property)) {
|
|
109
|
+
throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
// ensure the json data is a string
|
|
113
|
+
} catch (err) {
|
|
114
|
+
_iterator.e(err);
|
|
115
|
+
} finally {
|
|
116
|
+
_iterator.f();
|
|
117
|
+
}
|
|
118
|
+
if (data['pos_chain'] && !(typeof data['pos_chain'] === 'string' || data['pos_chain'] instanceof String)) {
|
|
119
|
+
throw new Error("Expected the field `pos_chain` to be a primitive type in the JSON string but got " + data['pos_chain']);
|
|
120
|
+
}
|
|
121
|
+
// ensure the json data is a string
|
|
122
|
+
if (data['stake_address'] && !(typeof data['stake_address'] === 'string' || data['stake_address'] instanceof String)) {
|
|
123
|
+
throw new Error("Expected the field `stake_address` to be a primitive type in the JSON string but got " + data['stake_address']);
|
|
124
|
+
}
|
|
125
|
+
// ensure the json data is a string
|
|
126
|
+
if (data['unbond_address'] && !(typeof data['unbond_address'] === 'string' || data['unbond_address'] instanceof String)) {
|
|
127
|
+
throw new Error("Expected the field `unbond_address` to be a primitive type in the JSON string but got " + data['unbond_address']);
|
|
128
|
+
}
|
|
129
|
+
return true;
|
|
130
|
+
}
|
|
131
|
+
}]);
|
|
132
|
+
}();
|
|
133
|
+
BabylonStakingExtra.RequiredProperties = ["pool_type", "pos_chain"];
|
|
134
|
+
|
|
135
|
+
/**
|
|
136
|
+
* @member {module:model/StakingPoolType} pool_type
|
|
137
|
+
*/
|
|
138
|
+
BabylonStakingExtra.prototype['pool_type'] = undefined;
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* The Proof-of-Stake (PoS) chain.
|
|
142
|
+
* @member {String} pos_chain
|
|
143
|
+
*/
|
|
144
|
+
BabylonStakingExtra.prototype['pos_chain'] = undefined;
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* The estimated time when the bitcoins will be unlocked, in Unix timestamp format, measured in milliseconds.
|
|
148
|
+
* @member {Number} unlock_timestamp
|
|
149
|
+
*/
|
|
150
|
+
BabylonStakingExtra.prototype['unlock_timestamp'] = undefined;
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* The block height at which the bitcoins will be unlocked.
|
|
154
|
+
* @member {Number} unlock_block_height
|
|
155
|
+
*/
|
|
156
|
+
BabylonStakingExtra.prototype['unlock_block_height'] = undefined;
|
|
157
|
+
|
|
158
|
+
/**
|
|
159
|
+
* The address receiving the staked bitcoins.
|
|
160
|
+
* @member {String} stake_address
|
|
161
|
+
*/
|
|
162
|
+
BabylonStakingExtra.prototype['stake_address'] = undefined;
|
|
163
|
+
|
|
164
|
+
/**
|
|
165
|
+
* The address receiving the unlocked bitcoins.
|
|
166
|
+
* @member {String} unbond_address
|
|
167
|
+
*/
|
|
168
|
+
BabylonStakingExtra.prototype['unbond_address'] = undefined;
|
|
169
|
+
|
|
170
|
+
// Implement BaseStakeExtra interface:
|
|
171
|
+
/**
|
|
172
|
+
* @member {module:model/StakingPoolType} pool_type
|
|
173
|
+
*/
|
|
174
|
+
_BaseStakeExtra["default"].prototype['pool_type'] = undefined;
|
|
175
|
+
var _default = exports["default"] = BabylonStakingExtra;
|
|
@@ -5,6 +5,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports["default"] = void 0;
|
|
7
7
|
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
+
var _BaseStakeExtra = _interopRequireDefault(require("./BaseStakeExtra"));
|
|
9
|
+
var _StakingPoolType = _interopRequireDefault(require("./StakingPoolType"));
|
|
8
10
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
9
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); }
|
|
10
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; } } }; }
|
|
@@ -17,7 +19,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
17
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); } /**
|
|
18
20
|
* Cobo Wallet as a Service 2.0
|
|
19
21
|
*
|
|
20
|
-
* Contact:
|
|
22
|
+
* Contact: help@cobo.com
|
|
21
23
|
*
|
|
22
24
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
23
25
|
* https://openapi-generator.tech
|
|
@@ -31,17 +33,19 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
31
33
|
var BabylonValidator = /*#__PURE__*/function () {
|
|
32
34
|
/**
|
|
33
35
|
* Constructs a new <code>BabylonValidator</code>.
|
|
34
|
-
* The babylon validator information.
|
|
35
36
|
* @alias module:model/BabylonValidator
|
|
37
|
+
* @implements module:model/BaseStakeExtra
|
|
38
|
+
* @param pool_type {module:model/StakingPoolType}
|
|
36
39
|
* @param icon_url {String} The URL of the validator's icon.
|
|
37
|
-
* @param name {String} The name
|
|
38
|
-
* @param public_key {String} The public key of validator.
|
|
39
|
-
* @param commission_rate {Number} The commission rate of validator.
|
|
40
|
-
* @param supported_pos_chains {Array.<module:model/BabylonValidator.SupportedPosChainsEnum>}
|
|
40
|
+
* @param name {String} The validator's name.
|
|
41
|
+
* @param public_key {String} The public key of the validator.
|
|
42
|
+
* @param commission_rate {Number} The commission rate of the validator.
|
|
43
|
+
* @param supported_pos_chains {Array.<module:model/BabylonValidator.SupportedPosChainsEnum>} A list of supported Proof-of-Stake (PoS) chains.
|
|
41
44
|
*/
|
|
42
|
-
function BabylonValidator(icon_url, name, public_key, commission_rate, supported_pos_chains) {
|
|
45
|
+
function BabylonValidator(pool_type, icon_url, name, public_key, commission_rate, supported_pos_chains) {
|
|
43
46
|
_classCallCheck(this, BabylonValidator);
|
|
44
|
-
|
|
47
|
+
_BaseStakeExtra["default"].initialize(this, pool_type);
|
|
48
|
+
BabylonValidator.initialize(this, pool_type, icon_url, name, public_key, commission_rate, supported_pos_chains);
|
|
45
49
|
}
|
|
46
50
|
|
|
47
51
|
/**
|
|
@@ -51,7 +55,8 @@ var BabylonValidator = /*#__PURE__*/function () {
|
|
|
51
55
|
*/
|
|
52
56
|
return _createClass(BabylonValidator, null, [{
|
|
53
57
|
key: "initialize",
|
|
54
|
-
value: function initialize(obj, icon_url, name, public_key, commission_rate, supported_pos_chains) {
|
|
58
|
+
value: function initialize(obj, pool_type, icon_url, name, public_key, commission_rate, supported_pos_chains) {
|
|
59
|
+
obj['pool_type'] = pool_type;
|
|
55
60
|
obj['icon_url'] = icon_url;
|
|
56
61
|
obj['name'] = name;
|
|
57
62
|
obj['public_key'] = public_key;
|
|
@@ -71,6 +76,10 @@ var BabylonValidator = /*#__PURE__*/function () {
|
|
|
71
76
|
value: function constructFromObject(data, obj) {
|
|
72
77
|
if (data) {
|
|
73
78
|
obj = obj || new BabylonValidator();
|
|
79
|
+
_BaseStakeExtra["default"].constructFromObject(data, obj);
|
|
80
|
+
if (data.hasOwnProperty('pool_type')) {
|
|
81
|
+
obj['pool_type'] = _StakingPoolType["default"].constructFromObject(data['pool_type']);
|
|
82
|
+
}
|
|
74
83
|
if (data.hasOwnProperty('icon_url')) {
|
|
75
84
|
obj['icon_url'] = _ApiClient["default"].convertToType(data['icon_url'], 'String');
|
|
76
85
|
}
|
|
@@ -136,7 +145,12 @@ var BabylonValidator = /*#__PURE__*/function () {
|
|
|
136
145
|
}
|
|
137
146
|
}]);
|
|
138
147
|
}();
|
|
139
|
-
BabylonValidator.RequiredProperties = ["icon_url", "name", "public_key", "commission_rate", "supported_pos_chains"];
|
|
148
|
+
BabylonValidator.RequiredProperties = ["pool_type", "icon_url", "name", "public_key", "commission_rate", "supported_pos_chains"];
|
|
149
|
+
|
|
150
|
+
/**
|
|
151
|
+
* @member {module:model/StakingPoolType} pool_type
|
|
152
|
+
*/
|
|
153
|
+
BabylonValidator.prototype['pool_type'] = undefined;
|
|
140
154
|
|
|
141
155
|
/**
|
|
142
156
|
* The URL of the validator's icon.
|
|
@@ -145,35 +159,41 @@ BabylonValidator.RequiredProperties = ["icon_url", "name", "public_key", "commis
|
|
|
145
159
|
BabylonValidator.prototype['icon_url'] = undefined;
|
|
146
160
|
|
|
147
161
|
/**
|
|
148
|
-
* The name
|
|
162
|
+
* The validator's name.
|
|
149
163
|
* @member {String} name
|
|
150
164
|
*/
|
|
151
165
|
BabylonValidator.prototype['name'] = undefined;
|
|
152
166
|
|
|
153
167
|
/**
|
|
154
|
-
*
|
|
168
|
+
* This property can be ignored.
|
|
155
169
|
* @member {Number} priority
|
|
156
170
|
*/
|
|
157
171
|
BabylonValidator.prototype['priority'] = undefined;
|
|
158
172
|
|
|
159
173
|
/**
|
|
160
|
-
* The public key of validator.
|
|
174
|
+
* The public key of the validator.
|
|
161
175
|
* @member {String} public_key
|
|
162
176
|
*/
|
|
163
177
|
BabylonValidator.prototype['public_key'] = undefined;
|
|
164
178
|
|
|
165
179
|
/**
|
|
166
|
-
* The commission rate of validator.
|
|
180
|
+
* The commission rate of the validator.
|
|
167
181
|
* @member {Number} commission_rate
|
|
168
182
|
*/
|
|
169
183
|
BabylonValidator.prototype['commission_rate'] = undefined;
|
|
170
184
|
|
|
171
185
|
/**
|
|
172
|
-
*
|
|
186
|
+
* A list of supported Proof-of-Stake (PoS) chains.
|
|
173
187
|
* @member {Array.<module:model/BabylonValidator.SupportedPosChainsEnum>} supported_pos_chains
|
|
174
188
|
*/
|
|
175
189
|
BabylonValidator.prototype['supported_pos_chains'] = undefined;
|
|
176
190
|
|
|
191
|
+
// Implement BaseStakeExtra interface:
|
|
192
|
+
/**
|
|
193
|
+
* @member {module:model/StakingPoolType} pool_type
|
|
194
|
+
*/
|
|
195
|
+
_BaseStakeExtra["default"].prototype['pool_type'] = undefined;
|
|
196
|
+
|
|
177
197
|
/**
|
|
178
198
|
* Allowed values for the <code>supported_pos_chains</code> property.
|
|
179
199
|
* @enum {String}
|
|
@@ -18,7 +18,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
18
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
19
|
* Cobo Wallet as a Service 2.0
|
|
20
20
|
*
|
|
21
|
-
* Contact:
|
|
21
|
+
* Contact: help@cobo.com
|
|
22
22
|
*
|
|
23
23
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
24
24
|
* https://openapi-generator.tech
|
|
@@ -32,7 +32,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
32
32
|
var BaseContractCallSource = /*#__PURE__*/function () {
|
|
33
33
|
/**
|
|
34
34
|
* Constructs a new <code>BaseContractCallSource</code>.
|
|
35
|
-
* The information about the transaction source type `Org-Controlled` and `User-Controlled`.
|
|
35
|
+
* The information about the transaction source type `Org-Controlled` and `User-Controlled`. Refer to [Transaction sources and destinations](/v2/guides/transactions/sources-and-destinations) for a detailed introduction about the supported sources and destinations for each transaction type. Switch between the tabs to display the properties for different transaction sources.
|
|
36
36
|
* @alias module:model/BaseContractCallSource
|
|
37
37
|
* @param source_type {module:model/ContractCallSourceType}
|
|
38
38
|
* @param wallet_id {String} The wallet ID.
|
|
@@ -18,7 +18,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
18
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
19
|
* Cobo Wallet as a Service 2.0
|
|
20
20
|
*
|
|
21
|
-
* Contact:
|
|
21
|
+
* Contact: help@cobo.com
|
|
22
22
|
*
|
|
23
23
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
24
24
|
* https://openapi-generator.tech
|
|
@@ -18,7 +18,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
18
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
19
|
* Cobo Wallet as a Service 2.0
|
|
20
20
|
*
|
|
21
|
-
* Contact:
|
|
21
|
+
* Contact: help@cobo.com
|
|
22
22
|
*
|
|
23
23
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
24
24
|
* https://openapi-generator.tech
|
|
@@ -32,7 +32,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
32
32
|
var BaseStakeExtra = /*#__PURE__*/function () {
|
|
33
33
|
/**
|
|
34
34
|
* Constructs a new <code>BaseStakeExtra</code>.
|
|
35
|
-
*
|
|
35
|
+
* The base information about a staking protocol.
|
|
36
36
|
* @alias module:model/BaseStakeExtra
|
|
37
37
|
* @param pool_type {module:model/StakingPoolType}
|
|
38
38
|
*/
|