From 9853e29d89b2846454197438c7d1b4b636384d6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20C=C3=A1rdenas?= Date: Thu, 4 Jan 2024 10:58:42 -0600 Subject: [PATCH] fix: update client code, fix mempool fee return type (#1797) --- client/src/generated/.openapi-generator/FILES | 172 +++++ client/src/generated/apis/AccountsApi.ts | 550 +++++++++++++-- client/src/generated/apis/BlocksApi.ts | 214 +++++- client/src/generated/apis/BurnchainApi.ts | 214 ------ client/src/generated/apis/FaucetsApi.ts | 83 ++- client/src/generated/apis/FeesApi.ts | 148 +++- .../src/generated/apis/FungibleTokensApi.ts | 150 ++++ client/src/generated/apis/InfoApi.ts | 330 +++++++-- client/src/generated/apis/MempoolApi.ts | 80 +++ client/src/generated/apis/MicroblocksApi.ts | 196 ++++++ client/src/generated/apis/NamesApi.ts | 581 ++++++++++++++++ .../generated/apis/NonFungibleTokensApi.ts | 415 +++++++++++ client/src/generated/apis/RosettaApi.ts | 339 ++++----- client/src/generated/apis/SearchApi.ts | 26 +- .../src/generated/apis/SmartContractsApi.ts | 218 ++++-- client/src/generated/apis/StackingApi.ts | 113 +++ .../src/generated/apis/StackingRewardsApi.ts | 339 +++++++++ client/src/generated/apis/TransactionsApi.ts | 645 ++++++++++++++++-- client/src/generated/apis/index.ts | 10 +- client/src/generated/index.ts | 2 + .../generated/models/AccountDataResponse.ts | 7 +- .../models/AddressAssetsListResponse.ts | 7 +- .../models/AddressBalanceResponse.ts | 43 +- .../models/AddressNftListResponse.ts | 87 +++ .../models/AddressNftListResponseValue.ts | 64 ++ client/src/generated/models/AddressNonces.ts | 88 +++ .../models/AddressStxBalanceResponse.ts | 129 ---- .../models/AddressStxInboundListResponse.ts | 87 +++ .../models/AddressTokenOfferingLocked.ts | 79 +++ .../models/AddressTransactionWithTransfers.ts | 111 +++ ...ressTransactionWithTransfersFtTransfers.ts | 80 +++ ...essTransactionWithTransfersNftTransfers.ts | 87 +++ ...essTransactionWithTransfersStxTransfers.ts | 72 ++ .../AddressTransactionWithTransfersValue.ts | 64 ++ .../models/AddressTransactionsListResponse.ts | 7 +- ...ssTransactionsWithTransfersListResponse.ts | 87 +++ .../generated/models/AddressUnlockSchedule.ts | 64 ++ client/src/generated/models/Block.ts | 95 ++- .../src/generated/models/BlockListResponse.ts | 7 +- client/src/generated/models/BnsError.ts | 56 ++ .../models/BnsGetAllNamespacesResponse.ts | 56 ++ .../models/BnsGetNameInfoResponse.ts | 120 ++++ .../models/BnsGetNamePriceResponse.ts | 64 ++ .../models/BnsGetNamespacePriceResponse.ts | 64 ++ .../models/BnsNamesOwnByAddressResponse.ts | 56 ++ .../src/generated/models/BurnchainReward.ts | 7 +- .../models/BurnchainRewardListResponse.ts | 7 +- .../models/BurnchainRewardSlotHolder.ts | 88 +++ .../BurnchainRewardSlotHolderListResponse.ts | 87 +++ .../generated/models/BurnchainRewardsTotal.ts | 7 +- client/src/generated/models/ChainTip.ts | 96 +++ .../models/ContractInterfaceResponse.ts | 7 +- .../generated/models/ContractListResponse.ts | 79 +++ .../models/ContractSourceResponse.ts | 7 +- .../generated/models/CoreNodeInfoResponse.ts | 7 +- .../generated/models/CoreNodePoxResponse.ts | 7 +- client/src/generated/models/FeeRate.ts | 56 ++ client/src/generated/models/FeeRateRequest.ts | 56 ++ .../generated/models/FungibleTokenMetadata.ts | 120 ++++ .../models/FungibleTokensMetadataList.ts | 87 +++ .../models/GetRawTransactionResult.ts | 56 ++ .../GetStxSupplyLegacyFormatResponse.ts | 96 +++ .../generated/models/GetStxSupplyResponse.ts | 80 +++ .../generated/models/InboundStxTransfer.ts | 114 ++++ client/src/generated/models/InlineObject.ts | 56 ++ .../src/generated/models/InlineResponse403.ts | 64 ++ .../src/generated/models/MapEntryResponse.ts | 7 +- .../generated/models/MempoolFeePriorities.ts | 87 +++ .../models/MempoolFeePrioritiesAll.ts | 80 +++ .../models/MempoolTransactionListResponse.ts | 7 +- .../models/MempoolTransactionStatsResponse.ts | 99 +++ .../MempoolTransactionStatsResponseTxAges.ts | 87 +++ ...poolTransactionStatsResponseTxByteSizes.ts | 87 +++ ...sactionStatsResponseTxSimpleFeeAverages.ts | 87 +++ ...esponseTxSimpleFeeAveragesTokenTransfer.ts | 80 +++ ...oolTransactionStatsResponseTxTypeCounts.ts | 80 +++ client/src/generated/models/Microblock.ts | 160 +++++ .../models/MicroblockListResponse.ts | 87 +++ .../models/NetworkBlockTimeResponse.ts | 7 +- .../models/NetworkBlockTimesResponse.ts | 31 +- .../NetworkBlockTimesResponseMainnet.ts | 57 -- .../src/generated/models/NetworkIdentifier.ts | 7 +- client/src/generated/models/NftEvent.ts | 127 ++++ .../NonFungibleTokenHistoryEventList.ts | 80 +++ .../models/NonFungibleTokenHoldingsList.ts | 80 +++ .../models/NonFungibleTokenMetadata.ts | 104 +++ .../models/NonFungibleTokenMintList.ts | 80 +++ .../models/NonFungibleTokensMetadataList.ts | 87 +++ .../models/OtherTransactionIdentifier.ts | 56 ++ client/src/generated/models/PoolDelegation.ts | 96 +++ .../models/PoolDelegationsResponse.ts | 87 +++ .../models/PostCoreNodeTransactionsError.ts | 7 +- .../generated/models/ReadOnlyFunctionArgs.ts | 7 +- .../models/ReadOnlyFunctionSuccessResponse.ts | 7 +- client/src/generated/models/RosettaAccount.ts | 7 +- .../models/RosettaAccountBalanceRequest.ts | 7 +- .../models/RosettaAccountBalanceResponse.ts | 9 +- ...ttaAccountBalanceResponseCoinIdentifier.ts | 7 +- .../RosettaAccountBalanceResponseMetadata.ts | 7 +- .../models/RosettaAccountIdentifier.ts | 79 +++ client/src/generated/models/RosettaAmount.ts | 7 +- client/src/generated/models/RosettaBlock.ts | 25 +- .../generated/models/RosettaBlockMetadata.ts | 35 +- .../generated/models/RosettaBlockMetadata1.ts | 29 +- .../generated/models/RosettaBlockMetadata2.ts | 65 -- .../generated/models/RosettaBlockRequest.ts | 11 +- .../generated/models/RosettaBlockResponse.ts | 23 +- .../models/RosettaBlockTransactionRequest.ts | 9 +- .../models/RosettaBlockTransactionResponse.ts | 7 +- client/src/generated/models/RosettaCoin.ts | 7 +- .../src/generated/models/RosettaCoinChange.ts | 25 +- .../RosettaConstructionCombineRequest.ts | 7 +- .../RosettaConstructionCombineResponse.ts | 7 +- .../RosettaConstructionDeriveRequest.ts | 7 +- .../RosettaConstructionDeriveResponse.ts | 28 +- .../models/RosettaConstructionHashRequest.ts | 7 +- .../models/RosettaConstructionHashResponse.ts | 7 +- .../RosettaConstructionMetadataRequest.ts | 7 +- .../RosettaConstructionMetadataResponse.ts | 15 +- ...ttaConstructionMetadataResponseMetadata.ts | 7 +- .../models/RosettaConstructionParseRequest.ts | 7 +- .../RosettaConstructionParseResponse.ts | 31 +- .../RosettaConstructionPayloadResponse.ts | 7 +- .../RosettaConstructionPayloadsRequest.ts | 19 +- .../RosettaConstructionPreprocessRequest.ts | 23 +- .../RosettaConstructionPreprocessResponse.ts | 7 +- .../RosettaConstructionSubmitRequest.ts | 7 +- .../RosettaConstructionSubmitResponse.ts | 7 +- .../src/generated/models/RosettaCurrency.ts | 7 +- client/src/generated/models/RosettaError.ts | 7 +- .../generated/models/RosettaErrorDetails.ts | 7 +- .../generated/models/RosettaErrorNoDetails.ts | 72 ++ .../models/RosettaGenesisBlockIdentifier.ts | 64 ++ .../generated/models/RosettaMaxFeeAmount.ts | 79 +++ .../generated/models/RosettaMempoolRequest.ts | 7 +- .../models/RosettaMempoolResponse.ts | 7 +- .../RosettaMempoolTransactionRequest.ts | 7 +- .../RosettaMempoolTransactionResponse.ts | 7 +- .../models/RosettaNetworkListResponse.ts | 7 +- ...NetworkListResponseSubNetworkIdentifier.ts | 9 +- ...istResponseSubNetworkIdentifierMetadata.ts | 7 +- .../models/RosettaNetworkOptionsResponse.ts | 7 +- .../RosettaNetworkOptionsResponseAllow.ts | 23 +- .../RosettaNetworkOptionsResponseVersion.ts | 7 +- .../models/RosettaNetworkStatusResponse.ts | 115 ++++ .../models/RosettaOldestBlockIdentifier.ts | 64 ++ .../src/generated/models/RosettaOperation.ts | 25 +- .../models/RosettaOperationIdentifier.ts | 7 +- .../models/RosettaOperationStatus.ts | 7 +- client/src/generated/models/RosettaOptions.ts | 73 +- .../generated/models/RosettaOptionsRequest.ts | 7 +- .../models/RosettaParentBlockIdentifier.ts | 7 +- client/src/generated/models/RosettaPeers.ts | 64 ++ .../src/generated/models/RosettaPublicKey.ts | 25 +- .../models/RosettaRelatedOperation.ts | 28 +- .../src/generated/models/RosettaSignature.ts | 31 +- .../generated/models/RosettaStatusRequest.ts | 7 +- .../src/generated/models/RosettaSubAccount.ts | 7 +- .../src/generated/models/RosettaSyncStatus.ts | 80 +++ .../generated/models/RosettaTransaction.ts | 23 +- .../src/generated/models/RunFaucetResponse.ts | 9 +- .../generated/models/ServerStatusResponse.ts | 95 +++ client/src/generated/models/SigningPayload.ts | 33 +- client/src/generated/models/SmartContract.ts | 96 +++ ...essBalanceResponseStx.ts => StxBalance.ts} | 41 +- .../src/generated/models/TargetBlockTime.ts | 56 ++ .../models/TransactionEventsResponse.ts | 72 ++ .../models/TransactionFeeEstimateRequest.ts | 64 ++ .../models/TransactionFeeEstimateResponse.ts | 91 +++ ...sactionFeeEstimateResponseEstimatedCost.ts | 88 +++ ...ansactionFeeEstimateResponseEstimations.ts | 64 ++ .../generated/models/TransactionIdentifier.ts | 7 +- .../generated/models/TransactionResults.ts | 7 +- .../UnanchoredTransactionListResponse.ts | 64 ++ client/src/generated/models/index.ts | 75 +- client/src/generated/runtime.ts | 40 +- docs/openapi.yaml | 4 +- 177 files changed, 10412 insertions(+), 1505 deletions(-) create mode 100644 client/src/generated/.openapi-generator/FILES delete mode 100644 client/src/generated/apis/BurnchainApi.ts create mode 100644 client/src/generated/apis/FungibleTokensApi.ts create mode 100644 client/src/generated/apis/MempoolApi.ts create mode 100644 client/src/generated/apis/MicroblocksApi.ts create mode 100644 client/src/generated/apis/NamesApi.ts create mode 100644 client/src/generated/apis/NonFungibleTokensApi.ts create mode 100644 client/src/generated/apis/StackingApi.ts create mode 100644 client/src/generated/apis/StackingRewardsApi.ts create mode 100644 client/src/generated/models/AddressNftListResponse.ts create mode 100644 client/src/generated/models/AddressNftListResponseValue.ts create mode 100644 client/src/generated/models/AddressNonces.ts delete mode 100644 client/src/generated/models/AddressStxBalanceResponse.ts create mode 100644 client/src/generated/models/AddressStxInboundListResponse.ts create mode 100644 client/src/generated/models/AddressTokenOfferingLocked.ts create mode 100644 client/src/generated/models/AddressTransactionWithTransfers.ts create mode 100644 client/src/generated/models/AddressTransactionWithTransfersFtTransfers.ts create mode 100644 client/src/generated/models/AddressTransactionWithTransfersNftTransfers.ts create mode 100644 client/src/generated/models/AddressTransactionWithTransfersStxTransfers.ts create mode 100644 client/src/generated/models/AddressTransactionWithTransfersValue.ts create mode 100644 client/src/generated/models/AddressTransactionsWithTransfersListResponse.ts create mode 100644 client/src/generated/models/AddressUnlockSchedule.ts create mode 100644 client/src/generated/models/BnsError.ts create mode 100644 client/src/generated/models/BnsGetAllNamespacesResponse.ts create mode 100644 client/src/generated/models/BnsGetNameInfoResponse.ts create mode 100644 client/src/generated/models/BnsGetNamePriceResponse.ts create mode 100644 client/src/generated/models/BnsGetNamespacePriceResponse.ts create mode 100644 client/src/generated/models/BnsNamesOwnByAddressResponse.ts create mode 100644 client/src/generated/models/BurnchainRewardSlotHolder.ts create mode 100644 client/src/generated/models/BurnchainRewardSlotHolderListResponse.ts create mode 100644 client/src/generated/models/ChainTip.ts create mode 100644 client/src/generated/models/ContractListResponse.ts create mode 100644 client/src/generated/models/FeeRate.ts create mode 100644 client/src/generated/models/FeeRateRequest.ts create mode 100644 client/src/generated/models/FungibleTokenMetadata.ts create mode 100644 client/src/generated/models/FungibleTokensMetadataList.ts create mode 100644 client/src/generated/models/GetRawTransactionResult.ts create mode 100644 client/src/generated/models/GetStxSupplyLegacyFormatResponse.ts create mode 100644 client/src/generated/models/GetStxSupplyResponse.ts create mode 100644 client/src/generated/models/InboundStxTransfer.ts create mode 100644 client/src/generated/models/InlineObject.ts create mode 100644 client/src/generated/models/InlineResponse403.ts create mode 100644 client/src/generated/models/MempoolFeePriorities.ts create mode 100644 client/src/generated/models/MempoolFeePrioritiesAll.ts create mode 100644 client/src/generated/models/MempoolTransactionStatsResponse.ts create mode 100644 client/src/generated/models/MempoolTransactionStatsResponseTxAges.ts create mode 100644 client/src/generated/models/MempoolTransactionStatsResponseTxByteSizes.ts create mode 100644 client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAverages.ts create mode 100644 client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer.ts create mode 100644 client/src/generated/models/MempoolTransactionStatsResponseTxTypeCounts.ts create mode 100644 client/src/generated/models/Microblock.ts create mode 100644 client/src/generated/models/MicroblockListResponse.ts delete mode 100644 client/src/generated/models/NetworkBlockTimesResponseMainnet.ts create mode 100644 client/src/generated/models/NftEvent.ts create mode 100644 client/src/generated/models/NonFungibleTokenHistoryEventList.ts create mode 100644 client/src/generated/models/NonFungibleTokenHoldingsList.ts create mode 100644 client/src/generated/models/NonFungibleTokenMetadata.ts create mode 100644 client/src/generated/models/NonFungibleTokenMintList.ts create mode 100644 client/src/generated/models/NonFungibleTokensMetadataList.ts create mode 100644 client/src/generated/models/OtherTransactionIdentifier.ts create mode 100644 client/src/generated/models/PoolDelegation.ts create mode 100644 client/src/generated/models/PoolDelegationsResponse.ts create mode 100644 client/src/generated/models/RosettaAccountIdentifier.ts delete mode 100644 client/src/generated/models/RosettaBlockMetadata2.ts create mode 100644 client/src/generated/models/RosettaErrorNoDetails.ts create mode 100644 client/src/generated/models/RosettaGenesisBlockIdentifier.ts create mode 100644 client/src/generated/models/RosettaMaxFeeAmount.ts create mode 100644 client/src/generated/models/RosettaNetworkStatusResponse.ts create mode 100644 client/src/generated/models/RosettaOldestBlockIdentifier.ts create mode 100644 client/src/generated/models/RosettaPeers.ts create mode 100644 client/src/generated/models/RosettaSyncStatus.ts create mode 100644 client/src/generated/models/ServerStatusResponse.ts create mode 100644 client/src/generated/models/SmartContract.ts rename client/src/generated/models/{AddressBalanceResponseStx.ts => StxBalance.ts} (53%) create mode 100644 client/src/generated/models/TargetBlockTime.ts create mode 100644 client/src/generated/models/TransactionEventsResponse.ts create mode 100644 client/src/generated/models/TransactionFeeEstimateRequest.ts create mode 100644 client/src/generated/models/TransactionFeeEstimateResponse.ts create mode 100644 client/src/generated/models/TransactionFeeEstimateResponseEstimatedCost.ts create mode 100644 client/src/generated/models/TransactionFeeEstimateResponseEstimations.ts create mode 100644 client/src/generated/models/UnanchoredTransactionListResponse.ts diff --git a/client/src/generated/.openapi-generator/FILES b/client/src/generated/.openapi-generator/FILES new file mode 100644 index 0000000000..698b84bca8 --- /dev/null +++ b/client/src/generated/.openapi-generator/FILES @@ -0,0 +1,172 @@ +.openapi-generator-ignore +apis/AccountsApi.ts +apis/BlocksApi.ts +apis/FaucetsApi.ts +apis/FeesApi.ts +apis/FungibleTokensApi.ts +apis/InfoApi.ts +apis/MempoolApi.ts +apis/MicroblocksApi.ts +apis/NamesApi.ts +apis/NonFungibleTokensApi.ts +apis/RosettaApi.ts +apis/SearchApi.ts +apis/SmartContractsApi.ts +apis/StackingApi.ts +apis/StackingRewardsApi.ts +apis/TransactionsApi.ts +apis/index.ts +index.ts +models/AccountDataResponse.ts +models/AddressAssetsListResponse.ts +models/AddressBalanceResponse.ts +models/AddressNftListResponse.ts +models/AddressNftListResponseValue.ts +models/AddressNonces.ts +models/AddressStxInboundListResponse.ts +models/AddressTokenOfferingLocked.ts +models/AddressTransactionWithTransfers.ts +models/AddressTransactionWithTransfersFtTransfers.ts +models/AddressTransactionWithTransfersNftTransfers.ts +models/AddressTransactionWithTransfersStxTransfers.ts +models/AddressTransactionWithTransfersValue.ts +models/AddressTransactionsListResponse.ts +models/AddressTransactionsWithTransfersListResponse.ts +models/AddressUnlockSchedule.ts +models/Block.ts +models/BlockListResponse.ts +models/BnsError.ts +models/BnsGetAllNamespacesResponse.ts +models/BnsGetNameInfoResponse.ts +models/BnsGetNamePriceResponse.ts +models/BnsGetNamespacePriceResponse.ts +models/BnsNamesOwnByAddressResponse.ts +models/BurnchainReward.ts +models/BurnchainRewardListResponse.ts +models/BurnchainRewardSlotHolder.ts +models/BurnchainRewardSlotHolderListResponse.ts +models/BurnchainRewardsTotal.ts +models/ChainTip.ts +models/ContractInterfaceResponse.ts +models/ContractListResponse.ts +models/ContractSourceResponse.ts +models/CoreNodeInfoResponse.ts +models/CoreNodePoxResponse.ts +models/FeeRate.ts +models/FeeRateRequest.ts +models/FungibleTokenMetadata.ts +models/FungibleTokensMetadataList.ts +models/GetRawTransactionResult.ts +models/GetStxSupplyLegacyFormatResponse.ts +models/GetStxSupplyResponse.ts +models/InboundStxTransfer.ts +models/InlineObject.ts +models/InlineResponse403.ts +models/MapEntryResponse.ts +models/MempoolFeePriorities.ts +models/MempoolFeePrioritiesAll.ts +models/MempoolTransactionListResponse.ts +models/MempoolTransactionStatsResponse.ts +models/MempoolTransactionStatsResponseTxAges.ts +models/MempoolTransactionStatsResponseTxByteSizes.ts +models/MempoolTransactionStatsResponseTxSimpleFeeAverages.ts +models/MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer.ts +models/MempoolTransactionStatsResponseTxTypeCounts.ts +models/Microblock.ts +models/MicroblockListResponse.ts +models/NetworkBlockTimeResponse.ts +models/NetworkBlockTimesResponse.ts +models/NetworkIdentifier.ts +models/NftEvent.ts +models/NonFungibleTokenHistoryEventList.ts +models/NonFungibleTokenHoldingsList.ts +models/NonFungibleTokenMetadata.ts +models/NonFungibleTokenMintList.ts +models/NonFungibleTokensMetadataList.ts +models/OtherTransactionIdentifier.ts +models/PoolDelegation.ts +models/PoolDelegationsResponse.ts +models/PostCoreNodeTransactionsError.ts +models/ReadOnlyFunctionArgs.ts +models/ReadOnlyFunctionSuccessResponse.ts +models/RosettaAccount.ts +models/RosettaAccountBalanceRequest.ts +models/RosettaAccountBalanceResponse.ts +models/RosettaAccountBalanceResponseCoinIdentifier.ts +models/RosettaAccountBalanceResponseMetadata.ts +models/RosettaAccountIdentifier.ts +models/RosettaAmount.ts +models/RosettaBlock.ts +models/RosettaBlockMetadata.ts +models/RosettaBlockMetadata1.ts +models/RosettaBlockRequest.ts +models/RosettaBlockResponse.ts +models/RosettaBlockTransactionRequest.ts +models/RosettaBlockTransactionResponse.ts +models/RosettaCoin.ts +models/RosettaCoinChange.ts +models/RosettaConstructionCombineRequest.ts +models/RosettaConstructionCombineResponse.ts +models/RosettaConstructionDeriveRequest.ts +models/RosettaConstructionDeriveResponse.ts +models/RosettaConstructionHashRequest.ts +models/RosettaConstructionHashResponse.ts +models/RosettaConstructionMetadataRequest.ts +models/RosettaConstructionMetadataResponse.ts +models/RosettaConstructionMetadataResponseMetadata.ts +models/RosettaConstructionParseRequest.ts +models/RosettaConstructionParseResponse.ts +models/RosettaConstructionPayloadResponse.ts +models/RosettaConstructionPayloadsRequest.ts +models/RosettaConstructionPreprocessRequest.ts +models/RosettaConstructionPreprocessResponse.ts +models/RosettaConstructionSubmitRequest.ts +models/RosettaConstructionSubmitResponse.ts +models/RosettaCurrency.ts +models/RosettaError.ts +models/RosettaErrorDetails.ts +models/RosettaErrorNoDetails.ts +models/RosettaGenesisBlockIdentifier.ts +models/RosettaMaxFeeAmount.ts +models/RosettaMempoolRequest.ts +models/RosettaMempoolResponse.ts +models/RosettaMempoolTransactionRequest.ts +models/RosettaMempoolTransactionResponse.ts +models/RosettaNetworkListResponse.ts +models/RosettaNetworkListResponseSubNetworkIdentifier.ts +models/RosettaNetworkListResponseSubNetworkIdentifierMetadata.ts +models/RosettaNetworkOptionsResponse.ts +models/RosettaNetworkOptionsResponseAllow.ts +models/RosettaNetworkOptionsResponseVersion.ts +models/RosettaNetworkStatusResponse.ts +models/RosettaOldestBlockIdentifier.ts +models/RosettaOperation.ts +models/RosettaOperationIdentifier.ts +models/RosettaOperationStatus.ts +models/RosettaOptions.ts +models/RosettaOptionsRequest.ts +models/RosettaParentBlockIdentifier.ts +models/RosettaPeers.ts +models/RosettaPublicKey.ts +models/RosettaRelatedOperation.ts +models/RosettaSignature.ts +models/RosettaStatusRequest.ts +models/RosettaSubAccount.ts +models/RosettaSyncStatus.ts +models/RosettaTransaction.ts +models/RunFaucetResponse.ts +models/ServerStatusResponse.ts +models/SigningPayload.ts +models/SmartContract.ts +models/StxBalance.ts +models/TargetBlockTime.ts +models/TransactionEventsResponse.ts +models/TransactionFeeEstimateRequest.ts +models/TransactionFeeEstimateResponse.ts +models/TransactionFeeEstimateResponseEstimatedCost.ts +models/TransactionFeeEstimateResponseEstimations.ts +models/TransactionIdentifier.ts +models/TransactionResults.ts +models/UnanchoredTransactionListResponse.ts +models/index.ts +runtime.ts diff --git a/client/src/generated/apis/AccountsApi.ts b/client/src/generated/apis/AccountsApi.ts index 9ea7abf259..e1120dc74a 100644 --- a/client/src/generated/apis/AccountsApi.ts +++ b/client/src/generated/apis/AccountsApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -24,22 +24,47 @@ import { AddressBalanceResponse, AddressBalanceResponseFromJSON, AddressBalanceResponseToJSON, - AddressStxBalanceResponse, - AddressStxBalanceResponseFromJSON, - AddressStxBalanceResponseToJSON, + AddressNftListResponse, + AddressNftListResponseFromJSON, + AddressNftListResponseToJSON, + AddressNonces, + AddressNoncesFromJSON, + AddressNoncesToJSON, + AddressStxInboundListResponse, + AddressStxInboundListResponseFromJSON, + AddressStxInboundListResponseToJSON, + AddressTransactionWithTransfers, + AddressTransactionWithTransfersFromJSON, + AddressTransactionWithTransfersToJSON, AddressTransactionsListResponse, AddressTransactionsListResponseFromJSON, AddressTransactionsListResponseToJSON, + AddressTransactionsWithTransfersListResponse, + AddressTransactionsWithTransfersListResponseFromJSON, + AddressTransactionsWithTransfersListResponseToJSON, } from '../models'; export interface GetAccountAssetsRequest { principal: string; limit?: number; offset?: number; + unanchored?: boolean; + untilBlock?: string; } export interface GetAccountBalanceRequest { principal: string; + unanchored?: boolean; + untilBlock?: string; +} + +export interface GetAccountInboundRequest { + principal: string; + limit?: number; + offset?: number; + height?: number; + unanchored?: boolean; + untilBlock?: string; } export interface GetAccountInfoRequest { @@ -48,14 +73,47 @@ export interface GetAccountInfoRequest { tip?: string; } +export interface GetAccountNftRequest { + principal: string; + limit?: number; + offset?: number; + unanchored?: boolean; + untilBlock?: string; +} + +export interface GetAccountNoncesRequest { + principal: string; + blockHeight?: number; + blockHash?: string; +} + export interface GetAccountStxBalanceRequest { principal: string; + unanchored?: boolean; + untilBlock?: string; } export interface GetAccountTransactionsRequest { principal: string; limit?: number; offset?: number; + height?: number; + unanchored?: boolean; + untilBlock?: string; +} + +export interface GetAccountTransactionsWithTransfersRequest { + principal: string; + limit?: number; + offset?: number; + height?: number; + unanchored?: boolean; + untilBlock?: string; +} + +export interface GetSingleTransactionWithTransfersRequest { + principal: string; + txId: string; } /** @@ -66,86 +124,196 @@ export interface GetAccountTransactionsRequest { */ export interface AccountsApiInterface { /** - * + * Retrieves a list of all assets events associated with an account or a Contract Identifier. This includes Transfers, Mints. * @summary Get account assets - * @param {string} principal Stacks address or a Contract identifier (e.g. `SP31DA6FTSJX2WGTZ69SFY11BH51NZMB0ZW97B5P0.get-info`) + * @param {string} principal Stacks address or a Contract identifier * @param {number} [limit] max number of account assets to fetch * @param {number} [offset] index of first account assets to fetch + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {string} [untilBlock] returned data representing the state at that point in time, rather than the current block. Note - Use either of the query parameters but not both at a time. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof AccountsApiInterface */ - getAccountAssetsRaw(requestParameters: GetAccountAssetsRequest): Promise>; + getAccountAssetsRaw(requestParameters: GetAccountAssetsRequest, initOverrides?: RequestInit): Promise>; /** + * Retrieves a list of all assets events associated with an account or a Contract Identifier. This includes Transfers, Mints. * Get account assets */ - getAccountAssets(requestParameters: GetAccountAssetsRequest): Promise; + getAccountAssets(requestParameters: GetAccountAssetsRequest, initOverrides?: RequestInit): Promise; /** - * + * Retrieves total account balance information for a given Address or Contract Identifier. This includes the balances of STX Tokens, Fungible Tokens and Non-Fungible Tokens for the account. * @summary Get account balances - * @param {string} principal Stacks address or a Contract identifier (e.g. `SP31DA6FTSJX2WGTZ69SFY11BH51NZMB0ZW97B5P0.get-info`) + * @param {string} principal Stacks address or a Contract identifier + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {string} [untilBlock] returned data representing the state up until that point in time, rather than the current block. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof AccountsApiInterface */ - getAccountBalanceRaw(requestParameters: GetAccountBalanceRequest): Promise>; + getAccountBalanceRaw(requestParameters: GetAccountBalanceRequest, initOverrides?: RequestInit): Promise>; /** + * Retrieves total account balance information for a given Address or Contract Identifier. This includes the balances of STX Tokens, Fungible Tokens and Non-Fungible Tokens for the account. * Get account balances */ - getAccountBalance(requestParameters: GetAccountBalanceRequest): Promise; + getAccountBalance(requestParameters: GetAccountBalanceRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of STX transfers with memos to the given principal. This includes regular transfers from a stx-transfer transaction type, and transfers from contract-call transactions a the `send-many-memo` bulk sending contract. + * @summary Get inbound STX transfers + * @param {string} principal Stacks address or a Contract identifier + * @param {number} [limit] number of items to return + * @param {number} [offset] number of items to skip + * @param {number} [height] Filter for transfers only at this given block height + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {string} [untilBlock] returned data representing the state up until that point in time, rather than the current block. Note - Use either of the query parameters but not both at a time. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AccountsApiInterface + */ + getAccountInboundRaw(requestParameters: GetAccountInboundRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of STX transfers with memos to the given principal. This includes regular transfers from a stx-transfer transaction type, and transfers from contract-call transactions a the `send-many-memo` bulk sending contract. + * Get inbound STX transfers + */ + getAccountInbound(requestParameters: GetAccountInboundRequest, initOverrides?: RequestInit): Promise; /** - * Get the account data for the provided principal Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is a unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not 404, rather it returns an object with balance and nonce of 0. + * Retrieves the account data for a given Account or a Contract Identifier Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is an unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not return a 404 error, rather it returns an object with balance and nonce of 0. * @summary Get account info - * @param {string} principal Stacks address or a Contract identifier (e.g. `SP31DA6FTSJX2WGTZ69SFY11BH51NZMB0ZW97B5P0.get-info`) + * @param {string} principal Stacks address or a Contract identifier * @param {number} [proof] Returns object without the proof field if set to 0 * @param {string} [tip] The Stacks chain tip to query from * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof AccountsApiInterface */ - getAccountInfoRaw(requestParameters: GetAccountInfoRequest): Promise>; + getAccountInfoRaw(requestParameters: GetAccountInfoRequest, initOverrides?: RequestInit): Promise>; /** - * Get the account data for the provided principal Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is a unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not 404, rather it returns an object with balance and nonce of 0. + * Retrieves the account data for a given Account or a Contract Identifier Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is an unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not return a 404 error, rather it returns an object with balance and nonce of 0. * Get account info */ - getAccountInfo(requestParameters: GetAccountInfoRequest): Promise; + getAccountInfo(requestParameters: GetAccountInfoRequest, initOverrides?: RequestInit): Promise; + + /** + * **NOTE:** This endpoint is deprecated in favor of [Non-Fungible Token holdings](#operation/get_nft_holdings). Retrieves a list of all nfts owned by an address, contains the clarity value of the identifier of the nft. + * @summary Get nft events + * @param {string} principal Stacks address or a Contract identifier + * @param {number} [limit] number of items to return + * @param {number} [offset] number of items to skip + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {string} [untilBlock] returned data representing the state up until that point in time, rather than the current block. Note - Use either of the query parameters but not both at a time. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AccountsApiInterface + */ + getAccountNftRaw(requestParameters: GetAccountNftRequest, initOverrides?: RequestInit): Promise>; /** - * + * **NOTE:** This endpoint is deprecated in favor of [Non-Fungible Token holdings](#operation/get_nft_holdings). Retrieves a list of all nfts owned by an address, contains the clarity value of the identifier of the nft. + * Get nft events + */ + getAccountNft(requestParameters: GetAccountNftRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves the latest nonce values used by an account by inspecting the mempool, microblock transactions, and anchored transactions. + * @summary Get the latest nonce used by an account + * @param {string} principal Stacks address + * @param {number} [blockHeight] Optionally get the nonce at a given block height. + * @param {string} [blockHash] Optionally get the nonce at a given block hash. Note - Use either of the query parameters but not both at a time. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AccountsApiInterface + */ + getAccountNoncesRaw(requestParameters: GetAccountNoncesRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the latest nonce values used by an account by inspecting the mempool, microblock transactions, and anchored transactions. + * Get the latest nonce used by an account + */ + getAccountNonces(requestParameters: GetAccountNoncesRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves STX token balance for a given Address or Contract Identifier. * @summary Get account STX balance - * @param {string} principal Stacks address or a Contract identifier (e.g. `SP31DA6FTSJX2WGTZ69SFY11BH51NZMB0ZW97B5P0.get-info`) + * @param {string} principal Stacks address or a Contract identifier. + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks. + * @param {string} [untilBlock] returned data representing the state up until that point in time, rather than the current block. Note - Use either of the query parameters but not both at a time. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof AccountsApiInterface */ - getAccountStxBalanceRaw(requestParameters: GetAccountStxBalanceRequest): Promise>; + getAccountStxBalanceRaw(requestParameters: GetAccountStxBalanceRequest, initOverrides?: RequestInit): Promise>; /** + * Retrieves STX token balance for a given Address or Contract Identifier. * Get account STX balance */ - getAccountStxBalance(requestParameters: GetAccountStxBalanceRequest): Promise; + getAccountStxBalance(requestParameters: GetAccountStxBalanceRequest, initOverrides?: RequestInit): Promise; /** - * + * Retrieves a list of all Transactions for a given Address or Contract Identifier. More information on Transaction types can be found [here](https://docs.stacks.co/understand-stacks/transactions#types). If you need to actively monitor new transactions for an address or contract id, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * @summary Get account transactions - * @param {string} principal Stacks address or a Contract identifier (e.g. `SP31DA6FTSJX2WGTZ69SFY11BH51NZMB0ZW97B5P0.get-info`) + * @param {string} principal Stacks address or a Contract identifier * @param {number} [limit] max number of account transactions to fetch * @param {number} [offset] index of first account transaction to fetch + * @param {number} [height] Filter for transactions only at this given block height + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {string} [untilBlock] returned data representing the state up until that point in time, rather than the current block. Note - Use either of the query parameters but not both at a time. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof AccountsApiInterface */ - getAccountTransactionsRaw(requestParameters: GetAccountTransactionsRequest): Promise>; + getAccountTransactionsRaw(requestParameters: GetAccountTransactionsRequest, initOverrides?: RequestInit): Promise>; /** + * Retrieves a list of all Transactions for a given Address or Contract Identifier. More information on Transaction types can be found [here](https://docs.stacks.co/understand-stacks/transactions#types). If you need to actively monitor new transactions for an address or contract id, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get account transactions */ - getAccountTransactions(requestParameters: GetAccountTransactionsRequest): Promise; + getAccountTransactions(requestParameters: GetAccountTransactionsRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieve all transactions for an account or contract identifier including STX transfers for each transaction. + * @summary Get account transactions including STX transfers for each transaction. + * @param {string} principal Stacks address or a Contract identifier + * @param {number} [limit] max number of account transactions to fetch + * @param {number} [offset] index of first account transaction to fetch + * @param {number} [height] Filter for transactions only at this given block height + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {string} [untilBlock] returned data representing the state up until that point in time, rather than the current block. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AccountsApiInterface + */ + getAccountTransactionsWithTransfersRaw(requestParameters: GetAccountTransactionsWithTransfersRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieve all transactions for an account or contract identifier including STX transfers for each transaction. + * Get account transactions including STX transfers for each transaction. + */ + getAccountTransactionsWithTransfers(requestParameters: GetAccountTransactionsWithTransfersRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves transaction details for a given Transaction Id `tx_id`, for a given account or contract Identifier. + * @summary Get account transaction information for specific transaction + * @param {string} principal Stacks address or a contract identifier + * @param {string} txId Transaction id + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AccountsApiInterface + */ + getSingleTransactionWithTransfersRaw(requestParameters: GetSingleTransactionWithTransfersRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves transaction details for a given Transaction Id `tx_id`, for a given account or contract Identifier. + * Get account transaction information for specific transaction + */ + getSingleTransactionWithTransfers(requestParameters: GetSingleTransactionWithTransfersRequest, initOverrides?: RequestInit): Promise; } @@ -155,14 +323,15 @@ export interface AccountsApiInterface { export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface { /** + * Retrieves a list of all assets events associated with an account or a Contract Identifier. This includes Transfers, Mints. * Get account assets */ - async getAccountAssetsRaw(requestParameters: GetAccountAssetsRequest): Promise> { + async getAccountAssetsRaw(requestParameters: GetAccountAssetsRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.principal === null || requestParameters.principal === undefined) { throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountAssets.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.limit !== undefined) { queryParameters['limit'] = requestParameters.limit; @@ -172,6 +341,14 @@ export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface queryParameters['offset'] = requestParameters.offset; } + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.untilBlock !== undefined) { + queryParameters['until_block'] = requestParameters.untilBlock; + } + const headerParameters: runtime.HTTPHeaders = {}; const response = await this.request({ @@ -179,28 +356,38 @@ export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => AddressAssetsListResponseFromJSON(jsonValue)); } /** + * Retrieves a list of all assets events associated with an account or a Contract Identifier. This includes Transfers, Mints. * Get account assets */ - async getAccountAssets(requestParameters: GetAccountAssetsRequest): Promise { - const response = await this.getAccountAssetsRaw(requestParameters); + async getAccountAssets(requestParameters: GetAccountAssetsRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountAssetsRaw(requestParameters, initOverrides); return await response.value(); } /** + * Retrieves total account balance information for a given Address or Contract Identifier. This includes the balances of STX Tokens, Fungible Tokens and Non-Fungible Tokens for the account. * Get account balances */ - async getAccountBalanceRaw(requestParameters: GetAccountBalanceRequest): Promise> { + async getAccountBalanceRaw(requestParameters: GetAccountBalanceRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.principal === null || requestParameters.principal === undefined) { throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountBalance.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.untilBlock !== undefined) { + queryParameters['until_block'] = requestParameters.untilBlock; + } const headerParameters: runtime.HTTPHeaders = {}; @@ -209,29 +396,82 @@ export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => AddressBalanceResponseFromJSON(jsonValue)); } /** + * Retrieves total account balance information for a given Address or Contract Identifier. This includes the balances of STX Tokens, Fungible Tokens and Non-Fungible Tokens for the account. * Get account balances */ - async getAccountBalance(requestParameters: GetAccountBalanceRequest): Promise { - const response = await this.getAccountBalanceRaw(requestParameters); + async getAccountBalance(requestParameters: GetAccountBalanceRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountBalanceRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of STX transfers with memos to the given principal. This includes regular transfers from a stx-transfer transaction type, and transfers from contract-call transactions a the `send-many-memo` bulk sending contract. + * Get inbound STX transfers + */ + async getAccountInboundRaw(requestParameters: GetAccountInboundRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.principal === null || requestParameters.principal === undefined) { + throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountInbound.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.height !== undefined) { + queryParameters['height'] = requestParameters.height; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.untilBlock !== undefined) { + queryParameters['until_block'] = requestParameters.untilBlock; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/address/{principal}/stx_inbound`.replace(`{${"principal"}}`, encodeURIComponent(String(requestParameters.principal))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => AddressStxInboundListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of STX transfers with memos to the given principal. This includes regular transfers from a stx-transfer transaction type, and transfers from contract-call transactions a the `send-many-memo` bulk sending contract. + * Get inbound STX transfers + */ + async getAccountInbound(requestParameters: GetAccountInboundRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountInboundRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get the account data for the provided principal Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is a unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not 404, rather it returns an object with balance and nonce of 0. + * Retrieves the account data for a given Account or a Contract Identifier Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is an unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not return a 404 error, rather it returns an object with balance and nonce of 0. * Get account info */ - async getAccountInfoRaw(requestParameters: GetAccountInfoRequest): Promise> { + async getAccountInfoRaw(requestParameters: GetAccountInfoRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.principal === null || requestParameters.principal === undefined) { throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountInfo.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.proof !== undefined) { queryParameters['proof'] = requestParameters.proof; @@ -248,29 +488,126 @@ export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => AccountDataResponseFromJSON(jsonValue)); } /** - * Get the account data for the provided principal Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is a unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not 404, rather it returns an object with balance and nonce of 0. + * Retrieves the account data for a given Account or a Contract Identifier Where balance is the hex encoding of a unsigned 128-bit integer (big-endian), nonce is an unsigned 64-bit integer, and the proofs are provided as hex strings. For non-existent accounts, this does not return a 404 error, rather it returns an object with balance and nonce of 0. * Get account info */ - async getAccountInfo(requestParameters: GetAccountInfoRequest): Promise { - const response = await this.getAccountInfoRaw(requestParameters); + async getAccountInfo(requestParameters: GetAccountInfoRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountInfoRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of [Non-Fungible Token holdings](#operation/get_nft_holdings). Retrieves a list of all nfts owned by an address, contains the clarity value of the identifier of the nft. + * Get nft events + */ + async getAccountNftRaw(requestParameters: GetAccountNftRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.principal === null || requestParameters.principal === undefined) { + throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountNft.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.untilBlock !== undefined) { + queryParameters['until_block'] = requestParameters.untilBlock; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/address/{principal}/nft_events`.replace(`{${"principal"}}`, encodeURIComponent(String(requestParameters.principal))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => AddressNftListResponseFromJSON(jsonValue)); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of [Non-Fungible Token holdings](#operation/get_nft_holdings). Retrieves a list of all nfts owned by an address, contains the clarity value of the identifier of the nft. + * Get nft events + */ + async getAccountNft(requestParameters: GetAccountNftRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountNftRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves the latest nonce values used by an account by inspecting the mempool, microblock transactions, and anchored transactions. + * Get the latest nonce used by an account + */ + async getAccountNoncesRaw(requestParameters: GetAccountNoncesRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.principal === null || requestParameters.principal === undefined) { + throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountNonces.'); + } + + const queryParameters: any = {}; + + if (requestParameters.blockHeight !== undefined) { + queryParameters['block_height'] = requestParameters.blockHeight; + } + + if (requestParameters.blockHash !== undefined) { + queryParameters['block_hash'] = requestParameters.blockHash; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/address/{principal}/nonces`.replace(`{${"principal"}}`, encodeURIComponent(String(requestParameters.principal))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => AddressNoncesFromJSON(jsonValue)); + } + + /** + * Retrieves the latest nonce values used by an account by inspecting the mempool, microblock transactions, and anchored transactions. + * Get the latest nonce used by an account + */ + async getAccountNonces(requestParameters: GetAccountNoncesRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountNoncesRaw(requestParameters, initOverrides); return await response.value(); } /** + * Retrieves STX token balance for a given Address or Contract Identifier. * Get account STX balance */ - async getAccountStxBalanceRaw(requestParameters: GetAccountStxBalanceRequest): Promise> { + async getAccountStxBalanceRaw(requestParameters: GetAccountStxBalanceRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.principal === null || requestParameters.principal === undefined) { throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountStxBalance.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.untilBlock !== undefined) { + queryParameters['until_block'] = requestParameters.untilBlock; + } const headerParameters: runtime.HTTPHeaders = {}; @@ -279,28 +616,30 @@ export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); - return new runtime.JSONApiResponse(response, (jsonValue) => AddressStxBalanceResponseFromJSON(jsonValue)); + return new runtime.JSONApiResponse(response); } /** + * Retrieves STX token balance for a given Address or Contract Identifier. * Get account STX balance */ - async getAccountStxBalance(requestParameters: GetAccountStxBalanceRequest): Promise { - const response = await this.getAccountStxBalanceRaw(requestParameters); + async getAccountStxBalance(requestParameters: GetAccountStxBalanceRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountStxBalanceRaw(requestParameters, initOverrides); return await response.value(); } /** + * Retrieves a list of all Transactions for a given Address or Contract Identifier. More information on Transaction types can be found [here](https://docs.stacks.co/understand-stacks/transactions#types). If you need to actively monitor new transactions for an address or contract id, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get account transactions */ - async getAccountTransactionsRaw(requestParameters: GetAccountTransactionsRequest): Promise> { + async getAccountTransactionsRaw(requestParameters: GetAccountTransactionsRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.principal === null || requestParameters.principal === undefined) { throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountTransactions.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.limit !== undefined) { queryParameters['limit'] = requestParameters.limit; @@ -310,6 +649,18 @@ export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface queryParameters['offset'] = requestParameters.offset; } + if (requestParameters.height !== undefined) { + queryParameters['height'] = requestParameters.height; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.untilBlock !== undefined) { + queryParameters['until_block'] = requestParameters.untilBlock; + } + const headerParameters: runtime.HTTPHeaders = {}; const response = await this.request({ @@ -317,16 +668,105 @@ export class AccountsApi extends runtime.BaseAPI implements AccountsApiInterface method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => AddressTransactionsListResponseFromJSON(jsonValue)); } /** + * Retrieves a list of all Transactions for a given Address or Contract Identifier. More information on Transaction types can be found [here](https://docs.stacks.co/understand-stacks/transactions#types). If you need to actively monitor new transactions for an address or contract id, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get account transactions */ - async getAccountTransactions(requestParameters: GetAccountTransactionsRequest): Promise { - const response = await this.getAccountTransactionsRaw(requestParameters); + async getAccountTransactions(requestParameters: GetAccountTransactionsRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountTransactionsRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieve all transactions for an account or contract identifier including STX transfers for each transaction. + * Get account transactions including STX transfers for each transaction. + */ + async getAccountTransactionsWithTransfersRaw(requestParameters: GetAccountTransactionsWithTransfersRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.principal === null || requestParameters.principal === undefined) { + throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getAccountTransactionsWithTransfers.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.height !== undefined) { + queryParameters['height'] = requestParameters.height; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.untilBlock !== undefined) { + queryParameters['until_block'] = requestParameters.untilBlock; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/address/{principal}/transactions_with_transfers`.replace(`{${"principal"}}`, encodeURIComponent(String(requestParameters.principal))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => AddressTransactionsWithTransfersListResponseFromJSON(jsonValue)); + } + + /** + * Retrieve all transactions for an account or contract identifier including STX transfers for each transaction. + * Get account transactions including STX transfers for each transaction. + */ + async getAccountTransactionsWithTransfers(requestParameters: GetAccountTransactionsWithTransfersRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAccountTransactionsWithTransfersRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves transaction details for a given Transaction Id `tx_id`, for a given account or contract Identifier. + * Get account transaction information for specific transaction + */ + async getSingleTransactionWithTransfersRaw(requestParameters: GetSingleTransactionWithTransfersRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.principal === null || requestParameters.principal === undefined) { + throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getSingleTransactionWithTransfers.'); + } + + if (requestParameters.txId === null || requestParameters.txId === undefined) { + throw new runtime.RequiredError('txId','Required parameter requestParameters.txId was null or undefined when calling getSingleTransactionWithTransfers.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/address/{principal}/{tx_id}/with_transfers`.replace(`{${"principal"}}`, encodeURIComponent(String(requestParameters.principal))).replace(`{${"tx_id"}}`, encodeURIComponent(String(requestParameters.txId))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => AddressTransactionWithTransfersFromJSON(jsonValue)); + } + + /** + * Retrieves transaction details for a given Transaction Id `tx_id`, for a given account or contract Identifier. + * Get account transaction information for specific transaction + */ + async getSingleTransactionWithTransfers(requestParameters: GetSingleTransactionWithTransfersRequest, initOverrides?: RequestInit): Promise { + const response = await this.getSingleTransactionWithTransfersRaw(requestParameters, initOverrides); return await response.value(); } diff --git a/client/src/generated/apis/BlocksApi.ts b/client/src/generated/apis/BlocksApi.ts index 535b30d494..d51aa87cc3 100644 --- a/client/src/generated/apis/BlocksApi.ts +++ b/client/src/generated/apis/BlocksApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -23,10 +23,22 @@ import { BlockListResponseToJSON, } from '../models'; +export interface GetBlockByBurnBlockHashRequest { + burnBlockHash: string; +} + +export interface GetBlockByBurnBlockHeightRequest { + burnBlockHeight: number; +} + export interface GetBlockByHashRequest { hash: string; } +export interface GetBlockByHeightRequest { + height: number; +} + export interface GetBlockListRequest { limit?: number; offset?: number; @@ -40,23 +52,71 @@ export interface GetBlockListRequest { */ export interface BlocksApiInterface { /** - * Get a specific block by hash - * @summary Get block + * Retrieves block details of a specific block for a given burnchain block hash + * @summary Get block by burnchain block hash + * @param {string} burnBlockHash Hash of the burnchain block + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof BlocksApiInterface + */ + getBlockByBurnBlockHashRaw(requestParameters: GetBlockByBurnBlockHashRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves block details of a specific block for a given burnchain block hash + * Get block by burnchain block hash + */ + getBlockByBurnBlockHash(requestParameters: GetBlockByBurnBlockHashRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves block details of a specific block for a given burn chain height + * @summary Get block by burnchain height + * @param {number} burnBlockHeight Height of the burn chain block + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof BlocksApiInterface + */ + getBlockByBurnBlockHeightRaw(requestParameters: GetBlockByBurnBlockHeightRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves block details of a specific block for a given burn chain height + * Get block by burnchain height + */ + getBlockByBurnBlockHeight(requestParameters: GetBlockByBurnBlockHeightRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves block details of a specific block for a given chain height. You can use the hash from your latest block (\'get_block_list\' API) to get your block details. + * @summary Get block by hash * @param {string} hash Hash of the block * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof BlocksApiInterface */ - getBlockByHashRaw(requestParameters: GetBlockByHashRequest): Promise>; + getBlockByHashRaw(requestParameters: GetBlockByHashRequest, initOverrides?: RequestInit): Promise>; /** - * Get a specific block by hash - * Get block + * Retrieves block details of a specific block for a given chain height. You can use the hash from your latest block (\'get_block_list\' API) to get your block details. + * Get block by hash */ - getBlockByHash(requestParameters: GetBlockByHashRequest): Promise; + getBlockByHash(requestParameters: GetBlockByHashRequest, initOverrides?: RequestInit): Promise; /** - * Get all recently mined blocks + * Retrieves block details of a specific block at a given block height + * @summary Get block by height + * @param {number} height Height of the block + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof BlocksApiInterface + */ + getBlockByHeightRaw(requestParameters: GetBlockByHeightRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves block details of a specific block at a given block height + * Get block by height + */ + getBlockByHeight(requestParameters: GetBlockByHeightRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of recently mined blocks If you need to actively monitor new blocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * @summary Get recent blocks * @param {number} [limit] max number of blocks to fetch * @param {number} [offset] index of first block to fetch @@ -64,13 +124,13 @@ export interface BlocksApiInterface { * @throws {RequiredError} * @memberof BlocksApiInterface */ - getBlockListRaw(requestParameters: GetBlockListRequest): Promise>; + getBlockListRaw(requestParameters: GetBlockListRequest, initOverrides?: RequestInit): Promise>; /** - * Get all recently mined blocks + * Retrieves a list of recently mined blocks If you need to actively monitor new blocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get recent blocks */ - getBlockList(requestParameters: GetBlockListRequest): Promise; + getBlockList(requestParameters: GetBlockListRequest, initOverrides?: RequestInit): Promise; } @@ -80,15 +140,79 @@ export interface BlocksApiInterface { export class BlocksApi extends runtime.BaseAPI implements BlocksApiInterface { /** - * Get a specific block by hash - * Get block + * Retrieves block details of a specific block for a given burnchain block hash + * Get block by burnchain block hash */ - async getBlockByHashRaw(requestParameters: GetBlockByHashRequest): Promise> { + async getBlockByBurnBlockHashRaw(requestParameters: GetBlockByBurnBlockHashRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.burnBlockHash === null || requestParameters.burnBlockHash === undefined) { + throw new runtime.RequiredError('burnBlockHash','Required parameter requestParameters.burnBlockHash was null or undefined when calling getBlockByBurnBlockHash.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/block/by_burn_block_hash/{burn_block_hash}`.replace(`{${"burn_block_hash"}}`, encodeURIComponent(String(requestParameters.burnBlockHash))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BlockFromJSON(jsonValue)); + } + + /** + * Retrieves block details of a specific block for a given burnchain block hash + * Get block by burnchain block hash + */ + async getBlockByBurnBlockHash(requestParameters: GetBlockByBurnBlockHashRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBlockByBurnBlockHashRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves block details of a specific block for a given burn chain height + * Get block by burnchain height + */ + async getBlockByBurnBlockHeightRaw(requestParameters: GetBlockByBurnBlockHeightRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.burnBlockHeight === null || requestParameters.burnBlockHeight === undefined) { + throw new runtime.RequiredError('burnBlockHeight','Required parameter requestParameters.burnBlockHeight was null or undefined when calling getBlockByBurnBlockHeight.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/block/by_burn_block_height/{burn_block_height}`.replace(`{${"burn_block_height"}}`, encodeURIComponent(String(requestParameters.burnBlockHeight))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BlockFromJSON(jsonValue)); + } + + /** + * Retrieves block details of a specific block for a given burn chain height + * Get block by burnchain height + */ + async getBlockByBurnBlockHeight(requestParameters: GetBlockByBurnBlockHeightRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBlockByBurnBlockHeightRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves block details of a specific block for a given chain height. You can use the hash from your latest block (\'get_block_list\' API) to get your block details. + * Get block by hash + */ + async getBlockByHashRaw(requestParameters: GetBlockByHashRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.hash === null || requestParameters.hash === undefined) { throw new runtime.RequiredError('hash','Required parameter requestParameters.hash was null or undefined when calling getBlockByHash.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -97,26 +221,58 @@ export class BlocksApi extends runtime.BaseAPI implements BlocksApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BlockFromJSON(jsonValue)); + } + + /** + * Retrieves block details of a specific block for a given chain height. You can use the hash from your latest block (\'get_block_list\' API) to get your block details. + * Get block by hash + */ + async getBlockByHash(requestParameters: GetBlockByHashRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBlockByHashRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves block details of a specific block at a given block height + * Get block by height + */ + async getBlockByHeightRaw(requestParameters: GetBlockByHeightRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.height === null || requestParameters.height === undefined) { + throw new runtime.RequiredError('height','Required parameter requestParameters.height was null or undefined when calling getBlockByHeight.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/block/by_height/{height}`.replace(`{${"height"}}`, encodeURIComponent(String(requestParameters.height))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => BlockFromJSON(jsonValue)); } /** - * Get a specific block by hash - * Get block + * Retrieves block details of a specific block at a given block height + * Get block by height */ - async getBlockByHash(requestParameters: GetBlockByHashRequest): Promise { - const response = await this.getBlockByHashRaw(requestParameters); + async getBlockByHeight(requestParameters: GetBlockByHeightRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBlockByHeightRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get all recently mined blocks + * Retrieves a list of recently mined blocks If you need to actively monitor new blocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get recent blocks */ - async getBlockListRaw(requestParameters: GetBlockListRequest): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getBlockListRaw(requestParameters: GetBlockListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; if (requestParameters.limit !== undefined) { queryParameters['limit'] = requestParameters.limit; @@ -133,17 +289,17 @@ export class BlocksApi extends runtime.BaseAPI implements BlocksApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => BlockListResponseFromJSON(jsonValue)); } /** - * Get all recently mined blocks + * Retrieves a list of recently mined blocks If you need to actively monitor new blocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get recent blocks */ - async getBlockList(requestParameters: GetBlockListRequest): Promise { - const response = await this.getBlockListRaw(requestParameters); + async getBlockList(requestParameters: GetBlockListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBlockListRaw(requestParameters, initOverrides); return await response.value(); } diff --git a/client/src/generated/apis/BurnchainApi.ts b/client/src/generated/apis/BurnchainApi.ts deleted file mode 100644 index 3dfd4f987f..0000000000 --- a/client/src/generated/apis/BurnchainApi.ts +++ /dev/null @@ -1,214 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - BurnchainRewardListResponse, - BurnchainRewardListResponseFromJSON, - BurnchainRewardListResponseToJSON, - BurnchainRewardsTotal, - BurnchainRewardsTotalFromJSON, - BurnchainRewardsTotalToJSON, -} from '../models'; - -export interface GetBurnchainRewardListRequest { - limit?: number; - offset?: number; -} - -export interface GetBurnchainRewardListByAddressRequest { - address: string; - limit?: number; - offset?: number; -} - -export interface GetBurnchainRewardsTotalByAddressRequest { - address: string; -} - -/** - * BurnchainApi - interface - * - * @export - * @interface BurnchainApiInterface - */ -export interface BurnchainApiInterface { - /** - * Get a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info - * @summary Get recent burnchain reward recipients - * @param {number} [limit] max number of rewards to fetch - * @param {number} [offset] index of first rewards to fetch - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof BurnchainApiInterface - */ - getBurnchainRewardListRaw(requestParameters: GetBurnchainRewardListRequest): Promise>; - - /** - * Get a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info - * Get recent burnchain reward recipients - */ - getBurnchainRewardList(requestParameters: GetBurnchainRewardListRequest): Promise; - - /** - * Get a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info - * @summary Get recent burnchain reward for the given recipient - * @param {string} address Reward recipient address. Should either be in the native burnchain\'s format (e.g. B58 for Bitcoin), or if a STX principal address is provided it will be encoded as into the equivalent burnchain format - * @param {number} [limit] max number of rewards to fetch - * @param {number} [offset] index of first rewards to fetch - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof BurnchainApiInterface - */ - getBurnchainRewardListByAddressRaw(requestParameters: GetBurnchainRewardListByAddressRequest): Promise>; - - /** - * Get a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info - * Get recent burnchain reward for the given recipient - */ - getBurnchainRewardListByAddress(requestParameters: GetBurnchainRewardListByAddressRequest): Promise; - - /** - * Get the total burnchain (e.g. Bitcoin) rewards for the given recipient - * @summary Get total burnchain rewards for the given recipient - * @param {string} address Reward recipient address. Should either be in the native burnchain\'s format (e.g. B58 for Bitcoin), or if a STX principal address is provided it will be encoded as into the equivalent burnchain format - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof BurnchainApiInterface - */ - getBurnchainRewardsTotalByAddressRaw(requestParameters: GetBurnchainRewardsTotalByAddressRequest): Promise>; - - /** - * Get the total burnchain (e.g. Bitcoin) rewards for the given recipient - * Get total burnchain rewards for the given recipient - */ - getBurnchainRewardsTotalByAddress(requestParameters: GetBurnchainRewardsTotalByAddressRequest): Promise; - -} - -/** - * - */ -export class BurnchainApi extends runtime.BaseAPI implements BurnchainApiInterface { - - /** - * Get a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info - * Get recent burnchain reward recipients - */ - async getBurnchainRewardListRaw(requestParameters: GetBurnchainRewardListRequest): Promise> { - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.limit !== undefined) { - queryParameters['limit'] = requestParameters.limit; - } - - if (requestParameters.offset !== undefined) { - queryParameters['offset'] = requestParameters.offset; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - const response = await this.request({ - path: `/extended/v1/burnchain/rewards`, - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardListResponseFromJSON(jsonValue)); - } - - /** - * Get a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info - * Get recent burnchain reward recipients - */ - async getBurnchainRewardList(requestParameters: GetBurnchainRewardListRequest): Promise { - const response = await this.getBurnchainRewardListRaw(requestParameters); - return await response.value(); - } - - /** - * Get a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info - * Get recent burnchain reward for the given recipient - */ - async getBurnchainRewardListByAddressRaw(requestParameters: GetBurnchainRewardListByAddressRequest): Promise> { - if (requestParameters.address === null || requestParameters.address === undefined) { - throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling getBurnchainRewardListByAddress.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.limit !== undefined) { - queryParameters['limit'] = requestParameters.limit; - } - - if (requestParameters.offset !== undefined) { - queryParameters['offset'] = requestParameters.offset; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - const response = await this.request({ - path: `/extended/v1/burnchain/rewards/{address}`.replace(`{${"address"}}`, encodeURIComponent(String(requestParameters.address))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardListResponseFromJSON(jsonValue)); - } - - /** - * Get a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info - * Get recent burnchain reward for the given recipient - */ - async getBurnchainRewardListByAddress(requestParameters: GetBurnchainRewardListByAddressRequest): Promise { - const response = await this.getBurnchainRewardListByAddressRaw(requestParameters); - return await response.value(); - } - - /** - * Get the total burnchain (e.g. Bitcoin) rewards for the given recipient - * Get total burnchain rewards for the given recipient - */ - async getBurnchainRewardsTotalByAddressRaw(requestParameters: GetBurnchainRewardsTotalByAddressRequest): Promise> { - if (requestParameters.address === null || requestParameters.address === undefined) { - throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling getBurnchainRewardsTotalByAddress.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - const response = await this.request({ - path: `/extended/v1/burnchain/rewards/{address}/total`.replace(`{${"address"}}`, encodeURIComponent(String(requestParameters.address))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardsTotalFromJSON(jsonValue)); - } - - /** - * Get the total burnchain (e.g. Bitcoin) rewards for the given recipient - * Get total burnchain rewards for the given recipient - */ - async getBurnchainRewardsTotalByAddress(requestParameters: GetBurnchainRewardsTotalByAddressRequest): Promise { - const response = await this.getBurnchainRewardsTotalByAddressRaw(requestParameters); - return await response.value(); - } - -} diff --git a/client/src/generated/apis/FaucetsApi.ts b/client/src/generated/apis/FaucetsApi.ts index 4fe27b8ffb..2f7d512afa 100644 --- a/client/src/generated/apis/FaucetsApi.ts +++ b/client/src/generated/apis/FaucetsApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -15,6 +15,12 @@ import * as runtime from '../runtime'; import { + InlineObject, + InlineObjectFromJSON, + InlineObjectToJSON, + InlineResponse403, + InlineResponse403FromJSON, + InlineResponse403ToJSON, RunFaucetResponse, RunFaucetResponseFromJSON, RunFaucetResponseToJSON, @@ -22,6 +28,7 @@ import { export interface RunFaucetBtcRequest { address: string; + inlineObject?: InlineObject; } export interface RunFaucetStxRequest { @@ -37,37 +44,38 @@ export interface RunFaucetStxRequest { */ export interface FaucetsApiInterface { /** - * Get BTC tokens for the testnet - * @summary Get BTC tokens - * @param {string} address BTC address + * Add 1 BTC token to the specified testnet BTC address. The endpoint returns the transaction ID, which you can use to view the transaction in a testnet Bitcoin block explorer. The tokens are delivered once the transaction has been included in a block. **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * @summary Add testnet BTC tokens to address + * @param {string} address A valid testnet BTC address + * @param {InlineObject} [inlineObject] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof FaucetsApiInterface */ - runFaucetBtcRaw(requestParameters: RunFaucetBtcRequest): Promise>; + runFaucetBtcRaw(requestParameters: RunFaucetBtcRequest, initOverrides?: RequestInit): Promise>; /** - * Get BTC tokens for the testnet - * Get BTC tokens + * Add 1 BTC token to the specified testnet BTC address. The endpoint returns the transaction ID, which you can use to view the transaction in a testnet Bitcoin block explorer. The tokens are delivered once the transaction has been included in a block. **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * Add testnet BTC tokens to address */ - runFaucetBtc(requestParameters: RunFaucetBtcRequest): Promise; + runFaucetBtc(requestParameters: RunFaucetBtcRequest, initOverrides?: RequestInit): Promise; /** - * Get STX tokens for the testnet - * @summary Get STX tokens - * @param {string} address STX address - * @param {boolean} [stacking] Request the amount of STX needed for stacking + * Add 500 STX tokens to the specified testnet address. Testnet STX addresses begin with `ST`. If the `stacking` parameter is set to `true`, the faucet will add the required number of tokens for individual stacking to the specified testnet address. The endpoint returns the transaction ID, which you can use to view the transaction in the [Stacks Explorer](https://explorer.hiro.so/?chain=testnet). The tokens are delivered once the transaction has been included in an anchor block. A common reason for failed faucet transactions is that the faucet has run out of tokens. If you are experiencing failed faucet transactions to a testnet address, you can get help in [Discord](https://stacks.chat). **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * @summary Get STX testnet tokens + * @param {string} address A valid testnet STX address + * @param {boolean} [stacking] Request the amount of STX tokens needed for individual address stacking * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof FaucetsApiInterface */ - runFaucetStxRaw(requestParameters: RunFaucetStxRequest): Promise>; + runFaucetStxRaw(requestParameters: RunFaucetStxRequest, initOverrides?: RequestInit): Promise>; /** - * Get STX tokens for the testnet - * Get STX tokens + * Add 500 STX tokens to the specified testnet address. Testnet STX addresses begin with `ST`. If the `stacking` parameter is set to `true`, the faucet will add the required number of tokens for individual stacking to the specified testnet address. The endpoint returns the transaction ID, which you can use to view the transaction in the [Stacks Explorer](https://explorer.hiro.so/?chain=testnet). The tokens are delivered once the transaction has been included in an anchor block. A common reason for failed faucet transactions is that the faucet has run out of tokens. If you are experiencing failed faucet transactions to a testnet address, you can get help in [Discord](https://stacks.chat). **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * Get STX testnet tokens */ - runFaucetStx(requestParameters: RunFaucetStxRequest): Promise; + runFaucetStx(requestParameters: RunFaucetStxRequest, initOverrides?: RequestInit): Promise; } @@ -77,15 +85,15 @@ export interface FaucetsApiInterface { export class FaucetsApi extends runtime.BaseAPI implements FaucetsApiInterface { /** - * Get BTC tokens for the testnet - * Get BTC tokens + * Add 1 BTC token to the specified testnet BTC address. The endpoint returns the transaction ID, which you can use to view the transaction in a testnet Bitcoin block explorer. The tokens are delivered once the transaction has been included in a block. **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * Add testnet BTC tokens to address */ - async runFaucetBtcRaw(requestParameters: RunFaucetBtcRequest): Promise> { + async runFaucetBtcRaw(requestParameters: RunFaucetBtcRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.address === null || requestParameters.address === undefined) { throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling runFaucetBtc.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.address !== undefined) { queryParameters['address'] = requestParameters.address; @@ -93,35 +101,38 @@ export class FaucetsApi extends runtime.BaseAPI implements FaucetsApiInterface { const headerParameters: runtime.HTTPHeaders = {}; + headerParameters['Content-Type'] = 'application/json'; + const response = await this.request({ path: `/extended/v1/faucets/btc`, method: 'POST', headers: headerParameters, query: queryParameters, - }); + body: InlineObjectToJSON(requestParameters.inlineObject), + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RunFaucetResponseFromJSON(jsonValue)); } /** - * Get BTC tokens for the testnet - * Get BTC tokens + * Add 1 BTC token to the specified testnet BTC address. The endpoint returns the transaction ID, which you can use to view the transaction in a testnet Bitcoin block explorer. The tokens are delivered once the transaction has been included in a block. **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * Add testnet BTC tokens to address */ - async runFaucetBtc(requestParameters: RunFaucetBtcRequest): Promise { - const response = await this.runFaucetBtcRaw(requestParameters); + async runFaucetBtc(requestParameters: RunFaucetBtcRequest, initOverrides?: RequestInit): Promise { + const response = await this.runFaucetBtcRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get STX tokens for the testnet - * Get STX tokens + * Add 500 STX tokens to the specified testnet address. Testnet STX addresses begin with `ST`. If the `stacking` parameter is set to `true`, the faucet will add the required number of tokens for individual stacking to the specified testnet address. The endpoint returns the transaction ID, which you can use to view the transaction in the [Stacks Explorer](https://explorer.hiro.so/?chain=testnet). The tokens are delivered once the transaction has been included in an anchor block. A common reason for failed faucet transactions is that the faucet has run out of tokens. If you are experiencing failed faucet transactions to a testnet address, you can get help in [Discord](https://stacks.chat). **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * Get STX testnet tokens */ - async runFaucetStxRaw(requestParameters: RunFaucetStxRequest): Promise> { + async runFaucetStxRaw(requestParameters: RunFaucetStxRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.address === null || requestParameters.address === undefined) { throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling runFaucetStx.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.address !== undefined) { queryParameters['address'] = requestParameters.address; @@ -138,17 +149,17 @@ export class FaucetsApi extends runtime.BaseAPI implements FaucetsApiInterface { method: 'POST', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RunFaucetResponseFromJSON(jsonValue)); } /** - * Get STX tokens for the testnet - * Get STX tokens + * Add 500 STX tokens to the specified testnet address. Testnet STX addresses begin with `ST`. If the `stacking` parameter is set to `true`, the faucet will add the required number of tokens for individual stacking to the specified testnet address. The endpoint returns the transaction ID, which you can use to view the transaction in the [Stacks Explorer](https://explorer.hiro.so/?chain=testnet). The tokens are delivered once the transaction has been included in an anchor block. A common reason for failed faucet transactions is that the faucet has run out of tokens. If you are experiencing failed faucet transactions to a testnet address, you can get help in [Discord](https://stacks.chat). **Note:** This is a testnet only endpoint. This endpoint will not work on the mainnet. + * Get STX testnet tokens */ - async runFaucetStx(requestParameters: RunFaucetStxRequest): Promise { - const response = await this.runFaucetStxRaw(requestParameters); + async runFaucetStx(requestParameters: RunFaucetStxRequest, initOverrides?: RequestInit): Promise { + const response = await this.runFaucetStxRaw(requestParameters, initOverrides); return await response.value(); } diff --git a/client/src/generated/apis/FeesApi.ts b/client/src/generated/apis/FeesApi.ts index 6bbd22bec4..510755aee5 100644 --- a/client/src/generated/apis/FeesApi.ts +++ b/client/src/generated/apis/FeesApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,6 +14,28 @@ import * as runtime from '../runtime'; +import { + FeeRate, + FeeRateFromJSON, + FeeRateToJSON, + FeeRateRequest, + FeeRateRequestFromJSON, + FeeRateRequestToJSON, + TransactionFeeEstimateRequest, + TransactionFeeEstimateRequestFromJSON, + TransactionFeeEstimateRequestToJSON, + TransactionFeeEstimateResponse, + TransactionFeeEstimateResponseFromJSON, + TransactionFeeEstimateResponseToJSON, +} from '../models'; + +export interface FetchFeeRateRequest { + feeRateRequest: FeeRateRequest; +} + +export interface PostFeeTransactionRequest { + transactionFeeEstimateRequest?: TransactionFeeEstimateRequest; +} /** * FeesApi - interface @@ -23,19 +45,51 @@ import * as runtime from '../runtime'; */ export interface FeesApiInterface { /** - * Get an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer + * **NOTE:** This endpoint is deprecated in favor of [Get approximate fees for a given transaction](#operation/post_fee_transaction). Retrieves estimated fee rate. + * @summary Fetch fee rate + * @param {FeeRateRequest} feeRateRequest + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof FeesApiInterface + */ + fetchFeeRateRaw(requestParameters: FetchFeeRateRequest, initOverrides?: RequestInit): Promise>; + + /** + * **NOTE:** This endpoint is deprecated in favor of [Get approximate fees for a given transaction](#operation/post_fee_transaction). Retrieves estimated fee rate. + * Fetch fee rate + */ + fetchFeeRate(requestParameters: FetchFeeRateRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer * @summary Get estimated fee * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof FeesApiInterface */ - getFeeTransferRaw(): Promise>; + getFeeTransferRaw(initOverrides?: RequestInit): Promise>; /** - * Get an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer + * Retrieves an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer * Get estimated fee */ - getFeeTransfer(): Promise; + getFeeTransfer(initOverrides?: RequestInit): Promise; + + /** + * Get an estimated fee for the supplied transaction. This estimates the execution cost of the transaction, the current fee rate of the network, and returns estimates for fee amounts. * `transaction_payload` is a hex-encoded serialization of the TransactionPayload for the transaction. * `estimated_len` is an optional argument that provides the endpoint with an estimation of the final length (in bytes) of the transaction, including any post-conditions and signatures If the node cannot provide an estimate for the transaction (e.g., if the node has never seen a contract-call for the given contract and function) or if estimation is not configured on this node, a 400 response is returned. The 400 response will be a JSON error containing a `reason` field which can be one of the following: * `DatabaseError` - this Stacks node has had an internal database error while trying to estimate the costs of the supplied transaction. * `NoEstimateAvailable` - this Stacks node has not seen this kind of contract-call before, and it cannot provide an estimate yet. * `CostEstimationDisabled` - this Stacks node does not perform fee or cost estimation, and it cannot respond on this endpoint. The 200 response contains the following data: * `estimated_cost` - the estimated multi-dimensional cost of executing the Clarity VM on the provided transaction. * `estimated_cost_scalar` - a unitless integer that the Stacks node uses to compare how much of the block limit is consumed by different transactions. This value incorporates the estimated length of the transaction and the estimated execution cost of the transaction. The range of this integer may vary between different Stacks nodes. In order to compute an estimate of total fee amount for the transaction, this value is multiplied by the same Stacks node\'s estimated fee rate. * `cost_scalar_change_by_byte` - a float value that indicates how much the `estimated_cost_scalar` value would increase for every additional byte in the final transaction. * `estimations` - an array of estimated fee rates and total fees to pay in microSTX for the transaction. This array provides a range of estimates (default: 3) that may be used. Each element of the array contains the following fields: * `fee_rate` - the estimated value for the current fee rates in the network * `fee` - the estimated value for the total fee in microSTX that the given transaction should pay. These values are the result of computing: `fee_rate` x `estimated_cost_scalar`. If the estimated fees are less than the minimum relay fee `(1 ustx x estimated_len)`, then that minimum relay fee will be returned here instead. Note: If the final transaction\'s byte size is larger than supplied to `estimated_len`, then applications should increase this fee amount by: `fee_rate` x `cost_scalar_change_by_byte` x (`final_size` - `estimated_size`) + * @summary Get approximate fees for a given transaction + * @param {TransactionFeeEstimateRequest} [transactionFeeEstimateRequest] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof FeesApiInterface + */ + postFeeTransactionRaw(requestParameters: PostFeeTransactionRequest, initOverrides?: RequestInit): Promise>; + + /** + * Get an estimated fee for the supplied transaction. This estimates the execution cost of the transaction, the current fee rate of the network, and returns estimates for fee amounts. * `transaction_payload` is a hex-encoded serialization of the TransactionPayload for the transaction. * `estimated_len` is an optional argument that provides the endpoint with an estimation of the final length (in bytes) of the transaction, including any post-conditions and signatures If the node cannot provide an estimate for the transaction (e.g., if the node has never seen a contract-call for the given contract and function) or if estimation is not configured on this node, a 400 response is returned. The 400 response will be a JSON error containing a `reason` field which can be one of the following: * `DatabaseError` - this Stacks node has had an internal database error while trying to estimate the costs of the supplied transaction. * `NoEstimateAvailable` - this Stacks node has not seen this kind of contract-call before, and it cannot provide an estimate yet. * `CostEstimationDisabled` - this Stacks node does not perform fee or cost estimation, and it cannot respond on this endpoint. The 200 response contains the following data: * `estimated_cost` - the estimated multi-dimensional cost of executing the Clarity VM on the provided transaction. * `estimated_cost_scalar` - a unitless integer that the Stacks node uses to compare how much of the block limit is consumed by different transactions. This value incorporates the estimated length of the transaction and the estimated execution cost of the transaction. The range of this integer may vary between different Stacks nodes. In order to compute an estimate of total fee amount for the transaction, this value is multiplied by the same Stacks node\'s estimated fee rate. * `cost_scalar_change_by_byte` - a float value that indicates how much the `estimated_cost_scalar` value would increase for every additional byte in the final transaction. * `estimations` - an array of estimated fee rates and total fees to pay in microSTX for the transaction. This array provides a range of estimates (default: 3) that may be used. Each element of the array contains the following fields: * `fee_rate` - the estimated value for the current fee rates in the network * `fee` - the estimated value for the total fee in microSTX that the given transaction should pay. These values are the result of computing: `fee_rate` x `estimated_cost_scalar`. If the estimated fees are less than the minimum relay fee `(1 ustx x estimated_len)`, then that minimum relay fee will be returned here instead. Note: If the final transaction\'s byte size is larger than supplied to `estimated_len`, then applications should increase this fee amount by: `fee_rate` x `cost_scalar_change_by_byte` x (`final_size` - `estimated_size`) + * Get approximate fees for a given transaction + */ + postFeeTransaction(requestParameters: PostFeeTransactionRequest, initOverrides?: RequestInit): Promise; } @@ -45,11 +99,46 @@ export interface FeesApiInterface { export class FeesApi extends runtime.BaseAPI implements FeesApiInterface { /** - * Get an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer + * **NOTE:** This endpoint is deprecated in favor of [Get approximate fees for a given transaction](#operation/post_fee_transaction). Retrieves estimated fee rate. + * Fetch fee rate + */ + async fetchFeeRateRaw(requestParameters: FetchFeeRateRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.feeRateRequest === null || requestParameters.feeRateRequest === undefined) { + throw new runtime.RequiredError('feeRateRequest','Required parameter requestParameters.feeRateRequest was null or undefined when calling fetchFeeRate.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + const response = await this.request({ + path: `/extended/v1/fee_rate`, + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: FeeRateRequestToJSON(requestParameters.feeRateRequest), + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => FeeRateFromJSON(jsonValue)); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of [Get approximate fees for a given transaction](#operation/post_fee_transaction). Retrieves estimated fee rate. + * Fetch fee rate + */ + async fetchFeeRate(requestParameters: FetchFeeRateRequest, initOverrides?: RequestInit): Promise { + const response = await this.fetchFeeRateRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer * Get estimated fee */ - async getFeeTransferRaw(): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getFeeTransferRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -58,17 +147,48 @@ export class FeesApi extends runtime.BaseAPI implements FeesApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response); } /** - * Get an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer + * Retrieves an estimated fee rate for STX transfer transactions. This a a fee rate / byte, and is returned as a JSON integer * Get estimated fee */ - async getFeeTransfer(): Promise { - const response = await this.getFeeTransferRaw(); + async getFeeTransfer(initOverrides?: RequestInit): Promise { + const response = await this.getFeeTransferRaw(initOverrides); + return await response.value(); + } + + /** + * Get an estimated fee for the supplied transaction. This estimates the execution cost of the transaction, the current fee rate of the network, and returns estimates for fee amounts. * `transaction_payload` is a hex-encoded serialization of the TransactionPayload for the transaction. * `estimated_len` is an optional argument that provides the endpoint with an estimation of the final length (in bytes) of the transaction, including any post-conditions and signatures If the node cannot provide an estimate for the transaction (e.g., if the node has never seen a contract-call for the given contract and function) or if estimation is not configured on this node, a 400 response is returned. The 400 response will be a JSON error containing a `reason` field which can be one of the following: * `DatabaseError` - this Stacks node has had an internal database error while trying to estimate the costs of the supplied transaction. * `NoEstimateAvailable` - this Stacks node has not seen this kind of contract-call before, and it cannot provide an estimate yet. * `CostEstimationDisabled` - this Stacks node does not perform fee or cost estimation, and it cannot respond on this endpoint. The 200 response contains the following data: * `estimated_cost` - the estimated multi-dimensional cost of executing the Clarity VM on the provided transaction. * `estimated_cost_scalar` - a unitless integer that the Stacks node uses to compare how much of the block limit is consumed by different transactions. This value incorporates the estimated length of the transaction and the estimated execution cost of the transaction. The range of this integer may vary between different Stacks nodes. In order to compute an estimate of total fee amount for the transaction, this value is multiplied by the same Stacks node\'s estimated fee rate. * `cost_scalar_change_by_byte` - a float value that indicates how much the `estimated_cost_scalar` value would increase for every additional byte in the final transaction. * `estimations` - an array of estimated fee rates and total fees to pay in microSTX for the transaction. This array provides a range of estimates (default: 3) that may be used. Each element of the array contains the following fields: * `fee_rate` - the estimated value for the current fee rates in the network * `fee` - the estimated value for the total fee in microSTX that the given transaction should pay. These values are the result of computing: `fee_rate` x `estimated_cost_scalar`. If the estimated fees are less than the minimum relay fee `(1 ustx x estimated_len)`, then that minimum relay fee will be returned here instead. Note: If the final transaction\'s byte size is larger than supplied to `estimated_len`, then applications should increase this fee amount by: `fee_rate` x `cost_scalar_change_by_byte` x (`final_size` - `estimated_size`) + * Get approximate fees for a given transaction + */ + async postFeeTransactionRaw(requestParameters: PostFeeTransactionRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + const response = await this.request({ + path: `/v2/fees/transaction`, + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: TransactionFeeEstimateRequestToJSON(requestParameters.transactionFeeEstimateRequest), + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => TransactionFeeEstimateResponseFromJSON(jsonValue)); + } + + /** + * Get an estimated fee for the supplied transaction. This estimates the execution cost of the transaction, the current fee rate of the network, and returns estimates for fee amounts. * `transaction_payload` is a hex-encoded serialization of the TransactionPayload for the transaction. * `estimated_len` is an optional argument that provides the endpoint with an estimation of the final length (in bytes) of the transaction, including any post-conditions and signatures If the node cannot provide an estimate for the transaction (e.g., if the node has never seen a contract-call for the given contract and function) or if estimation is not configured on this node, a 400 response is returned. The 400 response will be a JSON error containing a `reason` field which can be one of the following: * `DatabaseError` - this Stacks node has had an internal database error while trying to estimate the costs of the supplied transaction. * `NoEstimateAvailable` - this Stacks node has not seen this kind of contract-call before, and it cannot provide an estimate yet. * `CostEstimationDisabled` - this Stacks node does not perform fee or cost estimation, and it cannot respond on this endpoint. The 200 response contains the following data: * `estimated_cost` - the estimated multi-dimensional cost of executing the Clarity VM on the provided transaction. * `estimated_cost_scalar` - a unitless integer that the Stacks node uses to compare how much of the block limit is consumed by different transactions. This value incorporates the estimated length of the transaction and the estimated execution cost of the transaction. The range of this integer may vary between different Stacks nodes. In order to compute an estimate of total fee amount for the transaction, this value is multiplied by the same Stacks node\'s estimated fee rate. * `cost_scalar_change_by_byte` - a float value that indicates how much the `estimated_cost_scalar` value would increase for every additional byte in the final transaction. * `estimations` - an array of estimated fee rates and total fees to pay in microSTX for the transaction. This array provides a range of estimates (default: 3) that may be used. Each element of the array contains the following fields: * `fee_rate` - the estimated value for the current fee rates in the network * `fee` - the estimated value for the total fee in microSTX that the given transaction should pay. These values are the result of computing: `fee_rate` x `estimated_cost_scalar`. If the estimated fees are less than the minimum relay fee `(1 ustx x estimated_len)`, then that minimum relay fee will be returned here instead. Note: If the final transaction\'s byte size is larger than supplied to `estimated_len`, then applications should increase this fee amount by: `fee_rate` x `cost_scalar_change_by_byte` x (`final_size` - `estimated_size`) + * Get approximate fees for a given transaction + */ + async postFeeTransaction(requestParameters: PostFeeTransactionRequest, initOverrides?: RequestInit): Promise { + const response = await this.postFeeTransactionRaw(requestParameters, initOverrides); return await response.value(); } diff --git a/client/src/generated/apis/FungibleTokensApi.ts b/client/src/generated/apis/FungibleTokensApi.ts new file mode 100644 index 0000000000..b55945fee0 --- /dev/null +++ b/client/src/generated/apis/FungibleTokensApi.ts @@ -0,0 +1,150 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + FungibleTokenMetadata, + FungibleTokenMetadataFromJSON, + FungibleTokenMetadataToJSON, + FungibleTokensMetadataList, + FungibleTokensMetadataListFromJSON, + FungibleTokensMetadataListToJSON, +} from '../models'; + +export interface GetContractFtMetadataRequest { + contractId: string; +} + +export interface GetFtMetadataListRequest { + limit?: number; + offset?: number; +} + +/** + * FungibleTokensApi - interface + * + * @export + * @interface FungibleTokensApiInterface + */ +export interface FungibleTokensApiInterface { + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves the metadata for fungible tokens for a given contract id + * @summary Fungible tokens metadata for contract id + * @param {string} contractId token\'s contract id + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof FungibleTokensApiInterface + */ + getContractFtMetadataRaw(requestParameters: GetContractFtMetadataRequest, initOverrides?: RequestInit): Promise>; + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves the metadata for fungible tokens for a given contract id + * Fungible tokens metadata for contract id + */ + getContractFtMetadata(requestParameters: GetContractFtMetadataRequest, initOverrides?: RequestInit): Promise; + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves list of fungible tokens with their metadata. More information on Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#fungible-tokens). + * @summary Fungible tokens metadata list + * @param {number} [limit] max number of tokens to fetch. + * @param {number} [offset] index of first tokens to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof FungibleTokensApiInterface + */ + getFtMetadataListRaw(requestParameters: GetFtMetadataListRequest, initOverrides?: RequestInit): Promise>; + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves list of fungible tokens with their metadata. More information on Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#fungible-tokens). + * Fungible tokens metadata list + */ + getFtMetadataList(requestParameters: GetFtMetadataListRequest, initOverrides?: RequestInit): Promise; + +} + +/** + * + */ +export class FungibleTokensApi extends runtime.BaseAPI implements FungibleTokensApiInterface { + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves the metadata for fungible tokens for a given contract id + * Fungible tokens metadata for contract id + */ + async getContractFtMetadataRaw(requestParameters: GetContractFtMetadataRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.contractId === null || requestParameters.contractId === undefined) { + throw new runtime.RequiredError('contractId','Required parameter requestParameters.contractId was null or undefined when calling getContractFtMetadata.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tokens/{contractId}/ft/metadata`.replace(`{${"contractId"}}`, encodeURIComponent(String(requestParameters.contractId))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => FungibleTokenMetadataFromJSON(jsonValue)); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves the metadata for fungible tokens for a given contract id + * Fungible tokens metadata for contract id + */ + async getContractFtMetadata(requestParameters: GetContractFtMetadataRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractFtMetadataRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves list of fungible tokens with their metadata. More information on Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#fungible-tokens). + * Fungible tokens metadata list + */ + async getFtMetadataListRaw(requestParameters: GetFtMetadataListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tokens/ft/metadata`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => FungibleTokensMetadataListFromJSON(jsonValue)); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves list of fungible tokens with their metadata. More information on Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#fungible-tokens). + * Fungible tokens metadata list + */ + async getFtMetadataList(requestParameters: GetFtMetadataListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getFtMetadataListRaw(requestParameters, initOverrides); + return await response.value(); + } + +} diff --git a/client/src/generated/apis/InfoApi.ts b/client/src/generated/apis/InfoApi.ts index 26f4b5b1ab..b93cdce1f1 100644 --- a/client/src/generated/apis/InfoApi.ts +++ b/client/src/generated/apis/InfoApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -21,18 +21,35 @@ import { CoreNodePoxResponse, CoreNodePoxResponseFromJSON, CoreNodePoxResponseToJSON, + GetStxSupplyLegacyFormatResponse, + GetStxSupplyLegacyFormatResponseFromJSON, + GetStxSupplyLegacyFormatResponseToJSON, + GetStxSupplyResponse, + GetStxSupplyResponseFromJSON, + GetStxSupplyResponseToJSON, NetworkBlockTimeResponse, NetworkBlockTimeResponseFromJSON, NetworkBlockTimeResponseToJSON, NetworkBlockTimesResponse, NetworkBlockTimesResponseFromJSON, NetworkBlockTimesResponseToJSON, + ServerStatusResponse, + ServerStatusResponseFromJSON, + ServerStatusResponseToJSON, } from '../models'; export interface GetNetworkBlockTimeByNetworkRequest { network: GetNetworkBlockTimeByNetworkNetworkEnum; } +export interface GetStxSupplyRequest { + height?: number; +} + +export interface GetTotalStxSupplyLegacyFormatRequest { + height?: number; +} + /** * InfoApi - interface * @@ -41,78 +58,142 @@ export interface GetNetworkBlockTimeByNetworkRequest { */ export interface InfoApiInterface { /** - * Get Core API information + * Retrieves information about the Core API including the server version * @summary Get Core API info * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof InfoApiInterface */ - getCoreApiInfoRaw(): Promise>; + getCoreApiInfoRaw(initOverrides?: RequestInit): Promise>; /** - * Get Core API information + * Retrieves information about the Core API including the server version * Get Core API info */ - getCoreApiInfo(): Promise; + getCoreApiInfo(initOverrides?: RequestInit): Promise; /** - * + * Retrieves the target block time for a given network. The network can be mainnet or testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * @summary Get a given network\'s target block time - * @param {'testnet' | 'mainnet'} network Which network to retrieve the target block time of + * @param {'testnet' | 'mainnet'} network the target block time for a given network (testnet, mainnet). * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof InfoApiInterface */ - getNetworkBlockTimeByNetworkRaw(requestParameters: GetNetworkBlockTimeByNetworkRequest): Promise>; + getNetworkBlockTimeByNetworkRaw(requestParameters: GetNetworkBlockTimeByNetworkRequest, initOverrides?: RequestInit): Promise>; /** + * Retrieves the target block time for a given network. The network can be mainnet or testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * Get a given network\'s target block time */ - getNetworkBlockTimeByNetwork(requestParameters: GetNetworkBlockTimeByNetworkRequest): Promise; + getNetworkBlockTimeByNetwork(requestParameters: GetNetworkBlockTimeByNetworkRequest, initOverrides?: RequestInit): Promise; /** - * + * Retrieves the target block times for mainnet and testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * @summary Get the network target block time * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof InfoApiInterface */ - getNetworkBlockTimesRaw(): Promise>; + getNetworkBlockTimesRaw(initOverrides?: RequestInit): Promise>; /** + * Retrieves the target block times for mainnet and testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * Get the network target block time */ - getNetworkBlockTimes(): Promise; + getNetworkBlockTimes(initOverrides?: RequestInit): Promise; /** - * Get Proof of Transfer (PoX) information. Can be used for Stacking. - * @summary Get PoX details + * Retrieves Proof-of-Transfer (PoX) information. Can be used for Stacking. + * @summary Get Proof-of-Transfer details * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof InfoApiInterface */ - getPoxInfoRaw(): Promise>; + getPoxInfoRaw(initOverrides?: RequestInit): Promise>; /** - * Get Proof of Transfer (PoX) information. Can be used for Stacking. - * Get PoX details + * Retrieves Proof-of-Transfer (PoX) information. Can be used for Stacking. + * Get Proof-of-Transfer details */ - getPoxInfo(): Promise; + getPoxInfo(initOverrides?: RequestInit): Promise; /** - * Get Blockchain API status - * @summary Get Blockchain API status + * Retrieves the running status of the Stacks Blockchain API, including the server version and current chain tip information. + * @summary API status * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof InfoApiInterface */ - getStatusRaw(): Promise>; + getStatusRaw(initOverrides?: RequestInit): Promise>; /** - * Get Blockchain API status - * Get Blockchain API status + * Retrieves the running status of the Stacks Blockchain API, including the server version and current chain tip information. + * API status */ - getStatus(): Promise; + getStatus(initOverrides?: RequestInit): Promise; + + /** + * Retrieves the total and unlocked STX supply. More information on Stacking can be found [here] (https://docs.stacks.co/understand-stacks/stacking). **Note:** This uses the estimated future total supply for the year 2050. + * @summary Get total and unlocked STX supply + * @param {number} [height] Supply details are queried from specified block height. If the block height is not specified, the latest block height is taken as default value. Note that the `block height` is referred to the stacks blockchain. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof InfoApiInterface + */ + getStxSupplyRaw(requestParameters: GetStxSupplyRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the total and unlocked STX supply. More information on Stacking can be found [here] (https://docs.stacks.co/understand-stacks/stacking). **Note:** This uses the estimated future total supply for the year 2050. + * Get total and unlocked STX supply + */ + getStxSupply(requestParameters: GetStxSupplyRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves the STX tokens currently in circulation that have been unlocked as plain text. + * @summary Get circulating STX supply in plain text format + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof InfoApiInterface + */ + getStxSupplyCirculatingPlainRaw(initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the STX tokens currently in circulation that have been unlocked as plain text. + * Get circulating STX supply in plain text format + */ + getStxSupplyCirculatingPlain(initOverrides?: RequestInit): Promise; + + /** + * Retrieves the total supply for STX tokens as plain text. **Note:** this uses the estimated future total supply for the year 2050. + * @summary Get total STX supply in plain text format + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof InfoApiInterface + */ + getStxSupplyTotalSupplyPlainRaw(initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the total supply for STX tokens as plain text. **Note:** this uses the estimated future total supply for the year 2050. + * Get total STX supply in plain text format + */ + getStxSupplyTotalSupplyPlain(initOverrides?: RequestInit): Promise; + + /** + * Retrieves total supply of STX tokens including those currently in circulation that have been unlocked. **Note:** this uses the estimated future total supply for the year 2050. + * @summary Get total and unlocked STX supply (results formatted the same as the legacy 1.0 API) + * @param {number} [height] Supply details are queried from specified block height. If the block height is not specified, the latest block height is taken as default value. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof InfoApiInterface + */ + getTotalStxSupplyLegacyFormatRaw(requestParameters: GetTotalStxSupplyLegacyFormatRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves total supply of STX tokens including those currently in circulation that have been unlocked. **Note:** this uses the estimated future total supply for the year 2050. + * Get total and unlocked STX supply (results formatted the same as the legacy 1.0 API) + */ + getTotalStxSupplyLegacyFormat(requestParameters: GetTotalStxSupplyLegacyFormatRequest, initOverrides?: RequestInit): Promise; } @@ -122,11 +203,11 @@ export interface InfoApiInterface { export class InfoApi extends runtime.BaseAPI implements InfoApiInterface { /** - * Get Core API information + * Retrieves information about the Core API including the server version * Get Core API info */ - async getCoreApiInfoRaw(): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getCoreApiInfoRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -135,29 +216,30 @@ export class InfoApi extends runtime.BaseAPI implements InfoApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => CoreNodeInfoResponseFromJSON(jsonValue)); } /** - * Get Core API information + * Retrieves information about the Core API including the server version * Get Core API info */ - async getCoreApiInfo(): Promise { - const response = await this.getCoreApiInfoRaw(); + async getCoreApiInfo(initOverrides?: RequestInit): Promise { + const response = await this.getCoreApiInfoRaw(initOverrides); return await response.value(); } /** + * Retrieves the target block time for a given network. The network can be mainnet or testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * Get a given network\'s target block time */ - async getNetworkBlockTimeByNetworkRaw(requestParameters: GetNetworkBlockTimeByNetworkRequest): Promise> { + async getNetworkBlockTimeByNetworkRaw(requestParameters: GetNetworkBlockTimeByNetworkRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.network === null || requestParameters.network === undefined) { throw new runtime.RequiredError('network','Required parameter requestParameters.network was null or undefined when calling getNetworkBlockTimeByNetwork.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -166,24 +248,26 @@ export class InfoApi extends runtime.BaseAPI implements InfoApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => NetworkBlockTimeResponseFromJSON(jsonValue)); } /** + * Retrieves the target block time for a given network. The network can be mainnet or testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * Get a given network\'s target block time */ - async getNetworkBlockTimeByNetwork(requestParameters: GetNetworkBlockTimeByNetworkRequest): Promise { - const response = await this.getNetworkBlockTimeByNetworkRaw(requestParameters); + async getNetworkBlockTimeByNetwork(requestParameters: GetNetworkBlockTimeByNetworkRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNetworkBlockTimeByNetworkRaw(requestParameters, initOverrides); return await response.value(); } /** + * Retrieves the target block times for mainnet and testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * Get the network target block time */ - async getNetworkBlockTimesRaw(): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getNetworkBlockTimesRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -192,25 +276,26 @@ export class InfoApi extends runtime.BaseAPI implements InfoApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => NetworkBlockTimesResponseFromJSON(jsonValue)); } /** + * Retrieves the target block times for mainnet and testnet. The block time is hardcoded and will change throughout the implementation phases of the testnet. * Get the network target block time */ - async getNetworkBlockTimes(): Promise { - const response = await this.getNetworkBlockTimesRaw(); + async getNetworkBlockTimes(initOverrides?: RequestInit): Promise { + const response = await this.getNetworkBlockTimesRaw(initOverrides); return await response.value(); } /** - * Get Proof of Transfer (PoX) information. Can be used for Stacking. - * Get PoX details + * Retrieves Proof-of-Transfer (PoX) information. Can be used for Stacking. + * Get Proof-of-Transfer details */ - async getPoxInfoRaw(): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getPoxInfoRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -219,26 +304,26 @@ export class InfoApi extends runtime.BaseAPI implements InfoApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => CoreNodePoxResponseFromJSON(jsonValue)); } /** - * Get Proof of Transfer (PoX) information. Can be used for Stacking. - * Get PoX details + * Retrieves Proof-of-Transfer (PoX) information. Can be used for Stacking. + * Get Proof-of-Transfer details */ - async getPoxInfo(): Promise { - const response = await this.getPoxInfoRaw(); + async getPoxInfo(initOverrides?: RequestInit): Promise { + const response = await this.getPoxInfoRaw(initOverrides); return await response.value(); } /** - * Get Blockchain API status - * Get Blockchain API status + * Retrieves the running status of the Stacks Blockchain API, including the server version and current chain tip information. + * API status */ - async getStatusRaw(): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getStatusRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -247,17 +332,138 @@ export class InfoApi extends runtime.BaseAPI implements InfoApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); - return new runtime.VoidApiResponse(response); + return new runtime.JSONApiResponse(response, (jsonValue) => ServerStatusResponseFromJSON(jsonValue)); + } + + /** + * Retrieves the running status of the Stacks Blockchain API, including the server version and current chain tip information. + * API status + */ + async getStatus(initOverrides?: RequestInit): Promise { + const response = await this.getStatusRaw(initOverrides); + return await response.value(); } /** - * Get Blockchain API status - * Get Blockchain API status + * Retrieves the total and unlocked STX supply. More information on Stacking can be found [here] (https://docs.stacks.co/understand-stacks/stacking). **Note:** This uses the estimated future total supply for the year 2050. + * Get total and unlocked STX supply */ - async getStatus(): Promise { - await this.getStatusRaw(); + async getStxSupplyRaw(requestParameters: GetStxSupplyRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.height !== undefined) { + queryParameters['height'] = requestParameters.height; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/stx_supply`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => GetStxSupplyResponseFromJSON(jsonValue)); + } + + /** + * Retrieves the total and unlocked STX supply. More information on Stacking can be found [here] (https://docs.stacks.co/understand-stacks/stacking). **Note:** This uses the estimated future total supply for the year 2050. + * Get total and unlocked STX supply + */ + async getStxSupply(requestParameters: GetStxSupplyRequest, initOverrides?: RequestInit): Promise { + const response = await this.getStxSupplyRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves the STX tokens currently in circulation that have been unlocked as plain text. + * Get circulating STX supply in plain text format + */ + async getStxSupplyCirculatingPlainRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/stx_supply/circulating/plain`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.TextApiResponse(response) as any; + } + + /** + * Retrieves the STX tokens currently in circulation that have been unlocked as plain text. + * Get circulating STX supply in plain text format + */ + async getStxSupplyCirculatingPlain(initOverrides?: RequestInit): Promise { + const response = await this.getStxSupplyCirculatingPlainRaw(initOverrides); + return await response.value(); + } + + /** + * Retrieves the total supply for STX tokens as plain text. **Note:** this uses the estimated future total supply for the year 2050. + * Get total STX supply in plain text format + */ + async getStxSupplyTotalSupplyPlainRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/stx_supply/total/plain`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.TextApiResponse(response) as any; + } + + /** + * Retrieves the total supply for STX tokens as plain text. **Note:** this uses the estimated future total supply for the year 2050. + * Get total STX supply in plain text format + */ + async getStxSupplyTotalSupplyPlain(initOverrides?: RequestInit): Promise { + const response = await this.getStxSupplyTotalSupplyPlainRaw(initOverrides); + return await response.value(); + } + + /** + * Retrieves total supply of STX tokens including those currently in circulation that have been unlocked. **Note:** this uses the estimated future total supply for the year 2050. + * Get total and unlocked STX supply (results formatted the same as the legacy 1.0 API) + */ + async getTotalStxSupplyLegacyFormatRaw(requestParameters: GetTotalStxSupplyLegacyFormatRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.height !== undefined) { + queryParameters['height'] = requestParameters.height; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/stx_supply/legacy_format`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => GetStxSupplyLegacyFormatResponseFromJSON(jsonValue)); + } + + /** + * Retrieves total supply of STX tokens including those currently in circulation that have been unlocked. **Note:** this uses the estimated future total supply for the year 2050. + * Get total and unlocked STX supply (results formatted the same as the legacy 1.0 API) + */ + async getTotalStxSupplyLegacyFormat(requestParameters: GetTotalStxSupplyLegacyFormatRequest, initOverrides?: RequestInit): Promise { + const response = await this.getTotalStxSupplyLegacyFormatRaw(requestParameters, initOverrides); + return await response.value(); } } diff --git a/client/src/generated/apis/MempoolApi.ts b/client/src/generated/apis/MempoolApi.ts new file mode 100644 index 0000000000..94c7a8e117 --- /dev/null +++ b/client/src/generated/apis/MempoolApi.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + MempoolFeePriorities, + MempoolFeePrioritiesFromJSON, + MempoolFeePrioritiesToJSON, +} from '../models'; + +/** + * MempoolApi - interface + * + * @export + * @interface MempoolApiInterface + */ +export interface MempoolApiInterface { + /** + * Returns estimated fee priorities (in micro-STX) for all transactions that are currently in the mempool. Also returns priorities separated by transaction type. + * @summary Get mempool transaction fee priorities + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof MempoolApiInterface + */ + getMempoolFeePrioritiesRaw(initOverrides?: RequestInit): Promise>; + + /** + * Returns estimated fee priorities (in micro-STX) for all transactions that are currently in the mempool. Also returns priorities separated by transaction type. + * Get mempool transaction fee priorities + */ + getMempoolFeePriorities(initOverrides?: RequestInit): Promise; + +} + +/** + * + */ +export class MempoolApi extends runtime.BaseAPI implements MempoolApiInterface { + + /** + * Returns estimated fee priorities (in micro-STX) for all transactions that are currently in the mempool. Also returns priorities separated by transaction type. + * Get mempool transaction fee priorities + */ + async getMempoolFeePrioritiesRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v2/mempool/fees`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => MempoolFeePrioritiesFromJSON(jsonValue)); + } + + /** + * Returns estimated fee priorities (in micro-STX) for all transactions that are currently in the mempool. Also returns priorities separated by transaction type. + * Get mempool transaction fee priorities + */ + async getMempoolFeePriorities(initOverrides?: RequestInit): Promise { + const response = await this.getMempoolFeePrioritiesRaw(initOverrides); + return await response.value(); + } + +} diff --git a/client/src/generated/apis/MicroblocksApi.ts b/client/src/generated/apis/MicroblocksApi.ts new file mode 100644 index 0000000000..3ce87be708 --- /dev/null +++ b/client/src/generated/apis/MicroblocksApi.ts @@ -0,0 +1,196 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + Microblock, + MicroblockFromJSON, + MicroblockToJSON, + MicroblockListResponse, + MicroblockListResponseFromJSON, + MicroblockListResponseToJSON, + UnanchoredTransactionListResponse, + UnanchoredTransactionListResponseFromJSON, + UnanchoredTransactionListResponseToJSON, +} from '../models'; + +export interface GetMicroblockByHashRequest { + hash: string; +} + +export interface GetMicroblockListRequest { + limit?: number; + offset?: number; +} + +/** + * MicroblocksApi - interface + * + * @export + * @interface MicroblocksApiInterface + */ +export interface MicroblocksApiInterface { + /** + * Retrieves a specific microblock by `hash` + * @summary Get microblock + * @param {string} hash Hash of the microblock + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof MicroblocksApiInterface + */ + getMicroblockByHashRaw(requestParameters: GetMicroblockByHashRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a specific microblock by `hash` + * Get microblock + */ + getMicroblockByHash(requestParameters: GetMicroblockByHashRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of microblocks. If you need to actively monitor new microblocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. + * @summary Get recent microblocks + * @param {number} [limit] Max number of microblocks to fetch + * @param {number} [offset] Index of the first microblock to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof MicroblocksApiInterface + */ + getMicroblockListRaw(requestParameters: GetMicroblockListRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of microblocks. If you need to actively monitor new microblocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. + * Get recent microblocks + */ + getMicroblockList(requestParameters: GetMicroblockListRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves transactions that have been streamed in microblocks but not yet accepted or rejected in an anchor block + * @summary Get the list of current transactions that belong to unanchored microblocks + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof MicroblocksApiInterface + */ + getUnanchoredTxsRaw(initOverrides?: RequestInit): Promise>; + + /** + * Retrieves transactions that have been streamed in microblocks but not yet accepted or rejected in an anchor block + * Get the list of current transactions that belong to unanchored microblocks + */ + getUnanchoredTxs(initOverrides?: RequestInit): Promise; + +} + +/** + * + */ +export class MicroblocksApi extends runtime.BaseAPI implements MicroblocksApiInterface { + + /** + * Retrieves a specific microblock by `hash` + * Get microblock + */ + async getMicroblockByHashRaw(requestParameters: GetMicroblockByHashRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.hash === null || requestParameters.hash === undefined) { + throw new runtime.RequiredError('hash','Required parameter requestParameters.hash was null or undefined when calling getMicroblockByHash.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/microblock/{hash}`.replace(`{${"hash"}}`, encodeURIComponent(String(requestParameters.hash))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => MicroblockFromJSON(jsonValue)); + } + + /** + * Retrieves a specific microblock by `hash` + * Get microblock + */ + async getMicroblockByHash(requestParameters: GetMicroblockByHashRequest, initOverrides?: RequestInit): Promise { + const response = await this.getMicroblockByHashRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of microblocks. If you need to actively monitor new microblocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. + * Get recent microblocks + */ + async getMicroblockListRaw(requestParameters: GetMicroblockListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/microblock`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => MicroblockListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of microblocks. If you need to actively monitor new microblocks, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. + * Get recent microblocks + */ + async getMicroblockList(requestParameters: GetMicroblockListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getMicroblockListRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves transactions that have been streamed in microblocks but not yet accepted or rejected in an anchor block + * Get the list of current transactions that belong to unanchored microblocks + */ + async getUnanchoredTxsRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/microblock/unanchored/txs`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => UnanchoredTransactionListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves transactions that have been streamed in microblocks but not yet accepted or rejected in an anchor block + * Get the list of current transactions that belong to unanchored microblocks + */ + async getUnanchoredTxs(initOverrides?: RequestInit): Promise { + const response = await this.getUnanchoredTxsRaw(initOverrides); + return await response.value(); + } + +} diff --git a/client/src/generated/apis/NamesApi.ts b/client/src/generated/apis/NamesApi.ts new file mode 100644 index 0000000000..d605968e62 --- /dev/null +++ b/client/src/generated/apis/NamesApi.ts @@ -0,0 +1,581 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + BnsError, + BnsErrorFromJSON, + BnsErrorToJSON, + BnsGetAllNamespacesResponse, + BnsGetAllNamespacesResponseFromJSON, + BnsGetAllNamespacesResponseToJSON, + BnsGetNameInfoResponse, + BnsGetNameInfoResponseFromJSON, + BnsGetNameInfoResponseToJSON, + BnsGetNamePriceResponse, + BnsGetNamePriceResponseFromJSON, + BnsGetNamePriceResponseToJSON, + BnsGetNamespacePriceResponse, + BnsGetNamespacePriceResponseFromJSON, + BnsGetNamespacePriceResponseToJSON, + BnsNamesOwnByAddressResponse, + BnsNamesOwnByAddressResponseFromJSON, + BnsNamesOwnByAddressResponseToJSON, +} from '../models'; + +export interface FetchSubdomainsListForNameRequest { + name: string; +} + +export interface FetchZoneFileRequest { + name: string; +} + +export interface GetAllNamesRequest { + page?: number; +} + +export interface GetHistoricalZoneFileRequest { + name: string; + zoneFileHash: string; +} + +export interface GetNameInfoRequest { + name: string; +} + +export interface GetNamePriceRequest { + name: string; +} + +export interface GetNamesOwnedByAddressRequest { + blockchain: string; + address: string; +} + +export interface GetNamespaceNamesRequest { + tld: string; + page?: number; +} + +export interface GetNamespacePriceRequest { + tld: string; +} + +/** + * NamesApi - interface + * + * @export + * @interface NamesApiInterface + */ +export interface NamesApiInterface { + /** + * Retrieves the list of subdomains for a specific name + * @summary Get Name Subdomains + * @param {string} name fully-qualified name + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + fetchSubdomainsListForNameRaw(requestParameters: FetchSubdomainsListForNameRequest, initOverrides?: RequestInit): Promise>>; + + /** + * Retrieves the list of subdomains for a specific name + * Get Name Subdomains + */ + fetchSubdomainsListForName(requestParameters: FetchSubdomainsListForNameRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a user’s raw zone file. This only works for RFC-compliant zone files. This method returns an error for names that have non-standard zone files. + * @summary Get Zone File + * @param {string} name fully-qualified name + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + fetchZoneFileRaw(requestParameters: FetchZoneFileRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a user’s raw zone file. This only works for RFC-compliant zone files. This method returns an error for names that have non-standard zone files. + * Get Zone File + */ + fetchZoneFile(requestParameters: FetchZoneFileRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of all names known to the node. + * @summary Get All Names + * @param {number} [page] names are defaulted to page 1 with 100 results. You can query specific page results by using the \'page\' query parameter. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getAllNamesRaw(requestParameters: GetAllNamesRequest, initOverrides?: RequestInit): Promise>>; + + /** + * Retrieves a list of all names known to the node. + * Get All Names + */ + getAllNames(requestParameters: GetAllNamesRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of all namespaces known to the node. + * @summary Get All Namespaces + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getAllNamespacesRaw(initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of all namespaces known to the node. + * Get All Namespaces + */ + getAllNamespaces(initOverrides?: RequestInit): Promise; + + /** + * Retrieves the historical zonefile specified by the username and zone hash. + * @summary Get Historical Zone File + * @param {string} name fully-qualified name + * @param {string} zoneFileHash zone file hash + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getHistoricalZoneFileRaw(requestParameters: GetHistoricalZoneFileRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the historical zonefile specified by the username and zone hash. + * Get Historical Zone File + */ + getHistoricalZoneFile(requestParameters: GetHistoricalZoneFileRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves details of a given name including the `address`, `status` and last transaction id - `last_txid`. + * @summary Get Name Details + * @param {string} name fully-qualified name + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getNameInfoRaw(requestParameters: GetNameInfoRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves details of a given name including the `address`, `status` and last transaction id - `last_txid`. + * Get Name Details + */ + getNameInfo(requestParameters: GetNameInfoRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves the price of a name. The `amount` given will be in the smallest possible units of the currency. + * @summary Get Name Price + * @param {string} name the name to query price information for + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getNamePriceRaw(requestParameters: GetNamePriceRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the price of a name. The `amount` given will be in the smallest possible units of the currency. + * Get Name Price + */ + getNamePrice(requestParameters: GetNamePriceRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of names owned by the address provided. + * @summary Get Names Owned by Address + * @param {string} blockchain the layer-1 blockchain for the address + * @param {string} address the address to lookup + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getNamesOwnedByAddressRaw(requestParameters: GetNamesOwnedByAddressRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of names owned by the address provided. + * Get Names Owned by Address + */ + getNamesOwnedByAddress(requestParameters: GetNamesOwnedByAddressRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of names within a given namespace. + * @summary Get Namespace Names + * @param {string} tld the namespace to fetch names from. + * @param {number} [page] namespace values are defaulted to page 1 with 100 results. You can query specific page results by using the \'page\' query parameter. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getNamespaceNamesRaw(requestParameters: GetNamespaceNamesRequest, initOverrides?: RequestInit): Promise>>; + + /** + * Retrieves a list of names within a given namespace. + * Get Namespace Names + */ + getNamespaceNames(requestParameters: GetNamespaceNamesRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the price of a namespace. The `amount` given will be in the smallest possible units of the currency. + * @summary Get Namespace Price + * @param {string} tld the namespace to fetch price for + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NamesApiInterface + */ + getNamespacePriceRaw(requestParameters: GetNamespacePriceRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the price of a namespace. The `amount` given will be in the smallest possible units of the currency. + * Get Namespace Price + */ + getNamespacePrice(requestParameters: GetNamespacePriceRequest, initOverrides?: RequestInit): Promise; + +} + +/** + * + */ +export class NamesApi extends runtime.BaseAPI implements NamesApiInterface { + + /** + * Retrieves the list of subdomains for a specific name + * Get Name Subdomains + */ + async fetchSubdomainsListForNameRaw(requestParameters: FetchSubdomainsListForNameRequest, initOverrides?: RequestInit): Promise>> { + if (requestParameters.name === null || requestParameters.name === undefined) { + throw new runtime.RequiredError('name','Required parameter requestParameters.name was null or undefined when calling fetchSubdomainsListForName.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/names/{name}/subdomains`.replace(`{${"name"}}`, encodeURIComponent(String(requestParameters.name))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response); + } + + /** + * Retrieves the list of subdomains for a specific name + * Get Name Subdomains + */ + async fetchSubdomainsListForName(requestParameters: FetchSubdomainsListForNameRequest, initOverrides?: RequestInit): Promise> { + const response = await this.fetchSubdomainsListForNameRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a user’s raw zone file. This only works for RFC-compliant zone files. This method returns an error for names that have non-standard zone files. + * Get Zone File + */ + async fetchZoneFileRaw(requestParameters: FetchZoneFileRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.name === null || requestParameters.name === undefined) { + throw new runtime.RequiredError('name','Required parameter requestParameters.name was null or undefined when calling fetchZoneFile.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/names/{name}/zonefile`.replace(`{${"name"}}`, encodeURIComponent(String(requestParameters.name))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response); + } + + /** + * Retrieves a user’s raw zone file. This only works for RFC-compliant zone files. This method returns an error for names that have non-standard zone files. + * Get Zone File + */ + async fetchZoneFile(requestParameters: FetchZoneFileRequest, initOverrides?: RequestInit): Promise { + const response = await this.fetchZoneFileRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of all names known to the node. + * Get All Names + */ + async getAllNamesRaw(requestParameters: GetAllNamesRequest, initOverrides?: RequestInit): Promise>> { + const queryParameters: any = {}; + + if (requestParameters.page !== undefined) { + queryParameters['page'] = requestParameters.page; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/names`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response); + } + + /** + * Retrieves a list of all names known to the node. + * Get All Names + */ + async getAllNames(requestParameters: GetAllNamesRequest, initOverrides?: RequestInit): Promise> { + const response = await this.getAllNamesRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of all namespaces known to the node. + * Get All Namespaces + */ + async getAllNamespacesRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/namespaces`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BnsGetAllNamespacesResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of all namespaces known to the node. + * Get All Namespaces + */ + async getAllNamespaces(initOverrides?: RequestInit): Promise { + const response = await this.getAllNamespacesRaw(initOverrides); + return await response.value(); + } + + /** + * Retrieves the historical zonefile specified by the username and zone hash. + * Get Historical Zone File + */ + async getHistoricalZoneFileRaw(requestParameters: GetHistoricalZoneFileRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.name === null || requestParameters.name === undefined) { + throw new runtime.RequiredError('name','Required parameter requestParameters.name was null or undefined when calling getHistoricalZoneFile.'); + } + + if (requestParameters.zoneFileHash === null || requestParameters.zoneFileHash === undefined) { + throw new runtime.RequiredError('zoneFileHash','Required parameter requestParameters.zoneFileHash was null or undefined when calling getHistoricalZoneFile.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/names/{name}/zonefile/{zoneFileHash}`.replace(`{${"name"}}`, encodeURIComponent(String(requestParameters.name))).replace(`{${"zoneFileHash"}}`, encodeURIComponent(String(requestParameters.zoneFileHash))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response); + } + + /** + * Retrieves the historical zonefile specified by the username and zone hash. + * Get Historical Zone File + */ + async getHistoricalZoneFile(requestParameters: GetHistoricalZoneFileRequest, initOverrides?: RequestInit): Promise { + const response = await this.getHistoricalZoneFileRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves details of a given name including the `address`, `status` and last transaction id - `last_txid`. + * Get Name Details + */ + async getNameInfoRaw(requestParameters: GetNameInfoRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.name === null || requestParameters.name === undefined) { + throw new runtime.RequiredError('name','Required parameter requestParameters.name was null or undefined when calling getNameInfo.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/names/{name}`.replace(`{${"name"}}`, encodeURIComponent(String(requestParameters.name))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BnsGetNameInfoResponseFromJSON(jsonValue)); + } + + /** + * Retrieves details of a given name including the `address`, `status` and last transaction id - `last_txid`. + * Get Name Details + */ + async getNameInfo(requestParameters: GetNameInfoRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNameInfoRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves the price of a name. The `amount` given will be in the smallest possible units of the currency. + * Get Name Price + */ + async getNamePriceRaw(requestParameters: GetNamePriceRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.name === null || requestParameters.name === undefined) { + throw new runtime.RequiredError('name','Required parameter requestParameters.name was null or undefined when calling getNamePrice.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v2/prices/names/{name}`.replace(`{${"name"}}`, encodeURIComponent(String(requestParameters.name))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BnsGetNamePriceResponseFromJSON(jsonValue)); + } + + /** + * Retrieves the price of a name. The `amount` given will be in the smallest possible units of the currency. + * Get Name Price + */ + async getNamePrice(requestParameters: GetNamePriceRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNamePriceRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of names owned by the address provided. + * Get Names Owned by Address + */ + async getNamesOwnedByAddressRaw(requestParameters: GetNamesOwnedByAddressRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.blockchain === null || requestParameters.blockchain === undefined) { + throw new runtime.RequiredError('blockchain','Required parameter requestParameters.blockchain was null or undefined when calling getNamesOwnedByAddress.'); + } + + if (requestParameters.address === null || requestParameters.address === undefined) { + throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling getNamesOwnedByAddress.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/addresses/{blockchain}/{address}`.replace(`{${"blockchain"}}`, encodeURIComponent(String(requestParameters.blockchain))).replace(`{${"address"}}`, encodeURIComponent(String(requestParameters.address))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BnsNamesOwnByAddressResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of names owned by the address provided. + * Get Names Owned by Address + */ + async getNamesOwnedByAddress(requestParameters: GetNamesOwnedByAddressRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNamesOwnedByAddressRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of names within a given namespace. + * Get Namespace Names + */ + async getNamespaceNamesRaw(requestParameters: GetNamespaceNamesRequest, initOverrides?: RequestInit): Promise>> { + if (requestParameters.tld === null || requestParameters.tld === undefined) { + throw new runtime.RequiredError('tld','Required parameter requestParameters.tld was null or undefined when calling getNamespaceNames.'); + } + + const queryParameters: any = {}; + + if (requestParameters.page !== undefined) { + queryParameters['page'] = requestParameters.page; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v1/namespaces/{tld}/names`.replace(`{${"tld"}}`, encodeURIComponent(String(requestParameters.tld))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response); + } + + /** + * Retrieves a list of names within a given namespace. + * Get Namespace Names + */ + async getNamespaceNames(requestParameters: GetNamespaceNamesRequest, initOverrides?: RequestInit): Promise> { + const response = await this.getNamespaceNamesRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves the price of a namespace. The `amount` given will be in the smallest possible units of the currency. + * Get Namespace Price + */ + async getNamespacePriceRaw(requestParameters: GetNamespacePriceRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.tld === null || requestParameters.tld === undefined) { + throw new runtime.RequiredError('tld','Required parameter requestParameters.tld was null or undefined when calling getNamespacePrice.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/v2/prices/namespaces/{tld}`.replace(`{${"tld"}}`, encodeURIComponent(String(requestParameters.tld))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BnsGetNamespacePriceResponseFromJSON(jsonValue)); + } + + /** + * Retrieves the price of a namespace. The `amount` given will be in the smallest possible units of the currency. + * Get Namespace Price + */ + async getNamespacePrice(requestParameters: GetNamespacePriceRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNamespacePriceRaw(requestParameters, initOverrides); + return await response.value(); + } + +} diff --git a/client/src/generated/apis/NonFungibleTokensApi.ts b/client/src/generated/apis/NonFungibleTokensApi.ts new file mode 100644 index 0000000000..5313556c29 --- /dev/null +++ b/client/src/generated/apis/NonFungibleTokensApi.ts @@ -0,0 +1,415 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + NonFungibleTokenHistoryEventList, + NonFungibleTokenHistoryEventListFromJSON, + NonFungibleTokenHistoryEventListToJSON, + NonFungibleTokenHoldingsList, + NonFungibleTokenHoldingsListFromJSON, + NonFungibleTokenHoldingsListToJSON, + NonFungibleTokenMetadata, + NonFungibleTokenMetadataFromJSON, + NonFungibleTokenMetadataToJSON, + NonFungibleTokenMintList, + NonFungibleTokenMintListFromJSON, + NonFungibleTokenMintListToJSON, + NonFungibleTokensMetadataList, + NonFungibleTokensMetadataListFromJSON, + NonFungibleTokensMetadataListToJSON, +} from '../models'; + +export interface GetContractNftMetadataRequest { + contractId: string; +} + +export interface GetNftHistoryRequest { + assetIdentifier: string; + value: string; + limit?: number; + offset?: number; + unanchored?: boolean; + txMetadata?: boolean; +} + +export interface GetNftHoldingsRequest { + principal: string; + assetIdentifiers?: Array; + limit?: number; + offset?: number; + unanchored?: boolean; + txMetadata?: boolean; +} + +export interface GetNftMetadataListRequest { + limit?: number; + offset?: number; +} + +export interface GetNftMintsRequest { + assetIdentifier: string; + limit?: number; + offset?: number; + unanchored?: boolean; + txMetadata?: boolean; +} + +/** + * NonFungibleTokensApi - interface + * + * @export + * @interface NonFungibleTokensApiInterface + */ +export interface NonFungibleTokensApiInterface { + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves metadata for non fungible tokens for a given contract id. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * @summary Non fungible tokens metadata for contract ID + * @param {string} contractId token\'s contract id + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NonFungibleTokensApiInterface + */ + getContractNftMetadataRaw(requestParameters: GetContractNftMetadataRequest, initOverrides?: RequestInit): Promise>; + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves metadata for non fungible tokens for a given contract id. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non fungible tokens metadata for contract ID + */ + getContractNftMetadata(requestParameters: GetContractNftMetadataRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves all events relevant to a Non-Fungible Token. Useful to determine the ownership history of a particular asset. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * @summary Non-Fungible Token history + * @param {string} assetIdentifier token asset class identifier + * @param {string} value hex representation of the token\'s unique value + * @param {number} [limit] max number of events to fetch + * @param {number} [offset] index of first event to fetch + * @param {boolean} [unanchored] whether or not to include events from unconfirmed transactions + * @param {boolean} [txMetadata] whether or not to include the complete transaction metadata instead of just `tx_id`. Enabling this option can affect performance and response times. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NonFungibleTokensApiInterface + */ + getNftHistoryRaw(requestParameters: GetNftHistoryRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves all events relevant to a Non-Fungible Token. Useful to determine the ownership history of a particular asset. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token history + */ + getNftHistory(requestParameters: GetNftHistoryRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves the list of Non-Fungible Tokens owned by the given principal (STX address or Smart Contract ID). Results can be filtered by one or more asset identifiers and can include metadata about the transaction that made the principal own each token. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * @summary Non-Fungible Token holdings + * @param {string} principal token owner\'s STX address or Smart Contract ID + * @param {Array} [assetIdentifiers] identifiers of the token asset classes to filter for + * @param {number} [limit] max number of tokens to fetch + * @param {number} [offset] index of first tokens to fetch + * @param {boolean} [unanchored] whether or not to include tokens from unconfirmed transactions + * @param {boolean} [txMetadata] whether or not to include the complete transaction metadata instead of just `tx_id`. Enabling this option can affect performance and response times. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NonFungibleTokensApiInterface + */ + getNftHoldingsRaw(requestParameters: GetNftHoldingsRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the list of Non-Fungible Tokens owned by the given principal (STX address or Smart Contract ID). Results can be filtered by one or more asset identifiers and can include metadata about the transaction that made the principal own each token. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token holdings + */ + getNftHoldings(requestParameters: GetNftHoldingsRequest, initOverrides?: RequestInit): Promise; + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves a list of non fungible tokens with their metadata. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * @summary Non fungible tokens metadata list + * @param {number} [limit] max number of tokens to fetch + * @param {number} [offset] index of first tokens to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NonFungibleTokensApiInterface + */ + getNftMetadataListRaw(requestParameters: GetNftMetadataListRequest, initOverrides?: RequestInit): Promise>; + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves a list of non fungible tokens with their metadata. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non fungible tokens metadata list + */ + getNftMetadataList(requestParameters: GetNftMetadataListRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves all mint events for a Non-Fungible Token asset class. Useful to determine which NFTs of a particular collection have been claimed. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * @summary Non-Fungible Token mints + * @param {string} assetIdentifier token asset class identifier + * @param {number} [limit] max number of events to fetch + * @param {number} [offset] index of first event to fetch + * @param {boolean} [unanchored] whether or not to include events from unconfirmed transactions + * @param {boolean} [txMetadata] whether or not to include the complete transaction metadata instead of just `tx_id`. Enabling this option can affect performance and response times. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NonFungibleTokensApiInterface + */ + getNftMintsRaw(requestParameters: GetNftMintsRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves all mint events for a Non-Fungible Token asset class. Useful to determine which NFTs of a particular collection have been claimed. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token mints + */ + getNftMints(requestParameters: GetNftMintsRequest, initOverrides?: RequestInit): Promise; + +} + +/** + * + */ +export class NonFungibleTokensApi extends runtime.BaseAPI implements NonFungibleTokensApiInterface { + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves metadata for non fungible tokens for a given contract id. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non fungible tokens metadata for contract ID + */ + async getContractNftMetadataRaw(requestParameters: GetContractNftMetadataRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.contractId === null || requestParameters.contractId === undefined) { + throw new runtime.RequiredError('contractId','Required parameter requestParameters.contractId was null or undefined when calling getContractNftMetadata.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tokens/{contractId}/nft/metadata`.replace(`{${"contractId"}}`, encodeURIComponent(String(requestParameters.contractId))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => NonFungibleTokenMetadataFromJSON(jsonValue)); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves metadata for non fungible tokens for a given contract id. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non fungible tokens metadata for contract ID + */ + async getContractNftMetadata(requestParameters: GetContractNftMetadataRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractNftMetadataRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves all events relevant to a Non-Fungible Token. Useful to determine the ownership history of a particular asset. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token history + */ + async getNftHistoryRaw(requestParameters: GetNftHistoryRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.assetIdentifier === null || requestParameters.assetIdentifier === undefined) { + throw new runtime.RequiredError('assetIdentifier','Required parameter requestParameters.assetIdentifier was null or undefined when calling getNftHistory.'); + } + + if (requestParameters.value === null || requestParameters.value === undefined) { + throw new runtime.RequiredError('value','Required parameter requestParameters.value was null or undefined when calling getNftHistory.'); + } + + const queryParameters: any = {}; + + if (requestParameters.assetIdentifier !== undefined) { + queryParameters['asset_identifier'] = requestParameters.assetIdentifier; + } + + if (requestParameters.value !== undefined) { + queryParameters['value'] = requestParameters.value; + } + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.txMetadata !== undefined) { + queryParameters['tx_metadata'] = requestParameters.txMetadata; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tokens/nft/history`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => NonFungibleTokenHistoryEventListFromJSON(jsonValue)); + } + + /** + * Retrieves all events relevant to a Non-Fungible Token. Useful to determine the ownership history of a particular asset. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token history + */ + async getNftHistory(requestParameters: GetNftHistoryRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNftHistoryRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves the list of Non-Fungible Tokens owned by the given principal (STX address or Smart Contract ID). Results can be filtered by one or more asset identifiers and can include metadata about the transaction that made the principal own each token. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token holdings + */ + async getNftHoldingsRaw(requestParameters: GetNftHoldingsRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.principal === null || requestParameters.principal === undefined) { + throw new runtime.RequiredError('principal','Required parameter requestParameters.principal was null or undefined when calling getNftHoldings.'); + } + + const queryParameters: any = {}; + + if (requestParameters.principal !== undefined) { + queryParameters['principal'] = requestParameters.principal; + } + + if (requestParameters.assetIdentifiers) { + queryParameters['asset_identifiers'] = requestParameters.assetIdentifiers; + } + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.txMetadata !== undefined) { + queryParameters['tx_metadata'] = requestParameters.txMetadata; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tokens/nft/holdings`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => NonFungibleTokenHoldingsListFromJSON(jsonValue)); + } + + /** + * Retrieves the list of Non-Fungible Tokens owned by the given principal (STX address or Smart Contract ID). Results can be filtered by one or more asset identifiers and can include metadata about the transaction that made the principal own each token. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token holdings + */ + async getNftHoldings(requestParameters: GetNftHoldingsRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNftHoldingsRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves a list of non fungible tokens with their metadata. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non fungible tokens metadata list + */ + async getNftMetadataListRaw(requestParameters: GetNftMetadataListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tokens/nft/metadata`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => NonFungibleTokensMetadataListFromJSON(jsonValue)); + } + + /** + * **NOTE:** This endpoint is deprecated in favor of the [Token Metadata Service](https://github.com/hirosystems/token-metadata-service). Retrieves a list of non fungible tokens with their metadata. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non fungible tokens metadata list + */ + async getNftMetadataList(requestParameters: GetNftMetadataListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNftMetadataListRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves all mint events for a Non-Fungible Token asset class. Useful to determine which NFTs of a particular collection have been claimed. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token mints + */ + async getNftMintsRaw(requestParameters: GetNftMintsRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.assetIdentifier === null || requestParameters.assetIdentifier === undefined) { + throw new runtime.RequiredError('assetIdentifier','Required parameter requestParameters.assetIdentifier was null or undefined when calling getNftMints.'); + } + + const queryParameters: any = {}; + + if (requestParameters.assetIdentifier !== undefined) { + queryParameters['asset_identifier'] = requestParameters.assetIdentifier; + } + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.txMetadata !== undefined) { + queryParameters['tx_metadata'] = requestParameters.txMetadata; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tokens/nft/mints`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => NonFungibleTokenMintListFromJSON(jsonValue)); + } + + /** + * Retrieves all mint events for a Non-Fungible Token asset class. Useful to determine which NFTs of a particular collection have been claimed. More information on Non-Fungible Tokens on the Stacks blockchain can be found [here](https://docs.stacks.co/write-smart-contracts/tokens#non-fungible-tokens-nfts). + * Non-Fungible Token mints + */ + async getNftMints(requestParameters: GetNftMintsRequest, initOverrides?: RequestInit): Promise { + const response = await this.getNftMintsRaw(requestParameters, initOverrides); + return await response.value(); + } + +} diff --git a/client/src/generated/apis/RosettaApi.ts b/client/src/generated/apis/RosettaApi.ts index 2d2db9fff9..9bcd140db6 100644 --- a/client/src/generated/apis/RosettaApi.ts +++ b/client/src/generated/apis/RosettaApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -102,6 +102,9 @@ import { RosettaNetworkOptionsResponse, RosettaNetworkOptionsResponseFromJSON, RosettaNetworkOptionsResponseToJSON, + RosettaNetworkStatusResponse, + RosettaNetworkStatusResponseFromJSON, + RosettaNetworkStatusResponseToJSON, RosettaOptionsRequest, RosettaOptionsRequestFromJSON, RosettaOptionsRequestToJSON, @@ -185,109 +188,109 @@ export interface RosettaApiInterface { * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaAccountBalanceRaw(requestParameters: RosettaAccountBalanceOperationRequest): Promise>; + rosettaAccountBalanceRaw(requestParameters: RosettaAccountBalanceOperationRequest, initOverrides?: RequestInit): Promise>; /** * An AccountBalanceRequest is utilized to make a balance request on the /account/balance endpoint. If the block_identifier is populated, a historical balance query should be performed. * Get an Account Balance */ - rosettaAccountBalance(requestParameters: RosettaAccountBalanceOperationRequest): Promise; + rosettaAccountBalance(requestParameters: RosettaAccountBalanceOperationRequest, initOverrides?: RequestInit): Promise; /** - * A BlockRequest is utilized to make a block request on the /block endpoint. + * Retrieves the Block information for a given block identifier including a list of all transactions in the block. * @summary Get a Block * @param {RosettaBlockRequest} rosettaBlockRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaBlockRaw(requestParameters: RosettaBlockOperationRequest): Promise>; + rosettaBlockRaw(requestParameters: RosettaBlockOperationRequest, initOverrides?: RequestInit): Promise>; /** - * A BlockRequest is utilized to make a block request on the /block endpoint. + * Retrieves the Block information for a given block identifier including a list of all transactions in the block. * Get a Block */ - rosettaBlock(requestParameters: RosettaBlockOperationRequest): Promise; + rosettaBlock(requestParameters: RosettaBlockOperationRequest, initOverrides?: RequestInit): Promise; /** - * A BlockTransactionRequest is used to fetch a Transaction included in a block that is not returned in a BlockResponse. + * Retrieves a Transaction included in a block that is not returned in a BlockResponse. * @summary Get a Block Transaction * @param {RosettaBlockTransactionRequest} rosettaBlockTransactionRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaBlockTransactionRaw(requestParameters: RosettaBlockTransactionOperationRequest): Promise>; + rosettaBlockTransactionRaw(requestParameters: RosettaBlockTransactionOperationRequest, initOverrides?: RequestInit): Promise>; /** - * A BlockTransactionRequest is used to fetch a Transaction included in a block that is not returned in a BlockResponse. + * Retrieves a Transaction included in a block that is not returned in a BlockResponse. * Get a Block Transaction */ - rosettaBlockTransaction(requestParameters: RosettaBlockTransactionOperationRequest): Promise; + rosettaBlockTransaction(requestParameters: RosettaBlockTransactionOperationRequest, initOverrides?: RequestInit): Promise; /** - * Take unsigned transaction and signature, combine both and return signed transaction + * Take unsigned transaction and signature, combine both and return signed transaction. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * @summary Create Network Transaction from Signatures * @param {RosettaConstructionCombineRequest} rosettaConstructionCombineRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionCombineRaw(requestParameters: RosettaConstructionCombineOperationRequest): Promise>; + rosettaConstructionCombineRaw(requestParameters: RosettaConstructionCombineOperationRequest, initOverrides?: RequestInit): Promise>; /** - * Take unsigned transaction and signature, combine both and return signed transaction + * Take unsigned transaction and signature, combine both and return signed transaction. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Create Network Transaction from Signatures */ - rosettaConstructionCombine(requestParameters: RosettaConstructionCombineOperationRequest): Promise; + rosettaConstructionCombine(requestParameters: RosettaConstructionCombineOperationRequest, initOverrides?: RequestInit): Promise; /** - * TODO + * Retrieves the Account Identifier information based on a Public Key for a given network * @summary Derive an AccountIdentifier from a PublicKey * @param {RosettaConstructionDeriveRequest} rosettaConstructionDeriveRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionDeriveRaw(requestParameters: RosettaConstructionDeriveOperationRequest): Promise>; + rosettaConstructionDeriveRaw(requestParameters: RosettaConstructionDeriveOperationRequest, initOverrides?: RequestInit): Promise>; /** - * TODO + * Retrieves the Account Identifier information based on a Public Key for a given network * Derive an AccountIdentifier from a PublicKey */ - rosettaConstructionDerive(requestParameters: RosettaConstructionDeriveOperationRequest): Promise; + rosettaConstructionDerive(requestParameters: RosettaConstructionDeriveOperationRequest, initOverrides?: RequestInit): Promise; /** - * TODO + * Retrieves the network-specific transaction hash for a signed transaction. * @summary Get the Hash of a Signed Transaction * @param {RosettaConstructionHashRequest} rosettaConstructionHashRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionHashRaw(requestParameters: RosettaConstructionHashOperationRequest): Promise>; + rosettaConstructionHashRaw(requestParameters: RosettaConstructionHashOperationRequest, initOverrides?: RequestInit): Promise>; /** - * TODO + * Retrieves the network-specific transaction hash for a signed transaction. * Get the Hash of a Signed Transaction */ - rosettaConstructionHash(requestParameters: RosettaConstructionHashOperationRequest): Promise; + rosettaConstructionHash(requestParameters: RosettaConstructionHashOperationRequest, initOverrides?: RequestInit): Promise; /** - * TODO + * To Do * @summary Get Metadata for Transaction Construction * @param {RosettaConstructionMetadataRequest} rosettaConstructionMetadataRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionMetadataRaw(requestParameters: RosettaConstructionMetadataOperationRequest): Promise>; + rosettaConstructionMetadataRaw(requestParameters: RosettaConstructionMetadataOperationRequest, initOverrides?: RequestInit): Promise>; /** - * TODO + * To Do * Get Metadata for Transaction Construction */ - rosettaConstructionMetadata(requestParameters: RosettaConstructionMetadataOperationRequest): Promise; + rosettaConstructionMetadata(requestParameters: RosettaConstructionMetadataOperationRequest, initOverrides?: RequestInit): Promise; /** * TODO @@ -297,29 +300,29 @@ export interface RosettaApiInterface { * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionParseRaw(requestParameters: RosettaConstructionParseOperationRequest): Promise>; + rosettaConstructionParseRaw(requestParameters: RosettaConstructionParseOperationRequest, initOverrides?: RequestInit): Promise>; /** * TODO * Parse a Transaction */ - rosettaConstructionParse(requestParameters: RosettaConstructionParseOperationRequest): Promise; + rosettaConstructionParse(requestParameters: RosettaConstructionParseOperationRequest, initOverrides?: RequestInit): Promise; /** - * Generate and unsigned transaction from operations and metadata + * Generate an unsigned transaction from operations and metadata. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * @summary Generate an Unsigned Transaction and Signing Payloads * @param {RosettaConstructionPayloadsRequest} rosettaConstructionPayloadsRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionPayloadsRaw(requestParameters: RosettaConstructionPayloadsOperationRequest): Promise>; + rosettaConstructionPayloadsRaw(requestParameters: RosettaConstructionPayloadsOperationRequest, initOverrides?: RequestInit): Promise>; /** - * Generate and unsigned transaction from operations and metadata + * Generate an unsigned transaction from operations and metadata. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Generate an Unsigned Transaction and Signing Payloads */ - rosettaConstructionPayloads(requestParameters: RosettaConstructionPayloadsOperationRequest): Promise; + rosettaConstructionPayloads(requestParameters: RosettaConstructionPayloadsOperationRequest, initOverrides?: RequestInit): Promise; /** * TODO @@ -329,108 +332,108 @@ export interface RosettaApiInterface { * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionPreprocessRaw(requestParameters: RosettaConstructionPreprocessOperationRequest): Promise>; + rosettaConstructionPreprocessRaw(requestParameters: RosettaConstructionPreprocessOperationRequest, initOverrides?: RequestInit): Promise>; /** * TODO * Create a Request to Fetch Metadata */ - rosettaConstructionPreprocess(requestParameters: RosettaConstructionPreprocessOperationRequest): Promise; + rosettaConstructionPreprocess(requestParameters: RosettaConstructionPreprocessOperationRequest, initOverrides?: RequestInit): Promise; /** - * Submit a pre-signed transaction to the node. + * Submit a pre-signed transaction to the node. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * @summary Submit a Signed Transaction * @param {RosettaConstructionSubmitRequest} rosettaConstructionSubmitRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaConstructionSubmitRaw(requestParameters: RosettaConstructionSubmitOperationRequest): Promise>; + rosettaConstructionSubmitRaw(requestParameters: RosettaConstructionSubmitOperationRequest, initOverrides?: RequestInit): Promise>; /** - * Submit a pre-signed transaction to the node. + * Submit a pre-signed transaction to the node. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Submit a Signed Transaction */ - rosettaConstructionSubmit(requestParameters: RosettaConstructionSubmitOperationRequest): Promise; + rosettaConstructionSubmit(requestParameters: RosettaConstructionSubmitOperationRequest, initOverrides?: RequestInit): Promise; /** - * Get all Transaction Identifiers in the mempool. + * Retrieves a list of transactions currently in the mempool for a given network. * @summary Get All Mempool Transactions * @param {RosettaMempoolRequest} rosettaMempoolRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaMempoolRaw(requestParameters: RosettaMempoolOperationRequest): Promise>; + rosettaMempoolRaw(requestParameters: RosettaMempoolOperationRequest, initOverrides?: RequestInit): Promise>; /** - * Get all Transaction Identifiers in the mempool. + * Retrieves a list of transactions currently in the mempool for a given network. * Get All Mempool Transactions */ - rosettaMempool(requestParameters: RosettaMempoolOperationRequest): Promise; + rosettaMempool(requestParameters: RosettaMempoolOperationRequest, initOverrides?: RequestInit): Promise; /** - * A MempoolTransactionRequest is utilized to retrieve a transaction from the mempool. + * Retrieves transaction details from the mempool for a given transaction id from a given network. * @summary Get a Mempool Transaction * @param {RosettaMempoolTransactionRequest} rosettaMempoolTransactionRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaMempoolTransactionRaw(requestParameters: RosettaMempoolTransactionOperationRequest): Promise>; + rosettaMempoolTransactionRaw(requestParameters: RosettaMempoolTransactionOperationRequest, initOverrides?: RequestInit): Promise>; /** - * A MempoolTransactionRequest is utilized to retrieve a transaction from the mempool. + * Retrieves transaction details from the mempool for a given transaction id from a given network. * Get a Mempool Transaction */ - rosettaMempoolTransaction(requestParameters: RosettaMempoolTransactionOperationRequest): Promise; + rosettaMempoolTransaction(requestParameters: RosettaMempoolTransactionOperationRequest, initOverrides?: RequestInit): Promise; /** - * This endpoint returns a list of NetworkIdentifiers that the Rosetta server supports. + * Retrieves a list of NetworkIdentifiers that the Rosetta server supports. * @summary Get List of Available Networks * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaNetworkListRaw(): Promise>; + rosettaNetworkListRaw(initOverrides?: RequestInit): Promise>; /** - * This endpoint returns a list of NetworkIdentifiers that the Rosetta server supports. + * Retrieves a list of NetworkIdentifiers that the Rosetta server supports. * Get List of Available Networks */ - rosettaNetworkList(): Promise; + rosettaNetworkList(initOverrides?: RequestInit): Promise; /** - * This endpoint returns the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. + * Retrieves the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. * @summary Get Network Options * @param {RosettaOptionsRequest} rosettaOptionsRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaNetworkOptionsRaw(requestParameters: RosettaNetworkOptionsRequest): Promise>; + rosettaNetworkOptionsRaw(requestParameters: RosettaNetworkOptionsRequest, initOverrides?: RequestInit): Promise>; /** - * This endpoint returns the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. + * Retrieves the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. * Get Network Options */ - rosettaNetworkOptions(requestParameters: RosettaNetworkOptionsRequest): Promise; + rosettaNetworkOptions(requestParameters: RosettaNetworkOptionsRequest, initOverrides?: RequestInit): Promise; /** - * This endpoint returns the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. + * Retrieves the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. * @summary Get Network Status * @param {RosettaStatusRequest} rosettaStatusRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RosettaApiInterface */ - rosettaNetworkStatusRaw(requestParameters: RosettaNetworkStatusRequest): Promise>; + rosettaNetworkStatusRaw(requestParameters: RosettaNetworkStatusRequest, initOverrides?: RequestInit): Promise>; /** - * This endpoint returns the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. + * Retrieves the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. * Get Network Status */ - rosettaNetworkStatus(requestParameters: RosettaNetworkStatusRequest): Promise<{ [key: string]: object; }>; + rosettaNetworkStatus(requestParameters: RosettaNetworkStatusRequest, initOverrides?: RequestInit): Promise; } @@ -443,12 +446,12 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { * An AccountBalanceRequest is utilized to make a balance request on the /account/balance endpoint. If the block_identifier is populated, a historical balance query should be performed. * Get an Account Balance */ - async rosettaAccountBalanceRaw(requestParameters: RosettaAccountBalanceOperationRequest): Promise> { + async rosettaAccountBalanceRaw(requestParameters: RosettaAccountBalanceOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaAccountBalanceRequest === null || requestParameters.rosettaAccountBalanceRequest === undefined) { throw new runtime.RequiredError('rosettaAccountBalanceRequest','Required parameter requestParameters.rosettaAccountBalanceRequest was null or undefined when calling rosettaAccountBalance.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -460,7 +463,7 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaAccountBalanceRequestToJSON(requestParameters.rosettaAccountBalanceRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaAccountBalanceResponseFromJSON(jsonValue)); } @@ -469,21 +472,21 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { * An AccountBalanceRequest is utilized to make a balance request on the /account/balance endpoint. If the block_identifier is populated, a historical balance query should be performed. * Get an Account Balance */ - async rosettaAccountBalance(requestParameters: RosettaAccountBalanceOperationRequest): Promise { - const response = await this.rosettaAccountBalanceRaw(requestParameters); + async rosettaAccountBalance(requestParameters: RosettaAccountBalanceOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaAccountBalanceRaw(requestParameters, initOverrides); return await response.value(); } /** - * A BlockRequest is utilized to make a block request on the /block endpoint. + * Retrieves the Block information for a given block identifier including a list of all transactions in the block. * Get a Block */ - async rosettaBlockRaw(requestParameters: RosettaBlockOperationRequest): Promise> { + async rosettaBlockRaw(requestParameters: RosettaBlockOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaBlockRequest === null || requestParameters.rosettaBlockRequest === undefined) { throw new runtime.RequiredError('rosettaBlockRequest','Required parameter requestParameters.rosettaBlockRequest was null or undefined when calling rosettaBlock.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -495,30 +498,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaBlockRequestToJSON(requestParameters.rosettaBlockRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaBlockResponseFromJSON(jsonValue)); } /** - * A BlockRequest is utilized to make a block request on the /block endpoint. + * Retrieves the Block information for a given block identifier including a list of all transactions in the block. * Get a Block */ - async rosettaBlock(requestParameters: RosettaBlockOperationRequest): Promise { - const response = await this.rosettaBlockRaw(requestParameters); + async rosettaBlock(requestParameters: RosettaBlockOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaBlockRaw(requestParameters, initOverrides); return await response.value(); } /** - * A BlockTransactionRequest is used to fetch a Transaction included in a block that is not returned in a BlockResponse. + * Retrieves a Transaction included in a block that is not returned in a BlockResponse. * Get a Block Transaction */ - async rosettaBlockTransactionRaw(requestParameters: RosettaBlockTransactionOperationRequest): Promise> { + async rosettaBlockTransactionRaw(requestParameters: RosettaBlockTransactionOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaBlockTransactionRequest === null || requestParameters.rosettaBlockTransactionRequest === undefined) { throw new runtime.RequiredError('rosettaBlockTransactionRequest','Required parameter requestParameters.rosettaBlockTransactionRequest was null or undefined when calling rosettaBlockTransaction.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -530,30 +533,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaBlockTransactionRequestToJSON(requestParameters.rosettaBlockTransactionRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaBlockTransactionResponseFromJSON(jsonValue)); } /** - * A BlockTransactionRequest is used to fetch a Transaction included in a block that is not returned in a BlockResponse. + * Retrieves a Transaction included in a block that is not returned in a BlockResponse. * Get a Block Transaction */ - async rosettaBlockTransaction(requestParameters: RosettaBlockTransactionOperationRequest): Promise { - const response = await this.rosettaBlockTransactionRaw(requestParameters); + async rosettaBlockTransaction(requestParameters: RosettaBlockTransactionOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaBlockTransactionRaw(requestParameters, initOverrides); return await response.value(); } /** - * Take unsigned transaction and signature, combine both and return signed transaction + * Take unsigned transaction and signature, combine both and return signed transaction. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Create Network Transaction from Signatures */ - async rosettaConstructionCombineRaw(requestParameters: RosettaConstructionCombineOperationRequest): Promise> { + async rosettaConstructionCombineRaw(requestParameters: RosettaConstructionCombineOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionCombineRequest === null || requestParameters.rosettaConstructionCombineRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionCombineRequest','Required parameter requestParameters.rosettaConstructionCombineRequest was null or undefined when calling rosettaConstructionCombine.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -565,30 +568,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionCombineRequestToJSON(requestParameters.rosettaConstructionCombineRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionCombineResponseFromJSON(jsonValue)); } /** - * Take unsigned transaction and signature, combine both and return signed transaction + * Take unsigned transaction and signature, combine both and return signed transaction. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Create Network Transaction from Signatures */ - async rosettaConstructionCombine(requestParameters: RosettaConstructionCombineOperationRequest): Promise { - const response = await this.rosettaConstructionCombineRaw(requestParameters); + async rosettaConstructionCombine(requestParameters: RosettaConstructionCombineOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionCombineRaw(requestParameters, initOverrides); return await response.value(); } /** - * TODO + * Retrieves the Account Identifier information based on a Public Key for a given network * Derive an AccountIdentifier from a PublicKey */ - async rosettaConstructionDeriveRaw(requestParameters: RosettaConstructionDeriveOperationRequest): Promise> { + async rosettaConstructionDeriveRaw(requestParameters: RosettaConstructionDeriveOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionDeriveRequest === null || requestParameters.rosettaConstructionDeriveRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionDeriveRequest','Required parameter requestParameters.rosettaConstructionDeriveRequest was null or undefined when calling rosettaConstructionDerive.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -600,30 +603,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionDeriveRequestToJSON(requestParameters.rosettaConstructionDeriveRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionDeriveResponseFromJSON(jsonValue)); } /** - * TODO + * Retrieves the Account Identifier information based on a Public Key for a given network * Derive an AccountIdentifier from a PublicKey */ - async rosettaConstructionDerive(requestParameters: RosettaConstructionDeriveOperationRequest): Promise { - const response = await this.rosettaConstructionDeriveRaw(requestParameters); + async rosettaConstructionDerive(requestParameters: RosettaConstructionDeriveOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionDeriveRaw(requestParameters, initOverrides); return await response.value(); } /** - * TODO + * Retrieves the network-specific transaction hash for a signed transaction. * Get the Hash of a Signed Transaction */ - async rosettaConstructionHashRaw(requestParameters: RosettaConstructionHashOperationRequest): Promise> { + async rosettaConstructionHashRaw(requestParameters: RosettaConstructionHashOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionHashRequest === null || requestParameters.rosettaConstructionHashRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionHashRequest','Required parameter requestParameters.rosettaConstructionHashRequest was null or undefined when calling rosettaConstructionHash.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -635,30 +638,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionHashRequestToJSON(requestParameters.rosettaConstructionHashRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionHashResponseFromJSON(jsonValue)); } /** - * TODO + * Retrieves the network-specific transaction hash for a signed transaction. * Get the Hash of a Signed Transaction */ - async rosettaConstructionHash(requestParameters: RosettaConstructionHashOperationRequest): Promise { - const response = await this.rosettaConstructionHashRaw(requestParameters); + async rosettaConstructionHash(requestParameters: RosettaConstructionHashOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionHashRaw(requestParameters, initOverrides); return await response.value(); } /** - * TODO + * To Do * Get Metadata for Transaction Construction */ - async rosettaConstructionMetadataRaw(requestParameters: RosettaConstructionMetadataOperationRequest): Promise> { + async rosettaConstructionMetadataRaw(requestParameters: RosettaConstructionMetadataOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionMetadataRequest === null || requestParameters.rosettaConstructionMetadataRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionMetadataRequest','Required parameter requestParameters.rosettaConstructionMetadataRequest was null or undefined when calling rosettaConstructionMetadata.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -670,17 +673,17 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionMetadataRequestToJSON(requestParameters.rosettaConstructionMetadataRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionMetadataResponseFromJSON(jsonValue)); } /** - * TODO + * To Do * Get Metadata for Transaction Construction */ - async rosettaConstructionMetadata(requestParameters: RosettaConstructionMetadataOperationRequest): Promise { - const response = await this.rosettaConstructionMetadataRaw(requestParameters); + async rosettaConstructionMetadata(requestParameters: RosettaConstructionMetadataOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionMetadataRaw(requestParameters, initOverrides); return await response.value(); } @@ -688,12 +691,12 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { * TODO * Parse a Transaction */ - async rosettaConstructionParseRaw(requestParameters: RosettaConstructionParseOperationRequest): Promise> { + async rosettaConstructionParseRaw(requestParameters: RosettaConstructionParseOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionParseRequest === null || requestParameters.rosettaConstructionParseRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionParseRequest','Required parameter requestParameters.rosettaConstructionParseRequest was null or undefined when calling rosettaConstructionParse.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -705,7 +708,7 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionParseRequestToJSON(requestParameters.rosettaConstructionParseRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionParseResponseFromJSON(jsonValue)); } @@ -714,21 +717,21 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { * TODO * Parse a Transaction */ - async rosettaConstructionParse(requestParameters: RosettaConstructionParseOperationRequest): Promise { - const response = await this.rosettaConstructionParseRaw(requestParameters); + async rosettaConstructionParse(requestParameters: RosettaConstructionParseOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionParseRaw(requestParameters, initOverrides); return await response.value(); } /** - * Generate and unsigned transaction from operations and metadata + * Generate an unsigned transaction from operations and metadata. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Generate an Unsigned Transaction and Signing Payloads */ - async rosettaConstructionPayloadsRaw(requestParameters: RosettaConstructionPayloadsOperationRequest): Promise> { + async rosettaConstructionPayloadsRaw(requestParameters: RosettaConstructionPayloadsOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionPayloadsRequest === null || requestParameters.rosettaConstructionPayloadsRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionPayloadsRequest','Required parameter requestParameters.rosettaConstructionPayloadsRequest was null or undefined when calling rosettaConstructionPayloads.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -740,17 +743,17 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionPayloadsRequestToJSON(requestParameters.rosettaConstructionPayloadsRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionPayloadResponseFromJSON(jsonValue)); } /** - * Generate and unsigned transaction from operations and metadata + * Generate an unsigned transaction from operations and metadata. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Generate an Unsigned Transaction and Signing Payloads */ - async rosettaConstructionPayloads(requestParameters: RosettaConstructionPayloadsOperationRequest): Promise { - const response = await this.rosettaConstructionPayloadsRaw(requestParameters); + async rosettaConstructionPayloads(requestParameters: RosettaConstructionPayloadsOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionPayloadsRaw(requestParameters, initOverrides); return await response.value(); } @@ -758,12 +761,12 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { * TODO * Create a Request to Fetch Metadata */ - async rosettaConstructionPreprocessRaw(requestParameters: RosettaConstructionPreprocessOperationRequest): Promise> { + async rosettaConstructionPreprocessRaw(requestParameters: RosettaConstructionPreprocessOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionPreprocessRequest === null || requestParameters.rosettaConstructionPreprocessRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionPreprocessRequest','Required parameter requestParameters.rosettaConstructionPreprocessRequest was null or undefined when calling rosettaConstructionPreprocess.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -775,7 +778,7 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionPreprocessRequestToJSON(requestParameters.rosettaConstructionPreprocessRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionPreprocessResponseFromJSON(jsonValue)); } @@ -784,21 +787,21 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { * TODO * Create a Request to Fetch Metadata */ - async rosettaConstructionPreprocess(requestParameters: RosettaConstructionPreprocessOperationRequest): Promise { - const response = await this.rosettaConstructionPreprocessRaw(requestParameters); + async rosettaConstructionPreprocess(requestParameters: RosettaConstructionPreprocessOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionPreprocessRaw(requestParameters, initOverrides); return await response.value(); } /** - * Submit a pre-signed transaction to the node. + * Submit a pre-signed transaction to the node. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Submit a Signed Transaction */ - async rosettaConstructionSubmitRaw(requestParameters: RosettaConstructionSubmitOperationRequest): Promise> { + async rosettaConstructionSubmitRaw(requestParameters: RosettaConstructionSubmitOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaConstructionSubmitRequest === null || requestParameters.rosettaConstructionSubmitRequest === undefined) { throw new runtime.RequiredError('rosettaConstructionSubmitRequest','Required parameter requestParameters.rosettaConstructionSubmitRequest was null or undefined when calling rosettaConstructionSubmit.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -810,30 +813,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaConstructionSubmitRequestToJSON(requestParameters.rosettaConstructionSubmitRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaConstructionSubmitResponseFromJSON(jsonValue)); } /** - * Submit a pre-signed transaction to the node. + * Submit a pre-signed transaction to the node. The examples below are illustrative only. You\'ll need to use your wallet to generate actual values to use them in the request payload. * Submit a Signed Transaction */ - async rosettaConstructionSubmit(requestParameters: RosettaConstructionSubmitOperationRequest): Promise { - const response = await this.rosettaConstructionSubmitRaw(requestParameters); + async rosettaConstructionSubmit(requestParameters: RosettaConstructionSubmitOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaConstructionSubmitRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get all Transaction Identifiers in the mempool. + * Retrieves a list of transactions currently in the mempool for a given network. * Get All Mempool Transactions */ - async rosettaMempoolRaw(requestParameters: RosettaMempoolOperationRequest): Promise> { + async rosettaMempoolRaw(requestParameters: RosettaMempoolOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaMempoolRequest === null || requestParameters.rosettaMempoolRequest === undefined) { throw new runtime.RequiredError('rosettaMempoolRequest','Required parameter requestParameters.rosettaMempoolRequest was null or undefined when calling rosettaMempool.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -845,30 +848,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaMempoolRequestToJSON(requestParameters.rosettaMempoolRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaMempoolResponseFromJSON(jsonValue)); } /** - * Get all Transaction Identifiers in the mempool. + * Retrieves a list of transactions currently in the mempool for a given network. * Get All Mempool Transactions */ - async rosettaMempool(requestParameters: RosettaMempoolOperationRequest): Promise { - const response = await this.rosettaMempoolRaw(requestParameters); + async rosettaMempool(requestParameters: RosettaMempoolOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaMempoolRaw(requestParameters, initOverrides); return await response.value(); } /** - * A MempoolTransactionRequest is utilized to retrieve a transaction from the mempool. + * Retrieves transaction details from the mempool for a given transaction id from a given network. * Get a Mempool Transaction */ - async rosettaMempoolTransactionRaw(requestParameters: RosettaMempoolTransactionOperationRequest): Promise> { + async rosettaMempoolTransactionRaw(requestParameters: RosettaMempoolTransactionOperationRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaMempoolTransactionRequest === null || requestParameters.rosettaMempoolTransactionRequest === undefined) { throw new runtime.RequiredError('rosettaMempoolTransactionRequest','Required parameter requestParameters.rosettaMempoolTransactionRequest was null or undefined when calling rosettaMempoolTransaction.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -880,26 +883,26 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaMempoolTransactionRequestToJSON(requestParameters.rosettaMempoolTransactionRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaMempoolTransactionResponseFromJSON(jsonValue)); } /** - * A MempoolTransactionRequest is utilized to retrieve a transaction from the mempool. + * Retrieves transaction details from the mempool for a given transaction id from a given network. * Get a Mempool Transaction */ - async rosettaMempoolTransaction(requestParameters: RosettaMempoolTransactionOperationRequest): Promise { - const response = await this.rosettaMempoolTransactionRaw(requestParameters); + async rosettaMempoolTransaction(requestParameters: RosettaMempoolTransactionOperationRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaMempoolTransactionRaw(requestParameters, initOverrides); return await response.value(); } /** - * This endpoint returns a list of NetworkIdentifiers that the Rosetta server supports. + * Retrieves a list of NetworkIdentifiers that the Rosetta server supports. * Get List of Available Networks */ - async rosettaNetworkListRaw(): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async rosettaNetworkListRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -908,30 +911,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { method: 'POST', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaNetworkListResponseFromJSON(jsonValue)); } /** - * This endpoint returns a list of NetworkIdentifiers that the Rosetta server supports. + * Retrieves a list of NetworkIdentifiers that the Rosetta server supports. * Get List of Available Networks */ - async rosettaNetworkList(): Promise { - const response = await this.rosettaNetworkListRaw(); + async rosettaNetworkList(initOverrides?: RequestInit): Promise { + const response = await this.rosettaNetworkListRaw(initOverrides); return await response.value(); } /** - * This endpoint returns the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. + * Retrieves the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. * Get Network Options */ - async rosettaNetworkOptionsRaw(requestParameters: RosettaNetworkOptionsRequest): Promise> { + async rosettaNetworkOptionsRaw(requestParameters: RosettaNetworkOptionsRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaOptionsRequest === null || requestParameters.rosettaOptionsRequest === undefined) { throw new runtime.RequiredError('rosettaOptionsRequest','Required parameter requestParameters.rosettaOptionsRequest was null or undefined when calling rosettaNetworkOptions.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -943,30 +946,30 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaOptionsRequestToJSON(requestParameters.rosettaOptionsRequest), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RosettaNetworkOptionsResponseFromJSON(jsonValue)); } /** - * This endpoint returns the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. + * Retrieves the version information and allowed network-specific types for a NetworkIdentifier. Any NetworkIdentifier returned by /network/list should be accessible here. Because options are retrievable in the context of a NetworkIdentifier, it is possible to define unique options for each network. * Get Network Options */ - async rosettaNetworkOptions(requestParameters: RosettaNetworkOptionsRequest): Promise { - const response = await this.rosettaNetworkOptionsRaw(requestParameters); + async rosettaNetworkOptions(requestParameters: RosettaNetworkOptionsRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaNetworkOptionsRaw(requestParameters, initOverrides); return await response.value(); } /** - * This endpoint returns the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. + * Retrieves the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. * Get Network Status */ - async rosettaNetworkStatusRaw(requestParameters: RosettaNetworkStatusRequest): Promise> { + async rosettaNetworkStatusRaw(requestParameters: RosettaNetworkStatusRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.rosettaStatusRequest === null || requestParameters.rosettaStatusRequest === undefined) { throw new runtime.RequiredError('rosettaStatusRequest','Required parameter requestParameters.rosettaStatusRequest was null or undefined when calling rosettaNetworkStatus.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -978,17 +981,17 @@ export class RosettaApi extends runtime.BaseAPI implements RosettaApiInterface { headers: headerParameters, query: queryParameters, body: RosettaStatusRequestToJSON(requestParameters.rosettaStatusRequest), - }); + }, initOverrides); - return new runtime.JSONApiResponse(response); + return new runtime.JSONApiResponse(response, (jsonValue) => RosettaNetworkStatusResponseFromJSON(jsonValue)); } /** - * This endpoint returns the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. + * Retrieves the current status of the network requested. Any NetworkIdentifier returned by /network/list should be accessible here. * Get Network Status */ - async rosettaNetworkStatus(requestParameters: RosettaNetworkStatusRequest): Promise<{ [key: string]: object; }> { - const response = await this.rosettaNetworkStatusRaw(requestParameters); + async rosettaNetworkStatus(requestParameters: RosettaNetworkStatusRequest, initOverrides?: RequestInit): Promise { + const response = await this.rosettaNetworkStatusRaw(requestParameters, initOverrides); return await response.value(); } diff --git a/client/src/generated/apis/SearchApi.ts b/client/src/generated/apis/SearchApi.ts index 1f72bb1b63..21fc1f9fd3 100644 --- a/client/src/generated/apis/SearchApi.ts +++ b/client/src/generated/apis/SearchApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -17,6 +17,7 @@ import * as runtime from '../runtime'; export interface SearchByIdRequest { id: string; + includeMetadata?: boolean; } /** @@ -30,17 +31,18 @@ export interface SearchApiInterface { * Search blocks, transactions, contracts, or accounts by hash/ID * @summary Search * @param {string} id The hex hash string for a block or transaction, account address, or contract address + * @param {boolean} [includeMetadata] This includes the detailed data for purticular hash in the response * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof SearchApiInterface */ - searchByIdRaw(requestParameters: SearchByIdRequest): Promise>; + searchByIdRaw(requestParameters: SearchByIdRequest, initOverrides?: RequestInit): Promise>; /** * Search blocks, transactions, contracts, or accounts by hash/ID * Search */ - searchById(requestParameters: SearchByIdRequest): Promise; + searchById(requestParameters: SearchByIdRequest, initOverrides?: RequestInit): Promise; } @@ -53,12 +55,16 @@ export class SearchApi extends runtime.BaseAPI implements SearchApiInterface { * Search blocks, transactions, contracts, or accounts by hash/ID * Search */ - async searchByIdRaw(requestParameters: SearchByIdRequest): Promise> { + async searchByIdRaw(requestParameters: SearchByIdRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.id === null || requestParameters.id === undefined) { throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling searchById.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; + + if (requestParameters.includeMetadata !== undefined) { + queryParameters['include_metadata'] = requestParameters.includeMetadata; + } const headerParameters: runtime.HTTPHeaders = {}; @@ -67,7 +73,7 @@ export class SearchApi extends runtime.BaseAPI implements SearchApiInterface { method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response); } @@ -76,8 +82,8 @@ export class SearchApi extends runtime.BaseAPI implements SearchApiInterface { * Search blocks, transactions, contracts, or accounts by hash/ID * Search */ - async searchById(requestParameters: SearchByIdRequest): Promise { - const response = await this.searchByIdRaw(requestParameters); + async searchById(requestParameters: SearchByIdRequest, initOverrides?: RequestInit): Promise { + const response = await this.searchByIdRaw(requestParameters, initOverrides); return await response.value(); } diff --git a/client/src/generated/apis/SmartContractsApi.ts b/client/src/generated/apis/SmartContractsApi.ts index 1de166f32e..d23e4daab5 100644 --- a/client/src/generated/apis/SmartContractsApi.ts +++ b/client/src/generated/apis/SmartContractsApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -18,6 +18,9 @@ import { ContractInterfaceResponse, ContractInterfaceResponseFromJSON, ContractInterfaceResponseToJSON, + ContractListResponse, + ContractListResponseFromJSON, + ContractListResponseToJSON, ContractSourceResponse, ContractSourceResponseFromJSON, ContractSourceResponseToJSON, @@ -30,6 +33,9 @@ import { ReadOnlyFunctionSuccessResponse, ReadOnlyFunctionSuccessResponseFromJSON, ReadOnlyFunctionSuccessResponseToJSON, + SmartContract, + SmartContractFromJSON, + SmartContractToJSON, } from '../models'; export interface CallReadOnlyFunctionRequest { @@ -42,6 +48,7 @@ export interface CallReadOnlyFunctionRequest { export interface GetContractByIdRequest { contractId: string; + unanchored?: boolean; } export interface GetContractDataMapEntryRequest { @@ -57,6 +64,7 @@ export interface GetContractEventsByIdRequest { contractId: string; limit?: number; offset?: number; + unanchored?: boolean; } export interface GetContractInterfaceRequest { @@ -72,6 +80,12 @@ export interface GetContractSourceRequest { tip?: string; } +export interface GetContractsByTraitRequest { + traitAbi: string; + limit?: number; + offset?: number; +} + /** * SmartContractsApi - interface * @@ -91,32 +105,33 @@ export interface SmartContractsApiInterface { * @throws {RequiredError} * @memberof SmartContractsApiInterface */ - callReadOnlyFunctionRaw(requestParameters: CallReadOnlyFunctionRequest): Promise>; + callReadOnlyFunctionRaw(requestParameters: CallReadOnlyFunctionRequest, initOverrides?: RequestInit): Promise>; /** * Call a read-only public function on a given smart contract. The smart contract and function are specified using the URL path. The arguments and the simulated tx-sender are supplied via the POST body in the following JSON format: * Call read-only function */ - callReadOnlyFunction(requestParameters: CallReadOnlyFunctionRequest): Promise; + callReadOnlyFunction(requestParameters: CallReadOnlyFunctionRequest, initOverrides?: RequestInit): Promise; /** - * Get contract info using the contract ID + * Retrieves details of a contract with a given `contract_id` * @summary Get contract info * @param {string} contractId Contract identifier formatted as `<contract_address>.<contract_name>` + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof SmartContractsApiInterface */ - getContractByIdRaw(requestParameters: GetContractByIdRequest): Promise>; + getContractByIdRaw(requestParameters: GetContractByIdRequest, initOverrides?: RequestInit): Promise>; /** - * Get contract info using the contract ID + * Retrieves details of a contract with a given `contract_id` * Get contract info */ - getContractById(requestParameters: GetContractByIdRequest): Promise; + getContractById(requestParameters: GetContractByIdRequest, initOverrides?: RequestInit): Promise; /** - * Attempt to fetch data from a contract data map. The contract is identified with [Stacks Address] and [Contract Name] in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. + * Attempt to fetch data from a contract data map. The contract is identified with Stacks Address `contract_address` and Contract Name `contract_address` in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. * @summary Get specific data-map inside a contract * @param {string} contractAddress Stacks address * @param {string} contractName Contract name @@ -128,34 +143,35 @@ export interface SmartContractsApiInterface { * @throws {RequiredError} * @memberof SmartContractsApiInterface */ - getContractDataMapEntryRaw(requestParameters: GetContractDataMapEntryRequest): Promise>; + getContractDataMapEntryRaw(requestParameters: GetContractDataMapEntryRequest, initOverrides?: RequestInit): Promise>; /** - * Attempt to fetch data from a contract data map. The contract is identified with [Stacks Address] and [Contract Name] in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. + * Attempt to fetch data from a contract data map. The contract is identified with Stacks Address `contract_address` and Contract Name `contract_address` in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. * Get specific data-map inside a contract */ - getContractDataMapEntry(requestParameters: GetContractDataMapEntryRequest): Promise; + getContractDataMapEntry(requestParameters: GetContractDataMapEntryRequest, initOverrides?: RequestInit): Promise; /** - * Get contract events using a contract ID + * Retrieves a list of events that have been triggered by a given `contract_id` * @summary Get contract events * @param {string} contractId Contract identifier formatted as `<contract_address>.<contract_name>` * @param {number} [limit] max number of contract events to fetch * @param {number} [offset] index of first contract event to fetch + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof SmartContractsApiInterface */ - getContractEventsByIdRaw(requestParameters: GetContractEventsByIdRequest): Promise>; + getContractEventsByIdRaw(requestParameters: GetContractEventsByIdRequest, initOverrides?: RequestInit): Promise>; /** - * Get contract events using a contract ID + * Retrieves a list of events that have been triggered by a given `contract_id` * Get contract events */ - getContractEventsById(requestParameters: GetContractEventsByIdRequest): Promise; + getContractEventsById(requestParameters: GetContractEventsByIdRequest, initOverrides?: RequestInit): Promise; /** - * Get contract interface using a `contract_address` and `contract name` + * Retrieves a contract interface with a given `contract_address` and `contract name` * @summary Get contract interface * @param {string} contractAddress Stacks address * @param {string} contractName Contract name @@ -164,16 +180,16 @@ export interface SmartContractsApiInterface { * @throws {RequiredError} * @memberof SmartContractsApiInterface */ - getContractInterfaceRaw(requestParameters: GetContractInterfaceRequest): Promise>; + getContractInterfaceRaw(requestParameters: GetContractInterfaceRequest, initOverrides?: RequestInit): Promise>; /** - * Get contract interface using a `contract_address` and `contract name` + * Retrieves a contract interface with a given `contract_address` and `contract name` * Get contract interface */ - getContractInterface(requestParameters: GetContractInterfaceRequest): Promise; + getContractInterface(requestParameters: GetContractInterfaceRequest, initOverrides?: RequestInit): Promise; /** - * Returns the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data + * Retrieves the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data * @summary Get contract source * @param {string} contractAddress Stacks address * @param {string} contractName Contract name @@ -183,13 +199,31 @@ export interface SmartContractsApiInterface { * @throws {RequiredError} * @memberof SmartContractsApiInterface */ - getContractSourceRaw(requestParameters: GetContractSourceRequest): Promise>; + getContractSourceRaw(requestParameters: GetContractSourceRequest, initOverrides?: RequestInit): Promise>; /** - * Returns the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data + * Retrieves the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data * Get contract source */ - getContractSource(requestParameters: GetContractSourceRequest): Promise; + getContractSource(requestParameters: GetContractSourceRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of contracts based on the following traits listed in JSON format - functions, variables, maps, fungible tokens and non-fungible tokens + * @summary Get contracts by trait + * @param {string} traitAbi JSON abi of the trait. + * @param {number} [limit] max number of contracts fetch + * @param {number} [offset] index of first contract event to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof SmartContractsApiInterface + */ + getContractsByTraitRaw(requestParameters: GetContractsByTraitRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of contracts based on the following traits listed in JSON format - functions, variables, maps, fungible tokens and non-fungible tokens + * Get contracts by trait + */ + getContractsByTrait(requestParameters: GetContractsByTraitRequest, initOverrides?: RequestInit): Promise; } @@ -202,7 +236,7 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts * Call a read-only public function on a given smart contract. The smart contract and function are specified using the URL path. The arguments and the simulated tx-sender are supplied via the POST body in the following JSON format: * Call read-only function */ - async callReadOnlyFunctionRaw(requestParameters: CallReadOnlyFunctionRequest): Promise> { + async callReadOnlyFunctionRaw(requestParameters: CallReadOnlyFunctionRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.contractAddress === null || requestParameters.contractAddress === undefined) { throw new runtime.RequiredError('contractAddress','Required parameter requestParameters.contractAddress was null or undefined when calling callReadOnlyFunction.'); } @@ -219,7 +253,7 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts throw new runtime.RequiredError('readOnlyFunctionArgs','Required parameter requestParameters.readOnlyFunctionArgs was null or undefined when calling callReadOnlyFunction.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.tip !== undefined) { queryParameters['tip'] = requestParameters.tip; @@ -235,7 +269,7 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts headers: headerParameters, query: queryParameters, body: ReadOnlyFunctionArgsToJSON(requestParameters.readOnlyFunctionArgs), - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => ReadOnlyFunctionSuccessResponseFromJSON(jsonValue)); } @@ -244,21 +278,25 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts * Call a read-only public function on a given smart contract. The smart contract and function are specified using the URL path. The arguments and the simulated tx-sender are supplied via the POST body in the following JSON format: * Call read-only function */ - async callReadOnlyFunction(requestParameters: CallReadOnlyFunctionRequest): Promise { - const response = await this.callReadOnlyFunctionRaw(requestParameters); + async callReadOnlyFunction(requestParameters: CallReadOnlyFunctionRequest, initOverrides?: RequestInit): Promise { + const response = await this.callReadOnlyFunctionRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get contract info using the contract ID + * Retrieves details of a contract with a given `contract_id` * Get contract info */ - async getContractByIdRaw(requestParameters: GetContractByIdRequest): Promise> { + async getContractByIdRaw(requestParameters: GetContractByIdRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.contractId === null || requestParameters.contractId === undefined) { throw new runtime.RequiredError('contractId','Required parameter requestParameters.contractId was null or undefined when calling getContractById.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } const headerParameters: runtime.HTTPHeaders = {}; @@ -267,25 +305,25 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); - return new runtime.JSONApiResponse(response); + return new runtime.JSONApiResponse(response, (jsonValue) => SmartContractFromJSON(jsonValue)); } /** - * Get contract info using the contract ID + * Retrieves details of a contract with a given `contract_id` * Get contract info */ - async getContractById(requestParameters: GetContractByIdRequest): Promise { - const response = await this.getContractByIdRaw(requestParameters); + async getContractById(requestParameters: GetContractByIdRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractByIdRaw(requestParameters, initOverrides); return await response.value(); } /** - * Attempt to fetch data from a contract data map. The contract is identified with [Stacks Address] and [Contract Name] in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. + * Attempt to fetch data from a contract data map. The contract is identified with Stacks Address `contract_address` and Contract Name `contract_address` in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. * Get specific data-map inside a contract */ - async getContractDataMapEntryRaw(requestParameters: GetContractDataMapEntryRequest): Promise> { + async getContractDataMapEntryRaw(requestParameters: GetContractDataMapEntryRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.contractAddress === null || requestParameters.contractAddress === undefined) { throw new runtime.RequiredError('contractAddress','Required parameter requestParameters.contractAddress was null or undefined when calling getContractDataMapEntry.'); } @@ -302,7 +340,7 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts throw new runtime.RequiredError('key','Required parameter requestParameters.key was null or undefined when calling getContractDataMapEntry.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.proof !== undefined) { queryParameters['proof'] = requestParameters.proof; @@ -322,30 +360,30 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts headers: headerParameters, query: queryParameters, body: requestParameters.key as any, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => MapEntryResponseFromJSON(jsonValue)); } /** - * Attempt to fetch data from a contract data map. The contract is identified with [Stacks Address] and [Contract Name] in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. + * Attempt to fetch data from a contract data map. The contract is identified with Stacks Address `contract_address` and Contract Name `contract_address` in the URL path. The map is identified with [Map Name]. The key to lookup in the map is supplied via the POST body. This should be supplied as the hex string serialization of the key (which should be a Clarity value). Note, this is a JSON string atom. In the response, `data` is the hex serialization of the map response. Note that map responses are Clarity option types, for non-existent values, this is a serialized none, and for all other responses, it is a serialized (some ...) object. * Get specific data-map inside a contract */ - async getContractDataMapEntry(requestParameters: GetContractDataMapEntryRequest): Promise { - const response = await this.getContractDataMapEntryRaw(requestParameters); + async getContractDataMapEntry(requestParameters: GetContractDataMapEntryRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractDataMapEntryRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get contract events using a contract ID + * Retrieves a list of events that have been triggered by a given `contract_id` * Get contract events */ - async getContractEventsByIdRaw(requestParameters: GetContractEventsByIdRequest): Promise> { + async getContractEventsByIdRaw(requestParameters: GetContractEventsByIdRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.contractId === null || requestParameters.contractId === undefined) { throw new runtime.RequiredError('contractId','Required parameter requestParameters.contractId was null or undefined when calling getContractEventsById.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.limit !== undefined) { queryParameters['limit'] = requestParameters.limit; @@ -355,6 +393,10 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts queryParameters['offset'] = requestParameters.offset; } + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + const headerParameters: runtime.HTTPHeaders = {}; const response = await this.request({ @@ -362,25 +404,25 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response); } /** - * Get contract events using a contract ID + * Retrieves a list of events that have been triggered by a given `contract_id` * Get contract events */ - async getContractEventsById(requestParameters: GetContractEventsByIdRequest): Promise { - const response = await this.getContractEventsByIdRaw(requestParameters); + async getContractEventsById(requestParameters: GetContractEventsByIdRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractEventsByIdRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get contract interface using a `contract_address` and `contract name` + * Retrieves a contract interface with a given `contract_address` and `contract name` * Get contract interface */ - async getContractInterfaceRaw(requestParameters: GetContractInterfaceRequest): Promise> { + async getContractInterfaceRaw(requestParameters: GetContractInterfaceRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.contractAddress === null || requestParameters.contractAddress === undefined) { throw new runtime.RequiredError('contractAddress','Required parameter requestParameters.contractAddress was null or undefined when calling getContractInterface.'); } @@ -389,7 +431,7 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts throw new runtime.RequiredError('contractName','Required parameter requestParameters.contractName was null or undefined when calling getContractInterface.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.tip !== undefined) { queryParameters['tip'] = requestParameters.tip; @@ -402,25 +444,25 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => ContractInterfaceResponseFromJSON(jsonValue)); } /** - * Get contract interface using a `contract_address` and `contract name` + * Retrieves a contract interface with a given `contract_address` and `contract name` * Get contract interface */ - async getContractInterface(requestParameters: GetContractInterfaceRequest): Promise { - const response = await this.getContractInterfaceRaw(requestParameters); + async getContractInterface(requestParameters: GetContractInterfaceRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractInterfaceRaw(requestParameters, initOverrides); return await response.value(); } /** - * Returns the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data + * Retrieves the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data * Get contract source */ - async getContractSourceRaw(requestParameters: GetContractSourceRequest): Promise> { + async getContractSourceRaw(requestParameters: GetContractSourceRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.contractAddress === null || requestParameters.contractAddress === undefined) { throw new runtime.RequiredError('contractAddress','Required parameter requestParameters.contractAddress was null or undefined when calling getContractSource.'); } @@ -429,7 +471,7 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts throw new runtime.RequiredError('contractName','Required parameter requestParameters.contractName was null or undefined when calling getContractSource.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.proof !== undefined) { queryParameters['proof'] = requestParameters.proof; @@ -446,17 +488,61 @@ export class SmartContractsApi extends runtime.BaseAPI implements SmartContracts method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => ContractSourceResponseFromJSON(jsonValue)); } /** - * Returns the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data + * Retrieves the Clarity source code of a given contract, along with the block height it was published in, and the MARF proof for the data * Get contract source */ - async getContractSource(requestParameters: GetContractSourceRequest): Promise { - const response = await this.getContractSourceRaw(requestParameters); + async getContractSource(requestParameters: GetContractSourceRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractSourceRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of contracts based on the following traits listed in JSON format - functions, variables, maps, fungible tokens and non-fungible tokens + * Get contracts by trait + */ + async getContractsByTraitRaw(requestParameters: GetContractsByTraitRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.traitAbi === null || requestParameters.traitAbi === undefined) { + throw new runtime.RequiredError('traitAbi','Required parameter requestParameters.traitAbi was null or undefined when calling getContractsByTrait.'); + } + + const queryParameters: any = {}; + + if (requestParameters.traitAbi !== undefined) { + queryParameters['trait_abi'] = requestParameters.traitAbi; + } + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/contract/by_trait`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => ContractListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of contracts based on the following traits listed in JSON format - functions, variables, maps, fungible tokens and non-fungible tokens + * Get contracts by trait + */ + async getContractsByTrait(requestParameters: GetContractsByTraitRequest, initOverrides?: RequestInit): Promise { + const response = await this.getContractsByTraitRaw(requestParameters, initOverrides); return await response.value(); } diff --git a/client/src/generated/apis/StackingApi.ts b/client/src/generated/apis/StackingApi.ts new file mode 100644 index 0000000000..e48599ad02 --- /dev/null +++ b/client/src/generated/apis/StackingApi.ts @@ -0,0 +1,113 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + PoolDelegationsResponse, + PoolDelegationsResponseFromJSON, + PoolDelegationsResponseToJSON, +} from '../models'; + +export interface GetPoolDelegationsRequest { + poolPrincipal: string; + afterBlock?: number; + unanchored?: boolean; + limit?: number; + offset?: number; +} + +/** + * StackingApi - interface + * + * @export + * @interface StackingApiInterface + */ +export interface StackingApiInterface { + /** + * Retrieves the list of stacking pool members for a given delegator principal. + * @summary Stacking pool members + * @param {string} poolPrincipal Address principal of the stacking pool delegator + * @param {number} [afterBlock] If specified, only delegation events after the given block will be included + * @param {boolean} [unanchored] whether or not to include Stackers from unconfirmed transactions + * @param {number} [limit] number of items to return + * @param {number} [offset] number of items to skip + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StackingApiInterface + */ + getPoolDelegationsRaw(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the list of stacking pool members for a given delegator principal. + * Stacking pool members + */ + getPoolDelegations(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise; + +} + +/** + * + */ +export class StackingApi extends runtime.BaseAPI implements StackingApiInterface { + + /** + * Retrieves the list of stacking pool members for a given delegator principal. + * Stacking pool members + */ + async getPoolDelegationsRaw(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.poolPrincipal === null || requestParameters.poolPrincipal === undefined) { + throw new runtime.RequiredError('poolPrincipal','Required parameter requestParameters.poolPrincipal was null or undefined when calling getPoolDelegations.'); + } + + const queryParameters: any = {}; + + if (requestParameters.afterBlock !== undefined) { + queryParameters['after_block'] = requestParameters.afterBlock; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/beta/stacking/{pool_principal}/delegations`.replace(`{${"pool_principal"}}`, encodeURIComponent(String(requestParameters.poolPrincipal))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => PoolDelegationsResponseFromJSON(jsonValue)); + } + + /** + * Retrieves the list of stacking pool members for a given delegator principal. + * Stacking pool members + */ + async getPoolDelegations(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise { + const response = await this.getPoolDelegationsRaw(requestParameters, initOverrides); + return await response.value(); + } + +} diff --git a/client/src/generated/apis/StackingRewardsApi.ts b/client/src/generated/apis/StackingRewardsApi.ts new file mode 100644 index 0000000000..b1facee70b --- /dev/null +++ b/client/src/generated/apis/StackingRewardsApi.ts @@ -0,0 +1,339 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + BurnchainRewardListResponse, + BurnchainRewardListResponseFromJSON, + BurnchainRewardListResponseToJSON, + BurnchainRewardSlotHolderListResponse, + BurnchainRewardSlotHolderListResponseFromJSON, + BurnchainRewardSlotHolderListResponseToJSON, + BurnchainRewardsTotal, + BurnchainRewardsTotalFromJSON, + BurnchainRewardsTotalToJSON, +} from '../models'; + +export interface GetBurnchainRewardListRequest { + limit?: number; + offset?: number; +} + +export interface GetBurnchainRewardListByAddressRequest { + address: string; + limit?: number; + offset?: number; +} + +export interface GetBurnchainRewardSlotHoldersRequest { + limit?: number; + offset?: number; +} + +export interface GetBurnchainRewardSlotHoldersByAddressRequest { + address: string; + limit?: number; + offset?: number; +} + +export interface GetBurnchainRewardsTotalByAddressRequest { + address: string; +} + +/** + * StackingRewardsApi - interface + * + * @export + * @interface StackingRewardsApiInterface + */ +export interface StackingRewardsApiInterface { + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info + * @summary Get recent burnchain reward recipients + * @param {number} [limit] max number of rewards to fetch + * @param {number} [offset] index of first rewards to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StackingRewardsApiInterface + */ + getBurnchainRewardListRaw(requestParameters: GetBurnchainRewardListRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info + * Get recent burnchain reward recipients + */ + getBurnchainRewardList(requestParameters: GetBurnchainRewardListRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info + * @summary Get recent burnchain reward for the given recipient + * @param {string} address Reward recipient address. Should either be in the native burnchain\'s format (e.g. B58 for Bitcoin), or if a STX principal address is provided it will be encoded as into the equivalent burnchain format + * @param {number} [limit] max number of rewards to fetch + * @param {number} [offset] index of first rewards to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StackingRewardsApiInterface + */ + getBurnchainRewardListByAddressRaw(requestParameters: GetBurnchainRewardListByAddressRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info + * Get recent burnchain reward for the given recipient + */ + getBurnchainRewardListByAddress(requestParameters: GetBurnchainRewardListByAddressRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments. + * @summary Get recent reward slot holders + * @param {number} [limit] max number of items to fetch + * @param {number} [offset] index of the first items to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StackingRewardsApiInterface + */ + getBurnchainRewardSlotHoldersRaw(requestParameters: GetBurnchainRewardSlotHoldersRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments. + * Get recent reward slot holders + */ + getBurnchainRewardSlotHolders(requestParameters: GetBurnchainRewardSlotHoldersRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments for a given reward slot holder recipient address. + * @summary Get recent reward slot holder entries for the given address + * @param {string} address Reward slot holder recipient address. Should either be in the native burnchain\'s format (e.g. B58 for Bitcoin), or if a STX principal address is provided it will be encoded as into the equivalent burnchain format + * @param {number} [limit] max number of items to fetch + * @param {number} [offset] index of the first items to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StackingRewardsApiInterface + */ + getBurnchainRewardSlotHoldersByAddressRaw(requestParameters: GetBurnchainRewardSlotHoldersByAddressRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments for a given reward slot holder recipient address. + * Get recent reward slot holder entries for the given address + */ + getBurnchainRewardSlotHoldersByAddress(requestParameters: GetBurnchainRewardSlotHoldersByAddressRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves the total burnchain (e.g. Bitcoin) rewards for a given recipient `address` + * @summary Get total burnchain rewards for the given recipient + * @param {string} address Reward recipient address. Should either be in the native burnchain\'s format (e.g. B58 for Bitcoin), or if a STX principal address is provided it will be encoded as into the equivalent burnchain format + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StackingRewardsApiInterface + */ + getBurnchainRewardsTotalByAddressRaw(requestParameters: GetBurnchainRewardsTotalByAddressRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the total burnchain (e.g. Bitcoin) rewards for a given recipient `address` + * Get total burnchain rewards for the given recipient + */ + getBurnchainRewardsTotalByAddress(requestParameters: GetBurnchainRewardsTotalByAddressRequest, initOverrides?: RequestInit): Promise; + +} + +/** + * + */ +export class StackingRewardsApi extends runtime.BaseAPI implements StackingRewardsApiInterface { + + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info + * Get recent burnchain reward recipients + */ + async getBurnchainRewardListRaw(requestParameters: GetBurnchainRewardListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/burnchain/rewards`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) reward recipients with the associated amounts and block info + * Get recent burnchain reward recipients + */ + async getBurnchainRewardList(requestParameters: GetBurnchainRewardListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBurnchainRewardListRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info + * Get recent burnchain reward for the given recipient + */ + async getBurnchainRewardListByAddressRaw(requestParameters: GetBurnchainRewardListByAddressRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.address === null || requestParameters.address === undefined) { + throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling getBurnchainRewardListByAddress.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/burnchain/rewards/{address}`.replace(`{${"address"}}`, encodeURIComponent(String(requestParameters.address))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of recent burnchain (e.g. Bitcoin) rewards for the given recipient with the associated amounts and block info + * Get recent burnchain reward for the given recipient + */ + async getBurnchainRewardListByAddress(requestParameters: GetBurnchainRewardListByAddressRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBurnchainRewardListByAddressRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments. + * Get recent reward slot holders + */ + async getBurnchainRewardSlotHoldersRaw(requestParameters: GetBurnchainRewardSlotHoldersRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/burnchain/reward_slot_holders`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardSlotHolderListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments. + * Get recent reward slot holders + */ + async getBurnchainRewardSlotHolders(requestParameters: GetBurnchainRewardSlotHoldersRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBurnchainRewardSlotHoldersRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments for a given reward slot holder recipient address. + * Get recent reward slot holder entries for the given address + */ + async getBurnchainRewardSlotHoldersByAddressRaw(requestParameters: GetBurnchainRewardSlotHoldersByAddressRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.address === null || requestParameters.address === undefined) { + throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling getBurnchainRewardSlotHoldersByAddress.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/burnchain/reward_slot_holders/{address}`.replace(`{${"address"}}`, encodeURIComponent(String(requestParameters.address))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardSlotHolderListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves a list of the Bitcoin addresses that would validly receive Proof-of-Transfer commitments for a given reward slot holder recipient address. + * Get recent reward slot holder entries for the given address + */ + async getBurnchainRewardSlotHoldersByAddress(requestParameters: GetBurnchainRewardSlotHoldersByAddressRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBurnchainRewardSlotHoldersByAddressRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves the total burnchain (e.g. Bitcoin) rewards for a given recipient `address` + * Get total burnchain rewards for the given recipient + */ + async getBurnchainRewardsTotalByAddressRaw(requestParameters: GetBurnchainRewardsTotalByAddressRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.address === null || requestParameters.address === undefined) { + throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling getBurnchainRewardsTotalByAddress.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/burnchain/rewards/{address}/total`.replace(`{${"address"}}`, encodeURIComponent(String(requestParameters.address))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => BurnchainRewardsTotalFromJSON(jsonValue)); + } + + /** + * Retrieves the total burnchain (e.g. Bitcoin) rewards for a given recipient `address` + * Get total burnchain rewards for the given recipient + */ + async getBurnchainRewardsTotalByAddress(requestParameters: GetBurnchainRewardsTotalByAddressRequest, initOverrides?: RequestInit): Promise { + const response = await this.getBurnchainRewardsTotalByAddressRaw(requestParameters, initOverrides); + return await response.value(); + } + +} diff --git a/client/src/generated/apis/TransactionsApi.ts b/client/src/generated/apis/TransactionsApi.ts index 8f24ec9133..63b6fe9899 100644 --- a/client/src/generated/apis/TransactionsApi.ts +++ b/client/src/generated/apis/TransactionsApi.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -15,35 +15,91 @@ import * as runtime from '../runtime'; import { + GetRawTransactionResult, + GetRawTransactionResultFromJSON, + GetRawTransactionResultToJSON, MempoolTransactionListResponse, MempoolTransactionListResponseFromJSON, MempoolTransactionListResponseToJSON, + MempoolTransactionStatsResponse, + MempoolTransactionStatsResponseFromJSON, + MempoolTransactionStatsResponseToJSON, PostCoreNodeTransactionsError, PostCoreNodeTransactionsErrorFromJSON, PostCoreNodeTransactionsErrorToJSON, + TransactionEventsResponse, + TransactionEventsResponseFromJSON, + TransactionEventsResponseToJSON, TransactionResults, TransactionResultsFromJSON, TransactionResultsToJSON, } from '../models'; +export interface GetAddressMempoolTransactionsRequest { + address: string; + limit?: number; + offset?: number; + unanchored?: boolean; +} + +export interface GetDroppedMempoolTransactionListRequest { + limit?: number; + offset?: number; +} + +export interface GetFilteredEventsRequest { + txId?: string; + address?: string; + limit?: number; + offset?: number; + type?: Array; +} + export interface GetMempoolTransactionListRequest { senderAddress?: string; recipientAddress?: string; address?: string; limit?: number; offset?: number; + unanchored?: boolean; +} + +export interface GetRawTransactionByIdRequest { + txId: string; } export interface GetTransactionByIdRequest { txId: string; eventOffset?: number; eventLimit?: number; + unanchored?: boolean; } export interface GetTransactionListRequest { limit?: number; offset?: number; type?: Array; + unanchored?: boolean; +} + +export interface GetTransactionsByBlockHashRequest { + blockHash: string; + limit?: number; + offset?: number; +} + +export interface GetTransactionsByBlockHeightRequest { + height: number; + limit?: number; + offset?: number; + unanchored?: boolean; +} + +export interface GetTxListDetailsRequest { + txId: Array; + eventOffset?: number; + eventLimit?: number; + unanchored?: boolean; } export interface PostCoreNodeTransactionsRequest { @@ -58,76 +114,222 @@ export interface PostCoreNodeTransactionsRequest { */ export interface TransactionsApiInterface { /** - * Get all recently-broadcast mempool transactions + * Retrieves all transactions for a given address that are currently in mempool + * @summary Transactions for address + * @param {string} address Transactions for the address + * @param {number} [limit] max number of transactions to fetch + * @param {number} [offset] index of first transaction to fetch + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getAddressMempoolTransactionsRaw(requestParameters: GetAddressMempoolTransactionsRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves all transactions for a given address that are currently in mempool + * Transactions for address + */ + getAddressMempoolTransactions(requestParameters: GetAddressMempoolTransactionsRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves all recently-broadcast transactions that have been dropped from the mempool. Transactions are dropped from the mempool if: * they were stale and awaiting garbage collection or, * were expensive, or * were replaced with a new fee + * @summary Get dropped mempool transactions + * @param {number} [limit] max number of mempool transactions to fetch + * @param {number} [offset] index of first mempool transaction to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getDroppedMempoolTransactionListRaw(requestParameters: GetDroppedMempoolTransactionListRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves all recently-broadcast transactions that have been dropped from the mempool. Transactions are dropped from the mempool if: * they were stale and awaiting garbage collection or, * were expensive, or * were replaced with a new fee + * Get dropped mempool transactions + */ + getDroppedMempoolTransactionList(requestParameters: GetDroppedMempoolTransactionListRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves the list of events filtered by principal (STX address or Smart Contract ID), transaction id or event types. The list of event types is (\'smart_contract_log\', \'stx_lock\', \'stx_asset\', \'fungible_token_asset\', \'non_fungible_token_asset\'). + * @summary Transaction Events + * @param {string} [txId] Hash of transaction + * @param {string} [address] Stacks address or a Contract identifier + * @param {number} [limit] number of items to return + * @param {number} [offset] number of items to skip + * @param {Array<'smart_contract_log' | 'stx_lock' | 'stx_asset' | 'fungible_token_asset' | 'non_fungible_token_asset'>} [type] Filter the events on event type + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getFilteredEventsRaw(requestParameters: GetFilteredEventsRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves the list of events filtered by principal (STX address or Smart Contract ID), transaction id or event types. The list of event types is (\'smart_contract_log\', \'stx_lock\', \'stx_asset\', \'fungible_token_asset\', \'non_fungible_token_asset\'). + * Transaction Events + */ + getFilteredEvents(requestParameters: GetFilteredEventsRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves all transactions that have been recently broadcast to the mempool. These are pending transactions awaiting confirmation. If you need to monitor new transactions, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * @summary Get mempool transactions - * @param {string} [senderAddress] Filter to only STX transfer transactions with this sender address. - * @param {string} [recipientAddress] Filter to only STX transfer transactions with this recipient address. - * @param {string} [address] Filter to only show STX transfer transactions with this address as the recipient or sender. + * @param {string} [senderAddress] Filter to only return transactions with this sender address. + * @param {string} [recipientAddress] Filter to only return transactions with this recipient address (only applicable for STX transfer tx types). + * @param {string} [address] Filter to only return transactions with this address as the sender or recipient (recipient only applicable for STX transfer tx types). * @param {number} [limit] max number of mempool transactions to fetch * @param {number} [offset] index of first mempool transaction to fetch + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof TransactionsApiInterface */ - getMempoolTransactionListRaw(requestParameters: GetMempoolTransactionListRequest): Promise>; + getMempoolTransactionListRaw(requestParameters: GetMempoolTransactionListRequest, initOverrides?: RequestInit): Promise>; /** - * Get all recently-broadcast mempool transactions + * Retrieves all transactions that have been recently broadcast to the mempool. These are pending transactions awaiting confirmation. If you need to monitor new transactions, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get mempool transactions */ - getMempoolTransactionList(requestParameters: GetMempoolTransactionListRequest): Promise; + getMempoolTransactionList(requestParameters: GetMempoolTransactionListRequest, initOverrides?: RequestInit): Promise; + + /** + * Queries for transactions counts, age (by block height), fees (simple average), and size. All results broken down by transaction type and percentiles (p25, p50, p75, p95). + * @summary Get statistics for mempool transactions + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getMempoolTransactionStatsRaw(initOverrides?: RequestInit): Promise>; /** - * Get a specific transaction by ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * Queries for transactions counts, age (by block height), fees (simple average), and size. All results broken down by transaction type and percentiles (p25, p50, p75, p95). + * Get statistics for mempool transactions + */ + getMempoolTransactionStats(initOverrides?: RequestInit): Promise; + + /** + * Retrieves a hex encoded serialized transaction for a given ID + * @summary Get Raw Transaction + * @param {string} txId Hash of transaction + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getRawTransactionByIdRaw(requestParameters: GetRawTransactionByIdRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a hex encoded serialized transaction for a given ID + * Get Raw Transaction + */ + getRawTransactionById(requestParameters: GetRawTransactionByIdRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves transaction details for a given transaction ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` * @summary Get transaction * @param {string} txId Hash of transaction * @param {number} [eventOffset] The number of events to skip * @param {number} [eventLimit] The numbers of events to return + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof TransactionsApiInterface */ - getTransactionByIdRaw(requestParameters: GetTransactionByIdRequest): Promise>; + getTransactionByIdRaw(requestParameters: GetTransactionByIdRequest, initOverrides?: RequestInit): Promise>; /** - * Get a specific transaction by ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * Retrieves transaction details for a given transaction ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` * Get transaction */ - getTransactionById(requestParameters: GetTransactionByIdRequest): Promise; + getTransactionById(requestParameters: GetTransactionByIdRequest, initOverrides?: RequestInit): Promise; /** - * Get all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` + * Retrieves all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` * @summary Get recent transactions * @param {number} [limit] max number of transactions to fetch * @param {number} [offset] index of first transaction to fetch * @param {Array<'coinbase' | 'token_transfer' | 'smart_contract' | 'contract_call' | 'poison_microblock'>} [type] Filter by transaction type + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof TransactionsApiInterface */ - getTransactionListRaw(requestParameters: GetTransactionListRequest): Promise>; + getTransactionListRaw(requestParameters: GetTransactionListRequest, initOverrides?: RequestInit): Promise>; /** - * Get all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` + * Retrieves all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` * Get recent transactions */ - getTransactionList(requestParameters: GetTransactionListRequest): Promise; + getTransactionList(requestParameters: GetTransactionListRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of all transactions within a block for a given block hash. + * @summary Transactions by block hash + * @param {string} blockHash Hash of block + * @param {number} [limit] max number of transactions to fetch + * @param {number} [offset] index of first transaction to fetch + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getTransactionsByBlockHashRaw(requestParameters: GetTransactionsByBlockHashRequest, initOverrides?: RequestInit): Promise>; /** - * Broadcast raw transactions on the network. You can use the [@stacks/transactions](https://github.com/hirosystems/stacks.js) project to generate a raw transaction payload. + * Retrieves a list of all transactions within a block for a given block hash. + * Transactions by block hash + */ + getTransactionsByBlockHash(requestParameters: GetTransactionsByBlockHashRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves all transactions within a block at a given height + * @summary Transactions by block height + * @param {number} height Height of block + * @param {number} [limit] max number of transactions to fetch + * @param {number} [offset] index of first transaction to fetch + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getTransactionsByBlockHeightRaw(requestParameters: GetTransactionsByBlockHeightRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves all transactions within a block at a given height + * Transactions by block height + */ + getTransactionsByBlockHeight(requestParameters: GetTransactionsByBlockHeightRequest, initOverrides?: RequestInit): Promise; + + /** + * Retrieves a list of transactions for a given list of transaction IDs If using TypeScript, import typings for this response from our types package: `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * @summary Get list of details for transactions + * @param {Array} txId Array of transaction ids + * @param {number} [eventOffset] The number of events to skip + * @param {number} [eventLimit] The numbers of events to return + * @param {boolean} [unanchored] Include transaction data from unanchored (i.e. unconfirmed) microblocks + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof TransactionsApiInterface + */ + getTxListDetailsRaw(requestParameters: GetTxListDetailsRequest, initOverrides?: RequestInit): Promise>; + + /** + * Retrieves a list of transactions for a given list of transaction IDs If using TypeScript, import typings for this response from our types package: `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * Get list of details for transactions + */ + getTxListDetails(requestParameters: GetTxListDetailsRequest, initOverrides?: RequestInit): Promise<{ [key: string]: object; }>; + + /** + * Broadcasts raw transactions on the network. You can use the [@stacks/transactions](https://github.com/blockstack/stacks.js) project to generate a raw transaction payload. * @summary Broadcast raw transaction * @param {Blob} [body] * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof TransactionsApiInterface */ - postCoreNodeTransactionsRaw(requestParameters: PostCoreNodeTransactionsRequest): Promise>; + postCoreNodeTransactionsRaw(requestParameters: PostCoreNodeTransactionsRequest, initOverrides?: RequestInit): Promise>; /** - * Broadcast raw transactions on the network. You can use the [@stacks/transactions](https://github.com/hirosystems/stacks.js) project to generate a raw transaction payload. + * Broadcasts raw transactions on the network. You can use the [@stacks/transactions](https://github.com/blockstack/stacks.js) project to generate a raw transaction payload. * Broadcast raw transaction */ - postCoreNodeTransactions(requestParameters: PostCoreNodeTransactionsRequest): Promise; + postCoreNodeTransactions(requestParameters: PostCoreNodeTransactionsRequest, initOverrides?: RequestInit): Promise; } @@ -137,11 +339,139 @@ export interface TransactionsApiInterface { export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiInterface { /** - * Get all recently-broadcast mempool transactions + * Retrieves all transactions for a given address that are currently in mempool + * Transactions for address + */ + async getAddressMempoolTransactionsRaw(requestParameters: GetAddressMempoolTransactionsRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.address === null || requestParameters.address === undefined) { + throw new runtime.RequiredError('address','Required parameter requestParameters.address was null or undefined when calling getAddressMempoolTransactions.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/address/{address}/mempool`.replace(`{${"address"}}`, encodeURIComponent(String(requestParameters.address))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => MempoolTransactionListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves all transactions for a given address that are currently in mempool + * Transactions for address + */ + async getAddressMempoolTransactions(requestParameters: GetAddressMempoolTransactionsRequest, initOverrides?: RequestInit): Promise { + const response = await this.getAddressMempoolTransactionsRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves all recently-broadcast transactions that have been dropped from the mempool. Transactions are dropped from the mempool if: * they were stale and awaiting garbage collection or, * were expensive, or * were replaced with a new fee + * Get dropped mempool transactions + */ + async getDroppedMempoolTransactionListRaw(requestParameters: GetDroppedMempoolTransactionListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tx/mempool/dropped`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => MempoolTransactionListResponseFromJSON(jsonValue)); + } + + /** + * Retrieves all recently-broadcast transactions that have been dropped from the mempool. Transactions are dropped from the mempool if: * they were stale and awaiting garbage collection or, * were expensive, or * were replaced with a new fee + * Get dropped mempool transactions + */ + async getDroppedMempoolTransactionList(requestParameters: GetDroppedMempoolTransactionListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getDroppedMempoolTransactionListRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves the list of events filtered by principal (STX address or Smart Contract ID), transaction id or event types. The list of event types is (\'smart_contract_log\', \'stx_lock\', \'stx_asset\', \'fungible_token_asset\', \'non_fungible_token_asset\'). + * Transaction Events + */ + async getFilteredEventsRaw(requestParameters: GetFilteredEventsRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + if (requestParameters.txId !== undefined) { + queryParameters['tx_id'] = requestParameters.txId; + } + + if (requestParameters.address !== undefined) { + queryParameters['address'] = requestParameters.address; + } + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.type) { + queryParameters['type'] = requestParameters.type; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tx/events`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => TransactionEventsResponseFromJSON(jsonValue)); + } + + /** + * Retrieves the list of events filtered by principal (STX address or Smart Contract ID), transaction id or event types. The list of event types is (\'smart_contract_log\', \'stx_lock\', \'stx_asset\', \'fungible_token_asset\', \'non_fungible_token_asset\'). + * Transaction Events + */ + async getFilteredEvents(requestParameters: GetFilteredEventsRequest, initOverrides?: RequestInit): Promise { + const response = await this.getFilteredEventsRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves all transactions that have been recently broadcast to the mempool. These are pending transactions awaiting confirmation. If you need to monitor new transactions, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get mempool transactions */ - async getMempoolTransactionListRaw(requestParameters: GetMempoolTransactionListRequest): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getMempoolTransactionListRaw(requestParameters: GetMempoolTransactionListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; if (requestParameters.senderAddress !== undefined) { queryParameters['sender_address'] = requestParameters.senderAddress; @@ -163,6 +493,10 @@ export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiI queryParameters['offset'] = requestParameters.offset; } + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + const headerParameters: runtime.HTTPHeaders = {}; const response = await this.request({ @@ -170,30 +504,90 @@ export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiI method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => MempoolTransactionListResponseFromJSON(jsonValue)); } /** - * Get all recently-broadcast mempool transactions + * Retrieves all transactions that have been recently broadcast to the mempool. These are pending transactions awaiting confirmation. If you need to monitor new transactions, we highly recommend subscribing to [WebSockets or Socket.io](https://github.com/hirosystems/stacks-blockchain-api/tree/master/client) for real-time updates. * Get mempool transactions */ - async getMempoolTransactionList(requestParameters: GetMempoolTransactionListRequest): Promise { - const response = await this.getMempoolTransactionListRaw(requestParameters); + async getMempoolTransactionList(requestParameters: GetMempoolTransactionListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getMempoolTransactionListRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get a specific transaction by ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * Queries for transactions counts, age (by block height), fees (simple average), and size. All results broken down by transaction type and percentiles (p25, p50, p75, p95). + * Get statistics for mempool transactions + */ + async getMempoolTransactionStatsRaw(initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tx/mempool/stats`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => MempoolTransactionStatsResponseFromJSON(jsonValue)); + } + + /** + * Queries for transactions counts, age (by block height), fees (simple average), and size. All results broken down by transaction type and percentiles (p25, p50, p75, p95). + * Get statistics for mempool transactions + */ + async getMempoolTransactionStats(initOverrides?: RequestInit): Promise { + const response = await this.getMempoolTransactionStatsRaw(initOverrides); + return await response.value(); + } + + /** + * Retrieves a hex encoded serialized transaction for a given ID + * Get Raw Transaction + */ + async getRawTransactionByIdRaw(requestParameters: GetRawTransactionByIdRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.txId === null || requestParameters.txId === undefined) { + throw new runtime.RequiredError('txId','Required parameter requestParameters.txId was null or undefined when calling getRawTransactionById.'); + } + + const queryParameters: any = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tx/{tx_id}/raw`.replace(`{${"tx_id"}}`, encodeURIComponent(String(requestParameters.txId))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => GetRawTransactionResultFromJSON(jsonValue)); + } + + /** + * Retrieves a hex encoded serialized transaction for a given ID + * Get Raw Transaction + */ + async getRawTransactionById(requestParameters: GetRawTransactionByIdRequest, initOverrides?: RequestInit): Promise { + const response = await this.getRawTransactionByIdRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves transaction details for a given transaction ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` * Get transaction */ - async getTransactionByIdRaw(requestParameters: GetTransactionByIdRequest): Promise> { + async getTransactionByIdRaw(requestParameters: GetTransactionByIdRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.txId === null || requestParameters.txId === undefined) { throw new runtime.RequiredError('txId','Required parameter requestParameters.txId was null or undefined when calling getTransactionById.'); } - const queryParameters: runtime.HTTPQuery = {}; + const queryParameters: any = {}; if (requestParameters.eventOffset !== undefined) { queryParameters['event_offset'] = requestParameters.eventOffset; @@ -203,6 +597,10 @@ export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiI queryParameters['event_limit'] = requestParameters.eventLimit; } + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + const headerParameters: runtime.HTTPHeaders = {}; const response = await this.request({ @@ -210,26 +608,26 @@ export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiI method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response); } /** - * Get a specific transaction by ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * Retrieves transaction details for a given transaction ID `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` * Get transaction */ - async getTransactionById(requestParameters: GetTransactionByIdRequest): Promise { - const response = await this.getTransactionByIdRaw(requestParameters); + async getTransactionById(requestParameters: GetTransactionByIdRequest, initOverrides?: RequestInit): Promise { + const response = await this.getTransactionByIdRaw(requestParameters, initOverrides); return await response.value(); } /** - * Get all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` + * Retrieves all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` * Get recent transactions */ - async getTransactionListRaw(requestParameters: GetTransactionListRequest): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async getTransactionListRaw(requestParameters: GetTransactionListRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; if (requestParameters.limit !== undefined) { queryParameters['limit'] = requestParameters.limit; @@ -243,6 +641,10 @@ export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiI queryParameters['type'] = requestParameters.type; } + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + const headerParameters: runtime.HTTPHeaders = {}; const response = await this.request({ @@ -250,26 +652,158 @@ export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiI method: 'GET', headers: headerParameters, query: queryParameters, - }); + }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => TransactionResultsFromJSON(jsonValue)); } /** - * Get all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` + * Retrieves all recently mined transactions If using TypeScript, import typings for this response from our types package: `import type { TransactionResults } from \'@stacks/stacks-blockchain-api-types\';` * Get recent transactions */ - async getTransactionList(requestParameters: GetTransactionListRequest): Promise { - const response = await this.getTransactionListRaw(requestParameters); + async getTransactionList(requestParameters: GetTransactionListRequest, initOverrides?: RequestInit): Promise { + const response = await this.getTransactionListRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of all transactions within a block for a given block hash. + * Transactions by block hash + */ + async getTransactionsByBlockHashRaw(requestParameters: GetTransactionsByBlockHashRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.blockHash === null || requestParameters.blockHash === undefined) { + throw new runtime.RequiredError('blockHash','Required parameter requestParameters.blockHash was null or undefined when calling getTransactionsByBlockHash.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tx/block/{block_hash}`.replace(`{${"block_hash"}}`, encodeURIComponent(String(requestParameters.blockHash))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => TransactionResultsFromJSON(jsonValue)); + } + + /** + * Retrieves a list of all transactions within a block for a given block hash. + * Transactions by block hash + */ + async getTransactionsByBlockHash(requestParameters: GetTransactionsByBlockHashRequest, initOverrides?: RequestInit): Promise { + const response = await this.getTransactionsByBlockHashRaw(requestParameters, initOverrides); return await response.value(); } /** - * Broadcast raw transactions on the network. You can use the [@stacks/transactions](https://github.com/hirosystems/stacks.js) project to generate a raw transaction payload. + * Retrieves all transactions within a block at a given height + * Transactions by block height + */ + async getTransactionsByBlockHeightRaw(requestParameters: GetTransactionsByBlockHeightRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.height === null || requestParameters.height === undefined) { + throw new runtime.RequiredError('height','Required parameter requestParameters.height was null or undefined when calling getTransactionsByBlockHeight.'); + } + + const queryParameters: any = {}; + + if (requestParameters.limit !== undefined) { + queryParameters['limit'] = requestParameters.limit; + } + + if (requestParameters.offset !== undefined) { + queryParameters['offset'] = requestParameters.offset; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tx/block_height/{height}`.replace(`{${"height"}}`, encodeURIComponent(String(requestParameters.height))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response, (jsonValue) => TransactionResultsFromJSON(jsonValue)); + } + + /** + * Retrieves all transactions within a block at a given height + * Transactions by block height + */ + async getTransactionsByBlockHeight(requestParameters: GetTransactionsByBlockHeightRequest, initOverrides?: RequestInit): Promise { + const response = await this.getTransactionsByBlockHeightRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Retrieves a list of transactions for a given list of transaction IDs If using TypeScript, import typings for this response from our types package: `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * Get list of details for transactions + */ + async getTxListDetailsRaw(requestParameters: GetTxListDetailsRequest, initOverrides?: RequestInit): Promise> { + if (requestParameters.txId === null || requestParameters.txId === undefined) { + throw new runtime.RequiredError('txId','Required parameter requestParameters.txId was null or undefined when calling getTxListDetails.'); + } + + const queryParameters: any = {}; + + if (requestParameters.txId) { + queryParameters['tx_id'] = requestParameters.txId; + } + + if (requestParameters.eventOffset !== undefined) { + queryParameters['event_offset'] = requestParameters.eventOffset; + } + + if (requestParameters.eventLimit !== undefined) { + queryParameters['event_limit'] = requestParameters.eventLimit; + } + + if (requestParameters.unanchored !== undefined) { + queryParameters['unanchored'] = requestParameters.unanchored; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/extended/v1/tx/multiple`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }, initOverrides); + + return new runtime.JSONApiResponse(response); + } + + /** + * Retrieves a list of transactions for a given list of transaction IDs If using TypeScript, import typings for this response from our types package: `import type { Transaction } from \'@stacks/stacks-blockchain-api-types\';` + * Get list of details for transactions + */ + async getTxListDetails(requestParameters: GetTxListDetailsRequest, initOverrides?: RequestInit): Promise<{ [key: string]: object; }> { + const response = await this.getTxListDetailsRaw(requestParameters, initOverrides); + return await response.value(); + } + + /** + * Broadcasts raw transactions on the network. You can use the [@stacks/transactions](https://github.com/blockstack/stacks.js) project to generate a raw transaction payload. * Broadcast raw transaction */ - async postCoreNodeTransactionsRaw(requestParameters: PostCoreNodeTransactionsRequest): Promise> { - const queryParameters: runtime.HTTPQuery = {}; + async postCoreNodeTransactionsRaw(requestParameters: PostCoreNodeTransactionsRequest, initOverrides?: RequestInit): Promise> { + const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; @@ -281,22 +815,33 @@ export class TransactionsApi extends runtime.BaseAPI implements TransactionsApiI headers: headerParameters, query: queryParameters, body: requestParameters.body as any, - }); + }, initOverrides); return new runtime.TextApiResponse(response) as any; } /** - * Broadcast raw transactions on the network. You can use the [@stacks/transactions](https://github.com/hirosystems/stacks.js) project to generate a raw transaction payload. + * Broadcasts raw transactions on the network. You can use the [@stacks/transactions](https://github.com/blockstack/stacks.js) project to generate a raw transaction payload. * Broadcast raw transaction */ - async postCoreNodeTransactions(requestParameters: PostCoreNodeTransactionsRequest): Promise { - const response = await this.postCoreNodeTransactionsRaw(requestParameters); + async postCoreNodeTransactions(requestParameters: PostCoreNodeTransactionsRequest, initOverrides?: RequestInit): Promise { + const response = await this.postCoreNodeTransactionsRaw(requestParameters, initOverrides); return await response.value(); } } +/** + * @export + * @enum {string} + */ +export enum GetFilteredEventsTypeEnum { + smart_contract_log = 'smart_contract_log', + stx_lock = 'stx_lock', + stx_asset = 'stx_asset', + fungible_token_asset = 'fungible_token_asset', + non_fungible_token_asset = 'non_fungible_token_asset' +} /** * @export * @enum {string} diff --git a/client/src/generated/apis/index.ts b/client/src/generated/apis/index.ts index 787ee7d15a..11ee668eae 100644 --- a/client/src/generated/apis/index.ts +++ b/client/src/generated/apis/index.ts @@ -1,10 +1,18 @@ +/* tslint:disable */ +/* eslint-disable */ export * from './AccountsApi'; export * from './BlocksApi'; -export * from './BurnchainApi'; export * from './FaucetsApi'; export * from './FeesApi'; +export * from './FungibleTokensApi'; export * from './InfoApi'; +export * from './MempoolApi'; +export * from './MicroblocksApi'; +export * from './NamesApi'; +export * from './NonFungibleTokensApi'; export * from './RosettaApi'; export * from './SearchApi'; export * from './SmartContractsApi'; +export * from './StackingApi'; +export * from './StackingRewardsApi'; export * from './TransactionsApi'; diff --git a/client/src/generated/index.ts b/client/src/generated/index.ts index 848ecfa4d1..be9d1edeef 100644 --- a/client/src/generated/index.ts +++ b/client/src/generated/index.ts @@ -1,3 +1,5 @@ +/* tslint:disable */ +/* eslint-disable */ export * from './runtime'; export * from './apis'; export * from './models'; diff --git a/client/src/generated/models/AccountDataResponse.ts b/client/src/generated/models/AccountDataResponse.ts index 5a6ece43f2..d262747694 100644 --- a/client/src/generated/models/AccountDataResponse.ts +++ b/client/src/generated/models/AccountDataResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -94,4 +94,3 @@ export function AccountDataResponseToJSON(value?: AccountDataResponse | null): a }; } - diff --git a/client/src/generated/models/AddressAssetsListResponse.ts b/client/src/generated/models/AddressAssetsListResponse.ts index 46dec6fa58..b38763213d 100644 --- a/client/src/generated/models/AddressAssetsListResponse.ts +++ b/client/src/generated/models/AddressAssetsListResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -78,4 +78,3 @@ export function AddressAssetsListResponseToJSON(value?: AddressAssetsListRespons }; } - diff --git a/client/src/generated/models/AddressBalanceResponse.ts b/client/src/generated/models/AddressBalanceResponse.ts index 462dd8a500..852dad1590 100644 --- a/client/src/generated/models/AddressBalanceResponse.ts +++ b/client/src/generated/models/AddressBalanceResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,10 +14,14 @@ import { exists, mapValues } from '../runtime'; import { - AddressBalanceResponseStx, - AddressBalanceResponseStxFromJSON, - AddressBalanceResponseStxFromJSONTyped, - AddressBalanceResponseStxToJSON, + AddressTokenOfferingLocked, + AddressTokenOfferingLockedFromJSON, + AddressTokenOfferingLockedFromJSONTyped, + AddressTokenOfferingLockedToJSON, + StxBalance, + StxBalanceFromJSON, + StxBalanceFromJSONTyped, + StxBalanceToJSON, } from './'; /** @@ -28,22 +32,28 @@ import { export interface AddressBalanceResponse { /** * - * @type {AddressBalanceResponseStx} + * @type {StxBalance} * @memberof AddressBalanceResponse */ - stx: AddressBalanceResponseStx; + stx: StxBalance; /** * - * @type {object} + * @type {{ [key: string]: object; }} * @memberof AddressBalanceResponse */ - fungible_tokens: object; + fungible_tokens: { [key: string]: object; }; /** * - * @type {object} + * @type {{ [key: string]: object; }} * @memberof AddressBalanceResponse */ - non_fungible_tokens: object; + non_fungible_tokens: { [key: string]: object; }; + /** + * + * @type {AddressTokenOfferingLocked} + * @memberof AddressBalanceResponse + */ + token_offering_locked?: AddressTokenOfferingLocked; } export function AddressBalanceResponseFromJSON(json: any): AddressBalanceResponse { @@ -56,9 +66,10 @@ export function AddressBalanceResponseFromJSONTyped(json: any, ignoreDiscriminat } return { - 'stx': AddressBalanceResponseStxFromJSON(json['stx']), + 'stx': StxBalanceFromJSON(json['stx']), 'fungible_tokens': json['fungible_tokens'], 'non_fungible_tokens': json['non_fungible_tokens'], + 'token_offering_locked': !exists(json, 'token_offering_locked') ? undefined : AddressTokenOfferingLockedFromJSON(json['token_offering_locked']), }; } @@ -71,10 +82,10 @@ export function AddressBalanceResponseToJSON(value?: AddressBalanceResponse | nu } return { - 'stx': AddressBalanceResponseStxToJSON(value.stx), + 'stx': StxBalanceToJSON(value.stx), 'fungible_tokens': value.fungible_tokens, 'non_fungible_tokens': value.non_fungible_tokens, + 'token_offering_locked': AddressTokenOfferingLockedToJSON(value.token_offering_locked), }; } - diff --git a/client/src/generated/models/AddressNftListResponse.ts b/client/src/generated/models/AddressNftListResponse.ts new file mode 100644 index 0000000000..3bfb1833a0 --- /dev/null +++ b/client/src/generated/models/AddressNftListResponse.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + NftEvent, + NftEventFromJSON, + NftEventFromJSONTyped, + NftEventToJSON, +} from './'; + +/** + * + * @export + * @interface AddressNftListResponse + */ +export interface AddressNftListResponse { + /** + * + * @type {number} + * @memberof AddressNftListResponse + */ + limit: number; + /** + * + * @type {number} + * @memberof AddressNftListResponse + */ + offset: number; + /** + * + * @type {number} + * @memberof AddressNftListResponse + */ + total: number; + /** + * + * @type {Array} + * @memberof AddressNftListResponse + */ + nft_events: Array; +} + +export function AddressNftListResponseFromJSON(json: any): AddressNftListResponse { + return AddressNftListResponseFromJSONTyped(json, false); +} + +export function AddressNftListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressNftListResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'nft_events': ((json['nft_events'] as Array).map(NftEventFromJSON)), + }; +} + +export function AddressNftListResponseToJSON(value?: AddressNftListResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'nft_events': ((value.nft_events as Array).map(NftEventToJSON)), + }; +} + diff --git a/client/src/generated/models/AddressNftListResponseValue.ts b/client/src/generated/models/AddressNftListResponseValue.ts new file mode 100644 index 0000000000..a326400dd7 --- /dev/null +++ b/client/src/generated/models/AddressNftListResponseValue.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Identifier of the NFT + * @export + * @interface AddressNftListResponseValue + */ +export interface AddressNftListResponseValue { + /** + * Hex string representing the identifier of the NFT + * @type {string} + * @memberof AddressNftListResponseValue + */ + hex: string; + /** + * Readable string of the NFT identifier + * @type {string} + * @memberof AddressNftListResponseValue + */ + repr: string; +} + +export function AddressNftListResponseValueFromJSON(json: any): AddressNftListResponseValue { + return AddressNftListResponseValueFromJSONTyped(json, false); +} + +export function AddressNftListResponseValueFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressNftListResponseValue { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'hex': json['hex'], + 'repr': json['repr'], + }; +} + +export function AddressNftListResponseValueToJSON(value?: AddressNftListResponseValue | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'hex': value.hex, + 'repr': value.repr, + }; +} + diff --git a/client/src/generated/models/AddressNonces.ts b/client/src/generated/models/AddressNonces.ts new file mode 100644 index 0000000000..f08de2bf50 --- /dev/null +++ b/client/src/generated/models/AddressNonces.ts @@ -0,0 +1,88 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * The latest nonce values used by an account by inspecting the mempool, microblock transactions, and anchored transactions + * @export + * @interface AddressNonces + */ +export interface AddressNonces { + /** + * The latest nonce found within mempool transactions sent by this address. Will be null if there are no current mempool transactions for this address. + * @type {number} + * @memberof AddressNonces + */ + last_mempool_tx_nonce: number | null; + /** + * The latest nonce found within transactions sent by this address, including unanchored microblock transactions. Will be null if there are no current transactions for this address. + * @type {number} + * @memberof AddressNonces + */ + last_executed_tx_nonce: number | null; + /** + * The likely nonce required for creating the next transaction, based on the last nonces seen by the API. This can be incorrect if the API's mempool or transactions aren't fully synchronized, even by a small amount, or if a previous transaction is still propagating through the Stacks blockchain network when this endpoint is called. + * @type {number} + * @memberof AddressNonces + */ + possible_next_nonce: number; + /** + * Nonces that appear to be missing and likely causing a mempool transaction to be stuck. + * @type {Array} + * @memberof AddressNonces + */ + detected_missing_nonces: Array; + /** + * Nonces currently in mempool for this address. + * @type {Array} + * @memberof AddressNonces + */ + detected_mempool_nonces?: Array; +} + +export function AddressNoncesFromJSON(json: any): AddressNonces { + return AddressNoncesFromJSONTyped(json, false); +} + +export function AddressNoncesFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressNonces { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'last_mempool_tx_nonce': json['last_mempool_tx_nonce'], + 'last_executed_tx_nonce': json['last_executed_tx_nonce'], + 'possible_next_nonce': json['possible_next_nonce'], + 'detected_missing_nonces': json['detected_missing_nonces'], + 'detected_mempool_nonces': !exists(json, 'detected_mempool_nonces') ? undefined : json['detected_mempool_nonces'], + }; +} + +export function AddressNoncesToJSON(value?: AddressNonces | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'last_mempool_tx_nonce': value.last_mempool_tx_nonce, + 'last_executed_tx_nonce': value.last_executed_tx_nonce, + 'possible_next_nonce': value.possible_next_nonce, + 'detected_missing_nonces': value.detected_missing_nonces, + 'detected_mempool_nonces': value.detected_mempool_nonces, + }; +} + diff --git a/client/src/generated/models/AddressStxBalanceResponse.ts b/client/src/generated/models/AddressStxBalanceResponse.ts deleted file mode 100644 index 51f8932dba..0000000000 --- a/client/src/generated/models/AddressStxBalanceResponse.ts +++ /dev/null @@ -1,129 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * GET request that returns address balances - * @export - * @interface AddressStxBalanceResponse - */ -export interface AddressStxBalanceResponse { - /** - * - * @type {string} - * @memberof AddressStxBalanceResponse - */ - balance: string; - /** - * - * @type {string} - * @memberof AddressStxBalanceResponse - */ - total_sent: string; - /** - * - * @type {string} - * @memberof AddressStxBalanceResponse - */ - total_received: string; - /** - * - * @type {string} - * @memberof AddressStxBalanceResponse - */ - total_fees_sent: string; - /** - * - * @type {string} - * @memberof AddressStxBalanceResponse - */ - total_miner_rewards_received: string; - /** - * The transaction where the lock event occurred. Empty if no tokens are locked. - * @type {string} - * @memberof AddressStxBalanceResponse - */ - lock_tx_id: string; - /** - * The amount of locked STX, as string quoted micro-STX. Zero if no tokens are locked. - * @type {string} - * @memberof AddressStxBalanceResponse - */ - locked: string; - /** - * The STX chain block height of when the lock event occurred. Zero if no tokens are locked. - * @type {number} - * @memberof AddressStxBalanceResponse - */ - lock_height: number; - /** - * The burnchain block height of when the lock event occurred. Zero if no tokens are locked. - * @type {number} - * @memberof AddressStxBalanceResponse - */ - burnchain_lock_height: number; - /** - * The burnchain block height of when the tokens unlock. Zero if no tokens are locked. - * @type {number} - * @memberof AddressStxBalanceResponse - */ - burnchain_unlock_height: number; -} - -export function AddressStxBalanceResponseFromJSON(json: any): AddressStxBalanceResponse { - return AddressStxBalanceResponseFromJSONTyped(json, false); -} - -export function AddressStxBalanceResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressStxBalanceResponse { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'balance': json['balance'], - 'total_sent': json['total_sent'], - 'total_received': json['total_received'], - 'total_fees_sent': json['total_fees_sent'], - 'total_miner_rewards_received': json['total_miner_rewards_received'], - 'lock_tx_id': json['lock_tx_id'], - 'locked': json['locked'], - 'lock_height': json['lock_height'], - 'burnchain_lock_height': json['burnchain_lock_height'], - 'burnchain_unlock_height': json['burnchain_unlock_height'], - }; -} - -export function AddressStxBalanceResponseToJSON(value?: AddressStxBalanceResponse | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'balance': value.balance, - 'total_sent': value.total_sent, - 'total_received': value.total_received, - 'total_fees_sent': value.total_fees_sent, - 'total_miner_rewards_received': value.total_miner_rewards_received, - 'lock_tx_id': value.lock_tx_id, - 'locked': value.locked, - 'lock_height': value.lock_height, - 'burnchain_lock_height': value.burnchain_lock_height, - 'burnchain_unlock_height': value.burnchain_unlock_height, - }; -} - - diff --git a/client/src/generated/models/AddressStxInboundListResponse.ts b/client/src/generated/models/AddressStxInboundListResponse.ts new file mode 100644 index 0000000000..ffd7165aee --- /dev/null +++ b/client/src/generated/models/AddressStxInboundListResponse.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + InboundStxTransfer, + InboundStxTransferFromJSON, + InboundStxTransferFromJSONTyped, + InboundStxTransferToJSON, +} from './'; + +/** + * GET request that returns a list of inbound STX transfers with a memo + * @export + * @interface AddressStxInboundListResponse + */ +export interface AddressStxInboundListResponse { + /** + * + * @type {number} + * @memberof AddressStxInboundListResponse + */ + limit: number; + /** + * + * @type {number} + * @memberof AddressStxInboundListResponse + */ + offset: number; + /** + * + * @type {number} + * @memberof AddressStxInboundListResponse + */ + total: number; + /** + * + * @type {Array} + * @memberof AddressStxInboundListResponse + */ + results: Array; +} + +export function AddressStxInboundListResponseFromJSON(json: any): AddressStxInboundListResponse { + return AddressStxInboundListResponseFromJSONTyped(json, false); +} + +export function AddressStxInboundListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressStxInboundListResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': ((json['results'] as Array).map(InboundStxTransferFromJSON)), + }; +} + +export function AddressStxInboundListResponseToJSON(value?: AddressStxInboundListResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': ((value.results as Array).map(InboundStxTransferToJSON)), + }; +} + diff --git a/client/src/generated/models/AddressTokenOfferingLocked.ts b/client/src/generated/models/AddressTokenOfferingLocked.ts new file mode 100644 index 0000000000..8a57a8c7d5 --- /dev/null +++ b/client/src/generated/models/AddressTokenOfferingLocked.ts @@ -0,0 +1,79 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + AddressUnlockSchedule, + AddressUnlockScheduleFromJSON, + AddressUnlockScheduleFromJSONTyped, + AddressUnlockScheduleToJSON, +} from './'; + +/** + * Token Offering Locked + * @export + * @interface AddressTokenOfferingLocked + */ +export interface AddressTokenOfferingLocked { + /** + * Micro-STX amount still locked at current block height. + * @type {string} + * @memberof AddressTokenOfferingLocked + */ + total_locked: string; + /** + * Micro-STX amount unlocked at current block height. + * @type {string} + * @memberof AddressTokenOfferingLocked + */ + total_unlocked: string; + /** + * + * @type {Array} + * @memberof AddressTokenOfferingLocked + */ + unlock_schedule: Array; +} + +export function AddressTokenOfferingLockedFromJSON(json: any): AddressTokenOfferingLocked { + return AddressTokenOfferingLockedFromJSONTyped(json, false); +} + +export function AddressTokenOfferingLockedFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressTokenOfferingLocked { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'total_locked': json['total_locked'], + 'total_unlocked': json['total_unlocked'], + 'unlock_schedule': ((json['unlock_schedule'] as Array).map(AddressUnlockScheduleFromJSON)), + }; +} + +export function AddressTokenOfferingLockedToJSON(value?: AddressTokenOfferingLocked | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'total_locked': value.total_locked, + 'total_unlocked': value.total_unlocked, + 'unlock_schedule': ((value.unlock_schedule as Array).map(AddressUnlockScheduleToJSON)), + }; +} + diff --git a/client/src/generated/models/AddressTransactionWithTransfers.ts b/client/src/generated/models/AddressTransactionWithTransfers.ts new file mode 100644 index 0000000000..384b27146d --- /dev/null +++ b/client/src/generated/models/AddressTransactionWithTransfers.ts @@ -0,0 +1,111 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + AddressTransactionWithTransfersFtTransfers, + AddressTransactionWithTransfersFtTransfersFromJSON, + AddressTransactionWithTransfersFtTransfersFromJSONTyped, + AddressTransactionWithTransfersFtTransfersToJSON, + AddressTransactionWithTransfersNftTransfers, + AddressTransactionWithTransfersNftTransfersFromJSON, + AddressTransactionWithTransfersNftTransfersFromJSONTyped, + AddressTransactionWithTransfersNftTransfersToJSON, + AddressTransactionWithTransfersStxTransfers, + AddressTransactionWithTransfersStxTransfersFromJSON, + AddressTransactionWithTransfersStxTransfersFromJSONTyped, + AddressTransactionWithTransfersStxTransfersToJSON, +} from './'; + +/** + * Transaction with STX transfers for a given address + * @export + * @interface AddressTransactionWithTransfers + */ +export interface AddressTransactionWithTransfers { + /** + * Describes all transaction types on Stacks 2.0 blockchain + * @type {object} + * @memberof AddressTransactionWithTransfers + */ + tx: object; + /** + * Total sent from the given address, including the tx fee, in micro-STX as an integer string. + * @type {string} + * @memberof AddressTransactionWithTransfers + */ + stx_sent: string; + /** + * Total received by the given address in micro-STX as an integer string. + * @type {string} + * @memberof AddressTransactionWithTransfers + */ + stx_received: string; + /** + * + * @type {Array} + * @memberof AddressTransactionWithTransfers + */ + stx_transfers: Array; + /** + * + * @type {Array} + * @memberof AddressTransactionWithTransfers + */ + ft_transfers?: Array; + /** + * + * @type {Array} + * @memberof AddressTransactionWithTransfers + */ + nft_transfers?: Array; +} + +export function AddressTransactionWithTransfersFromJSON(json: any): AddressTransactionWithTransfers { + return AddressTransactionWithTransfersFromJSONTyped(json, false); +} + +export function AddressTransactionWithTransfersFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressTransactionWithTransfers { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'tx': json['tx'], + 'stx_sent': json['stx_sent'], + 'stx_received': json['stx_received'], + 'stx_transfers': ((json['stx_transfers'] as Array).map(AddressTransactionWithTransfersStxTransfersFromJSON)), + 'ft_transfers': !exists(json, 'ft_transfers') ? undefined : ((json['ft_transfers'] as Array).map(AddressTransactionWithTransfersFtTransfersFromJSON)), + 'nft_transfers': !exists(json, 'nft_transfers') ? undefined : ((json['nft_transfers'] as Array).map(AddressTransactionWithTransfersNftTransfersFromJSON)), + }; +} + +export function AddressTransactionWithTransfersToJSON(value?: AddressTransactionWithTransfers | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'tx': value.tx, + 'stx_sent': value.stx_sent, + 'stx_received': value.stx_received, + 'stx_transfers': ((value.stx_transfers as Array).map(AddressTransactionWithTransfersStxTransfersToJSON)), + 'ft_transfers': value.ft_transfers === undefined ? undefined : ((value.ft_transfers as Array).map(AddressTransactionWithTransfersFtTransfersToJSON)), + 'nft_transfers': value.nft_transfers === undefined ? undefined : ((value.nft_transfers as Array).map(AddressTransactionWithTransfersNftTransfersToJSON)), + }; +} + diff --git a/client/src/generated/models/AddressTransactionWithTransfersFtTransfers.ts b/client/src/generated/models/AddressTransactionWithTransfersFtTransfers.ts new file mode 100644 index 0000000000..45e60130a1 --- /dev/null +++ b/client/src/generated/models/AddressTransactionWithTransfersFtTransfers.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface AddressTransactionWithTransfersFtTransfers + */ +export interface AddressTransactionWithTransfersFtTransfers { + /** + * Fungible Token asset identifier. + * @type {string} + * @memberof AddressTransactionWithTransfersFtTransfers + */ + asset_identifier: string; + /** + * Amount transferred as an integer string. This balance does not factor in possible SIP-010 decimals. + * @type {string} + * @memberof AddressTransactionWithTransfersFtTransfers + */ + amount: string; + /** + * Principal that sent the asset. + * @type {string} + * @memberof AddressTransactionWithTransfersFtTransfers + */ + sender?: string; + /** + * Principal that received the asset. + * @type {string} + * @memberof AddressTransactionWithTransfersFtTransfers + */ + recipient?: string; +} + +export function AddressTransactionWithTransfersFtTransfersFromJSON(json: any): AddressTransactionWithTransfersFtTransfers { + return AddressTransactionWithTransfersFtTransfersFromJSONTyped(json, false); +} + +export function AddressTransactionWithTransfersFtTransfersFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressTransactionWithTransfersFtTransfers { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'asset_identifier': json['asset_identifier'], + 'amount': json['amount'], + 'sender': !exists(json, 'sender') ? undefined : json['sender'], + 'recipient': !exists(json, 'recipient') ? undefined : json['recipient'], + }; +} + +export function AddressTransactionWithTransfersFtTransfersToJSON(value?: AddressTransactionWithTransfersFtTransfers | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'asset_identifier': value.asset_identifier, + 'amount': value.amount, + 'sender': value.sender, + 'recipient': value.recipient, + }; +} + diff --git a/client/src/generated/models/AddressTransactionWithTransfersNftTransfers.ts b/client/src/generated/models/AddressTransactionWithTransfersNftTransfers.ts new file mode 100644 index 0000000000..adf8f33be9 --- /dev/null +++ b/client/src/generated/models/AddressTransactionWithTransfersNftTransfers.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + AddressTransactionWithTransfersValue, + AddressTransactionWithTransfersValueFromJSON, + AddressTransactionWithTransfersValueFromJSONTyped, + AddressTransactionWithTransfersValueToJSON, +} from './'; + +/** + * + * @export + * @interface AddressTransactionWithTransfersNftTransfers + */ +export interface AddressTransactionWithTransfersNftTransfers { + /** + * Non Fungible Token asset identifier. + * @type {string} + * @memberof AddressTransactionWithTransfersNftTransfers + */ + asset_identifier: string; + /** + * + * @type {AddressTransactionWithTransfersValue} + * @memberof AddressTransactionWithTransfersNftTransfers + */ + value: AddressTransactionWithTransfersValue; + /** + * Principal that sent the asset. + * @type {string} + * @memberof AddressTransactionWithTransfersNftTransfers + */ + sender?: string; + /** + * Principal that received the asset. + * @type {string} + * @memberof AddressTransactionWithTransfersNftTransfers + */ + recipient?: string; +} + +export function AddressTransactionWithTransfersNftTransfersFromJSON(json: any): AddressTransactionWithTransfersNftTransfers { + return AddressTransactionWithTransfersNftTransfersFromJSONTyped(json, false); +} + +export function AddressTransactionWithTransfersNftTransfersFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressTransactionWithTransfersNftTransfers { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'asset_identifier': json['asset_identifier'], + 'value': AddressTransactionWithTransfersValueFromJSON(json['value']), + 'sender': !exists(json, 'sender') ? undefined : json['sender'], + 'recipient': !exists(json, 'recipient') ? undefined : json['recipient'], + }; +} + +export function AddressTransactionWithTransfersNftTransfersToJSON(value?: AddressTransactionWithTransfersNftTransfers | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'asset_identifier': value.asset_identifier, + 'value': AddressTransactionWithTransfersValueToJSON(value.value), + 'sender': value.sender, + 'recipient': value.recipient, + }; +} + diff --git a/client/src/generated/models/AddressTransactionWithTransfersStxTransfers.ts b/client/src/generated/models/AddressTransactionWithTransfersStxTransfers.ts new file mode 100644 index 0000000000..e8b5e190df --- /dev/null +++ b/client/src/generated/models/AddressTransactionWithTransfersStxTransfers.ts @@ -0,0 +1,72 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface AddressTransactionWithTransfersStxTransfers + */ +export interface AddressTransactionWithTransfersStxTransfers { + /** + * Amount transferred in micro-STX as an integer string. + * @type {string} + * @memberof AddressTransactionWithTransfersStxTransfers + */ + amount: string; + /** + * Principal that sent STX. This is unspecified if the STX were minted. + * @type {string} + * @memberof AddressTransactionWithTransfersStxTransfers + */ + sender?: string; + /** + * Principal that received STX. This is unspecified if the STX were burned. + * @type {string} + * @memberof AddressTransactionWithTransfersStxTransfers + */ + recipient?: string; +} + +export function AddressTransactionWithTransfersStxTransfersFromJSON(json: any): AddressTransactionWithTransfersStxTransfers { + return AddressTransactionWithTransfersStxTransfersFromJSONTyped(json, false); +} + +export function AddressTransactionWithTransfersStxTransfersFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressTransactionWithTransfersStxTransfers { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'amount': json['amount'], + 'sender': !exists(json, 'sender') ? undefined : json['sender'], + 'recipient': !exists(json, 'recipient') ? undefined : json['recipient'], + }; +} + +export function AddressTransactionWithTransfersStxTransfersToJSON(value?: AddressTransactionWithTransfersStxTransfers | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'amount': value.amount, + 'sender': value.sender, + 'recipient': value.recipient, + }; +} + diff --git a/client/src/generated/models/AddressTransactionWithTransfersValue.ts b/client/src/generated/models/AddressTransactionWithTransfersValue.ts new file mode 100644 index 0000000000..1894ee8099 --- /dev/null +++ b/client/src/generated/models/AddressTransactionWithTransfersValue.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Non Fungible Token asset value. + * @export + * @interface AddressTransactionWithTransfersValue + */ +export interface AddressTransactionWithTransfersValue { + /** + * + * @type {string} + * @memberof AddressTransactionWithTransfersValue + */ + hex: string; + /** + * + * @type {string} + * @memberof AddressTransactionWithTransfersValue + */ + repr: string; +} + +export function AddressTransactionWithTransfersValueFromJSON(json: any): AddressTransactionWithTransfersValue { + return AddressTransactionWithTransfersValueFromJSONTyped(json, false); +} + +export function AddressTransactionWithTransfersValueFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressTransactionWithTransfersValue { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'hex': json['hex'], + 'repr': json['repr'], + }; +} + +export function AddressTransactionWithTransfersValueToJSON(value?: AddressTransactionWithTransfersValue | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'hex': value.hex, + 'repr': value.repr, + }; +} + diff --git a/client/src/generated/models/AddressTransactionsListResponse.ts b/client/src/generated/models/AddressTransactionsListResponse.ts index bc0bdf3568..a493ee9b0f 100644 --- a/client/src/generated/models/AddressTransactionsListResponse.ts +++ b/client/src/generated/models/AddressTransactionsListResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -78,4 +78,3 @@ export function AddressTransactionsListResponseToJSON(value?: AddressTransaction }; } - diff --git a/client/src/generated/models/AddressTransactionsWithTransfersListResponse.ts b/client/src/generated/models/AddressTransactionsWithTransfersListResponse.ts new file mode 100644 index 0000000000..3f5e59d5f4 --- /dev/null +++ b/client/src/generated/models/AddressTransactionsWithTransfersListResponse.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + AddressTransactionWithTransfers, + AddressTransactionWithTransfersFromJSON, + AddressTransactionWithTransfersFromJSONTyped, + AddressTransactionWithTransfersToJSON, +} from './'; + +/** + * GET request that returns account transactions + * @export + * @interface AddressTransactionsWithTransfersListResponse + */ +export interface AddressTransactionsWithTransfersListResponse { + /** + * + * @type {number} + * @memberof AddressTransactionsWithTransfersListResponse + */ + limit: number; + /** + * + * @type {number} + * @memberof AddressTransactionsWithTransfersListResponse + */ + offset: number; + /** + * + * @type {number} + * @memberof AddressTransactionsWithTransfersListResponse + */ + total: number; + /** + * + * @type {Array} + * @memberof AddressTransactionsWithTransfersListResponse + */ + results: Array; +} + +export function AddressTransactionsWithTransfersListResponseFromJSON(json: any): AddressTransactionsWithTransfersListResponse { + return AddressTransactionsWithTransfersListResponseFromJSONTyped(json, false); +} + +export function AddressTransactionsWithTransfersListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressTransactionsWithTransfersListResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': ((json['results'] as Array).map(AddressTransactionWithTransfersFromJSON)), + }; +} + +export function AddressTransactionsWithTransfersListResponseToJSON(value?: AddressTransactionsWithTransfersListResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': ((value.results as Array).map(AddressTransactionWithTransfersToJSON)), + }; +} + diff --git a/client/src/generated/models/AddressUnlockSchedule.ts b/client/src/generated/models/AddressUnlockSchedule.ts new file mode 100644 index 0000000000..ac25d18f56 --- /dev/null +++ b/client/src/generated/models/AddressUnlockSchedule.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Unlock schedule amount and block height + * @export + * @interface AddressUnlockSchedule + */ +export interface AddressUnlockSchedule { + /** + * Micro-STX amount locked at this block height. + * @type {string} + * @memberof AddressUnlockSchedule + */ + amount: string; + /** + * + * @type {number} + * @memberof AddressUnlockSchedule + */ + block_height: number; +} + +export function AddressUnlockScheduleFromJSON(json: any): AddressUnlockSchedule { + return AddressUnlockScheduleFromJSONTyped(json, false); +} + +export function AddressUnlockScheduleFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressUnlockSchedule { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'amount': json['amount'], + 'block_height': json['block_height'], + }; +} + +export function AddressUnlockScheduleToJSON(value?: AddressUnlockSchedule | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'amount': value.amount, + 'block_height': value.block_height, + }; +} + diff --git a/client/src/generated/models/Block.ts b/client/src/generated/models/Block.ts index 64837c0ddf..4114018502 100644 --- a/client/src/generated/models/Block.ts +++ b/client/src/generated/models/Block.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -37,6 +37,12 @@ export interface Block { * @memberof Block */ hash: string; + /** + * The only hash that can uniquely identify an anchored block or an unconfirmed state trie + * @type {string} + * @memberof Block + */ + index_block_hash: string; /** * Hash of the parent block * @type {string} @@ -73,12 +79,72 @@ export interface Block { * @memberof Block */ miner_txid: string; + /** + * The hash of the last streamed block that precedes this block to which this block is to be appended. Not every anchored block will have a parent microblock stream. An anchored block that does not have a parent microblock stream has the parent microblock hash set to an empty string, and the parent microblock sequence number set to -1. + * @type {string} + * @memberof Block + */ + parent_microblock_hash: string; + /** + * The hash of the last streamed block that precedes this block to which this block is to be appended. Not every anchored block will have a parent microblock stream. An anchored block that does not have a parent microblock stream has the parent microblock hash set to an empty string, and the parent microblock sequence number set to -1. + * @type {number} + * @memberof Block + */ + parent_microblock_sequence: number; /** * List of transactions included in the block * @type {Array} * @memberof Block */ txs: Array; + /** + * List of microblocks that were accepted in this anchor block. Not every anchored block will have a accepted all (or any) of the previously streamed microblocks. Microblocks that were orphaned are not included in this list. + * @type {Array} + * @memberof Block + */ + microblocks_accepted: Array; + /** + * List of microblocks that were streamed/produced by this anchor block's miner. This list only includes microblocks that were accepted in the following anchor block. Microblocks that were orphaned are not included in this list. + * @type {Array} + * @memberof Block + */ + microblocks_streamed: Array; + /** + * Execution cost read count. + * @type {number} + * @memberof Block + */ + execution_cost_read_count: number; + /** + * Execution cost read length. + * @type {number} + * @memberof Block + */ + execution_cost_read_length: number; + /** + * Execution cost runtime. + * @type {number} + * @memberof Block + */ + execution_cost_runtime: number; + /** + * Execution cost write count. + * @type {number} + * @memberof Block + */ + execution_cost_write_count: number; + /** + * Execution cost write length. + * @type {number} + * @memberof Block + */ + execution_cost_write_length: number; + /** + * List of txs counts in each accepted microblock + * @type {{ [key: string]: number; }} + * @memberof Block + */ + microblock_tx_count: { [key: string]: number; }; } export function BlockFromJSON(json: any): Block { @@ -94,13 +160,24 @@ export function BlockFromJSONTyped(json: any, ignoreDiscriminator: boolean): Blo 'canonical': json['canonical'], 'height': json['height'], 'hash': json['hash'], + 'index_block_hash': json['index_block_hash'], 'parent_block_hash': json['parent_block_hash'], 'burn_block_time': json['burn_block_time'], 'burn_block_time_iso': json['burn_block_time_iso'], 'burn_block_hash': json['burn_block_hash'], 'burn_block_height': json['burn_block_height'], 'miner_txid': json['miner_txid'], + 'parent_microblock_hash': json['parent_microblock_hash'], + 'parent_microblock_sequence': json['parent_microblock_sequence'], 'txs': json['txs'], + 'microblocks_accepted': json['microblocks_accepted'], + 'microblocks_streamed': json['microblocks_streamed'], + 'execution_cost_read_count': json['execution_cost_read_count'], + 'execution_cost_read_length': json['execution_cost_read_length'], + 'execution_cost_runtime': json['execution_cost_runtime'], + 'execution_cost_write_count': json['execution_cost_write_count'], + 'execution_cost_write_length': json['execution_cost_write_length'], + 'microblock_tx_count': json['microblock_tx_count'], }; } @@ -116,14 +193,24 @@ export function BlockToJSON(value?: Block | null): any { 'canonical': value.canonical, 'height': value.height, 'hash': value.hash, + 'index_block_hash': value.index_block_hash, 'parent_block_hash': value.parent_block_hash, 'burn_block_time': value.burn_block_time, 'burn_block_time_iso': value.burn_block_time_iso, 'burn_block_hash': value.burn_block_hash, 'burn_block_height': value.burn_block_height, 'miner_txid': value.miner_txid, + 'parent_microblock_hash': value.parent_microblock_hash, + 'parent_microblock_sequence': value.parent_microblock_sequence, 'txs': value.txs, + 'microblocks_accepted': value.microblocks_accepted, + 'microblocks_streamed': value.microblocks_streamed, + 'execution_cost_read_count': value.execution_cost_read_count, + 'execution_cost_read_length': value.execution_cost_read_length, + 'execution_cost_runtime': value.execution_cost_runtime, + 'execution_cost_write_count': value.execution_cost_write_count, + 'execution_cost_write_length': value.execution_cost_write_length, + 'microblock_tx_count': value.microblock_tx_count, }; } - diff --git a/client/src/generated/models/BlockListResponse.ts b/client/src/generated/models/BlockListResponse.ts index 8b68d54671..a6d4d2abf5 100644 --- a/client/src/generated/models/BlockListResponse.ts +++ b/client/src/generated/models/BlockListResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -85,4 +85,3 @@ export function BlockListResponseToJSON(value?: BlockListResponse | null): any { }; } - diff --git a/client/src/generated/models/BnsError.ts b/client/src/generated/models/BnsError.ts new file mode 100644 index 0000000000..3eb24ec09e --- /dev/null +++ b/client/src/generated/models/BnsError.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Error + * @export + * @interface BnsError + */ +export interface BnsError { + /** + * + * @type {string} + * @memberof BnsError + */ + error?: string; +} + +export function BnsErrorFromJSON(json: any): BnsError { + return BnsErrorFromJSONTyped(json, false); +} + +export function BnsErrorFromJSONTyped(json: any, ignoreDiscriminator: boolean): BnsError { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'error': !exists(json, 'error') ? undefined : json['error'], + }; +} + +export function BnsErrorToJSON(value?: BnsError | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'error': value.error, + }; +} + diff --git a/client/src/generated/models/BnsGetAllNamespacesResponse.ts b/client/src/generated/models/BnsGetAllNamespacesResponse.ts new file mode 100644 index 0000000000..3951a07291 --- /dev/null +++ b/client/src/generated/models/BnsGetAllNamespacesResponse.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Fetch a list of all namespaces known to the node. + * @export + * @interface BnsGetAllNamespacesResponse + */ +export interface BnsGetAllNamespacesResponse { + /** + * + * @type {Array} + * @memberof BnsGetAllNamespacesResponse + */ + namespaces: Array; +} + +export function BnsGetAllNamespacesResponseFromJSON(json: any): BnsGetAllNamespacesResponse { + return BnsGetAllNamespacesResponseFromJSONTyped(json, false); +} + +export function BnsGetAllNamespacesResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): BnsGetAllNamespacesResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'namespaces': json['namespaces'], + }; +} + +export function BnsGetAllNamespacesResponseToJSON(value?: BnsGetAllNamespacesResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'namespaces': value.namespaces, + }; +} + diff --git a/client/src/generated/models/BnsGetNameInfoResponse.ts b/client/src/generated/models/BnsGetNameInfoResponse.ts new file mode 100644 index 0000000000..0c5e82a2c8 --- /dev/null +++ b/client/src/generated/models/BnsGetNameInfoResponse.ts @@ -0,0 +1,120 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Get name details + * @export + * @interface BnsGetNameInfoResponse + */ +export interface BnsGetNameInfoResponse { + /** + * + * @type {string} + * @memberof BnsGetNameInfoResponse + */ + address: string; + /** + * + * @type {string} + * @memberof BnsGetNameInfoResponse + */ + blockchain: string; + /** + * + * @type {number} + * @memberof BnsGetNameInfoResponse + */ + expire_block?: number; + /** + * + * @type {number} + * @memberof BnsGetNameInfoResponse + */ + grace_period?: number; + /** + * + * @type {string} + * @memberof BnsGetNameInfoResponse + */ + last_txid: string; + /** + * + * @type {string} + * @memberof BnsGetNameInfoResponse + */ + resolver?: string; + /** + * + * @type {string} + * @memberof BnsGetNameInfoResponse + */ + status: string; + /** + * + * @type {string} + * @memberof BnsGetNameInfoResponse + */ + zonefile: string; + /** + * + * @type {string} + * @memberof BnsGetNameInfoResponse + */ + zonefile_hash: string; +} + +export function BnsGetNameInfoResponseFromJSON(json: any): BnsGetNameInfoResponse { + return BnsGetNameInfoResponseFromJSONTyped(json, false); +} + +export function BnsGetNameInfoResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): BnsGetNameInfoResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'address': json['address'], + 'blockchain': json['blockchain'], + 'expire_block': !exists(json, 'expire_block') ? undefined : json['expire_block'], + 'grace_period': !exists(json, 'grace_period') ? undefined : json['grace_period'], + 'last_txid': json['last_txid'], + 'resolver': !exists(json, 'resolver') ? undefined : json['resolver'], + 'status': json['status'], + 'zonefile': json['zonefile'], + 'zonefile_hash': json['zonefile_hash'], + }; +} + +export function BnsGetNameInfoResponseToJSON(value?: BnsGetNameInfoResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'address': value.address, + 'blockchain': value.blockchain, + 'expire_block': value.expire_block, + 'grace_period': value.grace_period, + 'last_txid': value.last_txid, + 'resolver': value.resolver, + 'status': value.status, + 'zonefile': value.zonefile, + 'zonefile_hash': value.zonefile_hash, + }; +} + diff --git a/client/src/generated/models/BnsGetNamePriceResponse.ts b/client/src/generated/models/BnsGetNamePriceResponse.ts new file mode 100644 index 0000000000..13c03e48a4 --- /dev/null +++ b/client/src/generated/models/BnsGetNamePriceResponse.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Fetch price for name. + * @export + * @interface BnsGetNamePriceResponse + */ +export interface BnsGetNamePriceResponse { + /** + * + * @type {string} + * @memberof BnsGetNamePriceResponse + */ + units: string; + /** + * + * @type {string} + * @memberof BnsGetNamePriceResponse + */ + amount: string; +} + +export function BnsGetNamePriceResponseFromJSON(json: any): BnsGetNamePriceResponse { + return BnsGetNamePriceResponseFromJSONTyped(json, false); +} + +export function BnsGetNamePriceResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): BnsGetNamePriceResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'units': json['units'], + 'amount': json['amount'], + }; +} + +export function BnsGetNamePriceResponseToJSON(value?: BnsGetNamePriceResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'units': value.units, + 'amount': value.amount, + }; +} + diff --git a/client/src/generated/models/BnsGetNamespacePriceResponse.ts b/client/src/generated/models/BnsGetNamespacePriceResponse.ts new file mode 100644 index 0000000000..56f293be23 --- /dev/null +++ b/client/src/generated/models/BnsGetNamespacePriceResponse.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Fetch price for namespace. + * @export + * @interface BnsGetNamespacePriceResponse + */ +export interface BnsGetNamespacePriceResponse { + /** + * + * @type {string} + * @memberof BnsGetNamespacePriceResponse + */ + units: string; + /** + * + * @type {string} + * @memberof BnsGetNamespacePriceResponse + */ + amount: string; +} + +export function BnsGetNamespacePriceResponseFromJSON(json: any): BnsGetNamespacePriceResponse { + return BnsGetNamespacePriceResponseFromJSONTyped(json, false); +} + +export function BnsGetNamespacePriceResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): BnsGetNamespacePriceResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'units': json['units'], + 'amount': json['amount'], + }; +} + +export function BnsGetNamespacePriceResponseToJSON(value?: BnsGetNamespacePriceResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'units': value.units, + 'amount': value.amount, + }; +} + diff --git a/client/src/generated/models/BnsNamesOwnByAddressResponse.ts b/client/src/generated/models/BnsNamesOwnByAddressResponse.ts new file mode 100644 index 0000000000..9617a59b0c --- /dev/null +++ b/client/src/generated/models/BnsNamesOwnByAddressResponse.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Retrieves a list of names owned by the address provided. + * @export + * @interface BnsNamesOwnByAddressResponse + */ +export interface BnsNamesOwnByAddressResponse { + /** + * + * @type {Array} + * @memberof BnsNamesOwnByAddressResponse + */ + names: Array; +} + +export function BnsNamesOwnByAddressResponseFromJSON(json: any): BnsNamesOwnByAddressResponse { + return BnsNamesOwnByAddressResponseFromJSONTyped(json, false); +} + +export function BnsNamesOwnByAddressResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): BnsNamesOwnByAddressResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'names': json['names'], + }; +} + +export function BnsNamesOwnByAddressResponseToJSON(value?: BnsNamesOwnByAddressResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'names': value.names, + }; +} + diff --git a/client/src/generated/models/BurnchainReward.ts b/client/src/generated/models/BurnchainReward.ts index b85fc9b653..b605981ce9 100644 --- a/client/src/generated/models/BurnchainReward.ts +++ b/client/src/generated/models/BurnchainReward.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -102,4 +102,3 @@ export function BurnchainRewardToJSON(value?: BurnchainReward | null): any { }; } - diff --git a/client/src/generated/models/BurnchainRewardListResponse.ts b/client/src/generated/models/BurnchainRewardListResponse.ts index ed5010c3fb..b5cacf3edd 100644 --- a/client/src/generated/models/BurnchainRewardListResponse.ts +++ b/client/src/generated/models/BurnchainRewardListResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -77,4 +77,3 @@ export function BurnchainRewardListResponseToJSON(value?: BurnchainRewardListRes }; } - diff --git a/client/src/generated/models/BurnchainRewardSlotHolder.ts b/client/src/generated/models/BurnchainRewardSlotHolder.ts new file mode 100644 index 0000000000..1963ae1bd0 --- /dev/null +++ b/client/src/generated/models/BurnchainRewardSlotHolder.ts @@ -0,0 +1,88 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Reward slot holder on the burnchain + * @export + * @interface BurnchainRewardSlotHolder + */ +export interface BurnchainRewardSlotHolder { + /** + * Set to `true` if block corresponds to the canonical burchchain tip + * @type {boolean} + * @memberof BurnchainRewardSlotHolder + */ + canonical: boolean; + /** + * The hash representing the burnchain block + * @type {string} + * @memberof BurnchainRewardSlotHolder + */ + burn_block_hash: string; + /** + * Height of the burnchain block + * @type {number} + * @memberof BurnchainRewardSlotHolder + */ + burn_block_height: number; + /** + * The recipient address that validly received PoX commitments, in the format native to the burnchain (e.g. B58 encoded for Bitcoin) + * @type {string} + * @memberof BurnchainRewardSlotHolder + */ + address: string; + /** + * The index position of the reward entry, useful for ordering when there's more than one slot per burnchain block + * @type {number} + * @memberof BurnchainRewardSlotHolder + */ + slot_index: number; +} + +export function BurnchainRewardSlotHolderFromJSON(json: any): BurnchainRewardSlotHolder { + return BurnchainRewardSlotHolderFromJSONTyped(json, false); +} + +export function BurnchainRewardSlotHolderFromJSONTyped(json: any, ignoreDiscriminator: boolean): BurnchainRewardSlotHolder { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'canonical': json['canonical'], + 'burn_block_hash': json['burn_block_hash'], + 'burn_block_height': json['burn_block_height'], + 'address': json['address'], + 'slot_index': json['slot_index'], + }; +} + +export function BurnchainRewardSlotHolderToJSON(value?: BurnchainRewardSlotHolder | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'canonical': value.canonical, + 'burn_block_hash': value.burn_block_hash, + 'burn_block_height': value.burn_block_height, + 'address': value.address, + 'slot_index': value.slot_index, + }; +} + diff --git a/client/src/generated/models/BurnchainRewardSlotHolderListResponse.ts b/client/src/generated/models/BurnchainRewardSlotHolderListResponse.ts new file mode 100644 index 0000000000..81738f1a2a --- /dev/null +++ b/client/src/generated/models/BurnchainRewardSlotHolderListResponse.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + BurnchainRewardSlotHolder, + BurnchainRewardSlotHolderFromJSON, + BurnchainRewardSlotHolderFromJSONTyped, + BurnchainRewardSlotHolderToJSON, +} from './'; + +/** + * GET request that returns reward slot holders + * @export + * @interface BurnchainRewardSlotHolderListResponse + */ +export interface BurnchainRewardSlotHolderListResponse { + /** + * The number of items to return + * @type {number} + * @memberof BurnchainRewardSlotHolderListResponse + */ + limit: number; + /** + * The number of items to skip (starting at `0`) + * @type {number} + * @memberof BurnchainRewardSlotHolderListResponse + */ + offset: number; + /** + * Total number of available items + * @type {number} + * @memberof BurnchainRewardSlotHolderListResponse + */ + total: number; + /** + * + * @type {Array} + * @memberof BurnchainRewardSlotHolderListResponse + */ + results: Array; +} + +export function BurnchainRewardSlotHolderListResponseFromJSON(json: any): BurnchainRewardSlotHolderListResponse { + return BurnchainRewardSlotHolderListResponseFromJSONTyped(json, false); +} + +export function BurnchainRewardSlotHolderListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): BurnchainRewardSlotHolderListResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': ((json['results'] as Array).map(BurnchainRewardSlotHolderFromJSON)), + }; +} + +export function BurnchainRewardSlotHolderListResponseToJSON(value?: BurnchainRewardSlotHolderListResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': ((value.results as Array).map(BurnchainRewardSlotHolderToJSON)), + }; +} + diff --git a/client/src/generated/models/BurnchainRewardsTotal.ts b/client/src/generated/models/BurnchainRewardsTotal.ts index b668541728..69e309a700 100644 --- a/client/src/generated/models/BurnchainRewardsTotal.ts +++ b/client/src/generated/models/BurnchainRewardsTotal.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function BurnchainRewardsTotalToJSON(value?: BurnchainRewardsTotal | null }; } - diff --git a/client/src/generated/models/ChainTip.ts b/client/src/generated/models/ChainTip.ts new file mode 100644 index 0000000000..c7b3e00bcb --- /dev/null +++ b/client/src/generated/models/ChainTip.ts @@ -0,0 +1,96 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Current chain tip information + * @export + * @interface ChainTip + */ +export interface ChainTip { + /** + * the current block height + * @type {number} + * @memberof ChainTip + */ + block_height: number; + /** + * the current block hash + * @type {string} + * @memberof ChainTip + */ + block_hash: string; + /** + * the current index block hash + * @type {string} + * @memberof ChainTip + */ + index_block_hash: string; + /** + * the current microblock hash + * @type {string} + * @memberof ChainTip + */ + microblock_hash?: string; + /** + * the current microblock sequence number + * @type {number} + * @memberof ChainTip + */ + microblock_sequence?: number; + /** + * the current burn chain block height + * @type {number} + * @memberof ChainTip + */ + burn_block_height: number; +} + +export function ChainTipFromJSON(json: any): ChainTip { + return ChainTipFromJSONTyped(json, false); +} + +export function ChainTipFromJSONTyped(json: any, ignoreDiscriminator: boolean): ChainTip { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'block_height': json['block_height'], + 'block_hash': json['block_hash'], + 'index_block_hash': json['index_block_hash'], + 'microblock_hash': !exists(json, 'microblock_hash') ? undefined : json['microblock_hash'], + 'microblock_sequence': !exists(json, 'microblock_sequence') ? undefined : json['microblock_sequence'], + 'burn_block_height': json['burn_block_height'], + }; +} + +export function ChainTipToJSON(value?: ChainTip | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'block_height': value.block_height, + 'block_hash': value.block_hash, + 'index_block_hash': value.index_block_hash, + 'microblock_hash': value.microblock_hash, + 'microblock_sequence': value.microblock_sequence, + 'burn_block_height': value.burn_block_height, + }; +} + diff --git a/client/src/generated/models/ContractInterfaceResponse.ts b/client/src/generated/models/ContractInterfaceResponse.ts index d572aa5319..981323e1df 100644 --- a/client/src/generated/models/ContractInterfaceResponse.ts +++ b/client/src/generated/models/ContractInterfaceResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -86,4 +86,3 @@ export function ContractInterfaceResponseToJSON(value?: ContractInterfaceRespons }; } - diff --git a/client/src/generated/models/ContractListResponse.ts b/client/src/generated/models/ContractListResponse.ts new file mode 100644 index 0000000000..af1711e8f5 --- /dev/null +++ b/client/src/generated/models/ContractListResponse.ts @@ -0,0 +1,79 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + SmartContract, + SmartContractFromJSON, + SmartContractFromJSONTyped, + SmartContractToJSON, +} from './'; + +/** + * GET list of contracts + * @export + * @interface ContractListResponse + */ +export interface ContractListResponse { + /** + * The number of contracts to return + * @type {number} + * @memberof ContractListResponse + */ + limit: number; + /** + * The number to contracts to skip (starting at `0`) + * @type {number} + * @memberof ContractListResponse + */ + offset: number; + /** + * + * @type {Array} + * @memberof ContractListResponse + */ + results: Array; +} + +export function ContractListResponseFromJSON(json: any): ContractListResponse { + return ContractListResponseFromJSONTyped(json, false); +} + +export function ContractListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ContractListResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'results': ((json['results'] as Array).map(SmartContractFromJSON)), + }; +} + +export function ContractListResponseToJSON(value?: ContractListResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'results': ((value.results as Array).map(SmartContractToJSON)), + }; +} + diff --git a/client/src/generated/models/ContractSourceResponse.ts b/client/src/generated/models/ContractSourceResponse.ts index d46000d90f..2bc9c50fdb 100644 --- a/client/src/generated/models/ContractSourceResponse.ts +++ b/client/src/generated/models/ContractSourceResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -70,4 +70,3 @@ export function ContractSourceResponseToJSON(value?: ContractSourceResponse | nu }; } - diff --git a/client/src/generated/models/CoreNodeInfoResponse.ts b/client/src/generated/models/CoreNodeInfoResponse.ts index 5506ecac08..b9fc0597a0 100644 --- a/client/src/generated/models/CoreNodeInfoResponse.ts +++ b/client/src/generated/models/CoreNodeInfoResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -150,4 +150,3 @@ export function CoreNodeInfoResponseToJSON(value?: CoreNodeInfoResponse | null): }; } - diff --git a/client/src/generated/models/CoreNodePoxResponse.ts b/client/src/generated/models/CoreNodePoxResponse.ts index 0c513afd76..079c566a97 100644 --- a/client/src/generated/models/CoreNodePoxResponse.ts +++ b/client/src/generated/models/CoreNodePoxResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -118,4 +118,3 @@ export function CoreNodePoxResponseToJSON(value?: CoreNodePoxResponse | null): a }; } - diff --git a/client/src/generated/models/FeeRate.ts b/client/src/generated/models/FeeRate.ts new file mode 100644 index 0000000000..15482f7f4b --- /dev/null +++ b/client/src/generated/models/FeeRate.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Get fee rate information. + * @export + * @interface FeeRate + */ +export interface FeeRate { + /** + * + * @type {number} + * @memberof FeeRate + */ + fee_rate: number; +} + +export function FeeRateFromJSON(json: any): FeeRate { + return FeeRateFromJSONTyped(json, false); +} + +export function FeeRateFromJSONTyped(json: any, ignoreDiscriminator: boolean): FeeRate { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'fee_rate': json['fee_rate'], + }; +} + +export function FeeRateToJSON(value?: FeeRate | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'fee_rate': value.fee_rate, + }; +} + diff --git a/client/src/generated/models/FeeRateRequest.ts b/client/src/generated/models/FeeRateRequest.ts new file mode 100644 index 0000000000..a98b20acc0 --- /dev/null +++ b/client/src/generated/models/FeeRateRequest.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Request to fetch fee for a transaction + * @export + * @interface FeeRateRequest + */ +export interface FeeRateRequest { + /** + * A serialized transaction + * @type {string} + * @memberof FeeRateRequest + */ + transaction: string; +} + +export function FeeRateRequestFromJSON(json: any): FeeRateRequest { + return FeeRateRequestFromJSONTyped(json, false); +} + +export function FeeRateRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): FeeRateRequest { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'transaction': json['transaction'], + }; +} + +export function FeeRateRequestToJSON(value?: FeeRateRequest | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'transaction': value.transaction, + }; +} + diff --git a/client/src/generated/models/FungibleTokenMetadata.ts b/client/src/generated/models/FungibleTokenMetadata.ts new file mode 100644 index 0000000000..e83645ec49 --- /dev/null +++ b/client/src/generated/models/FungibleTokenMetadata.ts @@ -0,0 +1,120 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface FungibleTokenMetadata + */ +export interface FungibleTokenMetadata { + /** + * An optional string that is a valid URI which resolves to this token's metadata. Can be empty. + * @type {string} + * @memberof FungibleTokenMetadata + */ + token_uri: string; + /** + * Identifies the asset to which this token represents + * @type {string} + * @memberof FungibleTokenMetadata + */ + name: string; + /** + * Describes the asset to which this token represents + * @type {string} + * @memberof FungibleTokenMetadata + */ + description: string; + /** + * A URI pointing to a resource with mime type image/* representing the asset to which this token represents. The API may provide a URI to a cached resource, dependending on configuration. Otherwise, this can be the same value as the canonical image URI. + * @type {string} + * @memberof FungibleTokenMetadata + */ + image_uri: string; + /** + * The original image URI specified by the contract. A URI pointing to a resource with mime type image/* representing the asset to which this token represents. Consider making any images at a width between 320 and 1080 pixels and aspect ratio between 1.91:1 and 4:5 inclusive. + * @type {string} + * @memberof FungibleTokenMetadata + */ + image_canonical_uri: string; + /** + * A shorter representation of a token. This is sometimes referred to as a "ticker". Examples: "STX", "COOL", etc. Typically, a token could be referred to as $SYMBOL when referencing it in writing. + * @type {string} + * @memberof FungibleTokenMetadata + */ + symbol: string; + /** + * The number of decimal places in a token. + * @type {number} + * @memberof FungibleTokenMetadata + */ + decimals: number; + /** + * Tx id that deployed the contract + * @type {string} + * @memberof FungibleTokenMetadata + */ + tx_id: string; + /** + * principle that deployed the contract + * @type {string} + * @memberof FungibleTokenMetadata + */ + sender_address: string; +} + +export function FungibleTokenMetadataFromJSON(json: any): FungibleTokenMetadata { + return FungibleTokenMetadataFromJSONTyped(json, false); +} + +export function FungibleTokenMetadataFromJSONTyped(json: any, ignoreDiscriminator: boolean): FungibleTokenMetadata { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'token_uri': json['token_uri'], + 'name': json['name'], + 'description': json['description'], + 'image_uri': json['image_uri'], + 'image_canonical_uri': json['image_canonical_uri'], + 'symbol': json['symbol'], + 'decimals': json['decimals'], + 'tx_id': json['tx_id'], + 'sender_address': json['sender_address'], + }; +} + +export function FungibleTokenMetadataToJSON(value?: FungibleTokenMetadata | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'token_uri': value.token_uri, + 'name': value.name, + 'description': value.description, + 'image_uri': value.image_uri, + 'image_canonical_uri': value.image_canonical_uri, + 'symbol': value.symbol, + 'decimals': value.decimals, + 'tx_id': value.tx_id, + 'sender_address': value.sender_address, + }; +} + diff --git a/client/src/generated/models/FungibleTokensMetadataList.ts b/client/src/generated/models/FungibleTokensMetadataList.ts new file mode 100644 index 0000000000..e9a059f26c --- /dev/null +++ b/client/src/generated/models/FungibleTokensMetadataList.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + FungibleTokenMetadata, + FungibleTokenMetadataFromJSON, + FungibleTokenMetadataFromJSONTyped, + FungibleTokenMetadataToJSON, +} from './'; + +/** + * List of fungible tokens metadata + * @export + * @interface FungibleTokensMetadataList + */ +export interface FungibleTokensMetadataList { + /** + * The number of tokens metadata to return + * @type {number} + * @memberof FungibleTokensMetadataList + */ + limit: number; + /** + * The number to tokens metadata to skip (starting at `0`) + * @type {number} + * @memberof FungibleTokensMetadataList + */ + offset: number; + /** + * The number of tokens metadata available + * @type {number} + * @memberof FungibleTokensMetadataList + */ + total: number; + /** + * + * @type {Array} + * @memberof FungibleTokensMetadataList + */ + results: Array; +} + +export function FungibleTokensMetadataListFromJSON(json: any): FungibleTokensMetadataList { + return FungibleTokensMetadataListFromJSONTyped(json, false); +} + +export function FungibleTokensMetadataListFromJSONTyped(json: any, ignoreDiscriminator: boolean): FungibleTokensMetadataList { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': ((json['results'] as Array).map(FungibleTokenMetadataFromJSON)), + }; +} + +export function FungibleTokensMetadataListToJSON(value?: FungibleTokensMetadataList | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': ((value.results as Array).map(FungibleTokenMetadataToJSON)), + }; +} + diff --git a/client/src/generated/models/GetRawTransactionResult.ts b/client/src/generated/models/GetRawTransactionResult.ts new file mode 100644 index 0000000000..c43bf46498 --- /dev/null +++ b/client/src/generated/models/GetRawTransactionResult.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * GET raw transaction + * @export + * @interface GetRawTransactionResult + */ +export interface GetRawTransactionResult { + /** + * A hex encoded serialized transaction + * @type {string} + * @memberof GetRawTransactionResult + */ + raw_tx: string; +} + +export function GetRawTransactionResultFromJSON(json: any): GetRawTransactionResult { + return GetRawTransactionResultFromJSONTyped(json, false); +} + +export function GetRawTransactionResultFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetRawTransactionResult { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'raw_tx': json['raw_tx'], + }; +} + +export function GetRawTransactionResultToJSON(value?: GetRawTransactionResult | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'raw_tx': value.raw_tx, + }; +} + diff --git a/client/src/generated/models/GetStxSupplyLegacyFormatResponse.ts b/client/src/generated/models/GetStxSupplyLegacyFormatResponse.ts new file mode 100644 index 0000000000..4e0aad3d4a --- /dev/null +++ b/client/src/generated/models/GetStxSupplyLegacyFormatResponse.ts @@ -0,0 +1,96 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * GET request that returns network target block times + * @export + * @interface GetStxSupplyLegacyFormatResponse + */ +export interface GetStxSupplyLegacyFormatResponse { + /** + * String quoted decimal number of the percentage of STX that have unlocked + * @type {string} + * @memberof GetStxSupplyLegacyFormatResponse + */ + unlockedPercent: string; + /** + * String quoted decimal number of the total possible number of STX + * @type {string} + * @memberof GetStxSupplyLegacyFormatResponse + */ + totalStacks: string; + /** + * Same as `totalStacks` but formatted with comma thousands separators + * @type {string} + * @memberof GetStxSupplyLegacyFormatResponse + */ + totalStacksFormatted: string; + /** + * String quoted decimal number of the STX that have been mined or unlocked + * @type {string} + * @memberof GetStxSupplyLegacyFormatResponse + */ + unlockedSupply: string; + /** + * Same as `unlockedSupply` but formatted with comma thousands separators + * @type {string} + * @memberof GetStxSupplyLegacyFormatResponse + */ + unlockedSupplyFormatted: string; + /** + * The block height at which this information was queried + * @type {string} + * @memberof GetStxSupplyLegacyFormatResponse + */ + blockHeight: string; +} + +export function GetStxSupplyLegacyFormatResponseFromJSON(json: any): GetStxSupplyLegacyFormatResponse { + return GetStxSupplyLegacyFormatResponseFromJSONTyped(json, false); +} + +export function GetStxSupplyLegacyFormatResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetStxSupplyLegacyFormatResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'unlockedPercent': json['unlockedPercent'], + 'totalStacks': json['totalStacks'], + 'totalStacksFormatted': json['totalStacksFormatted'], + 'unlockedSupply': json['unlockedSupply'], + 'unlockedSupplyFormatted': json['unlockedSupplyFormatted'], + 'blockHeight': json['blockHeight'], + }; +} + +export function GetStxSupplyLegacyFormatResponseToJSON(value?: GetStxSupplyLegacyFormatResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'unlockedPercent': value.unlockedPercent, + 'totalStacks': value.totalStacks, + 'totalStacksFormatted': value.totalStacksFormatted, + 'unlockedSupply': value.unlockedSupply, + 'unlockedSupplyFormatted': value.unlockedSupplyFormatted, + 'blockHeight': value.blockHeight, + }; +} + diff --git a/client/src/generated/models/GetStxSupplyResponse.ts b/client/src/generated/models/GetStxSupplyResponse.ts new file mode 100644 index 0000000000..b9928b3de0 --- /dev/null +++ b/client/src/generated/models/GetStxSupplyResponse.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * GET request that returns network target block times + * @export + * @interface GetStxSupplyResponse + */ +export interface GetStxSupplyResponse { + /** + * String quoted decimal number of the percentage of STX that have unlocked + * @type {string} + * @memberof GetStxSupplyResponse + */ + unlocked_percent: string; + /** + * String quoted decimal number of the total possible number of STX + * @type {string} + * @memberof GetStxSupplyResponse + */ + total_stx: string; + /** + * String quoted decimal number of the STX that have been mined or unlocked + * @type {string} + * @memberof GetStxSupplyResponse + */ + unlocked_stx: string; + /** + * The block height at which this information was queried + * @type {number} + * @memberof GetStxSupplyResponse + */ + block_height: number; +} + +export function GetStxSupplyResponseFromJSON(json: any): GetStxSupplyResponse { + return GetStxSupplyResponseFromJSONTyped(json, false); +} + +export function GetStxSupplyResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetStxSupplyResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'unlocked_percent': json['unlocked_percent'], + 'total_stx': json['total_stx'], + 'unlocked_stx': json['unlocked_stx'], + 'block_height': json['block_height'], + }; +} + +export function GetStxSupplyResponseToJSON(value?: GetStxSupplyResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'unlocked_percent': value.unlocked_percent, + 'total_stx': value.total_stx, + 'unlocked_stx': value.unlocked_stx, + 'block_height': value.block_height, + }; +} + diff --git a/client/src/generated/models/InboundStxTransfer.ts b/client/src/generated/models/InboundStxTransfer.ts new file mode 100644 index 0000000000..4efee836f1 --- /dev/null +++ b/client/src/generated/models/InboundStxTransfer.ts @@ -0,0 +1,114 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * A inbound STX transfer with a memo + * @export + * @interface InboundStxTransfer + */ +export interface InboundStxTransfer { + /** + * Principal that sent this transfer + * @type {string} + * @memberof InboundStxTransfer + */ + sender: string; + /** + * Transfer amount in micro-STX as integer string + * @type {string} + * @memberof InboundStxTransfer + */ + amount: string; + /** + * Hex encoded memo bytes associated with the transfer + * @type {string} + * @memberof InboundStxTransfer + */ + memo: string; + /** + * Block height at which this transfer occurred + * @type {number} + * @memberof InboundStxTransfer + */ + block_height: number; + /** + * The transaction ID in which this transfer occurred + * @type {string} + * @memberof InboundStxTransfer + */ + tx_id: string; + /** + * Indicates if the transfer is from a stx-transfer transaction or a contract-call transaction + * @type {string} + * @memberof InboundStxTransfer + */ + transfer_type: InboundStxTransferTransferTypeEnum; + /** + * Index of the transaction within a block + * @type {number} + * @memberof InboundStxTransfer + */ + tx_index: number; +} + +/** +* @export +* @enum {string} +*/ +export enum InboundStxTransferTransferTypeEnum { + bulk_send = 'bulk-send', + stx_transfer = 'stx-transfer', + stx_transfer_memo = 'stx-transfer-memo' +} + +export function InboundStxTransferFromJSON(json: any): InboundStxTransfer { + return InboundStxTransferFromJSONTyped(json, false); +} + +export function InboundStxTransferFromJSONTyped(json: any, ignoreDiscriminator: boolean): InboundStxTransfer { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'sender': json['sender'], + 'amount': json['amount'], + 'memo': json['memo'], + 'block_height': json['block_height'], + 'tx_id': json['tx_id'], + 'transfer_type': json['transfer_type'], + 'tx_index': json['tx_index'], + }; +} + +export function InboundStxTransferToJSON(value?: InboundStxTransfer | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'sender': value.sender, + 'amount': value.amount, + 'memo': value.memo, + 'block_height': value.block_height, + 'tx_id': value.tx_id, + 'transfer_type': value.transfer_type, + 'tx_index': value.tx_index, + }; +} + diff --git a/client/src/generated/models/InlineObject.ts b/client/src/generated/models/InlineObject.ts new file mode 100644 index 0000000000..1ce31af828 --- /dev/null +++ b/client/src/generated/models/InlineObject.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface InlineObject + */ +export interface InlineObject { + /** + * BTC testnet address + * @type {string} + * @memberof InlineObject + */ + address?: string; +} + +export function InlineObjectFromJSON(json: any): InlineObject { + return InlineObjectFromJSONTyped(json, false); +} + +export function InlineObjectFromJSONTyped(json: any, ignoreDiscriminator: boolean): InlineObject { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'address': !exists(json, 'address') ? undefined : json['address'], + }; +} + +export function InlineObjectToJSON(value?: InlineObject | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'address': value.address, + }; +} + diff --git a/client/src/generated/models/InlineResponse403.ts b/client/src/generated/models/InlineResponse403.ts new file mode 100644 index 0000000000..7e8bbd4333 --- /dev/null +++ b/client/src/generated/models/InlineResponse403.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface InlineResponse403 + */ +export interface InlineResponse403 { + /** + * + * @type {string} + * @memberof InlineResponse403 + */ + error?: string; + /** + * + * @type {boolean} + * @memberof InlineResponse403 + */ + success?: boolean; +} + +export function InlineResponse403FromJSON(json: any): InlineResponse403 { + return InlineResponse403FromJSONTyped(json, false); +} + +export function InlineResponse403FromJSONTyped(json: any, ignoreDiscriminator: boolean): InlineResponse403 { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'error': !exists(json, 'error') ? undefined : json['error'], + 'success': !exists(json, 'success') ? undefined : json['success'], + }; +} + +export function InlineResponse403ToJSON(value?: InlineResponse403 | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'error': value.error, + 'success': value.success, + }; +} + diff --git a/client/src/generated/models/MapEntryResponse.ts b/client/src/generated/models/MapEntryResponse.ts index 700c3a5584..7a709eb570 100644 --- a/client/src/generated/models/MapEntryResponse.ts +++ b/client/src/generated/models/MapEntryResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function MapEntryResponseToJSON(value?: MapEntryResponse | null): any { }; } - diff --git a/client/src/generated/models/MempoolFeePriorities.ts b/client/src/generated/models/MempoolFeePriorities.ts new file mode 100644 index 0000000000..f59cd3ce9b --- /dev/null +++ b/client/src/generated/models/MempoolFeePriorities.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + MempoolFeePrioritiesAll, + MempoolFeePrioritiesAllFromJSON, + MempoolFeePrioritiesAllFromJSONTyped, + MempoolFeePrioritiesAllToJSON, +} from './'; + +/** + * GET request that returns fee priorities from mempool transactions + * @export + * @interface MempoolFeePriorities + */ +export interface MempoolFeePriorities { + /** + * + * @type {MempoolFeePrioritiesAll} + * @memberof MempoolFeePriorities + */ + all: MempoolFeePrioritiesAll; + /** + * + * @type {MempoolFeePrioritiesAll} + * @memberof MempoolFeePriorities + */ + token_transfer?: MempoolFeePrioritiesAll; + /** + * + * @type {MempoolFeePrioritiesAll} + * @memberof MempoolFeePriorities + */ + smart_contract?: MempoolFeePrioritiesAll; + /** + * + * @type {MempoolFeePrioritiesAll} + * @memberof MempoolFeePriorities + */ + contract_call?: MempoolFeePrioritiesAll; +} + +export function MempoolFeePrioritiesFromJSON(json: any): MempoolFeePriorities { + return MempoolFeePrioritiesFromJSONTyped(json, false); +} + +export function MempoolFeePrioritiesFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolFeePriorities { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'all': MempoolFeePrioritiesAllFromJSON(json['all']), + 'token_transfer': !exists(json, 'token_transfer') ? undefined : MempoolFeePrioritiesAllFromJSON(json['token_transfer']), + 'smart_contract': !exists(json, 'smart_contract') ? undefined : MempoolFeePrioritiesAllFromJSON(json['smart_contract']), + 'contract_call': !exists(json, 'contract_call') ? undefined : MempoolFeePrioritiesAllFromJSON(json['contract_call']), + }; +} + +export function MempoolFeePrioritiesToJSON(value?: MempoolFeePriorities | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'all': MempoolFeePrioritiesAllToJSON(value.all), + 'token_transfer': MempoolFeePrioritiesAllToJSON(value.token_transfer), + 'smart_contract': MempoolFeePrioritiesAllToJSON(value.smart_contract), + 'contract_call': MempoolFeePrioritiesAllToJSON(value.contract_call), + }; +} + diff --git a/client/src/generated/models/MempoolFeePrioritiesAll.ts b/client/src/generated/models/MempoolFeePrioritiesAll.ts new file mode 100644 index 0000000000..ff361674b7 --- /dev/null +++ b/client/src/generated/models/MempoolFeePrioritiesAll.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface MempoolFeePrioritiesAll + */ +export interface MempoolFeePrioritiesAll { + /** + * + * @type {number} + * @memberof MempoolFeePrioritiesAll + */ + no_priority: number; + /** + * + * @type {number} + * @memberof MempoolFeePrioritiesAll + */ + low_priority: number; + /** + * + * @type {number} + * @memberof MempoolFeePrioritiesAll + */ + medium_priority: number; + /** + * + * @type {number} + * @memberof MempoolFeePrioritiesAll + */ + high_priority: number; +} + +export function MempoolFeePrioritiesAllFromJSON(json: any): MempoolFeePrioritiesAll { + return MempoolFeePrioritiesAllFromJSONTyped(json, false); +} + +export function MempoolFeePrioritiesAllFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolFeePrioritiesAll { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'no_priority': json['no_priority'], + 'low_priority': json['low_priority'], + 'medium_priority': json['medium_priority'], + 'high_priority': json['high_priority'], + }; +} + +export function MempoolFeePrioritiesAllToJSON(value?: MempoolFeePrioritiesAll | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'no_priority': value.no_priority, + 'low_priority': value.low_priority, + 'medium_priority': value.medium_priority, + 'high_priority': value.high_priority, + }; +} + diff --git a/client/src/generated/models/MempoolTransactionListResponse.ts b/client/src/generated/models/MempoolTransactionListResponse.ts index 8b42e12e2c..c832556344 100644 --- a/client/src/generated/models/MempoolTransactionListResponse.ts +++ b/client/src/generated/models/MempoolTransactionListResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -78,4 +78,3 @@ export function MempoolTransactionListResponseToJSON(value?: MempoolTransactionL }; } - diff --git a/client/src/generated/models/MempoolTransactionStatsResponse.ts b/client/src/generated/models/MempoolTransactionStatsResponse.ts new file mode 100644 index 0000000000..42c0a28612 --- /dev/null +++ b/client/src/generated/models/MempoolTransactionStatsResponse.ts @@ -0,0 +1,99 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + MempoolTransactionStatsResponseTxAges, + MempoolTransactionStatsResponseTxAgesFromJSON, + MempoolTransactionStatsResponseTxAgesFromJSONTyped, + MempoolTransactionStatsResponseTxAgesToJSON, + MempoolTransactionStatsResponseTxByteSizes, + MempoolTransactionStatsResponseTxByteSizesFromJSON, + MempoolTransactionStatsResponseTxByteSizesFromJSONTyped, + MempoolTransactionStatsResponseTxByteSizesToJSON, + MempoolTransactionStatsResponseTxSimpleFeeAverages, + MempoolTransactionStatsResponseTxSimpleFeeAveragesFromJSON, + MempoolTransactionStatsResponseTxSimpleFeeAveragesFromJSONTyped, + MempoolTransactionStatsResponseTxSimpleFeeAveragesToJSON, + MempoolTransactionStatsResponseTxTypeCounts, + MempoolTransactionStatsResponseTxTypeCountsFromJSON, + MempoolTransactionStatsResponseTxTypeCountsFromJSONTyped, + MempoolTransactionStatsResponseTxTypeCountsToJSON, +} from './'; + +/** + * GET request that returns stats on mempool transactions + * @export + * @interface MempoolTransactionStatsResponse + */ +export interface MempoolTransactionStatsResponse { + /** + * + * @type {MempoolTransactionStatsResponseTxTypeCounts} + * @memberof MempoolTransactionStatsResponse + */ + tx_type_counts: MempoolTransactionStatsResponseTxTypeCounts; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAverages} + * @memberof MempoolTransactionStatsResponse + */ + tx_simple_fee_averages: MempoolTransactionStatsResponseTxSimpleFeeAverages; + /** + * + * @type {MempoolTransactionStatsResponseTxAges} + * @memberof MempoolTransactionStatsResponse + */ + tx_ages: MempoolTransactionStatsResponseTxAges; + /** + * + * @type {MempoolTransactionStatsResponseTxByteSizes} + * @memberof MempoolTransactionStatsResponse + */ + tx_byte_sizes: MempoolTransactionStatsResponseTxByteSizes; +} + +export function MempoolTransactionStatsResponseFromJSON(json: any): MempoolTransactionStatsResponse { + return MempoolTransactionStatsResponseFromJSONTyped(json, false); +} + +export function MempoolTransactionStatsResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolTransactionStatsResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'tx_type_counts': MempoolTransactionStatsResponseTxTypeCountsFromJSON(json['tx_type_counts']), + 'tx_simple_fee_averages': MempoolTransactionStatsResponseTxSimpleFeeAveragesFromJSON(json['tx_simple_fee_averages']), + 'tx_ages': MempoolTransactionStatsResponseTxAgesFromJSON(json['tx_ages']), + 'tx_byte_sizes': MempoolTransactionStatsResponseTxByteSizesFromJSON(json['tx_byte_sizes']), + }; +} + +export function MempoolTransactionStatsResponseToJSON(value?: MempoolTransactionStatsResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'tx_type_counts': MempoolTransactionStatsResponseTxTypeCountsToJSON(value.tx_type_counts), + 'tx_simple_fee_averages': MempoolTransactionStatsResponseTxSimpleFeeAveragesToJSON(value.tx_simple_fee_averages), + 'tx_ages': MempoolTransactionStatsResponseTxAgesToJSON(value.tx_ages), + 'tx_byte_sizes': MempoolTransactionStatsResponseTxByteSizesToJSON(value.tx_byte_sizes), + }; +} + diff --git a/client/src/generated/models/MempoolTransactionStatsResponseTxAges.ts b/client/src/generated/models/MempoolTransactionStatsResponseTxAges.ts new file mode 100644 index 0000000000..46e2ba5d29 --- /dev/null +++ b/client/src/generated/models/MempoolTransactionStatsResponseTxAges.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSONTyped, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON, +} from './'; + +/** + * The average time (in blocks) that transactions have lived in the mempool. The start block height is simply the current chain-tip of when the attached Stacks node receives the transaction. This timing can be different across Stacks nodes / API instances due to propagation timing differences in the p2p network. + * @export + * @interface MempoolTransactionStatsResponseTxAges + */ +export interface MempoolTransactionStatsResponseTxAges { + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxAges + */ + token_transfer: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxAges + */ + smart_contract: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxAges + */ + contract_call: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxAges + */ + poison_microblock: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; +} + +export function MempoolTransactionStatsResponseTxAgesFromJSON(json: any): MempoolTransactionStatsResponseTxAges { + return MempoolTransactionStatsResponseTxAgesFromJSONTyped(json, false); +} + +export function MempoolTransactionStatsResponseTxAgesFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolTransactionStatsResponseTxAges { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'token_transfer': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['token_transfer']), + 'smart_contract': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['smart_contract']), + 'contract_call': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['contract_call']), + 'poison_microblock': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['poison_microblock']), + }; +} + +export function MempoolTransactionStatsResponseTxAgesToJSON(value?: MempoolTransactionStatsResponseTxAges | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'token_transfer': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.token_transfer), + 'smart_contract': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.smart_contract), + 'contract_call': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.contract_call), + 'poison_microblock': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.poison_microblock), + }; +} + diff --git a/client/src/generated/models/MempoolTransactionStatsResponseTxByteSizes.ts b/client/src/generated/models/MempoolTransactionStatsResponseTxByteSizes.ts new file mode 100644 index 0000000000..7978098c52 --- /dev/null +++ b/client/src/generated/models/MempoolTransactionStatsResponseTxByteSizes.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSONTyped, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON, +} from './'; + +/** + * The average byte size of transactions in the mempool, broken down by transaction type. + * @export + * @interface MempoolTransactionStatsResponseTxByteSizes + */ +export interface MempoolTransactionStatsResponseTxByteSizes { + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxByteSizes + */ + token_transfer: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxByteSizes + */ + smart_contract: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxByteSizes + */ + contract_call: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxByteSizes + */ + poison_microblock: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; +} + +export function MempoolTransactionStatsResponseTxByteSizesFromJSON(json: any): MempoolTransactionStatsResponseTxByteSizes { + return MempoolTransactionStatsResponseTxByteSizesFromJSONTyped(json, false); +} + +export function MempoolTransactionStatsResponseTxByteSizesFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolTransactionStatsResponseTxByteSizes { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'token_transfer': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['token_transfer']), + 'smart_contract': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['smart_contract']), + 'contract_call': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['contract_call']), + 'poison_microblock': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['poison_microblock']), + }; +} + +export function MempoolTransactionStatsResponseTxByteSizesToJSON(value?: MempoolTransactionStatsResponseTxByteSizes | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'token_transfer': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.token_transfer), + 'smart_contract': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.smart_contract), + 'contract_call': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.contract_call), + 'poison_microblock': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.poison_microblock), + }; +} + diff --git a/client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAverages.ts b/client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAverages.ts new file mode 100644 index 0000000000..567b4242cd --- /dev/null +++ b/client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAverages.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSONTyped, + MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON, +} from './'; + +/** + * The simple mean (average) transaction fee, broken down by transaction type. Note that this does not factor in actual execution costs. The average fee is not a reliable metric for calculating a fee for a new transaction. + * @export + * @interface MempoolTransactionStatsResponseTxSimpleFeeAverages + */ +export interface MempoolTransactionStatsResponseTxSimpleFeeAverages { + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAverages + */ + token_transfer: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAverages + */ + smart_contract: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAverages + */ + contract_call: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; + /** + * + * @type {MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAverages + */ + poison_microblock: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer; +} + +export function MempoolTransactionStatsResponseTxSimpleFeeAveragesFromJSON(json: any): MempoolTransactionStatsResponseTxSimpleFeeAverages { + return MempoolTransactionStatsResponseTxSimpleFeeAveragesFromJSONTyped(json, false); +} + +export function MempoolTransactionStatsResponseTxSimpleFeeAveragesFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolTransactionStatsResponseTxSimpleFeeAverages { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'token_transfer': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['token_transfer']), + 'smart_contract': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['smart_contract']), + 'contract_call': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['contract_call']), + 'poison_microblock': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json['poison_microblock']), + }; +} + +export function MempoolTransactionStatsResponseTxSimpleFeeAveragesToJSON(value?: MempoolTransactionStatsResponseTxSimpleFeeAverages | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'token_transfer': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.token_transfer), + 'smart_contract': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.smart_contract), + 'contract_call': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.contract_call), + 'poison_microblock': MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value.poison_microblock), + }; +} + diff --git a/client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer.ts b/client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer.ts new file mode 100644 index 0000000000..b1fb3a49b8 --- /dev/null +++ b/client/src/generated/models/MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer + */ +export interface MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer { + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer + */ + p25: number | null; + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer + */ + p50: number | null; + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer + */ + p75: number | null; + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer + */ + p95: number | null; +} + +export function MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSON(json: any): MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer { + return MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSONTyped(json, false); +} + +export function MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'p25': json['p25'], + 'p50': json['p50'], + 'p75': json['p75'], + 'p95': json['p95'], + }; +} + +export function MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransferToJSON(value?: MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'p25': value.p25, + 'p50': value.p50, + 'p75': value.p75, + 'p95': value.p95, + }; +} + diff --git a/client/src/generated/models/MempoolTransactionStatsResponseTxTypeCounts.ts b/client/src/generated/models/MempoolTransactionStatsResponseTxTypeCounts.ts new file mode 100644 index 0000000000..4527e4b902 --- /dev/null +++ b/client/src/generated/models/MempoolTransactionStatsResponseTxTypeCounts.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Number of tranasction in the mempool, broken down by transaction type. + * @export + * @interface MempoolTransactionStatsResponseTxTypeCounts + */ +export interface MempoolTransactionStatsResponseTxTypeCounts { + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxTypeCounts + */ + token_transfer: number; + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxTypeCounts + */ + smart_contract: number; + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxTypeCounts + */ + contract_call: number; + /** + * + * @type {number} + * @memberof MempoolTransactionStatsResponseTxTypeCounts + */ + poison_microblock: number; +} + +export function MempoolTransactionStatsResponseTxTypeCountsFromJSON(json: any): MempoolTransactionStatsResponseTxTypeCounts { + return MempoolTransactionStatsResponseTxTypeCountsFromJSONTyped(json, false); +} + +export function MempoolTransactionStatsResponseTxTypeCountsFromJSONTyped(json: any, ignoreDiscriminator: boolean): MempoolTransactionStatsResponseTxTypeCounts { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'token_transfer': json['token_transfer'], + 'smart_contract': json['smart_contract'], + 'contract_call': json['contract_call'], + 'poison_microblock': json['poison_microblock'], + }; +} + +export function MempoolTransactionStatsResponseTxTypeCountsToJSON(value?: MempoolTransactionStatsResponseTxTypeCounts | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'token_transfer': value.token_transfer, + 'smart_contract': value.smart_contract, + 'contract_call': value.contract_call, + 'poison_microblock': value.poison_microblock, + }; +} + diff --git a/client/src/generated/models/Microblock.ts b/client/src/generated/models/Microblock.ts new file mode 100644 index 0000000000..ecafb1782a --- /dev/null +++ b/client/src/generated/models/Microblock.ts @@ -0,0 +1,160 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * A microblock + * @export + * @interface Microblock + */ +export interface Microblock { + /** + * Set to `true` if the microblock corresponds to the canonical chain tip. + * @type {boolean} + * @memberof Microblock + */ + canonical: boolean; + /** + * Set to `true` if the microblock was not orphaned in a following anchor block. Defaults to `true` if the following anchor block has not yet been created. + * @type {boolean} + * @memberof Microblock + */ + microblock_canonical: boolean; + /** + * The SHA512/256 hash of this microblock. + * @type {string} + * @memberof Microblock + */ + microblock_hash: string; + /** + * A hint to describe how to order a set of microblocks. Starts at 0. + * @type {number} + * @memberof Microblock + */ + microblock_sequence: number; + /** + * The SHA512/256 hash of the previous signed microblock in this stream. + * @type {string} + * @memberof Microblock + */ + microblock_parent_hash: string; + /** + * The anchor block height that confirmed this microblock. + * @type {number} + * @memberof Microblock + */ + block_height: number; + /** + * The height of the anchor block that preceded this microblock. + * @type {number} + * @memberof Microblock + */ + parent_block_height: number; + /** + * The hash of the anchor block that preceded this microblock. + * @type {string} + * @memberof Microblock + */ + parent_block_hash: string; + /** + * The hash of the Bitcoin block that preceded this microblock. + * @type {string} + * @memberof Microblock + */ + parent_burn_block_hash: string; + /** + * The block timestamp of the Bitcoin block that preceded this microblock. + * @type {number} + * @memberof Microblock + */ + parent_burn_block_time: number; + /** + * The ISO 8601 (YYYY-MM-DDTHH:mm:ss.sssZ) formatted block time of the bitcoin block that preceded this microblock. + * @type {string} + * @memberof Microblock + */ + parent_burn_block_time_iso: string; + /** + * The height of the Bitcoin block that preceded this microblock. + * @type {number} + * @memberof Microblock + */ + parent_burn_block_height: number; + /** + * The hash of the anchor block that confirmed this microblock. This wil be empty for unanchored microblocks + * @type {string} + * @memberof Microblock + */ + block_hash: string | null; + /** + * List of transactions included in the microblock + * @type {Array} + * @memberof Microblock + */ + txs: Array; +} + +export function MicroblockFromJSON(json: any): Microblock { + return MicroblockFromJSONTyped(json, false); +} + +export function MicroblockFromJSONTyped(json: any, ignoreDiscriminator: boolean): Microblock { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'canonical': json['canonical'], + 'microblock_canonical': json['microblock_canonical'], + 'microblock_hash': json['microblock_hash'], + 'microblock_sequence': json['microblock_sequence'], + 'microblock_parent_hash': json['microblock_parent_hash'], + 'block_height': json['block_height'], + 'parent_block_height': json['parent_block_height'], + 'parent_block_hash': json['parent_block_hash'], + 'parent_burn_block_hash': json['parent_burn_block_hash'], + 'parent_burn_block_time': json['parent_burn_block_time'], + 'parent_burn_block_time_iso': json['parent_burn_block_time_iso'], + 'parent_burn_block_height': json['parent_burn_block_height'], + 'block_hash': json['block_hash'], + 'txs': json['txs'], + }; +} + +export function MicroblockToJSON(value?: Microblock | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'canonical': value.canonical, + 'microblock_canonical': value.microblock_canonical, + 'microblock_hash': value.microblock_hash, + 'microblock_sequence': value.microblock_sequence, + 'microblock_parent_hash': value.microblock_parent_hash, + 'block_height': value.block_height, + 'parent_block_height': value.parent_block_height, + 'parent_block_hash': value.parent_block_hash, + 'parent_burn_block_hash': value.parent_burn_block_hash, + 'parent_burn_block_time': value.parent_burn_block_time, + 'parent_burn_block_time_iso': value.parent_burn_block_time_iso, + 'parent_burn_block_height': value.parent_burn_block_height, + 'block_hash': value.block_hash, + 'txs': value.txs, + }; +} + diff --git a/client/src/generated/models/MicroblockListResponse.ts b/client/src/generated/models/MicroblockListResponse.ts new file mode 100644 index 0000000000..70865e8f68 --- /dev/null +++ b/client/src/generated/models/MicroblockListResponse.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + Microblock, + MicroblockFromJSON, + MicroblockFromJSONTyped, + MicroblockToJSON, +} from './'; + +/** + * GET request that returns microblocks + * @export + * @interface MicroblockListResponse + */ +export interface MicroblockListResponse { + /** + * The number of microblocks to return + * @type {number} + * @memberof MicroblockListResponse + */ + limit: number; + /** + * The number to microblocks to skip (starting at `0`) + * @type {number} + * @memberof MicroblockListResponse + */ + offset: number; + /** + * The number of microblocks available + * @type {number} + * @memberof MicroblockListResponse + */ + total: number; + /** + * + * @type {Array} + * @memberof MicroblockListResponse + */ + results: Array; +} + +export function MicroblockListResponseFromJSON(json: any): MicroblockListResponse { + return MicroblockListResponseFromJSONTyped(json, false); +} + +export function MicroblockListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): MicroblockListResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': ((json['results'] as Array).map(MicroblockFromJSON)), + }; +} + +export function MicroblockListResponseToJSON(value?: MicroblockListResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': ((value.results as Array).map(MicroblockToJSON)), + }; +} + diff --git a/client/src/generated/models/NetworkBlockTimeResponse.ts b/client/src/generated/models/NetworkBlockTimeResponse.ts index edfaffadd8..245838cb94 100644 --- a/client/src/generated/models/NetworkBlockTimeResponse.ts +++ b/client/src/generated/models/NetworkBlockTimeResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,4 +54,3 @@ export function NetworkBlockTimeResponseToJSON(value?: NetworkBlockTimeResponse }; } - diff --git a/client/src/generated/models/NetworkBlockTimesResponse.ts b/client/src/generated/models/NetworkBlockTimesResponse.ts index e6042cc236..2471adcbbc 100644 --- a/client/src/generated/models/NetworkBlockTimesResponse.ts +++ b/client/src/generated/models/NetworkBlockTimesResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,10 +14,10 @@ import { exists, mapValues } from '../runtime'; import { - NetworkBlockTimesResponseMainnet, - NetworkBlockTimesResponseMainnetFromJSON, - NetworkBlockTimesResponseMainnetFromJSONTyped, - NetworkBlockTimesResponseMainnetToJSON, + TargetBlockTime, + TargetBlockTimeFromJSON, + TargetBlockTimeFromJSONTyped, + TargetBlockTimeToJSON, } from './'; /** @@ -28,16 +28,16 @@ import { export interface NetworkBlockTimesResponse { /** * - * @type {NetworkBlockTimesResponseMainnet} + * @type {TargetBlockTime} * @memberof NetworkBlockTimesResponse */ - mainnet: NetworkBlockTimesResponseMainnet; + mainnet: TargetBlockTime; /** * - * @type {NetworkBlockTimesResponseMainnet} + * @type {TargetBlockTime} * @memberof NetworkBlockTimesResponse */ - testnet: NetworkBlockTimesResponseMainnet; + testnet: TargetBlockTime; } export function NetworkBlockTimesResponseFromJSON(json: any): NetworkBlockTimesResponse { @@ -50,8 +50,8 @@ export function NetworkBlockTimesResponseFromJSONTyped(json: any, ignoreDiscrimi } return { - 'mainnet': NetworkBlockTimesResponseMainnetFromJSON(json['mainnet']), - 'testnet': NetworkBlockTimesResponseMainnetFromJSON(json['testnet']), + 'mainnet': TargetBlockTimeFromJSON(json['mainnet']), + 'testnet': TargetBlockTimeFromJSON(json['testnet']), }; } @@ -64,9 +64,8 @@ export function NetworkBlockTimesResponseToJSON(value?: NetworkBlockTimesRespons } return { - 'mainnet': NetworkBlockTimesResponseMainnetToJSON(value.mainnet), - 'testnet': NetworkBlockTimesResponseMainnetToJSON(value.testnet), + 'mainnet': TargetBlockTimeToJSON(value.mainnet), + 'testnet': TargetBlockTimeToJSON(value.testnet), }; } - diff --git a/client/src/generated/models/NetworkBlockTimesResponseMainnet.ts b/client/src/generated/models/NetworkBlockTimesResponseMainnet.ts deleted file mode 100644 index ffdbdf25a1..0000000000 --- a/client/src/generated/models/NetworkBlockTimesResponseMainnet.ts +++ /dev/null @@ -1,57 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * TargetBlockTime - * @export - * @interface NetworkBlockTimesResponseMainnet - */ -export interface NetworkBlockTimesResponseMainnet { - /** - * - * @type {number} - * @memberof NetworkBlockTimesResponseMainnet - */ - target_block_time: number; -} - -export function NetworkBlockTimesResponseMainnetFromJSON(json: any): NetworkBlockTimesResponseMainnet { - return NetworkBlockTimesResponseMainnetFromJSONTyped(json, false); -} - -export function NetworkBlockTimesResponseMainnetFromJSONTyped(json: any, ignoreDiscriminator: boolean): NetworkBlockTimesResponseMainnet { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'target_block_time': json['target_block_time'], - }; -} - -export function NetworkBlockTimesResponseMainnetToJSON(value?: NetworkBlockTimesResponseMainnet | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'target_block_time': value.target_block_time, - }; -} - - diff --git a/client/src/generated/models/NetworkIdentifier.ts b/client/src/generated/models/NetworkIdentifier.ts index 85e2e18a54..cb5dacde67 100644 --- a/client/src/generated/models/NetworkIdentifier.ts +++ b/client/src/generated/models/NetworkIdentifier.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -77,4 +77,3 @@ export function NetworkIdentifierToJSON(value?: NetworkIdentifier | null): any { }; } - diff --git a/client/src/generated/models/NftEvent.ts b/client/src/generated/models/NftEvent.ts new file mode 100644 index 0000000000..d6b73f8ba1 --- /dev/null +++ b/client/src/generated/models/NftEvent.ts @@ -0,0 +1,127 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + AddressNftListResponseValue, + AddressNftListResponseValueFromJSON, + AddressNftListResponseValueFromJSONTyped, + AddressNftListResponseValueToJSON, +} from './'; + +/** + * + * @export + * @interface NftEvent + */ +export interface NftEvent { + /** + * + * @type {string} + * @memberof NftEvent + */ + sender?: string; + /** + * + * @type {string} + * @memberof NftEvent + */ + recipient?: string; + /** + * + * @type {string} + * @memberof NftEvent + */ + asset_identifier: string; + /** + * + * @type {string} + * @memberof NftEvent + */ + asset_event_type: string; + /** + * + * @type {AddressNftListResponseValue} + * @memberof NftEvent + */ + value: AddressNftListResponseValue; + /** + * + * @type {string} + * @memberof NftEvent + */ + tx_id: string; + /** + * + * @type {number} + * @memberof NftEvent + */ + tx_index: number; + /** + * + * @type {number} + * @memberof NftEvent + */ + block_height: number; + /** + * + * @type {number} + * @memberof NftEvent + */ + event_index: number; +} + +export function NftEventFromJSON(json: any): NftEvent { + return NftEventFromJSONTyped(json, false); +} + +export function NftEventFromJSONTyped(json: any, ignoreDiscriminator: boolean): NftEvent { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'sender': !exists(json, 'sender') ? undefined : json['sender'], + 'recipient': !exists(json, 'recipient') ? undefined : json['recipient'], + 'asset_identifier': json['asset_identifier'], + 'asset_event_type': json['asset_event_type'], + 'value': AddressNftListResponseValueFromJSON(json['value']), + 'tx_id': json['tx_id'], + 'tx_index': json['tx_index'], + 'block_height': json['block_height'], + 'event_index': json['event_index'], + }; +} + +export function NftEventToJSON(value?: NftEvent | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'sender': value.sender, + 'recipient': value.recipient, + 'asset_identifier': value.asset_identifier, + 'asset_event_type': value.asset_event_type, + 'value': AddressNftListResponseValueToJSON(value.value), + 'tx_id': value.tx_id, + 'tx_index': value.tx_index, + 'block_height': value.block_height, + 'event_index': value.event_index, + }; +} + diff --git a/client/src/generated/models/NonFungibleTokenHistoryEventList.ts b/client/src/generated/models/NonFungibleTokenHistoryEventList.ts new file mode 100644 index 0000000000..bfbbd26d9f --- /dev/null +++ b/client/src/generated/models/NonFungibleTokenHistoryEventList.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * List of Non-Fungible Token history events + * @export + * @interface NonFungibleTokenHistoryEventList + */ +export interface NonFungibleTokenHistoryEventList { + /** + * The number of events to return + * @type {number} + * @memberof NonFungibleTokenHistoryEventList + */ + limit: number; + /** + * The number to events to skip (starting at `0`) + * @type {number} + * @memberof NonFungibleTokenHistoryEventList + */ + offset: number; + /** + * The number of events available + * @type {number} + * @memberof NonFungibleTokenHistoryEventList + */ + total: number; + /** + * + * @type {Array} + * @memberof NonFungibleTokenHistoryEventList + */ + results: Array; +} + +export function NonFungibleTokenHistoryEventListFromJSON(json: any): NonFungibleTokenHistoryEventList { + return NonFungibleTokenHistoryEventListFromJSONTyped(json, false); +} + +export function NonFungibleTokenHistoryEventListFromJSONTyped(json: any, ignoreDiscriminator: boolean): NonFungibleTokenHistoryEventList { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': json['results'], + }; +} + +export function NonFungibleTokenHistoryEventListToJSON(value?: NonFungibleTokenHistoryEventList | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': value.results, + }; +} + diff --git a/client/src/generated/models/NonFungibleTokenHoldingsList.ts b/client/src/generated/models/NonFungibleTokenHoldingsList.ts new file mode 100644 index 0000000000..5f190e2264 --- /dev/null +++ b/client/src/generated/models/NonFungibleTokenHoldingsList.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * List of Non-Fungible Token holdings + * @export + * @interface NonFungibleTokenHoldingsList + */ +export interface NonFungibleTokenHoldingsList { + /** + * The number of Non-Fungible Token holdings to return + * @type {number} + * @memberof NonFungibleTokenHoldingsList + */ + limit: number; + /** + * The number to Non-Fungible Token holdings to skip (starting at `0`) + * @type {number} + * @memberof NonFungibleTokenHoldingsList + */ + offset: number; + /** + * The number of Non-Fungible Token holdings available + * @type {number} + * @memberof NonFungibleTokenHoldingsList + */ + total: number; + /** + * + * @type {Array} + * @memberof NonFungibleTokenHoldingsList + */ + results: Array; +} + +export function NonFungibleTokenHoldingsListFromJSON(json: any): NonFungibleTokenHoldingsList { + return NonFungibleTokenHoldingsListFromJSONTyped(json, false); +} + +export function NonFungibleTokenHoldingsListFromJSONTyped(json: any, ignoreDiscriminator: boolean): NonFungibleTokenHoldingsList { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': json['results'], + }; +} + +export function NonFungibleTokenHoldingsListToJSON(value?: NonFungibleTokenHoldingsList | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': value.results, + }; +} + diff --git a/client/src/generated/models/NonFungibleTokenMetadata.ts b/client/src/generated/models/NonFungibleTokenMetadata.ts new file mode 100644 index 0000000000..e64fbb2c67 --- /dev/null +++ b/client/src/generated/models/NonFungibleTokenMetadata.ts @@ -0,0 +1,104 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface NonFungibleTokenMetadata + */ +export interface NonFungibleTokenMetadata { + /** + * An optional string that is a valid URI which resolves to this token's metadata. Can be empty. + * @type {string} + * @memberof NonFungibleTokenMetadata + */ + token_uri: string; + /** + * Identifies the asset to which this token represents + * @type {string} + * @memberof NonFungibleTokenMetadata + */ + name: string; + /** + * Describes the asset to which this token represents + * @type {string} + * @memberof NonFungibleTokenMetadata + */ + description: string; + /** + * A URI pointing to a resource with mime type image/* representing the asset to which this token represents. The API may provide a URI to a cached resource, dependending on configuration. Otherwise, this can be the same value as the canonical image URI. + * @type {string} + * @memberof NonFungibleTokenMetadata + */ + image_uri: string; + /** + * The original image URI specified by the contract. A URI pointing to a resource with mime type image/* representing the asset to which this token represents. Consider making any images at a width between 320 and 1080 pixels and aspect ratio between 1.91:1 and 4:5 inclusive. + * @type {string} + * @memberof NonFungibleTokenMetadata + */ + image_canonical_uri: string; + /** + * Tx id that deployed the contract + * @type {string} + * @memberof NonFungibleTokenMetadata + */ + tx_id: string; + /** + * principle that deployed the contract + * @type {string} + * @memberof NonFungibleTokenMetadata + */ + sender_address: string; +} + +export function NonFungibleTokenMetadataFromJSON(json: any): NonFungibleTokenMetadata { + return NonFungibleTokenMetadataFromJSONTyped(json, false); +} + +export function NonFungibleTokenMetadataFromJSONTyped(json: any, ignoreDiscriminator: boolean): NonFungibleTokenMetadata { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'token_uri': json['token_uri'], + 'name': json['name'], + 'description': json['description'], + 'image_uri': json['image_uri'], + 'image_canonical_uri': json['image_canonical_uri'], + 'tx_id': json['tx_id'], + 'sender_address': json['sender_address'], + }; +} + +export function NonFungibleTokenMetadataToJSON(value?: NonFungibleTokenMetadata | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'token_uri': value.token_uri, + 'name': value.name, + 'description': value.description, + 'image_uri': value.image_uri, + 'image_canonical_uri': value.image_canonical_uri, + 'tx_id': value.tx_id, + 'sender_address': value.sender_address, + }; +} + diff --git a/client/src/generated/models/NonFungibleTokenMintList.ts b/client/src/generated/models/NonFungibleTokenMintList.ts new file mode 100644 index 0000000000..2e3b5a7579 --- /dev/null +++ b/client/src/generated/models/NonFungibleTokenMintList.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * List of Non-Fungible Token mint events for an asset identifier + * @export + * @interface NonFungibleTokenMintList + */ +export interface NonFungibleTokenMintList { + /** + * The number of mint events to return + * @type {number} + * @memberof NonFungibleTokenMintList + */ + limit: number; + /** + * The number to mint events to skip (starting at `0`) + * @type {number} + * @memberof NonFungibleTokenMintList + */ + offset: number; + /** + * The number of mint events available + * @type {number} + * @memberof NonFungibleTokenMintList + */ + total: number; + /** + * + * @type {Array} + * @memberof NonFungibleTokenMintList + */ + results: Array; +} + +export function NonFungibleTokenMintListFromJSON(json: any): NonFungibleTokenMintList { + return NonFungibleTokenMintListFromJSONTyped(json, false); +} + +export function NonFungibleTokenMintListFromJSONTyped(json: any, ignoreDiscriminator: boolean): NonFungibleTokenMintList { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': json['results'], + }; +} + +export function NonFungibleTokenMintListToJSON(value?: NonFungibleTokenMintList | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': value.results, + }; +} + diff --git a/client/src/generated/models/NonFungibleTokensMetadataList.ts b/client/src/generated/models/NonFungibleTokensMetadataList.ts new file mode 100644 index 0000000000..b9f20627c2 --- /dev/null +++ b/client/src/generated/models/NonFungibleTokensMetadataList.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + NonFungibleTokenMetadata, + NonFungibleTokenMetadataFromJSON, + NonFungibleTokenMetadataFromJSONTyped, + NonFungibleTokenMetadataToJSON, +} from './'; + +/** + * List of non fungible tokens metadata + * @export + * @interface NonFungibleTokensMetadataList + */ +export interface NonFungibleTokensMetadataList { + /** + * The number of tokens metadata to return + * @type {number} + * @memberof NonFungibleTokensMetadataList + */ + limit: number; + /** + * The number to tokens metadata to skip (starting at `0`) + * @type {number} + * @memberof NonFungibleTokensMetadataList + */ + offset: number; + /** + * The number of tokens metadata available + * @type {number} + * @memberof NonFungibleTokensMetadataList + */ + total: number; + /** + * + * @type {Array} + * @memberof NonFungibleTokensMetadataList + */ + results: Array; +} + +export function NonFungibleTokensMetadataListFromJSON(json: any): NonFungibleTokensMetadataList { + return NonFungibleTokensMetadataListFromJSONTyped(json, false); +} + +export function NonFungibleTokensMetadataListFromJSONTyped(json: any, ignoreDiscriminator: boolean): NonFungibleTokensMetadataList { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': ((json['results'] as Array).map(NonFungibleTokenMetadataFromJSON)), + }; +} + +export function NonFungibleTokensMetadataListToJSON(value?: NonFungibleTokensMetadataList | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': ((value.results as Array).map(NonFungibleTokenMetadataToJSON)), + }; +} + diff --git a/client/src/generated/models/OtherTransactionIdentifier.ts b/client/src/generated/models/OtherTransactionIdentifier.ts new file mode 100644 index 0000000000..fcaa8f0468 --- /dev/null +++ b/client/src/generated/models/OtherTransactionIdentifier.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * The transaction_identifier uniquely identifies a transaction in a particular network and block or in the mempool. + * @export + * @interface OtherTransactionIdentifier + */ +export interface OtherTransactionIdentifier { + /** + * Any transactions that are attributable only to a block (ex: a block event) should use the hash of the block as the identifier. + * @type {string} + * @memberof OtherTransactionIdentifier + */ + hash: string; +} + +export function OtherTransactionIdentifierFromJSON(json: any): OtherTransactionIdentifier { + return OtherTransactionIdentifierFromJSONTyped(json, false); +} + +export function OtherTransactionIdentifierFromJSONTyped(json: any, ignoreDiscriminator: boolean): OtherTransactionIdentifier { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'hash': json['hash'], + }; +} + +export function OtherTransactionIdentifierToJSON(value?: OtherTransactionIdentifier | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'hash': value.hash, + }; +} + diff --git a/client/src/generated/models/PoolDelegation.ts b/client/src/generated/models/PoolDelegation.ts new file mode 100644 index 0000000000..06165beb3f --- /dev/null +++ b/client/src/generated/models/PoolDelegation.ts @@ -0,0 +1,96 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface PoolDelegation + */ +export interface PoolDelegation { + /** + * The principal of the pool member that issued the delegation + * @type {string} + * @memberof PoolDelegation + */ + stacker: string; + /** + * The pox-addr value specified by the stacker in the delegation operation + * @type {string} + * @memberof PoolDelegation + */ + pox_addr?: string; + /** + * The amount of uSTX delegated by the stacker + * @type {string} + * @memberof PoolDelegation + */ + amount_ustx: string; + /** + * The optional burnchain block unlock height that the stacker may have specified + * @type {number} + * @memberof PoolDelegation + */ + burn_block_unlock_height?: number; + /** + * The block height at which the stacker delegation transaction was mined at + * @type {number} + * @memberof PoolDelegation + */ + block_height: number; + /** + * The tx_id of the stacker delegation operation + * @type {string} + * @memberof PoolDelegation + */ + tx_id: string; +} + +export function PoolDelegationFromJSON(json: any): PoolDelegation { + return PoolDelegationFromJSONTyped(json, false); +} + +export function PoolDelegationFromJSONTyped(json: any, ignoreDiscriminator: boolean): PoolDelegation { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'stacker': json['stacker'], + 'pox_addr': !exists(json, 'pox_addr') ? undefined : json['pox_addr'], + 'amount_ustx': json['amount_ustx'], + 'burn_block_unlock_height': !exists(json, 'burn_block_unlock_height') ? undefined : json['burn_block_unlock_height'], + 'block_height': json['block_height'], + 'tx_id': json['tx_id'], + }; +} + +export function PoolDelegationToJSON(value?: PoolDelegation | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'stacker': value.stacker, + 'pox_addr': value.pox_addr, + 'amount_ustx': value.amount_ustx, + 'burn_block_unlock_height': value.burn_block_unlock_height, + 'block_height': value.block_height, + 'tx_id': value.tx_id, + }; +} + diff --git a/client/src/generated/models/PoolDelegationsResponse.ts b/client/src/generated/models/PoolDelegationsResponse.ts new file mode 100644 index 0000000000..0e931bdf75 --- /dev/null +++ b/client/src/generated/models/PoolDelegationsResponse.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + PoolDelegation, + PoolDelegationFromJSON, + PoolDelegationFromJSONTyped, + PoolDelegationToJSON, +} from './'; + +/** + * GET request that returns stacking pool member details for a given pool (delegator) principal + * @export + * @interface PoolDelegationsResponse + */ +export interface PoolDelegationsResponse { + /** + * The number of Stackers to return + * @type {number} + * @memberof PoolDelegationsResponse + */ + limit: number; + /** + * The number to Stackers to skip (starting at `0`) + * @type {number} + * @memberof PoolDelegationsResponse + */ + offset: number; + /** + * The total number of Stackers + * @type {number} + * @memberof PoolDelegationsResponse + */ + total: number; + /** + * + * @type {Array} + * @memberof PoolDelegationsResponse + */ + results: Array; +} + +export function PoolDelegationsResponseFromJSON(json: any): PoolDelegationsResponse { + return PoolDelegationsResponseFromJSONTyped(json, false); +} + +export function PoolDelegationsResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): PoolDelegationsResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'total': json['total'], + 'results': ((json['results'] as Array).map(PoolDelegationFromJSON)), + }; +} + +export function PoolDelegationsResponseToJSON(value?: PoolDelegationsResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'total': value.total, + 'results': ((value.results as Array).map(PoolDelegationToJSON)), + }; +} + diff --git a/client/src/generated/models/PostCoreNodeTransactionsError.ts b/client/src/generated/models/PostCoreNodeTransactionsError.ts index 23d10050f1..6c7d850454 100644 --- a/client/src/generated/models/PostCoreNodeTransactionsError.ts +++ b/client/src/generated/models/PostCoreNodeTransactionsError.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -78,4 +78,3 @@ export function PostCoreNodeTransactionsErrorToJSON(value?: PostCoreNodeTransact }; } - diff --git a/client/src/generated/models/ReadOnlyFunctionArgs.ts b/client/src/generated/models/ReadOnlyFunctionArgs.ts index 0b103702f5..0feaed7d22 100644 --- a/client/src/generated/models/ReadOnlyFunctionArgs.ts +++ b/client/src/generated/models/ReadOnlyFunctionArgs.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function ReadOnlyFunctionArgsToJSON(value?: ReadOnlyFunctionArgs | null): }; } - diff --git a/client/src/generated/models/ReadOnlyFunctionSuccessResponse.ts b/client/src/generated/models/ReadOnlyFunctionSuccessResponse.ts index 5f03861002..01a24eb90c 100644 --- a/client/src/generated/models/ReadOnlyFunctionSuccessResponse.ts +++ b/client/src/generated/models/ReadOnlyFunctionSuccessResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -70,4 +70,3 @@ export function ReadOnlyFunctionSuccessResponseToJSON(value?: ReadOnlyFunctionSu }; } - diff --git a/client/src/generated/models/RosettaAccount.ts b/client/src/generated/models/RosettaAccount.ts index baaf5c29e7..7fa9faa752 100644 --- a/client/src/generated/models/RosettaAccount.ts +++ b/client/src/generated/models/RosettaAccount.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -77,4 +77,3 @@ export function RosettaAccountToJSON(value?: RosettaAccount | null): any { }; } - diff --git a/client/src/generated/models/RosettaAccountBalanceRequest.ts b/client/src/generated/models/RosettaAccountBalanceRequest.ts index db92d4910f..c3148c87a2 100644 --- a/client/src/generated/models/RosettaAccountBalanceRequest.ts +++ b/client/src/generated/models/RosettaAccountBalanceRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -81,4 +81,3 @@ export function RosettaAccountBalanceRequestToJSON(value?: RosettaAccountBalance }; } - diff --git a/client/src/generated/models/RosettaAccountBalanceResponse.ts b/client/src/generated/models/RosettaAccountBalanceResponse.ts index d7958063a3..667eac2428 100644 --- a/client/src/generated/models/RosettaAccountBalanceResponse.ts +++ b/client/src/generated/models/RosettaAccountBalanceResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -39,7 +39,7 @@ export interface RosettaAccountBalanceResponse { * @type {object} * @memberof RosettaAccountBalanceResponse */ - block_identifier: object; + block_identifier: object | null; /** * A single account balance may have multiple currencies * @type {Array} @@ -93,4 +93,3 @@ export function RosettaAccountBalanceResponseToJSON(value?: RosettaAccountBalanc }; } - diff --git a/client/src/generated/models/RosettaAccountBalanceResponseCoinIdentifier.ts b/client/src/generated/models/RosettaAccountBalanceResponseCoinIdentifier.ts index 508700f6f3..1e179d5ca5 100644 --- a/client/src/generated/models/RosettaAccountBalanceResponseCoinIdentifier.ts +++ b/client/src/generated/models/RosettaAccountBalanceResponseCoinIdentifier.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,4 +54,3 @@ export function RosettaAccountBalanceResponseCoinIdentifierToJSON(value?: Rosett }; } - diff --git a/client/src/generated/models/RosettaAccountBalanceResponseMetadata.ts b/client/src/generated/models/RosettaAccountBalanceResponseMetadata.ts index 0e94579f7e..2b46f2c558 100644 --- a/client/src/generated/models/RosettaAccountBalanceResponseMetadata.ts +++ b/client/src/generated/models/RosettaAccountBalanceResponseMetadata.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,4 +54,3 @@ export function RosettaAccountBalanceResponseMetadataToJSON(value?: RosettaAccou }; } - diff --git a/client/src/generated/models/RosettaAccountIdentifier.ts b/client/src/generated/models/RosettaAccountIdentifier.ts new file mode 100644 index 0000000000..8a2ddaae6a --- /dev/null +++ b/client/src/generated/models/RosettaAccountIdentifier.ts @@ -0,0 +1,79 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + RosettaSubAccount, + RosettaSubAccountFromJSON, + RosettaSubAccountFromJSONTyped, + RosettaSubAccountToJSON, +} from './'; + +/** + * The account_identifier uniquely identifies an account within a network. All fields in the account_identifier are utilized to determine this uniqueness (including the metadata field, if populated). + * @export + * @interface RosettaAccountIdentifier + */ +export interface RosettaAccountIdentifier { + /** + * The address may be a cryptographic public key (or some encoding of it) or a provided username. + * @type {string} + * @memberof RosettaAccountIdentifier + */ + address: string; + /** + * + * @type {RosettaSubAccount} + * @memberof RosettaAccountIdentifier + */ + sub_account?: RosettaSubAccount; + /** + * Blockchains that utilize a username model (where the address is not a derivative of a cryptographic public key) should specify the public key(s) owned by the address in metadata. + * @type {object} + * @memberof RosettaAccountIdentifier + */ + metadata?: object; +} + +export function RosettaAccountIdentifierFromJSON(json: any): RosettaAccountIdentifier { + return RosettaAccountIdentifierFromJSONTyped(json, false); +} + +export function RosettaAccountIdentifierFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaAccountIdentifier { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'address': json['address'], + 'sub_account': !exists(json, 'sub_account') ? undefined : RosettaSubAccountFromJSON(json['sub_account']), + 'metadata': !exists(json, 'metadata') ? undefined : json['metadata'], + }; +} + +export function RosettaAccountIdentifierToJSON(value?: RosettaAccountIdentifier | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'address': value.address, + 'sub_account': RosettaSubAccountToJSON(value.sub_account), + 'metadata': value.metadata, + }; +} + diff --git a/client/src/generated/models/RosettaAmount.ts b/client/src/generated/models/RosettaAmount.ts index e54c4f9b53..75f6302f63 100644 --- a/client/src/generated/models/RosettaAmount.ts +++ b/client/src/generated/models/RosettaAmount.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -77,4 +77,3 @@ export function RosettaAmountToJSON(value?: RosettaAmount | null): any { }; } - diff --git a/client/src/generated/models/RosettaBlock.ts b/client/src/generated/models/RosettaBlock.ts index 1ca85eee7b..03143ae957 100644 --- a/client/src/generated/models/RosettaBlock.ts +++ b/client/src/generated/models/RosettaBlock.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,10 +14,10 @@ import { exists, mapValues } from '../runtime'; import { - RosettaBlockMetadata2, - RosettaBlockMetadata2FromJSON, - RosettaBlockMetadata2FromJSONTyped, - RosettaBlockMetadata2ToJSON, + RosettaBlockMetadata1, + RosettaBlockMetadata1FromJSON, + RosettaBlockMetadata1FromJSONTyped, + RosettaBlockMetadata1ToJSON, RosettaParentBlockIdentifier, RosettaParentBlockIdentifierFromJSON, RosettaParentBlockIdentifierFromJSONTyped, @@ -39,7 +39,7 @@ export interface RosettaBlock { * @type {object} * @memberof RosettaBlock */ - block_identifier: object; + block_identifier: object | null; /** * * @type {RosettaParentBlockIdentifier} @@ -60,10 +60,10 @@ export interface RosettaBlock { transactions: Array; /** * - * @type {RosettaBlockMetadata2} + * @type {RosettaBlockMetadata1} * @memberof RosettaBlock */ - metadata?: RosettaBlockMetadata2; + metadata?: RosettaBlockMetadata1; } export function RosettaBlockFromJSON(json: any): RosettaBlock { @@ -80,7 +80,7 @@ export function RosettaBlockFromJSONTyped(json: any, ignoreDiscriminator: boolea 'parent_block_identifier': RosettaParentBlockIdentifierFromJSON(json['parent_block_identifier']), 'timestamp': json['timestamp'], 'transactions': ((json['transactions'] as Array).map(RosettaTransactionFromJSON)), - 'metadata': !exists(json, 'metadata') ? undefined : RosettaBlockMetadata2FromJSON(json['metadata']), + 'metadata': !exists(json, 'metadata') ? undefined : RosettaBlockMetadata1FromJSON(json['metadata']), }; } @@ -97,8 +97,7 @@ export function RosettaBlockToJSON(value?: RosettaBlock | null): any { 'parent_block_identifier': RosettaParentBlockIdentifierToJSON(value.parent_block_identifier), 'timestamp': value.timestamp, 'transactions': ((value.transactions as Array).map(RosettaTransactionToJSON)), - 'metadata': RosettaBlockMetadata2ToJSON(value.metadata), + 'metadata': RosettaBlockMetadata1ToJSON(value.metadata), }; } - diff --git a/client/src/generated/models/RosettaBlockMetadata.ts b/client/src/generated/models/RosettaBlockMetadata.ts index 7840036b1c..82fa5fd047 100644 --- a/client/src/generated/models/RosettaBlockMetadata.ts +++ b/client/src/generated/models/RosettaBlockMetadata.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,23 +14,29 @@ import { exists, mapValues } from '../runtime'; /** - * Operations Meta Data + * Transactions that are related to other transactions (like a cross-shard transaction) should include the tranaction_identifier of these transactions in the metadata. * @export * @interface RosettaBlockMetadata */ export interface RosettaBlockMetadata { /** - * The asm + * STX token transfer memo. * @type {string} * @memberof RosettaBlockMetadata */ - asm: string; + memo?: string; /** - * The hex - * @type {string} + * The Size + * @type {number} * @memberof RosettaBlockMetadata */ - hex: string; + size?: number; + /** + * The locktime + * @type {number} + * @memberof RosettaBlockMetadata + */ + lockTime?: number; } export function RosettaBlockMetadataFromJSON(json: any): RosettaBlockMetadata { @@ -43,8 +49,9 @@ export function RosettaBlockMetadataFromJSONTyped(json: any, ignoreDiscriminator } return { - 'asm': json['asm'], - 'hex': json['hex'], + 'memo': !exists(json, 'memo') ? undefined : json['memo'], + 'size': !exists(json, 'size') ? undefined : json['size'], + 'lockTime': !exists(json, 'lockTime') ? undefined : json['lockTime'], }; } @@ -57,9 +64,9 @@ export function RosettaBlockMetadataToJSON(value?: RosettaBlockMetadata | null): } return { - 'asm': value.asm, - 'hex': value.hex, + 'memo': value.memo, + 'size': value.size, + 'lockTime': value.lockTime, }; } - diff --git a/client/src/generated/models/RosettaBlockMetadata1.ts b/client/src/generated/models/RosettaBlockMetadata1.ts index 589c0f4202..301da689c0 100644 --- a/client/src/generated/models/RosettaBlockMetadata1.ts +++ b/client/src/generated/models/RosettaBlockMetadata1.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,23 +14,23 @@ import { exists, mapValues } from '../runtime'; /** - * Transactions that are related to other transactions (like a cross-shard transaction) should include the tranaction_identifier of these transactions in the metadata. + * meta data * @export * @interface RosettaBlockMetadata1 */ export interface RosettaBlockMetadata1 { /** - * The Size - * @type {number} + * + * @type {string} * @memberof RosettaBlockMetadata1 */ - size: number; + transactions_root: string; /** - * The locktime - * @type {number} + * + * @type {string} * @memberof RosettaBlockMetadata1 */ - lockTime: number; + difficulty: string; } export function RosettaBlockMetadata1FromJSON(json: any): RosettaBlockMetadata1 { @@ -43,8 +43,8 @@ export function RosettaBlockMetadata1FromJSONTyped(json: any, ignoreDiscriminato } return { - 'size': json['size'], - 'lockTime': json['lockTime'], + 'transactions_root': json['transactions_root'], + 'difficulty': json['difficulty'], }; } @@ -57,9 +57,8 @@ export function RosettaBlockMetadata1ToJSON(value?: RosettaBlockMetadata1 | null } return { - 'size': value.size, - 'lockTime': value.lockTime, + 'transactions_root': value.transactions_root, + 'difficulty': value.difficulty, }; } - diff --git a/client/src/generated/models/RosettaBlockMetadata2.ts b/client/src/generated/models/RosettaBlockMetadata2.ts deleted file mode 100644 index 60e730d11e..0000000000 --- a/client/src/generated/models/RosettaBlockMetadata2.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * meta data - * @export - * @interface RosettaBlockMetadata2 - */ -export interface RosettaBlockMetadata2 { - /** - * - * @type {string} - * @memberof RosettaBlockMetadata2 - */ - transactions_root: string; - /** - * - * @type {string} - * @memberof RosettaBlockMetadata2 - */ - difficulty: string; -} - -export function RosettaBlockMetadata2FromJSON(json: any): RosettaBlockMetadata2 { - return RosettaBlockMetadata2FromJSONTyped(json, false); -} - -export function RosettaBlockMetadata2FromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaBlockMetadata2 { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'transactions_root': json['transactions_root'], - 'difficulty': json['difficulty'], - }; -} - -export function RosettaBlockMetadata2ToJSON(value?: RosettaBlockMetadata2 | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'transactions_root': value.transactions_root, - 'difficulty': value.difficulty, - }; -} - - diff --git a/client/src/generated/models/RosettaBlockRequest.ts b/client/src/generated/models/RosettaBlockRequest.ts index 9e603a0974..2422df9c8d 100644 --- a/client/src/generated/models/RosettaBlockRequest.ts +++ b/client/src/generated/models/RosettaBlockRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -37,7 +37,7 @@ export interface RosettaBlockRequest { * @type {object} * @memberof RosettaBlockRequest */ - block_identifier?: object; + block_identifier: object; } export function RosettaBlockRequestFromJSON(json: any): RosettaBlockRequest { @@ -51,7 +51,7 @@ export function RosettaBlockRequestFromJSONTyped(json: any, ignoreDiscriminator: return { 'network_identifier': NetworkIdentifierFromJSON(json['network_identifier']), - 'block_identifier': !exists(json, 'block_identifier') ? undefined : json['block_identifier'], + 'block_identifier': json['block_identifier'], }; } @@ -69,4 +69,3 @@ export function RosettaBlockRequestToJSON(value?: RosettaBlockRequest | null): a }; } - diff --git a/client/src/generated/models/RosettaBlockResponse.ts b/client/src/generated/models/RosettaBlockResponse.ts index d8cdc08622..9fabd951e4 100644 --- a/client/src/generated/models/RosettaBlockResponse.ts +++ b/client/src/generated/models/RosettaBlockResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,14 +14,14 @@ import { exists, mapValues } from '../runtime'; import { + OtherTransactionIdentifier, + OtherTransactionIdentifierFromJSON, + OtherTransactionIdentifierFromJSONTyped, + OtherTransactionIdentifierToJSON, RosettaBlock, RosettaBlockFromJSON, RosettaBlockFromJSONTyped, RosettaBlockToJSON, - TransactionIdentifier, - TransactionIdentifierFromJSON, - TransactionIdentifierFromJSONTyped, - TransactionIdentifierToJSON, } from './'; /** @@ -38,10 +38,10 @@ export interface RosettaBlockResponse { block?: RosettaBlock; /** * Some blockchains may require additional transactions to be fetched that weren't returned in the block response (ex: block only returns transaction hashes). For blockchains with a lot of transactions in each block, this can be very useful as consumers can concurrently fetch all transactions returned. - * @type {Array} + * @type {Array} * @memberof RosettaBlockResponse */ - other_transactions?: Array; + other_transactions?: Array; } export function RosettaBlockResponseFromJSON(json: any): RosettaBlockResponse { @@ -55,7 +55,7 @@ export function RosettaBlockResponseFromJSONTyped(json: any, ignoreDiscriminator return { 'block': !exists(json, 'block') ? undefined : RosettaBlockFromJSON(json['block']), - 'other_transactions': !exists(json, 'other_transactions') ? undefined : ((json['other_transactions'] as Array).map(TransactionIdentifierFromJSON)), + 'other_transactions': !exists(json, 'other_transactions') ? undefined : ((json['other_transactions'] as Array).map(OtherTransactionIdentifierFromJSON)), }; } @@ -69,8 +69,7 @@ export function RosettaBlockResponseToJSON(value?: RosettaBlockResponse | null): return { 'block': RosettaBlockToJSON(value.block), - 'other_transactions': value.other_transactions === undefined ? undefined : ((value.other_transactions as Array).map(TransactionIdentifierToJSON)), + 'other_transactions': value.other_transactions === undefined ? undefined : ((value.other_transactions as Array).map(OtherTransactionIdentifierToJSON)), }; } - diff --git a/client/src/generated/models/RosettaBlockTransactionRequest.ts b/client/src/generated/models/RosettaBlockTransactionRequest.ts index 14fd0d288f..c42c7e2d38 100644 --- a/client/src/generated/models/RosettaBlockTransactionRequest.ts +++ b/client/src/generated/models/RosettaBlockTransactionRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -37,7 +37,7 @@ export interface RosettaBlockTransactionRequest { */ network_identifier: NetworkIdentifier; /** - * The block_identifier uniquely identifies a block in a particular network. + * When fetching data by BlockIdentifier, it may be possible to only specify the index or hash. If neither property is specified, it is assumed that the client is making a request at the current block. * @type {object} * @memberof RosettaBlockTransactionRequest */ @@ -81,4 +81,3 @@ export function RosettaBlockTransactionRequestToJSON(value?: RosettaBlockTransac }; } - diff --git a/client/src/generated/models/RosettaBlockTransactionResponse.ts b/client/src/generated/models/RosettaBlockTransactionResponse.ts index 50d57cfba4..0adb687890 100644 --- a/client/src/generated/models/RosettaBlockTransactionResponse.ts +++ b/client/src/generated/models/RosettaBlockTransactionResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -61,4 +61,3 @@ export function RosettaBlockTransactionResponseToJSON(value?: RosettaBlockTransa }; } - diff --git a/client/src/generated/models/RosettaCoin.ts b/client/src/generated/models/RosettaCoin.ts index 782179e07e..56b305fb0f 100644 --- a/client/src/generated/models/RosettaCoin.ts +++ b/client/src/generated/models/RosettaCoin.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -73,4 +73,3 @@ export function RosettaCoinToJSON(value?: RosettaCoin | null): any { }; } - diff --git a/client/src/generated/models/RosettaCoinChange.ts b/client/src/generated/models/RosettaCoinChange.ts index b55ee5c8bb..50c504ffd4 100644 --- a/client/src/generated/models/RosettaCoinChange.ts +++ b/client/src/generated/models/RosettaCoinChange.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -40,6 +40,15 @@ export interface RosettaCoinChange { coin_action: RosettaCoinChangeCoinActionEnum; } +/** +* @export +* @enum {string} +*/ +export enum RosettaCoinChangeCoinActionEnum { + created = 'coin_created', + spent = 'coin_spent' +} + export function RosettaCoinChangeFromJSON(json: any): RosettaCoinChange { return RosettaCoinChangeFromJSONTyped(json, false); } @@ -69,13 +78,3 @@ export function RosettaCoinChangeToJSON(value?: RosettaCoinChange | null): any { }; } -/** -* @export -* @enum {string} -*/ -export enum RosettaCoinChangeCoinActionEnum { - created = 'coin_created', - spent = 'coin_spent' -} - - diff --git a/client/src/generated/models/RosettaConstructionCombineRequest.ts b/client/src/generated/models/RosettaConstructionCombineRequest.ts index 5a0b6a70dc..e2f49f6a6a 100644 --- a/client/src/generated/models/RosettaConstructionCombineRequest.ts +++ b/client/src/generated/models/RosettaConstructionCombineRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -81,4 +81,3 @@ export function RosettaConstructionCombineRequestToJSON(value?: RosettaConstruct }; } - diff --git a/client/src/generated/models/RosettaConstructionCombineResponse.ts b/client/src/generated/models/RosettaConstructionCombineResponse.ts index d69c9c4c69..67ef31766c 100644 --- a/client/src/generated/models/RosettaConstructionCombineResponse.ts +++ b/client/src/generated/models/RosettaConstructionCombineResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,4 +54,3 @@ export function RosettaConstructionCombineResponseToJSON(value?: RosettaConstruc }; } - diff --git a/client/src/generated/models/RosettaConstructionDeriveRequest.ts b/client/src/generated/models/RosettaConstructionDeriveRequest.ts index f12ba2ad46..40441e7ab0 100644 --- a/client/src/generated/models/RosettaConstructionDeriveRequest.ts +++ b/client/src/generated/models/RosettaConstructionDeriveRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -81,4 +81,3 @@ export function RosettaConstructionDeriveRequestToJSON(value?: RosettaConstructi }; } - diff --git a/client/src/generated/models/RosettaConstructionDeriveResponse.ts b/client/src/generated/models/RosettaConstructionDeriveResponse.ts index eb38b8ff0f..014f1f3da3 100644 --- a/client/src/generated/models/RosettaConstructionDeriveResponse.ts +++ b/client/src/generated/models/RosettaConstructionDeriveResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -13,6 +13,13 @@ */ import { exists, mapValues } from '../runtime'; +import { + RosettaAccountIdentifier, + RosettaAccountIdentifierFromJSON, + RosettaAccountIdentifierFromJSONTyped, + RosettaAccountIdentifierToJSON, +} from './'; + /** * ConstructionDeriveResponse is returned by the /construction/derive endpoint. * @export @@ -20,11 +27,17 @@ import { exists, mapValues } from '../runtime'; */ export interface RosettaConstructionDeriveResponse { /** - * Address in network-specific format. + * [DEPRECATED by account_identifier in v1.4.4] Address in network-specific format. * @type {string} * @memberof RosettaConstructionDeriveResponse */ - address: string; + address?: string; + /** + * + * @type {RosettaAccountIdentifier} + * @memberof RosettaConstructionDeriveResponse + */ + account_identifier?: RosettaAccountIdentifier; /** * * @type {object} @@ -43,7 +56,8 @@ export function RosettaConstructionDeriveResponseFromJSONTyped(json: any, ignore } return { - 'address': json['address'], + 'address': !exists(json, 'address') ? undefined : json['address'], + 'account_identifier': !exists(json, 'account_identifier') ? undefined : RosettaAccountIdentifierFromJSON(json['account_identifier']), 'metadata': !exists(json, 'metadata') ? undefined : json['metadata'], }; } @@ -58,8 +72,8 @@ export function RosettaConstructionDeriveResponseToJSON(value?: RosettaConstruct return { 'address': value.address, + 'account_identifier': RosettaAccountIdentifierToJSON(value.account_identifier), 'metadata': value.metadata, }; } - diff --git a/client/src/generated/models/RosettaConstructionHashRequest.ts b/client/src/generated/models/RosettaConstructionHashRequest.ts index 60ac23488a..230e5edea4 100644 --- a/client/src/generated/models/RosettaConstructionHashRequest.ts +++ b/client/src/generated/models/RosettaConstructionHashRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaConstructionHashRequestToJSON(value?: RosettaConstruction }; } - diff --git a/client/src/generated/models/RosettaConstructionHashResponse.ts b/client/src/generated/models/RosettaConstructionHashResponse.ts index 856d7e890d..9b05d8e3ae 100644 --- a/client/src/generated/models/RosettaConstructionHashResponse.ts +++ b/client/src/generated/models/RosettaConstructionHashResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaConstructionHashResponseToJSON(value?: RosettaConstructio }; } - diff --git a/client/src/generated/models/RosettaConstructionMetadataRequest.ts b/client/src/generated/models/RosettaConstructionMetadataRequest.ts index 0e697a2568..6af1d813b2 100644 --- a/client/src/generated/models/RosettaConstructionMetadataRequest.ts +++ b/client/src/generated/models/RosettaConstructionMetadataRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -85,4 +85,3 @@ export function RosettaConstructionMetadataRequestToJSON(value?: RosettaConstruc }; } - diff --git a/client/src/generated/models/RosettaConstructionMetadataResponse.ts b/client/src/generated/models/RosettaConstructionMetadataResponse.ts index f35defb935..c818946147 100644 --- a/client/src/generated/models/RosettaConstructionMetadataResponse.ts +++ b/client/src/generated/models/RosettaConstructionMetadataResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -38,10 +38,10 @@ export interface RosettaConstructionMetadataResponse { metadata: RosettaConstructionMetadataResponseMetadata; /** * - * @type {RosettaAmount} + * @type {Array} * @memberof RosettaConstructionMetadataResponse */ - suggested_fee?: RosettaAmount; + suggested_fee?: Array; } export function RosettaConstructionMetadataResponseFromJSON(json: any): RosettaConstructionMetadataResponse { @@ -55,7 +55,7 @@ export function RosettaConstructionMetadataResponseFromJSONTyped(json: any, igno return { 'metadata': RosettaConstructionMetadataResponseMetadataFromJSON(json['metadata']), - 'suggested_fee': !exists(json, 'suggested_fee') ? undefined : RosettaAmountFromJSON(json['suggested_fee']), + 'suggested_fee': !exists(json, 'suggested_fee') ? undefined : ((json['suggested_fee'] as Array).map(RosettaAmountFromJSON)), }; } @@ -69,8 +69,7 @@ export function RosettaConstructionMetadataResponseToJSON(value?: RosettaConstru return { 'metadata': RosettaConstructionMetadataResponseMetadataToJSON(value.metadata), - 'suggested_fee': RosettaAmountToJSON(value.suggested_fee), + 'suggested_fee': value.suggested_fee === undefined ? undefined : ((value.suggested_fee as Array).map(RosettaAmountToJSON)), }; } - diff --git a/client/src/generated/models/RosettaConstructionMetadataResponseMetadata.ts b/client/src/generated/models/RosettaConstructionMetadataResponseMetadata.ts index 539cb5b182..41619da360 100644 --- a/client/src/generated/models/RosettaConstructionMetadataResponseMetadata.ts +++ b/client/src/generated/models/RosettaConstructionMetadataResponseMetadata.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function RosettaConstructionMetadataResponseMetadataToJSON(value?: Rosett }; } - diff --git a/client/src/generated/models/RosettaConstructionParseRequest.ts b/client/src/generated/models/RosettaConstructionParseRequest.ts index 40d0009968..8056092f73 100644 --- a/client/src/generated/models/RosettaConstructionParseRequest.ts +++ b/client/src/generated/models/RosettaConstructionParseRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -77,4 +77,3 @@ export function RosettaConstructionParseRequestToJSON(value?: RosettaConstructio }; } - diff --git a/client/src/generated/models/RosettaConstructionParseResponse.ts b/client/src/generated/models/RosettaConstructionParseResponse.ts index c8be53a5e5..b959cabf2a 100644 --- a/client/src/generated/models/RosettaConstructionParseResponse.ts +++ b/client/src/generated/models/RosettaConstructionParseResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,10 +14,10 @@ import { exists, mapValues } from '../runtime'; import { - RosettaAccount, - RosettaAccountFromJSON, - RosettaAccountFromJSONTyped, - RosettaAccountToJSON, + RosettaAccountIdentifier, + RosettaAccountIdentifierFromJSON, + RosettaAccountIdentifierFromJSONTyped, + RosettaAccountIdentifierToJSON, RosettaOperation, RosettaOperationFromJSON, RosettaOperationFromJSONTyped, @@ -44,10 +44,16 @@ export interface RosettaConstructionParseResponse { signers?: Array; /** * - * @type {Array} + * @type {Array} * @memberof RosettaConstructionParseResponse */ - account_identifier_signers?: Array; + account_identifier_signers?: Array; + /** + * + * @type {object} + * @memberof RosettaConstructionParseResponse + */ + metadata?: object; } export function RosettaConstructionParseResponseFromJSON(json: any): RosettaConstructionParseResponse { @@ -62,7 +68,8 @@ export function RosettaConstructionParseResponseFromJSONTyped(json: any, ignoreD 'operations': ((json['operations'] as Array).map(RosettaOperationFromJSON)), 'signers': !exists(json, 'signers') ? undefined : json['signers'], - 'account_identifier_signers': !exists(json, 'account_identifier_signers') ? undefined : ((json['account_identifier_signers'] as Array).map(RosettaAccountFromJSON)), + 'account_identifier_signers': !exists(json, 'account_identifier_signers') ? undefined : ((json['account_identifier_signers'] as Array).map(RosettaAccountIdentifierFromJSON)), + 'metadata': !exists(json, 'metadata') ? undefined : json['metadata'], }; } @@ -77,8 +84,8 @@ export function RosettaConstructionParseResponseToJSON(value?: RosettaConstructi 'operations': ((value.operations as Array).map(RosettaOperationToJSON)), 'signers': value.signers, - 'account_identifier_signers': value.account_identifier_signers === undefined ? undefined : ((value.account_identifier_signers as Array).map(RosettaAccountToJSON)), + 'account_identifier_signers': value.account_identifier_signers === undefined ? undefined : ((value.account_identifier_signers as Array).map(RosettaAccountIdentifierToJSON)), + 'metadata': value.metadata, }; } - diff --git a/client/src/generated/models/RosettaConstructionPayloadResponse.ts b/client/src/generated/models/RosettaConstructionPayloadResponse.ts index ebdfb8230b..40e208cc83 100644 --- a/client/src/generated/models/RosettaConstructionPayloadResponse.ts +++ b/client/src/generated/models/RosettaConstructionPayloadResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaConstructionPayloadResponseToJSON(value?: RosettaConstruc }; } - diff --git a/client/src/generated/models/RosettaConstructionPayloadsRequest.ts b/client/src/generated/models/RosettaConstructionPayloadsRequest.ts index 81ff6021dd..3192753a63 100644 --- a/client/src/generated/models/RosettaConstructionPayloadsRequest.ts +++ b/client/src/generated/models/RosettaConstructionPayloadsRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -18,6 +18,10 @@ import { NetworkIdentifierFromJSON, NetworkIdentifierFromJSONTyped, NetworkIdentifierToJSON, + RosettaConstructionMetadataResponseMetadata, + RosettaConstructionMetadataResponseMetadataFromJSON, + RosettaConstructionMetadataResponseMetadataFromJSONTyped, + RosettaConstructionMetadataResponseMetadataToJSON, RosettaOperation, RosettaOperationFromJSON, RosettaOperationFromJSONTyped, @@ -52,6 +56,12 @@ export interface RosettaConstructionPayloadsRequest { * @memberof RosettaConstructionPayloadsRequest */ public_keys?: Array; + /** + * + * @type {RosettaConstructionMetadataResponseMetadata} + * @memberof RosettaConstructionPayloadsRequest + */ + metadata?: RosettaConstructionMetadataResponseMetadata; } export function RosettaConstructionPayloadsRequestFromJSON(json: any): RosettaConstructionPayloadsRequest { @@ -67,6 +77,7 @@ export function RosettaConstructionPayloadsRequestFromJSONTyped(json: any, ignor 'network_identifier': NetworkIdentifierFromJSON(json['network_identifier']), 'operations': ((json['operations'] as Array).map(RosettaOperationFromJSON)), 'public_keys': !exists(json, 'public_keys') ? undefined : ((json['public_keys'] as Array).map(RosettaPublicKeyFromJSON)), + 'metadata': !exists(json, 'metadata') ? undefined : RosettaConstructionMetadataResponseMetadataFromJSON(json['metadata']), }; } @@ -82,7 +93,7 @@ export function RosettaConstructionPayloadsRequestToJSON(value?: RosettaConstruc 'network_identifier': NetworkIdentifierToJSON(value.network_identifier), 'operations': ((value.operations as Array).map(RosettaOperationToJSON)), 'public_keys': value.public_keys === undefined ? undefined : ((value.public_keys as Array).map(RosettaPublicKeyToJSON)), + 'metadata': RosettaConstructionMetadataResponseMetadataToJSON(value.metadata), }; } - diff --git a/client/src/generated/models/RosettaConstructionPreprocessRequest.ts b/client/src/generated/models/RosettaConstructionPreprocessRequest.ts index 6776a07ce2..97afbc15e8 100644 --- a/client/src/generated/models/RosettaConstructionPreprocessRequest.ts +++ b/client/src/generated/models/RosettaConstructionPreprocessRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -18,10 +18,10 @@ import { NetworkIdentifierFromJSON, NetworkIdentifierFromJSONTyped, NetworkIdentifierToJSON, - RosettaAmount, - RosettaAmountFromJSON, - RosettaAmountFromJSONTyped, - RosettaAmountToJSON, + RosettaMaxFeeAmount, + RosettaMaxFeeAmountFromJSON, + RosettaMaxFeeAmountFromJSONTyped, + RosettaMaxFeeAmountToJSON, RosettaOperation, RosettaOperationFromJSON, RosettaOperationFromJSONTyped, @@ -54,10 +54,10 @@ export interface RosettaConstructionPreprocessRequest { metadata?: object; /** * - * @type {Array} + * @type {Array} * @memberof RosettaConstructionPreprocessRequest */ - max_fee?: Array; + max_fee?: Array; /** * The caller can also provide a suggested fee multiplier to indicate that the suggested fee should be scaled. This may be used to set higher fees for urgent transactions or to pay lower fees when there is less urgency. It is assumed that providing a very low multiplier (like 0.0001) will never lead to a transaction being created with a fee less than the minimum network fee (if applicable). In the case that the caller provides both a max fee and a suggested fee multiplier, the max fee will set an upper bound on the suggested fee (regardless of the multiplier provided). * @type {number} @@ -79,7 +79,7 @@ export function RosettaConstructionPreprocessRequestFromJSONTyped(json: any, ign 'network_identifier': NetworkIdentifierFromJSON(json['network_identifier']), 'operations': ((json['operations'] as Array).map(RosettaOperationFromJSON)), 'metadata': !exists(json, 'metadata') ? undefined : json['metadata'], - 'max_fee': !exists(json, 'max_fee') ? undefined : ((json['max_fee'] as Array).map(RosettaAmountFromJSON)), + 'max_fee': !exists(json, 'max_fee') ? undefined : ((json['max_fee'] as Array).map(RosettaMaxFeeAmountFromJSON)), 'suggested_fee_multiplier': !exists(json, 'suggested_fee_multiplier') ? undefined : json['suggested_fee_multiplier'], }; } @@ -96,9 +96,8 @@ export function RosettaConstructionPreprocessRequestToJSON(value?: RosettaConstr 'network_identifier': NetworkIdentifierToJSON(value.network_identifier), 'operations': ((value.operations as Array).map(RosettaOperationToJSON)), 'metadata': value.metadata, - 'max_fee': value.max_fee === undefined ? undefined : ((value.max_fee as Array).map(RosettaAmountToJSON)), + 'max_fee': value.max_fee === undefined ? undefined : ((value.max_fee as Array).map(RosettaMaxFeeAmountToJSON)), 'suggested_fee_multiplier': value.suggested_fee_multiplier, }; } - diff --git a/client/src/generated/models/RosettaConstructionPreprocessResponse.ts b/client/src/generated/models/RosettaConstructionPreprocessResponse.ts index 60ad99074f..d83b7f0039 100644 --- a/client/src/generated/models/RosettaConstructionPreprocessResponse.ts +++ b/client/src/generated/models/RosettaConstructionPreprocessResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -73,4 +73,3 @@ export function RosettaConstructionPreprocessResponseToJSON(value?: RosettaConst }; } - diff --git a/client/src/generated/models/RosettaConstructionSubmitRequest.ts b/client/src/generated/models/RosettaConstructionSubmitRequest.ts index 9dc3748874..a1d86391f3 100644 --- a/client/src/generated/models/RosettaConstructionSubmitRequest.ts +++ b/client/src/generated/models/RosettaConstructionSubmitRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaConstructionSubmitRequestToJSON(value?: RosettaConstructi }; } - diff --git a/client/src/generated/models/RosettaConstructionSubmitResponse.ts b/client/src/generated/models/RosettaConstructionSubmitResponse.ts index 078756a3dc..2dd054d58f 100644 --- a/client/src/generated/models/RosettaConstructionSubmitResponse.ts +++ b/client/src/generated/models/RosettaConstructionSubmitResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaConstructionSubmitResponseToJSON(value?: RosettaConstruct }; } - diff --git a/client/src/generated/models/RosettaCurrency.ts b/client/src/generated/models/RosettaCurrency.ts index a82c640117..911b731eef 100644 --- a/client/src/generated/models/RosettaCurrency.ts +++ b/client/src/generated/models/RosettaCurrency.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -70,4 +70,3 @@ export function RosettaCurrencyToJSON(value?: RosettaCurrency | null): any { }; } - diff --git a/client/src/generated/models/RosettaError.ts b/client/src/generated/models/RosettaError.ts index 128f80c521..21854759ba 100644 --- a/client/src/generated/models/RosettaError.ts +++ b/client/src/generated/models/RosettaError.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -85,4 +85,3 @@ export function RosettaErrorToJSON(value?: RosettaError | null): any { }; } - diff --git a/client/src/generated/models/RosettaErrorDetails.ts b/client/src/generated/models/RosettaErrorDetails.ts index beb9749d35..67728872fb 100644 --- a/client/src/generated/models/RosettaErrorDetails.ts +++ b/client/src/generated/models/RosettaErrorDetails.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function RosettaErrorDetailsToJSON(value?: RosettaErrorDetails | null): a }; } - diff --git a/client/src/generated/models/RosettaErrorNoDetails.ts b/client/src/generated/models/RosettaErrorNoDetails.ts new file mode 100644 index 0000000000..a0c4271140 --- /dev/null +++ b/client/src/generated/models/RosettaErrorNoDetails.ts @@ -0,0 +1,72 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Instead of utilizing HTTP status codes to describe node errors (which often do not have a good analog), rich errors are returned using this object. Both the code and message fields can be individually used to correctly identify an error. Implementations MUST use unique values for both fields. + * @export + * @interface RosettaErrorNoDetails + */ +export interface RosettaErrorNoDetails { + /** + * Code is a network-specific error code. If desired, this code can be equivalent to an HTTP status code. + * @type {number} + * @memberof RosettaErrorNoDetails + */ + code: number; + /** + * Message is a network-specific error message. The message MUST NOT change for a given code. In particular, this means that any contextual information should be included in the details field. + * @type {string} + * @memberof RosettaErrorNoDetails + */ + message: string; + /** + * An error is retriable if the same request may succeed if submitted again. + * @type {boolean} + * @memberof RosettaErrorNoDetails + */ + retriable: boolean; +} + +export function RosettaErrorNoDetailsFromJSON(json: any): RosettaErrorNoDetails { + return RosettaErrorNoDetailsFromJSONTyped(json, false); +} + +export function RosettaErrorNoDetailsFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaErrorNoDetails { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'code': json['code'], + 'message': json['message'], + 'retriable': json['retriable'], + }; +} + +export function RosettaErrorNoDetailsToJSON(value?: RosettaErrorNoDetails | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'code': value.code, + 'message': value.message, + 'retriable': value.retriable, + }; +} + diff --git a/client/src/generated/models/RosettaGenesisBlockIdentifier.ts b/client/src/generated/models/RosettaGenesisBlockIdentifier.ts new file mode 100644 index 0000000000..e733434cd1 --- /dev/null +++ b/client/src/generated/models/RosettaGenesisBlockIdentifier.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * The block_identifier uniquely identifies a block in a particular network. + * @export + * @interface RosettaGenesisBlockIdentifier + */ +export interface RosettaGenesisBlockIdentifier { + /** + * This is also known as the block height. + * @type {number} + * @memberof RosettaGenesisBlockIdentifier + */ + index: number; + /** + * Block hash + * @type {string} + * @memberof RosettaGenesisBlockIdentifier + */ + hash: string; +} + +export function RosettaGenesisBlockIdentifierFromJSON(json: any): RosettaGenesisBlockIdentifier { + return RosettaGenesisBlockIdentifierFromJSONTyped(json, false); +} + +export function RosettaGenesisBlockIdentifierFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaGenesisBlockIdentifier { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'index': json['index'], + 'hash': json['hash'], + }; +} + +export function RosettaGenesisBlockIdentifierToJSON(value?: RosettaGenesisBlockIdentifier | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'index': value.index, + 'hash': value.hash, + }; +} + diff --git a/client/src/generated/models/RosettaMaxFeeAmount.ts b/client/src/generated/models/RosettaMaxFeeAmount.ts new file mode 100644 index 0000000000..71e15a10b1 --- /dev/null +++ b/client/src/generated/models/RosettaMaxFeeAmount.ts @@ -0,0 +1,79 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + RosettaCurrency, + RosettaCurrencyFromJSON, + RosettaCurrencyFromJSONTyped, + RosettaCurrencyToJSON, +} from './'; + +/** + * Amount is some Value of a Currency. It is considered invalid to specify a Value without a Currency. + * @export + * @interface RosettaMaxFeeAmount + */ +export interface RosettaMaxFeeAmount { + /** + * Value of the transaction in atomic units represented as an arbitrary-sized signed integer. For example, 1 BTC would be represented by a value of 100000000. + * @type {string} + * @memberof RosettaMaxFeeAmount + */ + value: string; + /** + * + * @type {RosettaCurrency} + * @memberof RosettaMaxFeeAmount + */ + currency: RosettaCurrency; + /** + * + * @type {object} + * @memberof RosettaMaxFeeAmount + */ + metadata?: object; +} + +export function RosettaMaxFeeAmountFromJSON(json: any): RosettaMaxFeeAmount { + return RosettaMaxFeeAmountFromJSONTyped(json, false); +} + +export function RosettaMaxFeeAmountFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaMaxFeeAmount { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'value': json['value'], + 'currency': RosettaCurrencyFromJSON(json['currency']), + 'metadata': !exists(json, 'metadata') ? undefined : json['metadata'], + }; +} + +export function RosettaMaxFeeAmountToJSON(value?: RosettaMaxFeeAmount | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'value': value.value, + 'currency': RosettaCurrencyToJSON(value.currency), + 'metadata': value.metadata, + }; +} + diff --git a/client/src/generated/models/RosettaMempoolRequest.ts b/client/src/generated/models/RosettaMempoolRequest.ts index fab229e16e..ba1ab8234d 100644 --- a/client/src/generated/models/RosettaMempoolRequest.ts +++ b/client/src/generated/models/RosettaMempoolRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaMempoolRequestToJSON(value?: RosettaMempoolRequest | null }; } - diff --git a/client/src/generated/models/RosettaMempoolResponse.ts b/client/src/generated/models/RosettaMempoolResponse.ts index 3ea288b3e1..2e7fa178e3 100644 --- a/client/src/generated/models/RosettaMempoolResponse.ts +++ b/client/src/generated/models/RosettaMempoolResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaMempoolResponseToJSON(value?: RosettaMempoolResponse | nu }; } - diff --git a/client/src/generated/models/RosettaMempoolTransactionRequest.ts b/client/src/generated/models/RosettaMempoolTransactionRequest.ts index 7711c6b134..92793a46c8 100644 --- a/client/src/generated/models/RosettaMempoolTransactionRequest.ts +++ b/client/src/generated/models/RosettaMempoolTransactionRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -73,4 +73,3 @@ export function RosettaMempoolTransactionRequestToJSON(value?: RosettaMempoolTra }; } - diff --git a/client/src/generated/models/RosettaMempoolTransactionResponse.ts b/client/src/generated/models/RosettaMempoolTransactionResponse.ts index 72f60baaae..6e340106f4 100644 --- a/client/src/generated/models/RosettaMempoolTransactionResponse.ts +++ b/client/src/generated/models/RosettaMempoolTransactionResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaMempoolTransactionResponseToJSON(value?: RosettaMempoolTr }; } - diff --git a/client/src/generated/models/RosettaNetworkListResponse.ts b/client/src/generated/models/RosettaNetworkListResponse.ts index 37d457172b..ac1cdc1340 100644 --- a/client/src/generated/models/RosettaNetworkListResponse.ts +++ b/client/src/generated/models/RosettaNetworkListResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -61,4 +61,3 @@ export function RosettaNetworkListResponseToJSON(value?: RosettaNetworkListRespo }; } - diff --git a/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifier.ts b/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifier.ts index ef98b1a45a..4929199084 100644 --- a/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifier.ts +++ b/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifier.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -27,7 +27,7 @@ import { */ export interface RosettaNetworkListResponseSubNetworkIdentifier { /** - * Netowork name + * Network name * @type {string} * @memberof RosettaNetworkListResponseSubNetworkIdentifier */ @@ -69,4 +69,3 @@ export function RosettaNetworkListResponseSubNetworkIdentifierToJSON(value?: Ros }; } - diff --git a/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifierMetadata.ts b/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifierMetadata.ts index 5d065766f9..c2ab08cfa7 100644 --- a/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifierMetadata.ts +++ b/client/src/generated/models/RosettaNetworkListResponseSubNetworkIdentifierMetadata.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,4 +54,3 @@ export function RosettaNetworkListResponseSubNetworkIdentifierMetadataToJSON(val }; } - diff --git a/client/src/generated/models/RosettaNetworkOptionsResponse.ts b/client/src/generated/models/RosettaNetworkOptionsResponse.ts index ca9be373c4..993b81c198 100644 --- a/client/src/generated/models/RosettaNetworkOptionsResponse.ts +++ b/client/src/generated/models/RosettaNetworkOptionsResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -73,4 +73,3 @@ export function RosettaNetworkOptionsResponseToJSON(value?: RosettaNetworkOption }; } - diff --git a/client/src/generated/models/RosettaNetworkOptionsResponseAllow.ts b/client/src/generated/models/RosettaNetworkOptionsResponseAllow.ts index f39201f453..779157a2d2 100644 --- a/client/src/generated/models/RosettaNetworkOptionsResponseAllow.ts +++ b/client/src/generated/models/RosettaNetworkOptionsResponseAllow.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,10 +14,10 @@ import { exists, mapValues } from '../runtime'; import { - RosettaError, - RosettaErrorFromJSON, - RosettaErrorFromJSONTyped, - RosettaErrorToJSON, + RosettaErrorNoDetails, + RosettaErrorNoDetailsFromJSON, + RosettaErrorNoDetailsFromJSONTyped, + RosettaErrorNoDetailsToJSON, RosettaOperationStatus, RosettaOperationStatusFromJSON, RosettaOperationStatusFromJSONTyped, @@ -44,10 +44,10 @@ export interface RosettaNetworkOptionsResponseAllow { operation_types: Array; /** * All Errors that this implementation could return. Any error that is returned during parsing that is not listed here will cause client validation to error. - * @type {Array} + * @type {Array} * @memberof RosettaNetworkOptionsResponseAllow */ - errors: Array; + errors: Array; /** * Any Rosetta implementation that supports querying the balance of an account at any height in the past should set this to true. * @type {boolean} @@ -68,7 +68,7 @@ export function RosettaNetworkOptionsResponseAllowFromJSONTyped(json: any, ignor 'operation_statuses': ((json['operation_statuses'] as Array).map(RosettaOperationStatusFromJSON)), 'operation_types': json['operation_types'], - 'errors': ((json['errors'] as Array).map(RosettaErrorFromJSON)), + 'errors': ((json['errors'] as Array).map(RosettaErrorNoDetailsFromJSON)), 'historical_balance_lookup': json['historical_balance_lookup'], }; } @@ -84,9 +84,8 @@ export function RosettaNetworkOptionsResponseAllowToJSON(value?: RosettaNetworkO 'operation_statuses': ((value.operation_statuses as Array).map(RosettaOperationStatusToJSON)), 'operation_types': value.operation_types, - 'errors': ((value.errors as Array).map(RosettaErrorToJSON)), + 'errors': ((value.errors as Array).map(RosettaErrorNoDetailsToJSON)), 'historical_balance_lookup': value.historical_balance_lookup, }; } - diff --git a/client/src/generated/models/RosettaNetworkOptionsResponseVersion.ts b/client/src/generated/models/RosettaNetworkOptionsResponseVersion.ts index f918c46233..e5dd88e1c2 100644 --- a/client/src/generated/models/RosettaNetworkOptionsResponseVersion.ts +++ b/client/src/generated/models/RosettaNetworkOptionsResponseVersion.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -78,4 +78,3 @@ export function RosettaNetworkOptionsResponseVersionToJSON(value?: RosettaNetwor }; } - diff --git a/client/src/generated/models/RosettaNetworkStatusResponse.ts b/client/src/generated/models/RosettaNetworkStatusResponse.ts new file mode 100644 index 0000000000..f49d0599aa --- /dev/null +++ b/client/src/generated/models/RosettaNetworkStatusResponse.ts @@ -0,0 +1,115 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + RosettaGenesisBlockIdentifier, + RosettaGenesisBlockIdentifierFromJSON, + RosettaGenesisBlockIdentifierFromJSONTyped, + RosettaGenesisBlockIdentifierToJSON, + RosettaOldestBlockIdentifier, + RosettaOldestBlockIdentifierFromJSON, + RosettaOldestBlockIdentifierFromJSONTyped, + RosettaOldestBlockIdentifierToJSON, + RosettaPeers, + RosettaPeersFromJSON, + RosettaPeersFromJSONTyped, + RosettaPeersToJSON, + RosettaSyncStatus, + RosettaSyncStatusFromJSON, + RosettaSyncStatusFromJSONTyped, + RosettaSyncStatusToJSON, +} from './'; + +/** + * NetworkStatusResponse contains basic information about the node's view of a blockchain network. It is assumed that any BlockIdentifier.Index less than or equal to CurrentBlockIdentifier.Index can be queried. If a Rosetta implementation prunes historical state, it should populate the optional oldest_block_identifier field with the oldest block available to query. If this is not populated, it is assumed that the genesis_block_identifier is the oldest queryable block. If a Rosetta implementation performs some pre-sync before it is possible to query blocks, sync_status should be populated so that clients can still monitor healthiness. Without this field, it may appear that the implementation is stuck syncing and needs to be terminated. + * @export + * @interface RosettaNetworkStatusResponse + */ +export interface RosettaNetworkStatusResponse { + /** + * The block_identifier uniquely identifies a block in a particular network. + * @type {object} + * @memberof RosettaNetworkStatusResponse + */ + current_block_identifier: object | null; + /** + * The timestamp of the block in milliseconds since the Unix Epoch. The timestamp is stored in milliseconds because some blockchains produce blocks more often than once a second. + * @type {number} + * @memberof RosettaNetworkStatusResponse + */ + current_block_timestamp: number; + /** + * + * @type {RosettaGenesisBlockIdentifier} + * @memberof RosettaNetworkStatusResponse + */ + genesis_block_identifier: RosettaGenesisBlockIdentifier; + /** + * + * @type {RosettaOldestBlockIdentifier} + * @memberof RosettaNetworkStatusResponse + */ + oldest_block_identifier?: RosettaOldestBlockIdentifier; + /** + * + * @type {RosettaSyncStatus} + * @memberof RosettaNetworkStatusResponse + */ + sync_status?: RosettaSyncStatus; + /** + * Peers information + * @type {Array} + * @memberof RosettaNetworkStatusResponse + */ + peers: Array; +} + +export function RosettaNetworkStatusResponseFromJSON(json: any): RosettaNetworkStatusResponse { + return RosettaNetworkStatusResponseFromJSONTyped(json, false); +} + +export function RosettaNetworkStatusResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaNetworkStatusResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'current_block_identifier': json['current_block_identifier'], + 'current_block_timestamp': json['current_block_timestamp'], + 'genesis_block_identifier': RosettaGenesisBlockIdentifierFromJSON(json['genesis_block_identifier']), + 'oldest_block_identifier': !exists(json, 'oldest_block_identifier') ? undefined : RosettaOldestBlockIdentifierFromJSON(json['oldest_block_identifier']), + 'sync_status': !exists(json, 'sync_status') ? undefined : RosettaSyncStatusFromJSON(json['sync_status']), + 'peers': ((json['peers'] as Array).map(RosettaPeersFromJSON)), + }; +} + +export function RosettaNetworkStatusResponseToJSON(value?: RosettaNetworkStatusResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'current_block_identifier': value.current_block_identifier, + 'current_block_timestamp': value.current_block_timestamp, + 'genesis_block_identifier': RosettaGenesisBlockIdentifierToJSON(value.genesis_block_identifier), + 'oldest_block_identifier': RosettaOldestBlockIdentifierToJSON(value.oldest_block_identifier), + 'sync_status': RosettaSyncStatusToJSON(value.sync_status), + 'peers': ((value.peers as Array).map(RosettaPeersToJSON)), + }; +} + diff --git a/client/src/generated/models/RosettaOldestBlockIdentifier.ts b/client/src/generated/models/RosettaOldestBlockIdentifier.ts new file mode 100644 index 0000000000..3291bafa28 --- /dev/null +++ b/client/src/generated/models/RosettaOldestBlockIdentifier.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * The block_identifier uniquely identifies a block in a particular network. + * @export + * @interface RosettaOldestBlockIdentifier + */ +export interface RosettaOldestBlockIdentifier { + /** + * This is also known as the block height. + * @type {number} + * @memberof RosettaOldestBlockIdentifier + */ + index: number; + /** + * Block hash + * @type {string} + * @memberof RosettaOldestBlockIdentifier + */ + hash: string; +} + +export function RosettaOldestBlockIdentifierFromJSON(json: any): RosettaOldestBlockIdentifier { + return RosettaOldestBlockIdentifierFromJSONTyped(json, false); +} + +export function RosettaOldestBlockIdentifierFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaOldestBlockIdentifier { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'index': json['index'], + 'hash': json['hash'], + }; +} + +export function RosettaOldestBlockIdentifierToJSON(value?: RosettaOldestBlockIdentifier | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'index': value.index, + 'hash': value.hash, + }; +} + diff --git a/client/src/generated/models/RosettaOperation.ts b/client/src/generated/models/RosettaOperation.ts index b533be67be..1935e135d1 100644 --- a/client/src/generated/models/RosettaOperation.ts +++ b/client/src/generated/models/RosettaOperation.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -22,10 +22,6 @@ import { RosettaAmountFromJSON, RosettaAmountFromJSONTyped, RosettaAmountToJSON, - RosettaBlockMetadata, - RosettaBlockMetadataFromJSON, - RosettaBlockMetadataFromJSONTyped, - RosettaBlockMetadataToJSON, RosettaCoinChange, RosettaCoinChangeFromJSON, RosettaCoinChangeFromJSONTyped, @@ -69,7 +65,7 @@ export interface RosettaOperation { * @type {string} * @memberof RosettaOperation */ - status: string; + status?: string; /** * * @type {RosettaAccount} @@ -89,11 +85,11 @@ export interface RosettaOperation { */ coin_change?: RosettaCoinChange; /** - * - * @type {RosettaBlockMetadata} + * Operations Meta Data + * @type {object} * @memberof RosettaOperation */ - metadata?: RosettaBlockMetadata; + metadata?: object; } export function RosettaOperationFromJSON(json: any): RosettaOperation { @@ -109,11 +105,11 @@ export function RosettaOperationFromJSONTyped(json: any, ignoreDiscriminator: bo 'operation_identifier': RosettaOperationIdentifierFromJSON(json['operation_identifier']), 'related_operations': !exists(json, 'related_operations') ? undefined : ((json['related_operations'] as Array).map(RosettaRelatedOperationFromJSON)), 'type': json['type'], - 'status': json['status'], + 'status': !exists(json, 'status') ? undefined : json['status'], 'account': !exists(json, 'account') ? undefined : RosettaAccountFromJSON(json['account']), 'amount': !exists(json, 'amount') ? undefined : RosettaAmountFromJSON(json['amount']), 'coin_change': !exists(json, 'coin_change') ? undefined : RosettaCoinChangeFromJSON(json['coin_change']), - 'metadata': !exists(json, 'metadata') ? undefined : RosettaBlockMetadataFromJSON(json['metadata']), + 'metadata': !exists(json, 'metadata') ? undefined : json['metadata'], }; } @@ -133,8 +129,7 @@ export function RosettaOperationToJSON(value?: RosettaOperation | null): any { 'account': RosettaAccountToJSON(value.account), 'amount': RosettaAmountToJSON(value.amount), 'coin_change': RosettaCoinChangeToJSON(value.coin_change), - 'metadata': RosettaBlockMetadataToJSON(value.metadata), + 'metadata': value.metadata, }; } - diff --git a/client/src/generated/models/RosettaOperationIdentifier.ts b/client/src/generated/models/RosettaOperationIdentifier.ts index d2609403f9..b779123b89 100644 --- a/client/src/generated/models/RosettaOperationIdentifier.ts +++ b/client/src/generated/models/RosettaOperationIdentifier.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function RosettaOperationIdentifierToJSON(value?: RosettaOperationIdentif }; } - diff --git a/client/src/generated/models/RosettaOperationStatus.ts b/client/src/generated/models/RosettaOperationStatus.ts index 637e5df924..f55c4f76fd 100644 --- a/client/src/generated/models/RosettaOperationStatus.ts +++ b/client/src/generated/models/RosettaOperationStatus.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function RosettaOperationStatusToJSON(value?: RosettaOperationStatus | nu }; } - diff --git a/client/src/generated/models/RosettaOptions.ts b/client/src/generated/models/RosettaOptions.ts index 8eef051fe6..00c1f0e698 100644 --- a/client/src/generated/models/RosettaOptions.ts +++ b/client/src/generated/models/RosettaOptions.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -44,7 +44,7 @@ export interface RosettaOptions { */ token_transfer_recipient_address?: string; /** - * Amount to be transfeered. + * Amount to be transfered. * @type {string} * @memberof RosettaOptions */ @@ -91,6 +91,54 @@ export interface RosettaOptions { * @memberof RosettaOptions */ fee?: string; + /** + * Transaction approximative size (used to calculate total fee). + * @type {number} + * @memberof RosettaOptions + */ + size?: number; + /** + * STX token transfer memo. + * @type {string} + * @memberof RosettaOptions + */ + memo?: string; + /** + * Number of cycles when stacking. + * @type {number} + * @memberof RosettaOptions + */ + number_of_cycles?: number; + /** + * Address of the contract to call. + * @type {string} + * @memberof RosettaOptions + */ + contract_address?: string; + /** + * Name of the contract to call. + * @type {string} + * @memberof RosettaOptions + */ + contract_name?: string; + /** + * Set the burnchain (BTC) block for stacking lock to start. + * @type {number} + * @memberof RosettaOptions + */ + burn_block_height?: number; + /** + * Delegator address for when calling `delegate-stacking`. + * @type {string} + * @memberof RosettaOptions + */ + delegate_to?: string; + /** + * The reward address for stacking transaction. It should be a valid Bitcoin address + * @type {string} + * @memberof RosettaOptions + */ + pox_addr?: string; } export function RosettaOptionsFromJSON(json: any): RosettaOptions { @@ -115,6 +163,14 @@ export function RosettaOptionsFromJSONTyped(json: any, ignoreDiscriminator: bool 'suggested_fee_multiplier': !exists(json, 'suggested_fee_multiplier') ? undefined : json['suggested_fee_multiplier'], 'max_fee': !exists(json, 'max_fee') ? undefined : json['max_fee'], 'fee': !exists(json, 'fee') ? undefined : json['fee'], + 'size': !exists(json, 'size') ? undefined : json['size'], + 'memo': !exists(json, 'memo') ? undefined : json['memo'], + 'number_of_cycles': !exists(json, 'number_of_cycles') ? undefined : json['number_of_cycles'], + 'contract_address': !exists(json, 'contract_address') ? undefined : json['contract_address'], + 'contract_name': !exists(json, 'contract_name') ? undefined : json['contract_name'], + 'burn_block_height': !exists(json, 'burn_block_height') ? undefined : json['burn_block_height'], + 'delegate_to': !exists(json, 'delegate_to') ? undefined : json['delegate_to'], + 'pox_addr': !exists(json, 'pox_addr') ? undefined : json['pox_addr'], }; } @@ -139,7 +195,14 @@ export function RosettaOptionsToJSON(value?: RosettaOptions | null): any { 'suggested_fee_multiplier': value.suggested_fee_multiplier, 'max_fee': value.max_fee, 'fee': value.fee, + 'size': value.size, + 'memo': value.memo, + 'number_of_cycles': value.number_of_cycles, + 'contract_address': value.contract_address, + 'contract_name': value.contract_name, + 'burn_block_height': value.burn_block_height, + 'delegate_to': value.delegate_to, + 'pox_addr': value.pox_addr, }; } - diff --git a/client/src/generated/models/RosettaOptionsRequest.ts b/client/src/generated/models/RosettaOptionsRequest.ts index 7b5b628775..4f20419940 100644 --- a/client/src/generated/models/RosettaOptionsRequest.ts +++ b/client/src/generated/models/RosettaOptionsRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaOptionsRequestToJSON(value?: RosettaOptionsRequest | null }; } - diff --git a/client/src/generated/models/RosettaParentBlockIdentifier.ts b/client/src/generated/models/RosettaParentBlockIdentifier.ts index 81bc1d495e..e2eb22b611 100644 --- a/client/src/generated/models/RosettaParentBlockIdentifier.ts +++ b/client/src/generated/models/RosettaParentBlockIdentifier.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function RosettaParentBlockIdentifierToJSON(value?: RosettaParentBlockIde }; } - diff --git a/client/src/generated/models/RosettaPeers.ts b/client/src/generated/models/RosettaPeers.ts new file mode 100644 index 0000000000..ab6d65c224 --- /dev/null +++ b/client/src/generated/models/RosettaPeers.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * A Peer is a representation of a node's peer. + * @export + * @interface RosettaPeers + */ +export interface RosettaPeers { + /** + * peer id + * @type {string} + * @memberof RosettaPeers + */ + peer_id: string; + /** + * meta data + * @type {object} + * @memberof RosettaPeers + */ + metadata?: object; +} + +export function RosettaPeersFromJSON(json: any): RosettaPeers { + return RosettaPeersFromJSONTyped(json, false); +} + +export function RosettaPeersFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaPeers { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'peer_id': json['peer_id'], + 'metadata': !exists(json, 'metadata') ? undefined : json['metadata'], + }; +} + +export function RosettaPeersToJSON(value?: RosettaPeers | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'peer_id': value.peer_id, + 'metadata': value.metadata, + }; +} + diff --git a/client/src/generated/models/RosettaPublicKey.ts b/client/src/generated/models/RosettaPublicKey.ts index 28a7aa31f8..e501860e1a 100644 --- a/client/src/generated/models/RosettaPublicKey.ts +++ b/client/src/generated/models/RosettaPublicKey.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -33,6 +33,15 @@ export interface RosettaPublicKey { curve_type: RosettaPublicKeyCurveTypeEnum; } +/** +* @export +* @enum {string} +*/ +export enum RosettaPublicKeyCurveTypeEnum { + secp256k1 = 'secp256k1', + edwards25519 = 'edwards25519' +} + export function RosettaPublicKeyFromJSON(json: any): RosettaPublicKey { return RosettaPublicKeyFromJSONTyped(json, false); } @@ -62,13 +71,3 @@ export function RosettaPublicKeyToJSON(value?: RosettaPublicKey | null): any { }; } -/** -* @export -* @enum {string} -*/ -export enum RosettaPublicKeyCurveTypeEnum { - secp256k1 = 'secp256k1', - edwards25519 = 'edwards25519' -} - - diff --git a/client/src/generated/models/RosettaRelatedOperation.ts b/client/src/generated/models/RosettaRelatedOperation.ts index 93777da593..7177c893d6 100644 --- a/client/src/generated/models/RosettaRelatedOperation.ts +++ b/client/src/generated/models/RosettaRelatedOperation.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -13,13 +13,6 @@ */ import { exists, mapValues } from '../runtime'; -import { - RosettaOperationIdentifier, - RosettaOperationIdentifierFromJSON, - RosettaOperationIdentifierFromJSONTyped, - RosettaOperationIdentifierToJSON, -} from './'; - /** * Restrict referenced related_operations to identifier indexes < the current operation_identifier.index. This ensures there exists a clear DAG-structure of relations. Since operations are one-sided, one could imagine relating operations in a single transfer or linking operations in a call tree. * @export @@ -31,13 +24,13 @@ export interface RosettaRelatedOperation { * @type {number} * @memberof RosettaRelatedOperation */ - index?: number; + index: number; /** - * - * @type {RosettaOperationIdentifier} + * Some blockchains specify an operation index that is essential for client use. network_index should not be populated if there is no notion of an operation index in a blockchain (typically most account-based blockchains). + * @type {number} * @memberof RosettaRelatedOperation */ - operation_identifier: RosettaOperationIdentifier; + network_index?: number; } export function RosettaRelatedOperationFromJSON(json: any): RosettaRelatedOperation { @@ -50,8 +43,8 @@ export function RosettaRelatedOperationFromJSONTyped(json: any, ignoreDiscrimina } return { - 'index': !exists(json, 'index') ? undefined : json['index'], - 'operation_identifier': RosettaOperationIdentifierFromJSON(json['operation_identifier']), + 'index': json['index'], + 'network_index': !exists(json, 'network_index') ? undefined : json['network_index'], }; } @@ -65,8 +58,7 @@ export function RosettaRelatedOperationToJSON(value?: RosettaRelatedOperation | return { 'index': value.index, - 'operation_identifier': RosettaOperationIdentifierToJSON(value.operation_identifier), + 'network_index': value.network_index, }; } - diff --git a/client/src/generated/models/RosettaSignature.ts b/client/src/generated/models/RosettaSignature.ts index ed3e7da645..d2997957d1 100644 --- a/client/src/generated/models/RosettaSignature.ts +++ b/client/src/generated/models/RosettaSignature.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -56,6 +56,18 @@ export interface RosettaSignature { hex_bytes: string; } +/** +* @export +* @enum {string} +*/ +export enum RosettaSignatureSignatureTypeEnum { + ecdsa = 'ecdsa', + ecdsa_recovery = 'ecdsa_recovery', + ed25519 = 'ed25519', + schnorr_1 = 'schnorr_1', + schnorr_poseidon = 'schnorr_poseidon' +} + export function RosettaSignatureFromJSON(json: any): RosettaSignature { return RosettaSignatureFromJSONTyped(json, false); } @@ -89,16 +101,3 @@ export function RosettaSignatureToJSON(value?: RosettaSignature | null): any { }; } -/** -* @export -* @enum {string} -*/ -export enum RosettaSignatureSignatureTypeEnum { - ecdsa = 'ecdsa', - ecdsa_recovery = 'ecdsa_recovery', - ed25519 = 'ed25519', - schnorr_1 = 'schnorr_1', - schnorr_poseidon = 'schnorr_poseidon' -} - - diff --git a/client/src/generated/models/RosettaStatusRequest.ts b/client/src/generated/models/RosettaStatusRequest.ts index 3db8f6f129..91ea2c1dea 100644 --- a/client/src/generated/models/RosettaStatusRequest.ts +++ b/client/src/generated/models/RosettaStatusRequest.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -69,4 +69,3 @@ export function RosettaStatusRequestToJSON(value?: RosettaStatusRequest | null): }; } - diff --git a/client/src/generated/models/RosettaSubAccount.ts b/client/src/generated/models/RosettaSubAccount.ts index 90de66a382..0f21e3ff17 100644 --- a/client/src/generated/models/RosettaSubAccount.ts +++ b/client/src/generated/models/RosettaSubAccount.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -62,4 +62,3 @@ export function RosettaSubAccountToJSON(value?: RosettaSubAccount | null): any { }; } - diff --git a/client/src/generated/models/RosettaSyncStatus.ts b/client/src/generated/models/RosettaSyncStatus.ts new file mode 100644 index 0000000000..01c769ce8f --- /dev/null +++ b/client/src/generated/models/RosettaSyncStatus.ts @@ -0,0 +1,80 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * SyncStatus is used to provide additional context about an implementation's sync status. It is often used to indicate that an implementation is healthy when it cannot be queried until some sync phase occurs. If an implementation is immediately queryable, this model is often not populated. + * @export + * @interface RosettaSyncStatus + */ +export interface RosettaSyncStatus { + /** + * CurrentIndex is the index of the last synced block in the current stage. + * @type {number} + * @memberof RosettaSyncStatus + */ + current_index: number; + /** + * TargetIndex is the index of the block that the implementation is attempting to sync to in the current stage. + * @type {number} + * @memberof RosettaSyncStatus + */ + target_index?: number; + /** + * Stage is the phase of the sync process. + * @type {string} + * @memberof RosettaSyncStatus + */ + stage?: string; + /** + * Synced indicates if an implementation has synced up to the most recent block. + * @type {boolean} + * @memberof RosettaSyncStatus + */ + synced?: boolean; +} + +export function RosettaSyncStatusFromJSON(json: any): RosettaSyncStatus { + return RosettaSyncStatusFromJSONTyped(json, false); +} + +export function RosettaSyncStatusFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaSyncStatus { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'current_index': json['current_index'], + 'target_index': !exists(json, 'target_index') ? undefined : json['target_index'], + 'stage': !exists(json, 'stage') ? undefined : json['stage'], + 'synced': !exists(json, 'synced') ? undefined : json['synced'], + }; +} + +export function RosettaSyncStatusToJSON(value?: RosettaSyncStatus | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'current_index': value.current_index, + 'target_index': value.target_index, + 'stage': value.stage, + 'synced': value.synced, + }; +} + diff --git a/client/src/generated/models/RosettaTransaction.ts b/client/src/generated/models/RosettaTransaction.ts index 5fc9875714..cc94bf1d4d 100644 --- a/client/src/generated/models/RosettaTransaction.ts +++ b/client/src/generated/models/RosettaTransaction.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,10 +14,10 @@ import { exists, mapValues } from '../runtime'; import { - RosettaBlockMetadata1, - RosettaBlockMetadata1FromJSON, - RosettaBlockMetadata1FromJSONTyped, - RosettaBlockMetadata1ToJSON, + RosettaBlockMetadata, + RosettaBlockMetadataFromJSON, + RosettaBlockMetadataFromJSONTyped, + RosettaBlockMetadataToJSON, RosettaOperation, RosettaOperationFromJSON, RosettaOperationFromJSONTyped, @@ -48,10 +48,10 @@ export interface RosettaTransaction { operations: Array; /** * - * @type {RosettaBlockMetadata1} + * @type {RosettaBlockMetadata} * @memberof RosettaTransaction */ - metadata?: RosettaBlockMetadata1; + metadata?: RosettaBlockMetadata; } export function RosettaTransactionFromJSON(json: any): RosettaTransaction { @@ -66,7 +66,7 @@ export function RosettaTransactionFromJSONTyped(json: any, ignoreDiscriminator: 'transaction_identifier': TransactionIdentifierFromJSON(json['transaction_identifier']), 'operations': ((json['operations'] as Array).map(RosettaOperationFromJSON)), - 'metadata': !exists(json, 'metadata') ? undefined : RosettaBlockMetadata1FromJSON(json['metadata']), + 'metadata': !exists(json, 'metadata') ? undefined : RosettaBlockMetadataFromJSON(json['metadata']), }; } @@ -81,8 +81,7 @@ export function RosettaTransactionToJSON(value?: RosettaTransaction | null): any 'transaction_identifier': TransactionIdentifierToJSON(value.transaction_identifier), 'operations': ((value.operations as Array).map(RosettaOperationToJSON)), - 'metadata': RosettaBlockMetadata1ToJSON(value.metadata), + 'metadata': RosettaBlockMetadataToJSON(value.metadata), }; } - diff --git a/client/src/generated/models/RunFaucetResponse.ts b/client/src/generated/models/RunFaucetResponse.ts index 1975ab9d26..96b1a75120 100644 --- a/client/src/generated/models/RunFaucetResponse.ts +++ b/client/src/generated/models/RunFaucetResponse.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,7 +14,7 @@ import { exists, mapValues } from '../runtime'; /** - * POST request that runs the faucet + * POST request that initiates a transfer of tokens to a specified testnet address * @export * @interface RunFaucetResponse */ @@ -70,4 +70,3 @@ export function RunFaucetResponseToJSON(value?: RunFaucetResponse | null): any { }; } - diff --git a/client/src/generated/models/ServerStatusResponse.ts b/client/src/generated/models/ServerStatusResponse.ts new file mode 100644 index 0000000000..23fd807407 --- /dev/null +++ b/client/src/generated/models/ServerStatusResponse.ts @@ -0,0 +1,95 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + ChainTip, + ChainTipFromJSON, + ChainTipFromJSONTyped, + ChainTipToJSON, +} from './'; + +/** + * GET blockchain API status + * @export + * @interface ServerStatusResponse + */ +export interface ServerStatusResponse { + /** + * the server version that is currently running + * @type {string} + * @memberof ServerStatusResponse + */ + server_version?: string; + /** + * the current server status + * @type {string} + * @memberof ServerStatusResponse + */ + status: string; + /** + * + * @type {number} + * @memberof ServerStatusResponse + */ + pox_v1_unlock_height?: number | null; + /** + * + * @type {number} + * @memberof ServerStatusResponse + */ + pox_v2_unlock_height?: number | null; + /** + * + * @type {ChainTip} + * @memberof ServerStatusResponse + */ + chain_tip?: ChainTip; +} + +export function ServerStatusResponseFromJSON(json: any): ServerStatusResponse { + return ServerStatusResponseFromJSONTyped(json, false); +} + +export function ServerStatusResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ServerStatusResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'server_version': !exists(json, 'server_version') ? undefined : json['server_version'], + 'status': json['status'], + 'pox_v1_unlock_height': !exists(json, 'pox_v1_unlock_height') ? undefined : json['pox_v1_unlock_height'], + 'pox_v2_unlock_height': !exists(json, 'pox_v2_unlock_height') ? undefined : json['pox_v2_unlock_height'], + 'chain_tip': !exists(json, 'chain_tip') ? undefined : ChainTipFromJSON(json['chain_tip']), + }; +} + +export function ServerStatusResponseToJSON(value?: ServerStatusResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'server_version': value.server_version, + 'status': value.status, + 'pox_v1_unlock_height': value.pox_v1_unlock_height, + 'pox_v2_unlock_height': value.pox_v2_unlock_height, + 'chain_tip': ChainTipToJSON(value.chain_tip), + }; +} + diff --git a/client/src/generated/models/SigningPayload.ts b/client/src/generated/models/SigningPayload.ts index 3862c96922..2d455c7214 100644 --- a/client/src/generated/models/SigningPayload.ts +++ b/client/src/generated/models/SigningPayload.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -27,7 +27,7 @@ import { */ export interface SigningPayload { /** - * The network-specific address of the account that should sign the payload. + * [DEPRECATED by account_identifier in v1.4.4] The network-specific address of the account that should sign the payload. * @type {string} * @memberof SigningPayload */ @@ -52,6 +52,18 @@ export interface SigningPayload { signature_type?: SigningPayloadSignatureTypeEnum; } +/** +* @export +* @enum {string} +*/ +export enum SigningPayloadSignatureTypeEnum { + ecdsa = 'ecdsa', + ecdsa_recovery = 'ecdsa_recovery', + ed25519 = 'ed25519', + schnorr_1 = 'schnorr_1', + schnorr_poseidon = 'schnorr_poseidon' +} + export function SigningPayloadFromJSON(json: any): SigningPayload { return SigningPayloadFromJSONTyped(json, false); } @@ -85,16 +97,3 @@ export function SigningPayloadToJSON(value?: SigningPayload | null): any { }; } -/** -* @export -* @enum {string} -*/ -export enum SigningPayloadSignatureTypeEnum { - ecdsa = 'ecdsa', - ecdsa_recovery = 'ecdsa_recovery', - ed25519 = 'ed25519', - schnorr_1 = 'schnorr_1', - schnorr_poseidon = 'schnorr_poseidon' -} - - diff --git a/client/src/generated/models/SmartContract.ts b/client/src/generated/models/SmartContract.ts new file mode 100644 index 0000000000..434386b650 --- /dev/null +++ b/client/src/generated/models/SmartContract.ts @@ -0,0 +1,96 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * A Smart Contract Detail + * @export + * @interface SmartContract + */ +export interface SmartContract { + /** + * + * @type {string} + * @memberof SmartContract + */ + tx_id: string; + /** + * + * @type {boolean} + * @memberof SmartContract + */ + canonical: boolean; + /** + * + * @type {string} + * @memberof SmartContract + */ + contract_id: string; + /** + * + * @type {number} + * @memberof SmartContract + */ + block_height: number; + /** + * + * @type {string} + * @memberof SmartContract + */ + source_code: string; + /** + * + * @type {string} + * @memberof SmartContract + */ + abi: string; +} + +export function SmartContractFromJSON(json: any): SmartContract { + return SmartContractFromJSONTyped(json, false); +} + +export function SmartContractFromJSONTyped(json: any, ignoreDiscriminator: boolean): SmartContract { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'tx_id': json['tx_id'], + 'canonical': json['canonical'], + 'contract_id': json['contract_id'], + 'block_height': json['block_height'], + 'source_code': json['source_code'], + 'abi': json['abi'], + }; +} + +export function SmartContractToJSON(value?: SmartContract | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'tx_id': value.tx_id, + 'canonical': value.canonical, + 'contract_id': value.contract_id, + 'block_height': value.block_height, + 'source_code': value.source_code, + 'abi': value.abi, + }; +} + diff --git a/client/src/generated/models/AddressBalanceResponseStx.ts b/client/src/generated/models/StxBalance.ts similarity index 53% rename from client/src/generated/models/AddressBalanceResponseStx.ts rename to client/src/generated/models/StxBalance.ts index dccbec6dcc..1bfdc71358 100644 --- a/client/src/generated/models/AddressBalanceResponseStx.ts +++ b/client/src/generated/models/StxBalance.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -14,78 +14,78 @@ import { exists, mapValues } from '../runtime'; /** - * StxBalance + * * @export - * @interface AddressBalanceResponseStx + * @interface StxBalance */ -export interface AddressBalanceResponseStx { +export interface StxBalance { /** * * @type {string} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ balance: string; /** * * @type {string} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ total_sent: string; /** * * @type {string} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ total_received: string; /** * * @type {string} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ total_fees_sent: string; /** * * @type {string} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ total_miner_rewards_received: string; /** * The transaction where the lock event occurred. Empty if no tokens are locked. * @type {string} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ lock_tx_id: string; /** * The amount of locked STX, as string quoted micro-STX. Zero if no tokens are locked. * @type {string} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ locked: string; /** * The STX chain block height of when the lock event occurred. Zero if no tokens are locked. * @type {number} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ lock_height: number; /** * The burnchain block height of when the lock event occurred. Zero if no tokens are locked. * @type {number} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ burnchain_lock_height: number; /** * The burnchain block height of when the tokens unlock. Zero if no tokens are locked. * @type {number} - * @memberof AddressBalanceResponseStx + * @memberof StxBalance */ burnchain_unlock_height: number; } -export function AddressBalanceResponseStxFromJSON(json: any): AddressBalanceResponseStx { - return AddressBalanceResponseStxFromJSONTyped(json, false); +export function StxBalanceFromJSON(json: any): StxBalance { + return StxBalanceFromJSONTyped(json, false); } -export function AddressBalanceResponseStxFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressBalanceResponseStx { +export function StxBalanceFromJSONTyped(json: any, ignoreDiscriminator: boolean): StxBalance { if ((json === undefined) || (json === null)) { return json; } @@ -104,7 +104,7 @@ export function AddressBalanceResponseStxFromJSONTyped(json: any, ignoreDiscrimi }; } -export function AddressBalanceResponseStxToJSON(value?: AddressBalanceResponseStx | null): any { +export function StxBalanceToJSON(value?: StxBalance | null): any { if (value === undefined) { return undefined; } @@ -126,4 +126,3 @@ export function AddressBalanceResponseStxToJSON(value?: AddressBalanceResponseSt }; } - diff --git a/client/src/generated/models/TargetBlockTime.ts b/client/src/generated/models/TargetBlockTime.ts new file mode 100644 index 0000000000..d232ca9ee5 --- /dev/null +++ b/client/src/generated/models/TargetBlockTime.ts @@ -0,0 +1,56 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface TargetBlockTime + */ +export interface TargetBlockTime { + /** + * + * @type {number} + * @memberof TargetBlockTime + */ + target_block_time: number; +} + +export function TargetBlockTimeFromJSON(json: any): TargetBlockTime { + return TargetBlockTimeFromJSONTyped(json, false); +} + +export function TargetBlockTimeFromJSONTyped(json: any, ignoreDiscriminator: boolean): TargetBlockTime { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'target_block_time': json['target_block_time'], + }; +} + +export function TargetBlockTimeToJSON(value?: TargetBlockTime | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'target_block_time': value.target_block_time, + }; +} + diff --git a/client/src/generated/models/TransactionEventsResponse.ts b/client/src/generated/models/TransactionEventsResponse.ts new file mode 100644 index 0000000000..b0ef8b76eb --- /dev/null +++ b/client/src/generated/models/TransactionEventsResponse.ts @@ -0,0 +1,72 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * GET event for the given transaction + * @export + * @interface TransactionEventsResponse + */ +export interface TransactionEventsResponse { + /** + * + * @type {number} + * @memberof TransactionEventsResponse + */ + limit: number; + /** + * + * @type {number} + * @memberof TransactionEventsResponse + */ + offset: number; + /** + * + * @type {Array} + * @memberof TransactionEventsResponse + */ + results: Array; +} + +export function TransactionEventsResponseFromJSON(json: any): TransactionEventsResponse { + return TransactionEventsResponseFromJSONTyped(json, false); +} + +export function TransactionEventsResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionEventsResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'limit': json['limit'], + 'offset': json['offset'], + 'results': json['results'], + }; +} + +export function TransactionEventsResponseToJSON(value?: TransactionEventsResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'limit': value.limit, + 'offset': value.offset, + 'results': value.results, + }; +} + diff --git a/client/src/generated/models/TransactionFeeEstimateRequest.ts b/client/src/generated/models/TransactionFeeEstimateRequest.ts new file mode 100644 index 0000000000..e34df71d21 --- /dev/null +++ b/client/src/generated/models/TransactionFeeEstimateRequest.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * POST request for estimated fee + * @export + * @interface TransactionFeeEstimateRequest + */ +export interface TransactionFeeEstimateRequest { + /** + * + * @type {string} + * @memberof TransactionFeeEstimateRequest + */ + transaction_payload: string; + /** + * + * @type {number} + * @memberof TransactionFeeEstimateRequest + */ + estimated_len?: number; +} + +export function TransactionFeeEstimateRequestFromJSON(json: any): TransactionFeeEstimateRequest { + return TransactionFeeEstimateRequestFromJSONTyped(json, false); +} + +export function TransactionFeeEstimateRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionFeeEstimateRequest { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'transaction_payload': json['transaction_payload'], + 'estimated_len': !exists(json, 'estimated_len') ? undefined : json['estimated_len'], + }; +} + +export function TransactionFeeEstimateRequestToJSON(value?: TransactionFeeEstimateRequest | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'transaction_payload': value.transaction_payload, + 'estimated_len': value.estimated_len, + }; +} + diff --git a/client/src/generated/models/TransactionFeeEstimateResponse.ts b/client/src/generated/models/TransactionFeeEstimateResponse.ts new file mode 100644 index 0000000000..39bd7fcbdd --- /dev/null +++ b/client/src/generated/models/TransactionFeeEstimateResponse.ts @@ -0,0 +1,91 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + TransactionFeeEstimateResponseEstimatedCost, + TransactionFeeEstimateResponseEstimatedCostFromJSON, + TransactionFeeEstimateResponseEstimatedCostFromJSONTyped, + TransactionFeeEstimateResponseEstimatedCostToJSON, + TransactionFeeEstimateResponseEstimations, + TransactionFeeEstimateResponseEstimationsFromJSON, + TransactionFeeEstimateResponseEstimationsFromJSONTyped, + TransactionFeeEstimateResponseEstimationsToJSON, +} from './'; + +/** + * POST response for estimated fee + * @export + * @interface TransactionFeeEstimateResponse + */ +export interface TransactionFeeEstimateResponse { + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponse + */ + estimated_cost_scalar: number; + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponse + */ + cost_scalar_change_by_byte?: number; + /** + * + * @type {TransactionFeeEstimateResponseEstimatedCost} + * @memberof TransactionFeeEstimateResponse + */ + estimated_cost: TransactionFeeEstimateResponseEstimatedCost; + /** + * + * @type {Array} + * @memberof TransactionFeeEstimateResponse + */ + estimations?: Array; +} + +export function TransactionFeeEstimateResponseFromJSON(json: any): TransactionFeeEstimateResponse { + return TransactionFeeEstimateResponseFromJSONTyped(json, false); +} + +export function TransactionFeeEstimateResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionFeeEstimateResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'estimated_cost_scalar': json['estimated_cost_scalar'], + 'cost_scalar_change_by_byte': !exists(json, 'cost_scalar_change_by_byte') ? undefined : json['cost_scalar_change_by_byte'], + 'estimated_cost': TransactionFeeEstimateResponseEstimatedCostFromJSON(json['estimated_cost']), + 'estimations': !exists(json, 'estimations') ? undefined : ((json['estimations'] as Array).map(TransactionFeeEstimateResponseEstimationsFromJSON)), + }; +} + +export function TransactionFeeEstimateResponseToJSON(value?: TransactionFeeEstimateResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'estimated_cost_scalar': value.estimated_cost_scalar, + 'cost_scalar_change_by_byte': value.cost_scalar_change_by_byte, + 'estimated_cost': TransactionFeeEstimateResponseEstimatedCostToJSON(value.estimated_cost), + 'estimations': value.estimations === undefined ? undefined : ((value.estimations as Array).map(TransactionFeeEstimateResponseEstimationsToJSON)), + }; +} + diff --git a/client/src/generated/models/TransactionFeeEstimateResponseEstimatedCost.ts b/client/src/generated/models/TransactionFeeEstimateResponseEstimatedCost.ts new file mode 100644 index 0000000000..dc4160a3a0 --- /dev/null +++ b/client/src/generated/models/TransactionFeeEstimateResponseEstimatedCost.ts @@ -0,0 +1,88 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface TransactionFeeEstimateResponseEstimatedCost + */ +export interface TransactionFeeEstimateResponseEstimatedCost { + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponseEstimatedCost + */ + read_count: number; + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponseEstimatedCost + */ + read_length: number; + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponseEstimatedCost + */ + runtime: number; + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponseEstimatedCost + */ + write_count: number; + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponseEstimatedCost + */ + write_length: number; +} + +export function TransactionFeeEstimateResponseEstimatedCostFromJSON(json: any): TransactionFeeEstimateResponseEstimatedCost { + return TransactionFeeEstimateResponseEstimatedCostFromJSONTyped(json, false); +} + +export function TransactionFeeEstimateResponseEstimatedCostFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionFeeEstimateResponseEstimatedCost { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'read_count': json['read_count'], + 'read_length': json['read_length'], + 'runtime': json['runtime'], + 'write_count': json['write_count'], + 'write_length': json['write_length'], + }; +} + +export function TransactionFeeEstimateResponseEstimatedCostToJSON(value?: TransactionFeeEstimateResponseEstimatedCost | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'read_count': value.read_count, + 'read_length': value.read_length, + 'runtime': value.runtime, + 'write_count': value.write_count, + 'write_length': value.write_length, + }; +} + diff --git a/client/src/generated/models/TransactionFeeEstimateResponseEstimations.ts b/client/src/generated/models/TransactionFeeEstimateResponseEstimations.ts new file mode 100644 index 0000000000..ccb1484e89 --- /dev/null +++ b/client/src/generated/models/TransactionFeeEstimateResponseEstimations.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface TransactionFeeEstimateResponseEstimations + */ +export interface TransactionFeeEstimateResponseEstimations { + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponseEstimations + */ + fee_rate?: number; + /** + * + * @type {number} + * @memberof TransactionFeeEstimateResponseEstimations + */ + fee?: number; +} + +export function TransactionFeeEstimateResponseEstimationsFromJSON(json: any): TransactionFeeEstimateResponseEstimations { + return TransactionFeeEstimateResponseEstimationsFromJSONTyped(json, false); +} + +export function TransactionFeeEstimateResponseEstimationsFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionFeeEstimateResponseEstimations { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'fee_rate': !exists(json, 'fee_rate') ? undefined : json['fee_rate'], + 'fee': !exists(json, 'fee') ? undefined : json['fee'], + }; +} + +export function TransactionFeeEstimateResponseEstimationsToJSON(value?: TransactionFeeEstimateResponseEstimations | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'fee_rate': value.fee_rate, + 'fee': value.fee, + }; +} + diff --git a/client/src/generated/models/TransactionIdentifier.ts b/client/src/generated/models/TransactionIdentifier.ts index f7cc96773e..539bb6983e 100644 --- a/client/src/generated/models/TransactionIdentifier.ts +++ b/client/src/generated/models/TransactionIdentifier.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,4 +54,3 @@ export function TransactionIdentifierToJSON(value?: TransactionIdentifier | null }; } - diff --git a/client/src/generated/models/TransactionResults.ts b/client/src/generated/models/TransactionResults.ts index 1defa58877..6d9353ee16 100644 --- a/client/src/generated/models/TransactionResults.ts +++ b/client/src/generated/models/TransactionResults.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -78,4 +78,3 @@ export function TransactionResultsToJSON(value?: TransactionResults | null): any }; } - diff --git a/client/src/generated/models/UnanchoredTransactionListResponse.ts b/client/src/generated/models/UnanchoredTransactionListResponse.ts new file mode 100644 index 0000000000..ff248f61fb --- /dev/null +++ b/client/src/generated/models/UnanchoredTransactionListResponse.ts @@ -0,0 +1,64 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection + * + * The version of the OpenAPI document: STACKS_API_VERSION + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * GET request that returns unanchored transactions + * @export + * @interface UnanchoredTransactionListResponse + */ +export interface UnanchoredTransactionListResponse { + /** + * The number of unanchored transactions available + * @type {number} + * @memberof UnanchoredTransactionListResponse + */ + total: number; + /** + * + * @type {Array} + * @memberof UnanchoredTransactionListResponse + */ + results: Array; +} + +export function UnanchoredTransactionListResponseFromJSON(json: any): UnanchoredTransactionListResponse { + return UnanchoredTransactionListResponseFromJSONTyped(json, false); +} + +export function UnanchoredTransactionListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): UnanchoredTransactionListResponse { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'total': json['total'], + 'results': json['results'], + }; +} + +export function UnanchoredTransactionListResponseToJSON(value?: UnanchoredTransactionListResponse | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'total': value.total, + 'results': value.results, + }; +} + diff --git a/client/src/generated/models/index.ts b/client/src/generated/models/index.ts index e6735df4c5..8523717aef 100644 --- a/client/src/generated/models/index.ts +++ b/client/src/generated/models/index.ts @@ -1,24 +1,74 @@ +/* tslint:disable */ +/* eslint-disable */ export * from './AccountDataResponse'; export * from './AddressAssetsListResponse'; export * from './AddressBalanceResponse'; -export * from './AddressBalanceResponseStx'; -export * from './AddressStxBalanceResponse'; +export * from './AddressNftListResponse'; +export * from './AddressNftListResponseValue'; +export * from './AddressNonces'; +export * from './AddressStxInboundListResponse'; +export * from './AddressTokenOfferingLocked'; +export * from './AddressTransactionWithTransfers'; +export * from './AddressTransactionWithTransfersFtTransfers'; +export * from './AddressTransactionWithTransfersNftTransfers'; +export * from './AddressTransactionWithTransfersStxTransfers'; +export * from './AddressTransactionWithTransfersValue'; export * from './AddressTransactionsListResponse'; +export * from './AddressTransactionsWithTransfersListResponse'; +export * from './AddressUnlockSchedule'; export * from './Block'; export * from './BlockListResponse'; +export * from './BnsError'; +export * from './BnsGetAllNamespacesResponse'; +export * from './BnsGetNameInfoResponse'; +export * from './BnsGetNamePriceResponse'; +export * from './BnsGetNamespacePriceResponse'; +export * from './BnsNamesOwnByAddressResponse'; export * from './BurnchainReward'; export * from './BurnchainRewardListResponse'; +export * from './BurnchainRewardSlotHolder'; +export * from './BurnchainRewardSlotHolderListResponse'; export * from './BurnchainRewardsTotal'; +export * from './ChainTip'; export * from './ContractInterfaceResponse'; +export * from './ContractListResponse'; export * from './ContractSourceResponse'; export * from './CoreNodeInfoResponse'; export * from './CoreNodePoxResponse'; +export * from './FeeRate'; +export * from './FeeRateRequest'; +export * from './FungibleTokenMetadata'; +export * from './FungibleTokensMetadataList'; +export * from './GetRawTransactionResult'; +export * from './GetStxSupplyLegacyFormatResponse'; +export * from './GetStxSupplyResponse'; +export * from './InboundStxTransfer'; +export * from './InlineObject'; +export * from './InlineResponse403'; export * from './MapEntryResponse'; +export * from './MempoolFeePriorities'; +export * from './MempoolFeePrioritiesAll'; export * from './MempoolTransactionListResponse'; +export * from './MempoolTransactionStatsResponse'; +export * from './MempoolTransactionStatsResponseTxAges'; +export * from './MempoolTransactionStatsResponseTxByteSizes'; +export * from './MempoolTransactionStatsResponseTxSimpleFeeAverages'; +export * from './MempoolTransactionStatsResponseTxSimpleFeeAveragesTokenTransfer'; +export * from './MempoolTransactionStatsResponseTxTypeCounts'; +export * from './Microblock'; +export * from './MicroblockListResponse'; export * from './NetworkBlockTimeResponse'; export * from './NetworkBlockTimesResponse'; -export * from './NetworkBlockTimesResponseMainnet'; export * from './NetworkIdentifier'; +export * from './NftEvent'; +export * from './NonFungibleTokenHistoryEventList'; +export * from './NonFungibleTokenHoldingsList'; +export * from './NonFungibleTokenMetadata'; +export * from './NonFungibleTokenMintList'; +export * from './NonFungibleTokensMetadataList'; +export * from './OtherTransactionIdentifier'; +export * from './PoolDelegation'; +export * from './PoolDelegationsResponse'; export * from './PostCoreNodeTransactionsError'; export * from './ReadOnlyFunctionArgs'; export * from './ReadOnlyFunctionSuccessResponse'; @@ -27,11 +77,11 @@ export * from './RosettaAccountBalanceRequest'; export * from './RosettaAccountBalanceResponse'; export * from './RosettaAccountBalanceResponseCoinIdentifier'; export * from './RosettaAccountBalanceResponseMetadata'; +export * from './RosettaAccountIdentifier'; export * from './RosettaAmount'; export * from './RosettaBlock'; export * from './RosettaBlockMetadata'; export * from './RosettaBlockMetadata1'; -export * from './RosettaBlockMetadata2'; export * from './RosettaBlockRequest'; export * from './RosettaBlockResponse'; export * from './RosettaBlockTransactionRequest'; @@ -58,6 +108,9 @@ export * from './RosettaConstructionSubmitResponse'; export * from './RosettaCurrency'; export * from './RosettaError'; export * from './RosettaErrorDetails'; +export * from './RosettaErrorNoDetails'; +export * from './RosettaGenesisBlockIdentifier'; +export * from './RosettaMaxFeeAmount'; export * from './RosettaMempoolRequest'; export * from './RosettaMempoolResponse'; export * from './RosettaMempoolTransactionRequest'; @@ -68,19 +121,33 @@ export * from './RosettaNetworkListResponseSubNetworkIdentifierMetadata'; export * from './RosettaNetworkOptionsResponse'; export * from './RosettaNetworkOptionsResponseAllow'; export * from './RosettaNetworkOptionsResponseVersion'; +export * from './RosettaNetworkStatusResponse'; +export * from './RosettaOldestBlockIdentifier'; export * from './RosettaOperation'; export * from './RosettaOperationIdentifier'; export * from './RosettaOperationStatus'; export * from './RosettaOptions'; export * from './RosettaOptionsRequest'; export * from './RosettaParentBlockIdentifier'; +export * from './RosettaPeers'; export * from './RosettaPublicKey'; export * from './RosettaRelatedOperation'; export * from './RosettaSignature'; export * from './RosettaStatusRequest'; export * from './RosettaSubAccount'; +export * from './RosettaSyncStatus'; export * from './RosettaTransaction'; export * from './RunFaucetResponse'; +export * from './ServerStatusResponse'; export * from './SigningPayload'; +export * from './SmartContract'; +export * from './StxBalance'; +export * from './TargetBlockTime'; +export * from './TransactionEventsResponse'; +export * from './TransactionFeeEstimateRequest'; +export * from './TransactionFeeEstimateResponse'; +export * from './TransactionFeeEstimateResponseEstimatedCost'; +export * from './TransactionFeeEstimateResponseEstimations'; export * from './TransactionIdentifier'; export * from './TransactionResults'; +export * from './UnanchoredTransactionListResponse'; diff --git a/client/src/generated/runtime.ts b/client/src/generated/runtime.ts index 8557681453..7ff36f09e5 100644 --- a/client/src/generated/runtime.ts +++ b/client/src/generated/runtime.ts @@ -1,10 +1,10 @@ /* tslint:disable */ /* eslint-disable */ /** - * Stacks 2.0 Blockchain API - * This is the documentation for the Stacks 2.0 Blockchain API. It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API. [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) + * Stacks Blockchain API + * Welcome to the API reference overview for the Stacks Blockchain API. Download Postman collection * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: STACKS_API_VERSION * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -44,8 +44,8 @@ export class BaseAPI { return this.withMiddleware(...middlewares); } - protected async request(context: RequestOpts): Promise { - const { url, init } = this.createFetchParams(context); + protected async request(context: RequestOpts, initOverrides?: RequestInit): Promise { + const { url, init } = this.createFetchParams(context, initOverrides); const response = await this.fetchApi(url, init); if (response.status >= 200 && response.status < 300) { return response; @@ -53,7 +53,7 @@ export class BaseAPI { throw response; } - private createFetchParams(context: RequestOpts) { + private createFetchParams(context: RequestOpts, initOverrides?: RequestInit) { let url = this.configuration.basePath + context.path; if (context.query !== undefined && Object.keys(context.query).length !== 0) { // only add the querystring to the URL if there are query parameters. @@ -62,15 +62,16 @@ export class BaseAPI { url += '?' + this.configuration.queryParamsStringify(context.query); } const body = ((typeof FormData !== "undefined" && context.body instanceof FormData) || context.body instanceof URLSearchParams || isBlob(context.body)) - ? context.body - : JSON.stringify(context.body); + ? context.body + : JSON.stringify(context.body); const headers = Object.assign({}, this.configuration.headers, context.headers); const init = { method: context.method, headers: headers, body, - credentials: this.configuration.credentials + credentials: this.configuration.credentials, + ...initOverrides }; return { url, init }; } @@ -85,13 +86,13 @@ export class BaseAPI { }) || fetchParams; } } - let response = await this.configuration.fetchApi(fetchParams.url, fetchParams.init); + let response = await (this.configuration.fetchApi || fetch)(fetchParams.url, fetchParams.init); for (const middleware of this.middleware) { if (middleware.post) { response = await middleware.post({ fetch: this.fetchApi, - url, - init, + url: fetchParams.url, + init: fetchParams.init, response: response.clone(), }) || response; } @@ -135,7 +136,7 @@ export interface ConfigurationParameters { username?: string; // parameter for basic security password?: string; // parameter for basic security apiKey?: string | ((name: string) => string); // parameter for apiKey security - accessToken?: string | ((name?: string, scopes?: string[]) => string); // parameter for oauth2 security + accessToken?: string | Promise | ((name?: string, scopes?: string[]) => string | Promise); // parameter for oauth2 security headers?: HTTPHeaders; //header params we want to use on every request credentials?: RequestCredentials; //value for the credentials param we want to use on each request } @@ -147,8 +148,8 @@ export class Configuration { return this.configuration.basePath != null ? this.configuration.basePath : BASE_PATH; } - get fetchApi(): FetchAPI { - return this.configuration.fetchApi || window.fetch.bind(window); + get fetchApi(): FetchAPI | undefined { + return this.configuration.fetchApi; } get middleware(): Middleware[] { @@ -175,15 +176,15 @@ export class Configuration { return undefined; } - get accessToken(): ((name: string, scopes?: string[]) => string) | undefined { + get accessToken(): ((name?: string, scopes?: string[]) => string | Promise) | undefined { const accessToken = this.configuration.accessToken; if (accessToken) { - return typeof accessToken === 'function' ? accessToken : () => accessToken; + return typeof accessToken === 'function' ? accessToken : async () => accessToken; } return undefined; } - get headers(): HTTPHeaders | undefined { + get headers(): HTTPHeaders | undefined { return this.configuration.headers; } @@ -227,6 +228,9 @@ export function querystring(params: HTTPQuery, prefix: string = ''): string { .join(`&${encodeURIComponent(fullKey)}=`); return `${encodeURIComponent(fullKey)}=${multiValue}`; } + if (value instanceof Date) { + return `${encodeURIComponent(fullKey)}=${encodeURIComponent(value.toISOString())}`; + } if (value instanceof Object) { return querystring(value as HTTPQuery, fullKey); } diff --git a/docs/openapi.yaml b/docs/openapi.yaml index 7e3394ed43..7c5030d407 100644 --- a/docs/openapi.yaml +++ b/docs/openapi.yaml @@ -312,9 +312,9 @@ paths: content: application/json: schema: - $ref: ./api/transaction/get-mempool-transactions.schema.json + $ref: ./api/mempool/get-fee-priorities.schema.json example: - $ref: ./api/transaction/get-mempool-transactions.example.json + $ref: ./api/mempool/get-fee-priorities.example.json /extended/v1/tx/mempool/dropped: get: