@avalabs/glacier-sdk 2.8.0-alpha.99 → 2.8.0-canary.1c410fd.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +2198 -1700
- package/dist/index.js +562 -266
- package/esm/generated/Glacier.d.ts +22 -2
- package/esm/generated/Glacier.js +23 -3
- package/esm/generated/core/OpenAPI.js +1 -1
- package/esm/generated/models/ActiveDelegatorDetails.d.ts +15 -0
- package/esm/generated/models/ActiveValidatorDetails.d.ts +20 -0
- package/esm/generated/models/Blockchain.d.ts +10 -0
- package/esm/generated/models/BlockchainId.d.ts +6 -3
- package/esm/generated/models/BlockchainId.js +5 -2
- package/esm/generated/models/BlockchainIds.d.ts +9 -0
- package/esm/generated/models/BlockchainIds.js +10 -0
- package/esm/generated/models/BlockchainInfo.d.ts +5 -0
- package/esm/generated/models/ChainAddressChainIdMap.d.ts +2 -2
- package/esm/generated/models/ChainInfo.d.ts +1 -4
- package/esm/generated/models/CompletedDelegatorDetails.d.ts +15 -0
- package/esm/generated/models/CompletedValidatorDetails.d.ts +15 -0
- package/esm/generated/models/ContractDeploymentDetails.d.ts +13 -0
- package/esm/generated/models/CreateEvmTransactionExportRequest.d.ts +23 -0
- package/esm/generated/models/CreateEvmTransactionExportRequest.js +8 -0
- package/esm/generated/models/CreatePrimaryNetworkTransactionExportRequest.d.ts +23 -0
- package/esm/generated/models/CreatePrimaryNetworkTransactionExportRequest.js +8 -0
- package/esm/generated/models/DelegationStatusType.d.ts +7 -0
- package/esm/generated/models/DelegationStatusType.js +8 -0
- package/esm/generated/models/DelegatorsDetails.d.ts +6 -0
- package/esm/generated/models/EVMInput.d.ts +5 -0
- package/esm/generated/models/Erc1155Contract.d.ts +37 -0
- package/esm/generated/models/Erc1155Contract.js +8 -0
- package/esm/generated/models/Erc1155TokenBalance.d.ts +1 -2
- package/esm/generated/models/Erc1155Transfer.d.ts +1 -0
- package/esm/generated/models/Erc1155TransferDetails.d.ts +1 -0
- package/esm/generated/models/Erc20Contract.d.ts +41 -0
- package/esm/generated/models/Erc20Contract.js +8 -0
- package/esm/generated/models/Erc20Token.d.ts +1 -3
- package/esm/generated/models/Erc20TokenBalance.d.ts +2 -5
- package/esm/generated/models/Erc20Transfer.d.ts +1 -0
- package/esm/generated/models/Erc20TransferDetails.d.ts +1 -0
- package/esm/generated/models/Erc721Contract.d.ts +35 -0
- package/esm/generated/models/Erc721Contract.js +8 -0
- package/esm/generated/models/Erc721Transfer.d.ts +1 -0
- package/esm/generated/models/Erc721TransferDetails.d.ts +1 -0
- package/esm/generated/models/{GetBlockResponse.d.ts → EvmBlock.d.ts} +2 -6
- package/esm/generated/models/EvmNetworkOptions.d.ts +1 -1
- package/esm/generated/models/GetChainResponse.d.ts +1 -4
- package/esm/generated/models/GetEvmBlockResponse.d.ts +45 -0
- package/esm/generated/models/GetNetworkDetailsResponse.d.ts +9 -0
- package/esm/generated/models/GetPrimaryNetworkBlockResponse.d.ts +15 -0
- package/esm/generated/models/GetTransactionResponse.d.ts +1 -7
- package/esm/generated/models/HistoricalReward.d.ts +24 -0
- package/esm/generated/models/ImageAsset.d.ts +9 -0
- package/esm/generated/models/{ListListingsResponse.d.ts → ListBlockchainsResponse.d.ts} +4 -4
- package/esm/generated/models/ListCChainAtomicBalancesResponse.d.ts +2 -0
- package/esm/generated/models/ListCChainAtomicTransactionsResponse.d.ts +2 -0
- package/esm/generated/models/ListCollectibleBalancesResponse.d.ts +1 -2
- package/esm/generated/models/ListContractsResponse.d.ts +14 -0
- package/esm/generated/models/ListDelegatorDetailsResponse.d.ts +16 -0
- package/esm/generated/models/ListEvmBlocksResponse.d.ts +11 -0
- package/esm/generated/models/ListHistoricalRewardsResponse.d.ts +11 -0
- package/esm/generated/models/ListPChainBalancesResponse.d.ts +2 -0
- package/esm/generated/models/ListPChainTransactionsResponse.d.ts +2 -0
- package/esm/generated/models/ListPChainUtxosResponse.d.ts +2 -0
- package/esm/generated/models/ListPendingRewardsResponse.d.ts +11 -0
- package/esm/generated/models/ListPrimaryNetworkBlocksResponse.d.ts +13 -0
- package/esm/generated/models/{ListBlocksResponse.d.ts → ListSubnetsResponse.d.ts} +4 -4
- package/esm/generated/models/ListUtxosResponse.d.ts +2 -0
- package/esm/generated/models/ListValidatorDetailsResponse.d.ts +16 -0
- package/esm/generated/models/ListXChainBalancesResponse.d.ts +2 -0
- package/esm/generated/models/ListXChainTransactionsResponse.d.ts +2 -0
- package/esm/generated/models/ListXChainVerticesResponse.d.ts +2 -0
- package/esm/generated/models/Method.d.ts +1 -7
- package/esm/generated/models/NativeTokenBalance.d.ts +2 -5
- package/esm/generated/models/NetworkToken.d.ts +1 -3
- package/esm/generated/models/NetworkTokenDetails.d.ts +1 -3
- package/esm/generated/models/NetworkType.d.ts +6 -0
- package/esm/generated/models/NetworkType.js +7 -0
- package/esm/generated/models/OperationStatusResponse.d.ts +2 -2
- package/esm/generated/models/OperationType.d.ts +2 -1
- package/esm/generated/models/OperationType.js +2 -1
- package/esm/generated/models/PChainBalance.d.ts +16 -7
- package/esm/generated/models/PChainId.d.ts +2 -2
- package/esm/generated/models/PChainId.js +1 -1
- package/esm/generated/models/PChainSharedAsset.d.ts +8 -0
- package/esm/generated/models/PChainTransaction.d.ts +9 -15
- package/esm/generated/models/PChainTransactionType.d.ts +16 -0
- package/esm/generated/models/PChainTransactionType.js +17 -0
- package/esm/generated/models/PChainUtxo.d.ts +10 -1
- package/esm/generated/models/PendingDelegatorDetails.d.ts +15 -0
- package/esm/generated/models/PendingReward.d.ts +22 -0
- package/esm/generated/models/PendingValidatorDetails.d.ts +12 -0
- package/esm/generated/models/PricingProviders.d.ts +5 -0
- package/esm/generated/models/PrimaryNetwork.d.ts +6 -0
- package/esm/generated/models/PrimaryNetwork.js +7 -0
- package/esm/generated/models/{Block.d.ts → PrimaryNetworkBlock.d.ts} +3 -3
- package/esm/generated/models/PrimaryNetworkChainInfo.d.ts +9 -0
- package/esm/generated/models/PrimaryNetworkChainName.d.ts +7 -0
- package/esm/generated/models/PrimaryNetworkChainName.js +8 -0
- package/esm/generated/models/PrimaryNetworkOptions.d.ts +2 -1
- package/esm/generated/models/PrimaryNetworkTxType.d.ts +19 -0
- package/esm/generated/models/PrimaryNetworkTxType.js +20 -0
- package/esm/generated/models/RewardType.d.ts +6 -0
- package/esm/generated/models/RewardType.js +7 -0
- package/esm/generated/models/Rewards.d.ts +6 -0
- package/esm/generated/models/RichAddress.d.ts +1 -3
- package/esm/generated/models/StakingDistribution.d.ts +7 -0
- package/esm/generated/models/Subnet.d.ts +13 -0
- package/esm/generated/models/TransactionDetails.d.ts +1 -7
- package/esm/generated/models/TransactionExportMetadata.d.ts +15 -0
- package/esm/generated/models/UnknownContract.d.ts +31 -0
- package/esm/generated/models/UnknownContract.js +8 -0
- package/esm/generated/models/Utxo.d.ts +9 -1
- package/esm/generated/models/UtxoType.d.ts +6 -0
- package/esm/generated/models/UtxoType.js +7 -0
- package/esm/generated/models/ValidationStatusType.d.ts +7 -0
- package/esm/generated/models/ValidationStatusType.js +8 -0
- package/esm/generated/models/ValidatorsDetails.d.ts +11 -0
- package/esm/generated/models/XChainBalances.d.ts +2 -2
- package/esm/generated/models/XChainId.d.ts +3 -2
- package/esm/generated/models/XChainId.js +2 -1
- package/esm/generated/models/XChainLinearTransaction.d.ts +4 -4
- package/esm/generated/models/XChainLinearTransaction.js +1 -1
- package/esm/generated/models/XChainNonLinearTransaction.d.ts +4 -4
- package/esm/generated/models/XChainNonLinearTransaction.js +1 -1
- package/esm/generated/services/EvmBalancesService.d.ts +177 -0
- package/esm/generated/services/EvmBalancesService.js +116 -0
- package/esm/generated/services/EvmBlocksService.d.ts +47 -0
- package/esm/generated/services/EvmBlocksService.js +37 -0
- package/esm/generated/services/EvmChainsService.d.ts +36 -0
- package/esm/generated/services/EvmChainsService.js +29 -0
- package/esm/generated/services/EvmTransactionsService.d.ts +311 -0
- package/esm/generated/services/EvmTransactionsService.js +251 -0
- package/esm/generated/services/HealthCheckService.d.ts +1 -1
- package/esm/generated/services/NfTsService.d.ts +69 -0
- package/esm/generated/services/NfTsService.js +50 -0
- package/esm/generated/services/OperationsService.d.ts +8 -3
- package/esm/generated/services/PrimaryNetworkBalancesService.d.ts +40 -0
- package/esm/generated/services/PrimaryNetworkBalancesService.js +26 -0
- package/esm/generated/services/PrimaryNetworkBlocksService.d.ts +85 -0
- package/esm/generated/services/PrimaryNetworkBlocksService.js +62 -0
- package/esm/generated/services/PrimaryNetworkRewardsService.d.ts +69 -0
- package/esm/generated/services/PrimaryNetworkRewardsService.js +49 -0
- package/esm/generated/services/PrimaryNetworkService.d.ts +87 -253
- package/esm/generated/services/PrimaryNetworkService.js +53 -167
- package/esm/generated/services/PrimaryNetworkTransactionsService.d.ts +175 -0
- package/esm/generated/services/PrimaryNetworkTransactionsService.js +107 -0
- package/esm/generated/services/PrimaryNetworkUtxOsService.d.ts +54 -0
- package/esm/generated/services/PrimaryNetworkUtxOsService.js +34 -0
- package/esm/generated/services/PrimaryNetworkVerticesService.d.ts +90 -0
- package/esm/generated/services/PrimaryNetworkVerticesService.js +64 -0
- package/esm/index.d.ts +62 -31
- package/esm/index.js +27 -9
- package/package.json +2 -5
- package/esm/generated/models/Address.d.ts +0 -8
- package/esm/generated/models/CancelListingEventResponse.d.ts +0 -5
- package/esm/generated/models/CloseAuctionEventResponse.d.ts +0 -6
- package/esm/generated/models/CollectionMetrics.d.ts +0 -40
- package/esm/generated/models/CollectionSortByOption.d.ts +0 -8
- package/esm/generated/models/CollectionSortByOption.js +0 -9
- package/esm/generated/models/CreateTransactionExportRequest.d.ts +0 -11
- package/esm/generated/models/ErcType.d.ts +0 -8
- package/esm/generated/models/ErcType.js +0 -9
- package/esm/generated/models/ListNftCollectionWithMetricsResponse.d.ts +0 -11
- package/esm/generated/models/ListingCurrencyType.d.ts +0 -6
- package/esm/generated/models/ListingCurrencyType.js +0 -7
- package/esm/generated/models/ListingEventType.d.ts +0 -8
- package/esm/generated/models/ListingEventType.js +0 -9
- package/esm/generated/models/ListingResponse.d.ts +0 -19
- package/esm/generated/models/ListingType.d.ts +0 -6
- package/esm/generated/models/ListingType.js +0 -7
- package/esm/generated/models/ListingsSortByOption.d.ts +0 -5
- package/esm/generated/models/ListingsSortByOption.js +0 -6
- package/esm/generated/models/NftCollection.d.ts +0 -24
- package/esm/generated/models/NftCollectionWithMetrics.d.ts +0 -26
- package/esm/generated/models/NftFilterOptionsProperty.d.ts +0 -10
- package/esm/generated/models/NftSearchBody.d.ts +0 -10
- package/esm/generated/models/NftSearchResultTypeOption.d.ts +0 -6
- package/esm/generated/models/NftSearchResultTypeOption.js +0 -7
- package/esm/generated/models/OpenListingEventResponse.d.ts +0 -17
- package/esm/generated/models/OperationTransactionExportMetadata.d.ts +0 -18
- package/esm/generated/models/PChainConsumedUtxo.d.ts +0 -11
- package/esm/generated/models/PChainEmittedUtxo.d.ts +0 -19
- package/esm/generated/models/PaginationParams.d.ts +0 -13
- package/esm/generated/models/PurchaseListingEventResponse.d.ts +0 -17
- package/esm/generated/models/TokenWithPrice.d.ts +0 -28
- package/esm/generated/models/TrendingTimeframe.d.ts +0 -7
- package/esm/generated/models/TrendingTimeframe.js +0 -8
- package/esm/generated/services/EvmService.d.ts +0 -724
- package/esm/generated/services/EvmService.js +0 -509
package/dist/index.d.ts
CHANGED
|
@@ -60,13 +60,6 @@ declare abstract class BaseHttpRequest {
|
|
|
60
60
|
abstract request<T>(options: ApiRequestOptions): CancelablePromise<T>;
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
declare enum CollectionSortByOption {
|
|
64
|
-
SALE_TIMESTAMP = "saleTimestamp",
|
|
65
|
-
VOLUME = "volume",
|
|
66
|
-
VOLUME_CHANGE = "volumeChange",
|
|
67
|
-
FLOOR_PRICE = "floorPrice"
|
|
68
|
-
}
|
|
69
|
-
|
|
70
63
|
declare enum CurrencyCode {
|
|
71
64
|
USD = "usd",
|
|
72
65
|
EUR = "eur",
|
|
@@ -84,6 +77,59 @@ declare enum CurrencyCode {
|
|
|
84
77
|
NZD = "nzd"
|
|
85
78
|
}
|
|
86
79
|
|
|
80
|
+
type Money = {
|
|
81
|
+
/**
|
|
82
|
+
* ISO 4217 currency code.
|
|
83
|
+
*/
|
|
84
|
+
currencyCode: CurrencyCode;
|
|
85
|
+
/**
|
|
86
|
+
* Monetary value in base 10 decimals.
|
|
87
|
+
*/
|
|
88
|
+
value: number;
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
type NativeTokenBalance = {
|
|
92
|
+
/**
|
|
93
|
+
* The contract name.
|
|
94
|
+
*/
|
|
95
|
+
name: string;
|
|
96
|
+
/**
|
|
97
|
+
* The contract symbol.
|
|
98
|
+
*/
|
|
99
|
+
symbol: string;
|
|
100
|
+
/**
|
|
101
|
+
* The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
|
|
102
|
+
*/
|
|
103
|
+
decimals: number;
|
|
104
|
+
/**
|
|
105
|
+
* The logo uri for the address.
|
|
106
|
+
*/
|
|
107
|
+
logoUri?: string;
|
|
108
|
+
/**
|
|
109
|
+
* The evm chain id.
|
|
110
|
+
*/
|
|
111
|
+
chainId: string;
|
|
112
|
+
/**
|
|
113
|
+
* The token price, if available.
|
|
114
|
+
*/
|
|
115
|
+
price?: Money;
|
|
116
|
+
/**
|
|
117
|
+
* The address balance for the token, in units specified by the `decimals` value for the contract.
|
|
118
|
+
*/
|
|
119
|
+
balance: string;
|
|
120
|
+
/**
|
|
121
|
+
* The monetary value of the balance, if a price is available for the token.
|
|
122
|
+
*/
|
|
123
|
+
balanceValue?: Money;
|
|
124
|
+
};
|
|
125
|
+
|
|
126
|
+
type GetNativeBalanceResponse = {
|
|
127
|
+
/**
|
|
128
|
+
* The native token balance for the address.
|
|
129
|
+
*/
|
|
130
|
+
nativeTokenBalance: NativeTokenBalance;
|
|
131
|
+
};
|
|
132
|
+
|
|
87
133
|
declare enum NftTokenMetadataStatus {
|
|
88
134
|
UNKNOWN = "UNKNOWN",
|
|
89
135
|
MISSING_TOKEN = "MISSING_TOKEN",
|
|
@@ -115,17 +161,25 @@ type Erc1155TokenMetadata = {
|
|
|
115
161
|
properties?: string;
|
|
116
162
|
};
|
|
117
163
|
|
|
118
|
-
type
|
|
164
|
+
type Erc1155TokenBalance = {
|
|
119
165
|
/**
|
|
120
166
|
* A wallet or contract address in mixed-case checksum encoding.
|
|
121
167
|
*/
|
|
122
168
|
address: string;
|
|
123
|
-
ercType:
|
|
169
|
+
ercType: Erc1155TokenBalance.ercType;
|
|
124
170
|
tokenId: string;
|
|
125
171
|
tokenUri: string;
|
|
126
172
|
metadata: Erc1155TokenMetadata;
|
|
173
|
+
/**
|
|
174
|
+
* The evm chain id.
|
|
175
|
+
*/
|
|
176
|
+
chainId: string;
|
|
177
|
+
/**
|
|
178
|
+
* The address balance for the token, in units specified by the `decimals` value for the contract.
|
|
179
|
+
*/
|
|
180
|
+
balance: string;
|
|
127
181
|
};
|
|
128
|
-
declare namespace
|
|
182
|
+
declare namespace Erc1155TokenBalance {
|
|
129
183
|
enum ercType {
|
|
130
184
|
ERC_1155 = "ERC-1155"
|
|
131
185
|
}
|
|
@@ -147,7 +201,7 @@ type Erc721TokenMetadata = {
|
|
|
147
201
|
attributes?: string;
|
|
148
202
|
};
|
|
149
203
|
|
|
150
|
-
type
|
|
204
|
+
type Erc721TokenBalance = {
|
|
151
205
|
/**
|
|
152
206
|
* A wallet or contract address in mixed-case checksum encoding.
|
|
153
207
|
*/
|
|
@@ -160,7 +214,7 @@ type Erc721Token = {
|
|
|
160
214
|
* The contract symbol.
|
|
161
215
|
*/
|
|
162
216
|
symbol: string;
|
|
163
|
-
ercType:
|
|
217
|
+
ercType: Erc721TokenBalance.ercType;
|
|
164
218
|
tokenId: string;
|
|
165
219
|
tokenUri: string;
|
|
166
220
|
metadata: Erc721TokenMetadata;
|
|
@@ -168,134 +222,44 @@ type Erc721Token = {
|
|
|
168
222
|
* A wallet or contract address in mixed-case checksum encoding.
|
|
169
223
|
*/
|
|
170
224
|
ownerAddress?: string;
|
|
225
|
+
/**
|
|
226
|
+
* The evm chain id.
|
|
227
|
+
*/
|
|
228
|
+
chainId: string;
|
|
171
229
|
};
|
|
172
|
-
declare namespace
|
|
230
|
+
declare namespace Erc721TokenBalance {
|
|
173
231
|
enum ercType {
|
|
174
232
|
ERC_721 = "ERC-721"
|
|
175
233
|
}
|
|
176
234
|
}
|
|
177
235
|
|
|
178
|
-
type
|
|
179
|
-
/**
|
|
180
|
-
* The block number on the chain.
|
|
181
|
-
*/
|
|
182
|
-
blockNumber: string;
|
|
183
|
-
/**
|
|
184
|
-
* The block finality timestamp.
|
|
185
|
-
*/
|
|
186
|
-
blockTimestamp: number;
|
|
187
|
-
/**
|
|
188
|
-
* The block hash identifier.
|
|
189
|
-
*/
|
|
190
|
-
blockHash: string;
|
|
191
|
-
/**
|
|
192
|
-
* The number of evm transactions in the block.
|
|
193
|
-
*/
|
|
194
|
-
txCount: number;
|
|
195
|
-
/**
|
|
196
|
-
* The number of atomic transactions in the block.
|
|
197
|
-
*/
|
|
198
|
-
atomicTxCount: number;
|
|
199
|
-
/**
|
|
200
|
-
* The base gas fee for a transaction to be included in the block.
|
|
201
|
-
*/
|
|
202
|
-
baseFee: string;
|
|
203
|
-
/**
|
|
204
|
-
* The gas used for transactions in the block.
|
|
205
|
-
*/
|
|
206
|
-
gasUsed: string;
|
|
207
|
-
/**
|
|
208
|
-
* The total gas limit set for transactions in the block.
|
|
209
|
-
*/
|
|
210
|
-
gasLimit: string;
|
|
211
|
-
gasCost: string;
|
|
212
|
-
/**
|
|
213
|
-
* The hash of the parent block.
|
|
214
|
-
*/
|
|
215
|
-
parentHash: string;
|
|
236
|
+
type ListCollectibleBalancesResponse = {
|
|
216
237
|
/**
|
|
217
|
-
*
|
|
238
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
218
239
|
*/
|
|
219
|
-
|
|
240
|
+
nextPageToken?: string;
|
|
220
241
|
/**
|
|
221
|
-
* The
|
|
242
|
+
* The list of ERC-721 and ERC-1155 token balances for the address.
|
|
222
243
|
*/
|
|
223
|
-
|
|
244
|
+
collectibleBalances: Array<(Erc721TokenBalance | Erc1155TokenBalance)>;
|
|
224
245
|
};
|
|
225
246
|
|
|
226
|
-
|
|
227
|
-
OK = "OK",
|
|
228
|
-
UNAVAILABLE = "UNAVAILABLE"
|
|
229
|
-
}
|
|
230
|
-
|
|
231
|
-
type NetworkToken = {
|
|
232
|
-
/**
|
|
233
|
-
* The contract name.
|
|
234
|
-
*/
|
|
235
|
-
name: string;
|
|
236
|
-
/**
|
|
237
|
-
* The contract symbol.
|
|
238
|
-
*/
|
|
239
|
-
symbol: string;
|
|
240
|
-
/**
|
|
241
|
-
* The number of decimals the token uses. For example `6`,
|
|
242
|
-
* means to divide the token amount by `1000000` to get its user
|
|
243
|
-
* representation.
|
|
244
|
-
*/
|
|
245
|
-
decimals: number;
|
|
247
|
+
type ListErc1155BalancesResponse = {
|
|
246
248
|
/**
|
|
247
|
-
*
|
|
249
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
248
250
|
*/
|
|
249
|
-
|
|
250
|
-
description?: string;
|
|
251
|
-
};
|
|
252
|
-
|
|
253
|
-
type UtilityAddresses = {
|
|
254
|
-
multicall?: string;
|
|
255
|
-
};
|
|
256
|
-
|
|
257
|
-
declare enum VmName {
|
|
258
|
-
EVM = "EVM",
|
|
259
|
-
BITCOIN = "BITCOIN",
|
|
260
|
-
ETHEREUM = "ETHEREUM"
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
type GetChainResponse = {
|
|
264
|
-
chainId: string;
|
|
251
|
+
nextPageToken?: string;
|
|
265
252
|
/**
|
|
266
|
-
*
|
|
267
|
-
* `UNAVAILABLE` for several reasons, such as validator stake falling
|
|
268
|
-
* below threshold. If chain nodes are `UNAVAILABLE`, requests that rely
|
|
269
|
-
* on data from the chain nodes may return 503 errors.
|
|
253
|
+
* The list of ERC-1155 token balances for the address.
|
|
270
254
|
*/
|
|
271
|
-
|
|
272
|
-
chainName: string;
|
|
273
|
-
description: string;
|
|
274
|
-
platformChainId?: string;
|
|
275
|
-
subnetId?: string;
|
|
276
|
-
vmId?: string;
|
|
277
|
-
vmName: VmName;
|
|
278
|
-
explorerUrl?: string;
|
|
279
|
-
rpcUrl: string;
|
|
280
|
-
wsUrl?: string;
|
|
281
|
-
isTestnet: boolean;
|
|
282
|
-
utilityAddresses?: UtilityAddresses;
|
|
283
|
-
networkToken: NetworkToken;
|
|
284
|
-
chainLogoUri?: string;
|
|
255
|
+
erc1155TokenBalances: Array<Erc1155TokenBalance>;
|
|
285
256
|
};
|
|
286
257
|
|
|
287
|
-
type
|
|
288
|
-
/**
|
|
289
|
-
* ISO 4217 currency code.
|
|
290
|
-
*/
|
|
291
|
-
currencyCode: CurrencyCode;
|
|
258
|
+
type Erc20TokenBalance = {
|
|
292
259
|
/**
|
|
293
|
-
*
|
|
260
|
+
* A wallet or contract address in mixed-case checksum encoding.
|
|
294
261
|
*/
|
|
295
|
-
|
|
296
|
-
};
|
|
297
|
-
|
|
298
|
-
type NativeTokenBalance = {
|
|
262
|
+
address: string;
|
|
299
263
|
/**
|
|
300
264
|
* The contract name.
|
|
301
265
|
*/
|
|
@@ -305,26 +269,24 @@ type NativeTokenBalance = {
|
|
|
305
269
|
*/
|
|
306
270
|
symbol: string;
|
|
307
271
|
/**
|
|
308
|
-
* The number of decimals the token uses. For example `6`,
|
|
309
|
-
* means to divide the token amount by `1000000` to get its user
|
|
310
|
-
* representation.
|
|
272
|
+
* The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
|
|
311
273
|
*/
|
|
312
274
|
decimals: number;
|
|
313
275
|
/**
|
|
314
276
|
* The logo uri for the address.
|
|
315
277
|
*/
|
|
316
278
|
logoUri?: string;
|
|
317
|
-
|
|
318
|
-
* The evm chain id.
|
|
319
|
-
*/
|
|
320
|
-
chainId: string;
|
|
279
|
+
ercType: Erc20TokenBalance.ercType;
|
|
321
280
|
/**
|
|
322
281
|
* The token price, if available.
|
|
323
282
|
*/
|
|
324
283
|
price?: Money;
|
|
325
284
|
/**
|
|
326
|
-
* The
|
|
327
|
-
|
|
285
|
+
* The evm chain id.
|
|
286
|
+
*/
|
|
287
|
+
chainId: string;
|
|
288
|
+
/**
|
|
289
|
+
* The address balance for the token, in units specified by the `decimals` value for the contract.
|
|
328
290
|
*/
|
|
329
291
|
balance: string;
|
|
330
292
|
/**
|
|
@@ -332,122 +294,202 @@ type NativeTokenBalance = {
|
|
|
332
294
|
*/
|
|
333
295
|
balanceValue?: Money;
|
|
334
296
|
};
|
|
297
|
+
declare namespace Erc20TokenBalance {
|
|
298
|
+
enum ercType {
|
|
299
|
+
ERC_20 = "ERC-20"
|
|
300
|
+
}
|
|
301
|
+
}
|
|
335
302
|
|
|
336
|
-
type
|
|
337
|
-
/**
|
|
338
|
-
* The native token balance for the address.
|
|
339
|
-
*/
|
|
340
|
-
nativeTokenBalance: NativeTokenBalance;
|
|
341
|
-
};
|
|
342
|
-
|
|
343
|
-
type RichAddress = {
|
|
344
|
-
/**
|
|
345
|
-
* The contract name.
|
|
346
|
-
*/
|
|
347
|
-
name?: string;
|
|
348
|
-
/**
|
|
349
|
-
* The contract symbol.
|
|
350
|
-
*/
|
|
351
|
-
symbol?: string;
|
|
352
|
-
/**
|
|
353
|
-
* The number of decimals the token uses. For example `6`,
|
|
354
|
-
* means to divide the token amount by `1000000` to get its user
|
|
355
|
-
* representation.
|
|
356
|
-
*/
|
|
357
|
-
decimals?: number;
|
|
303
|
+
type ListErc20BalancesResponse = {
|
|
358
304
|
/**
|
|
359
|
-
*
|
|
305
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
360
306
|
*/
|
|
361
|
-
|
|
307
|
+
nextPageToken?: string;
|
|
362
308
|
/**
|
|
363
|
-
*
|
|
309
|
+
* The list of ERC-20 token balances for the address.
|
|
364
310
|
*/
|
|
365
|
-
|
|
366
|
-
};
|
|
367
|
-
|
|
368
|
-
type Erc1155TransferDetails = {
|
|
369
|
-
from: RichAddress;
|
|
370
|
-
to: RichAddress;
|
|
371
|
-
value: string;
|
|
372
|
-
erc1155Token: Erc1155Token;
|
|
311
|
+
erc20TokenBalances: Array<Erc20TokenBalance>;
|
|
373
312
|
};
|
|
374
313
|
|
|
375
|
-
type
|
|
376
|
-
/**
|
|
377
|
-
* A wallet or contract address in mixed-case checksum encoding.
|
|
378
|
-
*/
|
|
379
|
-
address: string;
|
|
314
|
+
type ListErc721BalancesResponse = {
|
|
380
315
|
/**
|
|
381
|
-
*
|
|
316
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
382
317
|
*/
|
|
383
|
-
|
|
318
|
+
nextPageToken?: string;
|
|
384
319
|
/**
|
|
385
|
-
* The
|
|
320
|
+
* The list of ERC-721 token balances for the address.
|
|
386
321
|
*/
|
|
387
|
-
|
|
322
|
+
erc721TokenBalances: Array<Erc721TokenBalance>;
|
|
323
|
+
};
|
|
324
|
+
|
|
325
|
+
declare class EvmBalancesService {
|
|
326
|
+
readonly httpRequest: BaseHttpRequest;
|
|
327
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
388
328
|
/**
|
|
389
|
-
*
|
|
390
|
-
*
|
|
391
|
-
*
|
|
329
|
+
* Get native token balance
|
|
330
|
+
* Gets native token balance of a wallet address.
|
|
331
|
+
*
|
|
332
|
+
* Balance at a given block can be retrieved with the `blockNumber` parameter.
|
|
333
|
+
* @returns GetNativeBalanceResponse
|
|
334
|
+
* @throws ApiError
|
|
392
335
|
*/
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
336
|
+
getNativeBalance({ chainId, address, blockNumber, currency, }: {
|
|
337
|
+
/**
|
|
338
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
339
|
+
*/
|
|
340
|
+
chainId: string;
|
|
341
|
+
/**
|
|
342
|
+
* A wallet address.
|
|
343
|
+
*/
|
|
344
|
+
address: string;
|
|
345
|
+
/**
|
|
346
|
+
* The block number, if not defined the block number will be the latest block.
|
|
347
|
+
*/
|
|
348
|
+
blockNumber?: string;
|
|
349
|
+
/**
|
|
350
|
+
* The currency that return values should use. Defaults to USD.
|
|
351
|
+
*/
|
|
352
|
+
currency?: CurrencyCode;
|
|
353
|
+
}): CancelablePromise<GetNativeBalanceResponse>;
|
|
399
354
|
/**
|
|
400
|
-
*
|
|
355
|
+
* List ERC-20 balances
|
|
356
|
+
* Lists ERC-20 token balances of a wallet address.
|
|
357
|
+
*
|
|
358
|
+
* Balance at a given block can be retrieved with the `blockNumber` parameter.
|
|
359
|
+
*
|
|
360
|
+
* Balance for specific contracts can be retrieved with the `contractAddresses` parameter.
|
|
361
|
+
* @returns ListErc20BalancesResponse
|
|
362
|
+
* @throws ApiError
|
|
401
363
|
*/
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
364
|
+
listErc20Balances({ chainId, address, blockNumber, pageSize, pageToken, contractAddresses, currency, }: {
|
|
365
|
+
/**
|
|
366
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
367
|
+
*/
|
|
368
|
+
chainId: string;
|
|
369
|
+
/**
|
|
370
|
+
* A wallet address.
|
|
371
|
+
*/
|
|
372
|
+
address: string;
|
|
373
|
+
/**
|
|
374
|
+
* The block number, if not defined the block number will be the latest block.
|
|
375
|
+
*/
|
|
376
|
+
blockNumber?: string;
|
|
377
|
+
/**
|
|
378
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
379
|
+
*/
|
|
380
|
+
pageSize?: number;
|
|
381
|
+
/**
|
|
382
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
383
|
+
*/
|
|
384
|
+
pageToken?: string;
|
|
385
|
+
/**
|
|
386
|
+
* A comma separated list of contract addresses to filter by.
|
|
387
|
+
*/
|
|
388
|
+
contractAddresses?: string;
|
|
389
|
+
/**
|
|
390
|
+
* The currency that return values should use. Defaults to USD.
|
|
391
|
+
*/
|
|
392
|
+
currency?: CurrencyCode;
|
|
393
|
+
}): CancelablePromise<ListErc20BalancesResponse>;
|
|
430
394
|
/**
|
|
431
|
-
*
|
|
432
|
-
*
|
|
433
|
-
*
|
|
434
|
-
*
|
|
435
|
-
*
|
|
436
|
-
*
|
|
437
|
-
* creation.
|
|
395
|
+
* List ERC-721 balances
|
|
396
|
+
* Lists ERC-721 token balances of a wallet address.
|
|
397
|
+
*
|
|
398
|
+
* Balance for a specific contract can be retrieved with the `contractAddress` parameter.
|
|
399
|
+
* @returns ListErc721BalancesResponse
|
|
400
|
+
* @throws ApiError
|
|
438
401
|
*/
|
|
439
|
-
|
|
402
|
+
listErc721Balances({ chainId, address, pageSize, pageToken, contractAddress, }: {
|
|
403
|
+
/**
|
|
404
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
405
|
+
*/
|
|
406
|
+
chainId: string;
|
|
407
|
+
/**
|
|
408
|
+
* A wallet address.
|
|
409
|
+
*/
|
|
410
|
+
address: string;
|
|
411
|
+
/**
|
|
412
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
413
|
+
*/
|
|
414
|
+
pageSize?: number;
|
|
415
|
+
/**
|
|
416
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
417
|
+
*/
|
|
418
|
+
pageToken?: string;
|
|
419
|
+
/**
|
|
420
|
+
* A contract addresses to filter by.
|
|
421
|
+
*/
|
|
422
|
+
contractAddress?: string;
|
|
423
|
+
}): CancelablePromise<ListErc721BalancesResponse>;
|
|
440
424
|
/**
|
|
441
|
-
*
|
|
425
|
+
* List ERC-1155 balances
|
|
426
|
+
* Lists ERC-1155 token balances of a wallet address.
|
|
427
|
+
*
|
|
428
|
+
* Balance at a given block can be retrieved with the `blockNumber` parameter.
|
|
429
|
+
*
|
|
430
|
+
* Balance for a specific contract can be retrieved with the `contractAddress` parameter.
|
|
431
|
+
* @returns ListErc1155BalancesResponse
|
|
432
|
+
* @throws ApiError
|
|
442
433
|
*/
|
|
443
|
-
|
|
434
|
+
listErc1155Balances({ chainId, address, blockNumber, pageSize, pageToken, contractAddress, }: {
|
|
435
|
+
/**
|
|
436
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
437
|
+
*/
|
|
438
|
+
chainId: string;
|
|
439
|
+
/**
|
|
440
|
+
* A wallet address.
|
|
441
|
+
*/
|
|
442
|
+
address: string;
|
|
443
|
+
/**
|
|
444
|
+
* The block number, if not defined the block number will be the latest block.
|
|
445
|
+
*/
|
|
446
|
+
blockNumber?: string;
|
|
447
|
+
/**
|
|
448
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
449
|
+
*/
|
|
450
|
+
pageSize?: number;
|
|
451
|
+
/**
|
|
452
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
453
|
+
*/
|
|
454
|
+
pageToken?: string;
|
|
455
|
+
/**
|
|
456
|
+
* A contract addresses to filter by.
|
|
457
|
+
*/
|
|
458
|
+
contractAddress?: string;
|
|
459
|
+
}): CancelablePromise<ListErc1155BalancesResponse>;
|
|
444
460
|
/**
|
|
445
|
-
*
|
|
461
|
+
* List collectible (ERC-721/ERC-1155) balances
|
|
462
|
+
* Lists ERC-721 and ERC-1155 token balances of a wallet address.
|
|
463
|
+
*
|
|
464
|
+
* Balance for a specific contract can be retrieved with the `contractAddress` parameter.
|
|
465
|
+
* @returns ListCollectibleBalancesResponse
|
|
466
|
+
* @throws ApiError
|
|
446
467
|
*/
|
|
447
|
-
|
|
448
|
-
|
|
468
|
+
listCollectibleBalances({ chainId, address, pageSize, pageToken, contractAddress, }: {
|
|
469
|
+
/**
|
|
470
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
471
|
+
*/
|
|
472
|
+
chainId: string;
|
|
473
|
+
/**
|
|
474
|
+
* A wallet address.
|
|
475
|
+
*/
|
|
476
|
+
address: string;
|
|
477
|
+
/**
|
|
478
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
479
|
+
*/
|
|
480
|
+
pageSize?: number;
|
|
481
|
+
/**
|
|
482
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
483
|
+
*/
|
|
484
|
+
pageToken?: string;
|
|
485
|
+
/**
|
|
486
|
+
* A contract addresses to filter by.
|
|
487
|
+
*/
|
|
488
|
+
contractAddress?: string;
|
|
489
|
+
}): CancelablePromise<ListCollectibleBalancesResponse>;
|
|
490
|
+
}
|
|
449
491
|
|
|
450
|
-
type
|
|
492
|
+
type GetEvmBlockResponse = {
|
|
451
493
|
/**
|
|
452
494
|
* The block number on the chain.
|
|
453
495
|
*/
|
|
@@ -461,149 +503,189 @@ type FullNativeTransactionDetails = {
|
|
|
461
503
|
*/
|
|
462
504
|
blockHash: string;
|
|
463
505
|
/**
|
|
464
|
-
* The
|
|
506
|
+
* The number of evm transactions in the block.
|
|
465
507
|
*/
|
|
466
|
-
|
|
508
|
+
txCount: number;
|
|
467
509
|
/**
|
|
468
|
-
* The transaction
|
|
510
|
+
* The base gas fee for a transaction to be included in the block.
|
|
469
511
|
*/
|
|
470
|
-
|
|
512
|
+
baseFee: string;
|
|
471
513
|
/**
|
|
472
|
-
* The
|
|
514
|
+
* The gas used for transactions in the block.
|
|
473
515
|
*/
|
|
474
|
-
|
|
516
|
+
gasUsed: string;
|
|
475
517
|
/**
|
|
476
|
-
* The
|
|
518
|
+
* The total gas limit set for transactions in the block.
|
|
477
519
|
*/
|
|
478
|
-
|
|
520
|
+
gasLimit: string;
|
|
521
|
+
gasCost: string;
|
|
479
522
|
/**
|
|
480
|
-
* The
|
|
523
|
+
* The hash of the parent block.
|
|
481
524
|
*/
|
|
482
|
-
|
|
525
|
+
parentHash: string;
|
|
483
526
|
/**
|
|
484
|
-
* The amount of
|
|
527
|
+
* The amount of fees spent/burned for transactions in the block.
|
|
485
528
|
*/
|
|
486
|
-
|
|
529
|
+
feesSpent: string;
|
|
487
530
|
/**
|
|
488
|
-
* The
|
|
531
|
+
* The cumulative number of transactions for the chain including this block.
|
|
489
532
|
*/
|
|
490
|
-
|
|
533
|
+
cumulativeTransactions: string;
|
|
534
|
+
};
|
|
535
|
+
|
|
536
|
+
type EvmBlock = {
|
|
491
537
|
/**
|
|
492
|
-
* The
|
|
538
|
+
* The block number on the chain.
|
|
493
539
|
*/
|
|
494
|
-
|
|
495
|
-
from: RichAddress;
|
|
496
|
-
to: RichAddress;
|
|
497
|
-
method?: Method;
|
|
498
|
-
value: string;
|
|
540
|
+
blockNumber: string;
|
|
499
541
|
/**
|
|
500
|
-
* The
|
|
542
|
+
* The block finality timestamp.
|
|
501
543
|
*/
|
|
502
|
-
|
|
503
|
-
baseFeePerGas: string;
|
|
504
|
-
maxFeePerGas?: string;
|
|
505
|
-
maxPriorityFeePerGas?: string;
|
|
506
|
-
};
|
|
507
|
-
|
|
508
|
-
declare enum InternalTransactionOpCall {
|
|
509
|
-
UNKNOWN = "UNKNOWN",
|
|
510
|
-
CALL = "CALL",
|
|
511
|
-
CREATE = "CREATE",
|
|
512
|
-
CREATE2 = "CREATE2",
|
|
513
|
-
CALLCODE = "CALLCODE",
|
|
514
|
-
DELEGATECALL = "DELEGATECALL",
|
|
515
|
-
STATICCALL = "STATICCALL"
|
|
516
|
-
}
|
|
517
|
-
|
|
518
|
-
type InternalTransactionDetails = {
|
|
519
|
-
from: RichAddress;
|
|
520
|
-
to: RichAddress;
|
|
521
|
-
internalTxType: InternalTransactionOpCall;
|
|
522
|
-
value: string;
|
|
544
|
+
blockTimestamp: number;
|
|
523
545
|
/**
|
|
524
|
-
*
|
|
546
|
+
* The block hash identifier.
|
|
525
547
|
*/
|
|
526
|
-
|
|
527
|
-
gasUsed: string;
|
|
528
|
-
gasLimit: string;
|
|
529
|
-
};
|
|
530
|
-
|
|
531
|
-
type NetworkTokenDetails = {
|
|
532
|
-
networkToken: NetworkToken;
|
|
548
|
+
blockHash: string;
|
|
533
549
|
/**
|
|
534
|
-
* The
|
|
550
|
+
* The number of evm transactions in the block.
|
|
535
551
|
*/
|
|
536
|
-
|
|
552
|
+
txCount: number;
|
|
537
553
|
/**
|
|
538
|
-
* The
|
|
539
|
-
* occured, if available. Note, this is only provided if the transaction
|
|
540
|
-
* occured more than 24 hours ago.
|
|
554
|
+
* The base gas fee for a transaction to be included in the block.
|
|
541
555
|
*/
|
|
542
|
-
|
|
543
|
-
};
|
|
544
|
-
|
|
545
|
-
type GetTransactionResponse = {
|
|
556
|
+
baseFee: string;
|
|
546
557
|
/**
|
|
547
|
-
* The
|
|
558
|
+
* The gas used for transactions in the block.
|
|
548
559
|
*/
|
|
549
|
-
|
|
560
|
+
gasUsed: string;
|
|
550
561
|
/**
|
|
551
|
-
* The
|
|
562
|
+
* The total gas limit set for transactions in the block.
|
|
552
563
|
*/
|
|
553
|
-
|
|
564
|
+
gasLimit: string;
|
|
565
|
+
gasCost: string;
|
|
554
566
|
/**
|
|
555
|
-
* The
|
|
567
|
+
* The hash of the parent block.
|
|
556
568
|
*/
|
|
557
|
-
|
|
569
|
+
parentHash: string;
|
|
558
570
|
/**
|
|
559
|
-
* The
|
|
560
|
-
* includes CALL and
|
|
561
|
-
* CALLCODE internal transactions that had a
|
|
562
|
-
* non-zero value and
|
|
563
|
-
* CREATE/CREATE2
|
|
564
|
-
* calls. Use a client provider to recieve a full debug trace of the
|
|
565
|
-
* transaction.
|
|
571
|
+
* The amount of fees spent/burned for transactions in the block.
|
|
566
572
|
*/
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
573
|
+
feesSpent: string;
|
|
574
|
+
/**
|
|
575
|
+
* The cumulative number of transactions for the chain including this block.
|
|
576
|
+
*/
|
|
577
|
+
cumulativeTransactions: string;
|
|
570
578
|
};
|
|
571
579
|
|
|
572
|
-
type
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
580
|
+
type ListEvmBlocksResponse = {
|
|
581
|
+
/**
|
|
582
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
583
|
+
*/
|
|
584
|
+
nextPageToken?: string;
|
|
585
|
+
blocks: Array<EvmBlock>;
|
|
578
586
|
};
|
|
579
587
|
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
588
|
+
declare class EvmBlocksService {
|
|
589
|
+
readonly httpRequest: BaseHttpRequest;
|
|
590
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
591
|
+
/**
|
|
592
|
+
* List latest blocks
|
|
593
|
+
* Lists the latest indexed blocks on the EVM-compatible chain sorted in descending order by block timestamp.
|
|
594
|
+
* @returns ListEvmBlocksResponse
|
|
595
|
+
* @throws ApiError
|
|
596
|
+
*/
|
|
597
|
+
getLatestBlocks({ chainId, pageSize, pageToken, }: {
|
|
598
|
+
/**
|
|
599
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
600
|
+
*/
|
|
601
|
+
chainId: string;
|
|
602
|
+
/**
|
|
603
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
604
|
+
*/
|
|
605
|
+
pageSize?: number;
|
|
606
|
+
/**
|
|
607
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
608
|
+
*/
|
|
609
|
+
pageToken?: string;
|
|
610
|
+
}): CancelablePromise<ListEvmBlocksResponse>;
|
|
611
|
+
/**
|
|
612
|
+
* Get block
|
|
613
|
+
* Gets the details of an individual block on the EVM-compatible chain.
|
|
614
|
+
* @returns GetEvmBlockResponse
|
|
615
|
+
* @throws ApiError
|
|
616
|
+
*/
|
|
617
|
+
getBlock({ chainId, blockId, }: {
|
|
618
|
+
/**
|
|
619
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
620
|
+
*/
|
|
621
|
+
chainId: string;
|
|
622
|
+
/**
|
|
623
|
+
* A block identifier which is either a block number or the block hash.
|
|
624
|
+
*/
|
|
625
|
+
blockId: string;
|
|
626
|
+
}): CancelablePromise<GetEvmBlockResponse>;
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
declare enum ChainStatus {
|
|
630
|
+
OK = "OK",
|
|
631
|
+
UNAVAILABLE = "UNAVAILABLE"
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
type NetworkToken = {
|
|
635
|
+
/**
|
|
636
|
+
* The contract name.
|
|
637
|
+
*/
|
|
638
|
+
name: string;
|
|
639
|
+
/**
|
|
640
|
+
* The contract symbol.
|
|
641
|
+
*/
|
|
642
|
+
symbol: string;
|
|
643
|
+
/**
|
|
644
|
+
* The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
|
|
645
|
+
*/
|
|
646
|
+
decimals: number;
|
|
647
|
+
/**
|
|
648
|
+
* The logo uri for the address.
|
|
649
|
+
*/
|
|
650
|
+
logoUri?: string;
|
|
651
|
+
description?: string;
|
|
652
|
+
};
|
|
653
|
+
|
|
654
|
+
type UtilityAddresses = {
|
|
655
|
+
multicall?: string;
|
|
590
656
|
};
|
|
591
657
|
|
|
592
|
-
|
|
658
|
+
declare enum VmName {
|
|
659
|
+
EVM = "EVM",
|
|
660
|
+
BITCOIN = "BITCOIN",
|
|
661
|
+
ETHEREUM = "ETHEREUM"
|
|
662
|
+
}
|
|
663
|
+
|
|
664
|
+
type GetChainResponse = {
|
|
665
|
+
chainId: string;
|
|
593
666
|
/**
|
|
594
|
-
*
|
|
667
|
+
* Status of chain nodes. Chain nodes can become temporarily `UNAVAILABLE` for several reasons, such as validator stake falling below threshold. If chain nodes are `UNAVAILABLE`, requests that rely on data from the chain nodes may return 503 errors.
|
|
595
668
|
*/
|
|
596
|
-
|
|
597
|
-
|
|
669
|
+
status: ChainStatus;
|
|
670
|
+
chainName: string;
|
|
671
|
+
description: string;
|
|
672
|
+
platformChainId?: string;
|
|
673
|
+
subnetId?: string;
|
|
674
|
+
vmId?: string;
|
|
675
|
+
vmName: VmName;
|
|
676
|
+
explorerUrl?: string;
|
|
677
|
+
rpcUrl: string;
|
|
678
|
+
wsUrl?: string;
|
|
679
|
+
isTestnet: boolean;
|
|
680
|
+
utilityAddresses?: UtilityAddresses;
|
|
681
|
+
networkToken: NetworkToken;
|
|
682
|
+
chainLogoUri?: string;
|
|
598
683
|
};
|
|
599
684
|
|
|
600
685
|
type ChainInfo = {
|
|
601
686
|
chainId: string;
|
|
602
687
|
/**
|
|
603
|
-
* Status of chain nodes. Chain nodes can become temporarily
|
|
604
|
-
* `UNAVAILABLE` for several reasons, such as validator stake falling
|
|
605
|
-
* below threshold. If chain nodes are `UNAVAILABLE`, requests that rely
|
|
606
|
-
* on data from the chain nodes may return 503 errors.
|
|
688
|
+
* Status of chain nodes. Chain nodes can become temporarily `UNAVAILABLE` for several reasons, such as validator stake falling below threshold. If chain nodes are `UNAVAILABLE`, requests that rely on data from the chain nodes may return 503 errors.
|
|
607
689
|
*/
|
|
608
690
|
status: ChainStatus;
|
|
609
691
|
chainName: string;
|
|
@@ -625,118 +707,88 @@ type ListChainsResponse = {
|
|
|
625
707
|
chains: Array<ChainInfo>;
|
|
626
708
|
};
|
|
627
709
|
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
metadata: Erc1155TokenMetadata;
|
|
710
|
+
declare enum NetworkType {
|
|
711
|
+
MAINNET = "mainnet",
|
|
712
|
+
TESTNET = "testnet"
|
|
713
|
+
}
|
|
714
|
+
|
|
715
|
+
declare class EvmChainsService {
|
|
716
|
+
readonly httpRequest: BaseHttpRequest;
|
|
717
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
637
718
|
/**
|
|
638
|
-
*
|
|
719
|
+
* List chains
|
|
720
|
+
* Lists the supported EVM-compatible chains. Filterable by network.
|
|
721
|
+
* @returns ListChainsResponse
|
|
722
|
+
* @throws ApiError
|
|
639
723
|
*/
|
|
640
|
-
|
|
724
|
+
supportedChains({ network, }: {
|
|
725
|
+
/**
|
|
726
|
+
* mainnet or testnet.
|
|
727
|
+
*/
|
|
728
|
+
network?: NetworkType;
|
|
729
|
+
}): CancelablePromise<ListChainsResponse>;
|
|
641
730
|
/**
|
|
642
|
-
*
|
|
643
|
-
*
|
|
731
|
+
* Get chain information
|
|
732
|
+
* Gets chain information for the EVM-compatible chain if supported by the api.
|
|
733
|
+
* @returns GetChainResponse
|
|
734
|
+
* @throws ApiError
|
|
644
735
|
*/
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
}
|
|
736
|
+
getChainInfo({ chainId, }: {
|
|
737
|
+
/**
|
|
738
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
739
|
+
*/
|
|
740
|
+
chainId: string;
|
|
741
|
+
}): CancelablePromise<GetChainResponse>;
|
|
651
742
|
}
|
|
652
743
|
|
|
653
|
-
type
|
|
744
|
+
type Erc1155Token = {
|
|
654
745
|
/**
|
|
655
746
|
* A wallet or contract address in mixed-case checksum encoding.
|
|
656
747
|
*/
|
|
657
748
|
address: string;
|
|
658
|
-
|
|
659
|
-
* The contract name.
|
|
660
|
-
*/
|
|
661
|
-
name: string;
|
|
662
|
-
/**
|
|
663
|
-
* The contract symbol.
|
|
664
|
-
*/
|
|
665
|
-
symbol: string;
|
|
666
|
-
ercType: Erc721TokenBalance.ercType;
|
|
749
|
+
ercType: Erc1155Token.ercType;
|
|
667
750
|
tokenId: string;
|
|
668
751
|
tokenUri: string;
|
|
669
|
-
metadata:
|
|
670
|
-
/**
|
|
671
|
-
* A wallet or contract address in mixed-case checksum encoding.
|
|
672
|
-
*/
|
|
673
|
-
ownerAddress?: string;
|
|
674
|
-
/**
|
|
675
|
-
* The evm chain id.
|
|
676
|
-
*/
|
|
677
|
-
chainId: string;
|
|
752
|
+
metadata: Erc1155TokenMetadata;
|
|
678
753
|
};
|
|
679
|
-
declare namespace
|
|
754
|
+
declare namespace Erc1155Token {
|
|
680
755
|
enum ercType {
|
|
681
|
-
|
|
756
|
+
ERC_1155 = "ERC-1155"
|
|
682
757
|
}
|
|
683
758
|
}
|
|
684
759
|
|
|
685
|
-
type
|
|
686
|
-
/**
|
|
687
|
-
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
688
|
-
*/
|
|
689
|
-
nextPageToken?: string;
|
|
690
|
-
/**
|
|
691
|
-
* The list of ERC-721 and ERC-1155 token balances for the
|
|
692
|
-
* address.
|
|
693
|
-
*/
|
|
694
|
-
collectibleBalances: Array<(Erc721TokenBalance | Erc1155TokenBalance)>;
|
|
695
|
-
};
|
|
696
|
-
|
|
697
|
-
type ListErc1155BalancesResponse = {
|
|
698
|
-
/**
|
|
699
|
-
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
700
|
-
*/
|
|
701
|
-
nextPageToken?: string;
|
|
760
|
+
type RichAddress = {
|
|
702
761
|
/**
|
|
703
|
-
* The
|
|
762
|
+
* The contract name.
|
|
704
763
|
*/
|
|
705
|
-
|
|
706
|
-
};
|
|
707
|
-
|
|
708
|
-
type Erc1155Transfer = {
|
|
764
|
+
name?: string;
|
|
709
765
|
/**
|
|
710
|
-
* The
|
|
766
|
+
* The contract symbol.
|
|
711
767
|
*/
|
|
712
|
-
|
|
768
|
+
symbol?: string;
|
|
713
769
|
/**
|
|
714
|
-
* The
|
|
770
|
+
* The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
|
|
715
771
|
*/
|
|
716
|
-
|
|
772
|
+
decimals?: number;
|
|
717
773
|
/**
|
|
718
|
-
* The
|
|
774
|
+
* The logo uri for the address.
|
|
719
775
|
*/
|
|
720
|
-
|
|
776
|
+
logoUri?: string;
|
|
721
777
|
/**
|
|
722
|
-
*
|
|
778
|
+
* A wallet or contract address in mixed-case checksum encoding.
|
|
723
779
|
*/
|
|
724
|
-
|
|
780
|
+
address: string;
|
|
781
|
+
};
|
|
782
|
+
|
|
783
|
+
type Erc1155TransferDetails = {
|
|
725
784
|
from: RichAddress;
|
|
726
785
|
to: RichAddress;
|
|
786
|
+
logIndex: number;
|
|
727
787
|
value: string;
|
|
728
788
|
erc1155Token: Erc1155Token;
|
|
729
789
|
};
|
|
730
790
|
|
|
731
|
-
type
|
|
732
|
-
/**
|
|
733
|
-
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
734
|
-
*/
|
|
735
|
-
nextPageToken?: string;
|
|
736
|
-
transactions: Array<Erc1155Transfer>;
|
|
737
|
-
};
|
|
738
|
-
|
|
739
|
-
type Erc20TokenBalance = {
|
|
791
|
+
type Erc20Token = {
|
|
740
792
|
/**
|
|
741
793
|
* A wallet or contract address in mixed-case checksum encoding.
|
|
742
794
|
*/
|
|
@@ -750,94 +802,90 @@ type Erc20TokenBalance = {
|
|
|
750
802
|
*/
|
|
751
803
|
symbol: string;
|
|
752
804
|
/**
|
|
753
|
-
* The number of decimals the token uses. For example `6`,
|
|
754
|
-
* means to divide the token amount by `1000000` to get its user
|
|
755
|
-
* representation.
|
|
805
|
+
* The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
|
|
756
806
|
*/
|
|
757
807
|
decimals: number;
|
|
758
808
|
/**
|
|
759
809
|
* The logo uri for the address.
|
|
760
810
|
*/
|
|
761
811
|
logoUri?: string;
|
|
762
|
-
ercType:
|
|
812
|
+
ercType: Erc20Token.ercType;
|
|
763
813
|
/**
|
|
764
814
|
* The token price, if available.
|
|
765
815
|
*/
|
|
766
816
|
price?: Money;
|
|
767
|
-
/**
|
|
768
|
-
* The evm chain id.
|
|
769
|
-
*/
|
|
770
|
-
chainId: string;
|
|
771
|
-
/**
|
|
772
|
-
* The address balance for the token, in units specified by the
|
|
773
|
-
* `decimals` value for the contract.
|
|
774
|
-
*/
|
|
775
|
-
balance: string;
|
|
776
|
-
/**
|
|
777
|
-
* The monetary value of the balance, if a price is available for the token.
|
|
778
|
-
*/
|
|
779
|
-
balanceValue?: Money;
|
|
780
817
|
};
|
|
781
|
-
declare namespace
|
|
818
|
+
declare namespace Erc20Token {
|
|
782
819
|
enum ercType {
|
|
783
820
|
ERC_20 = "ERC-20"
|
|
784
821
|
}
|
|
785
822
|
}
|
|
786
823
|
|
|
787
|
-
type
|
|
788
|
-
/**
|
|
789
|
-
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
790
|
-
*/
|
|
791
|
-
nextPageToken?: string;
|
|
792
|
-
/**
|
|
793
|
-
* The list of ERC-20 token balances for the address.
|
|
794
|
-
*/
|
|
795
|
-
erc20TokenBalances: Array<Erc20TokenBalance>;
|
|
796
|
-
};
|
|
797
|
-
|
|
798
|
-
type Erc20Transfer = {
|
|
799
|
-
/**
|
|
800
|
-
* The block number on the chain.
|
|
801
|
-
*/
|
|
802
|
-
blockNumber: string;
|
|
803
|
-
/**
|
|
804
|
-
* The block finality timestamp.
|
|
805
|
-
*/
|
|
806
|
-
blockTimestamp: number;
|
|
807
|
-
/**
|
|
808
|
-
* The block hash identifier.
|
|
809
|
-
*/
|
|
810
|
-
blockHash: string;
|
|
811
|
-
/**
|
|
812
|
-
* The transaction hash identifier.
|
|
813
|
-
*/
|
|
814
|
-
txHash: string;
|
|
824
|
+
type Erc20TransferDetails = {
|
|
815
825
|
from: RichAddress;
|
|
816
826
|
to: RichAddress;
|
|
827
|
+
logIndex: number;
|
|
817
828
|
value: string;
|
|
818
829
|
erc20Token: Erc20Token;
|
|
819
830
|
};
|
|
820
831
|
|
|
821
|
-
type
|
|
832
|
+
type Erc721Token = {
|
|
822
833
|
/**
|
|
823
|
-
* A
|
|
834
|
+
* A wallet or contract address in mixed-case checksum encoding.
|
|
824
835
|
*/
|
|
825
|
-
|
|
826
|
-
transactions: Array<Erc20Transfer>;
|
|
827
|
-
};
|
|
828
|
-
|
|
829
|
-
type ListErc721BalancesResponse = {
|
|
836
|
+
address: string;
|
|
830
837
|
/**
|
|
831
|
-
*
|
|
838
|
+
* The contract name.
|
|
832
839
|
*/
|
|
833
|
-
|
|
840
|
+
name: string;
|
|
834
841
|
/**
|
|
835
|
-
* The
|
|
842
|
+
* The contract symbol.
|
|
836
843
|
*/
|
|
837
|
-
|
|
844
|
+
symbol: string;
|
|
845
|
+
ercType: Erc721Token.ercType;
|
|
846
|
+
tokenId: string;
|
|
847
|
+
tokenUri: string;
|
|
848
|
+
metadata: Erc721TokenMetadata;
|
|
849
|
+
/**
|
|
850
|
+
* A wallet or contract address in mixed-case checksum encoding.
|
|
851
|
+
*/
|
|
852
|
+
ownerAddress?: string;
|
|
838
853
|
};
|
|
854
|
+
declare namespace Erc721Token {
|
|
855
|
+
enum ercType {
|
|
856
|
+
ERC_721 = "ERC-721"
|
|
857
|
+
}
|
|
858
|
+
}
|
|
839
859
|
|
|
840
|
-
type
|
|
860
|
+
type Erc721TransferDetails = {
|
|
861
|
+
from: RichAddress;
|
|
862
|
+
to: RichAddress;
|
|
863
|
+
logIndex: number;
|
|
864
|
+
erc721Token: Erc721Token;
|
|
865
|
+
};
|
|
866
|
+
|
|
867
|
+
declare enum TransactionMethodType {
|
|
868
|
+
NATIVE_TRANSFER = "NATIVE_TRANSFER",
|
|
869
|
+
CONTRACT_CALL = "CONTRACT_CALL",
|
|
870
|
+
CONTRACT_CREATION = "CONTRACT_CREATION"
|
|
871
|
+
}
|
|
872
|
+
|
|
873
|
+
type Method = {
|
|
874
|
+
/**
|
|
875
|
+
* The contract call type. NATIVE_TRANSFER indicates a transfer of the native token without any smart-contract interaction. CONTRACT_CALL indicates a smart-contract interaction. CONTRACT_CREATION indicates a smart-contract creation.
|
|
876
|
+
*/
|
|
877
|
+
callType: TransactionMethodType;
|
|
878
|
+
/**
|
|
879
|
+
* The contract method hash identifier. The method hash is only set if the `callType` is `CONTRACT_CALL`.
|
|
880
|
+
*/
|
|
881
|
+
methodHash: string;
|
|
882
|
+
/**
|
|
883
|
+
* The contract method name including parameter types. If the `callType` is `NATIVE_TRANSFER` this is set to 'Native Transfer'. If the `callType` is `CONTRACT_CREATION` this is set to 'Contract Created'.
|
|
884
|
+
*/
|
|
885
|
+
methodName?: string;
|
|
886
|
+
};
|
|
887
|
+
|
|
888
|
+
type FullNativeTransactionDetails = {
|
|
841
889
|
/**
|
|
842
890
|
* The block number on the chain.
|
|
843
891
|
*/
|
|
@@ -850,51 +898,62 @@ type Erc721Transfer = {
|
|
|
850
898
|
* The block hash identifier.
|
|
851
899
|
*/
|
|
852
900
|
blockHash: string;
|
|
901
|
+
/**
|
|
902
|
+
* The index at which the transaction occured in the block (0-indexed).
|
|
903
|
+
*/
|
|
904
|
+
blockIndex: number;
|
|
853
905
|
/**
|
|
854
906
|
* The transaction hash identifier.
|
|
855
907
|
*/
|
|
856
908
|
txHash: string;
|
|
857
|
-
from: RichAddress;
|
|
858
|
-
to: RichAddress;
|
|
859
|
-
erc721Token: Erc721Token;
|
|
860
|
-
};
|
|
861
|
-
|
|
862
|
-
type ListErc721TransactionsResponse = {
|
|
863
909
|
/**
|
|
864
|
-
*
|
|
910
|
+
* The transaction status, which is either 0 (failed) or 1 (successful).
|
|
865
911
|
*/
|
|
866
|
-
|
|
867
|
-
transactions: Array<Erc721Transfer>;
|
|
868
|
-
};
|
|
869
|
-
|
|
870
|
-
declare enum ListingEventType {
|
|
871
|
-
OPEN_LISTING = "OPEN_LISTING",
|
|
872
|
-
CANCEL_LISTING = "CANCEL_LISTING",
|
|
873
|
-
PURCHASE_LISTING = "PURCHASE_LISTING",
|
|
874
|
-
CLOSE_AUCTION = "CLOSE_AUCTION"
|
|
875
|
-
}
|
|
876
|
-
|
|
877
|
-
declare enum ListingsSortByOption {
|
|
878
|
-
LAST_EVENT_TIMESTAMP = "lastEventTimestamp"
|
|
879
|
-
}
|
|
880
|
-
|
|
881
|
-
type InternalTransaction = {
|
|
912
|
+
txStatus: string;
|
|
882
913
|
/**
|
|
883
|
-
* The
|
|
914
|
+
* The transaction type.
|
|
884
915
|
*/
|
|
885
|
-
|
|
916
|
+
txType: number;
|
|
886
917
|
/**
|
|
887
|
-
* The
|
|
918
|
+
* The gas limit set for the transaction.
|
|
888
919
|
*/
|
|
889
|
-
|
|
920
|
+
gasLimit: string;
|
|
890
921
|
/**
|
|
891
|
-
* The
|
|
922
|
+
* The amount of gas used.
|
|
892
923
|
*/
|
|
893
|
-
|
|
924
|
+
gasUsed: string;
|
|
894
925
|
/**
|
|
895
|
-
* The
|
|
926
|
+
* The gas price denominated by the number of decimals of the native token.
|
|
896
927
|
*/
|
|
897
|
-
|
|
928
|
+
gasPrice: string;
|
|
929
|
+
/**
|
|
930
|
+
* The nonce used by the sender of the transaction.
|
|
931
|
+
*/
|
|
932
|
+
nonce: string;
|
|
933
|
+
from: RichAddress;
|
|
934
|
+
to: RichAddress;
|
|
935
|
+
method?: Method;
|
|
936
|
+
value: string;
|
|
937
|
+
/**
|
|
938
|
+
* The data sent for the transaction.
|
|
939
|
+
*/
|
|
940
|
+
input: string;
|
|
941
|
+
baseFeePerGas: string;
|
|
942
|
+
maxFeePerGas?: string;
|
|
943
|
+
maxPriorityFeePerGas?: string;
|
|
944
|
+
};
|
|
945
|
+
|
|
946
|
+
declare enum InternalTransactionOpCall {
|
|
947
|
+
UNKNOWN = "UNKNOWN",
|
|
948
|
+
CALL = "CALL",
|
|
949
|
+
CREATE = "CREATE",
|
|
950
|
+
CREATE2 = "CREATE2",
|
|
951
|
+
CALLCODE = "CALLCODE",
|
|
952
|
+
DELEGATECALL = "DELEGATECALL",
|
|
953
|
+
STATICCALL = "STATICCALL"
|
|
954
|
+
}
|
|
955
|
+
|
|
956
|
+
type InternalTransactionDetails = {
|
|
898
957
|
from: RichAddress;
|
|
899
958
|
to: RichAddress;
|
|
900
959
|
internalTxType: InternalTransactionOpCall;
|
|
@@ -907,29 +966,62 @@ type InternalTransaction = {
|
|
|
907
966
|
gasLimit: string;
|
|
908
967
|
};
|
|
909
968
|
|
|
910
|
-
type
|
|
969
|
+
type NetworkTokenDetails = {
|
|
970
|
+
networkToken: NetworkToken;
|
|
911
971
|
/**
|
|
912
|
-
*
|
|
972
|
+
* The current token price, if available.
|
|
913
973
|
*/
|
|
914
|
-
|
|
915
|
-
|
|
974
|
+
currentPrice?: Money;
|
|
975
|
+
/**
|
|
976
|
+
* The historical token price at the time the transaction occured, if available. Note, this is only provided if the transaction occured more than 24 hours ago.
|
|
977
|
+
*/
|
|
978
|
+
historicalPrice?: Money;
|
|
979
|
+
};
|
|
980
|
+
|
|
981
|
+
type GetTransactionResponse = {
|
|
982
|
+
/**
|
|
983
|
+
* The list of ERC-20 transfers.
|
|
984
|
+
*/
|
|
985
|
+
erc20Transfers?: Array<Erc20TransferDetails>;
|
|
986
|
+
/**
|
|
987
|
+
* The list of ERC-721 transfers.
|
|
988
|
+
*/
|
|
989
|
+
erc721Transfers?: Array<Erc721TransferDetails>;
|
|
990
|
+
/**
|
|
991
|
+
* The list of ERC-1155 transfers.
|
|
992
|
+
*/
|
|
993
|
+
erc1155Transfers?: Array<Erc1155TransferDetails>;
|
|
994
|
+
/**
|
|
995
|
+
* The list of internal transactions. Note that this list only includes CALL and CALLCODE internal transactions that had a non-zero value and CREATE/CREATE2 calls. Use a client provider to recieve a full debug trace of the transaction.
|
|
996
|
+
*/
|
|
997
|
+
internalTransactions?: Array<InternalTransactionDetails>;
|
|
998
|
+
networkTokenDetails: NetworkTokenDetails;
|
|
999
|
+
nativeTransaction: FullNativeTransactionDetails;
|
|
916
1000
|
};
|
|
917
1001
|
|
|
918
|
-
type
|
|
919
|
-
|
|
1002
|
+
type ContractDeploymentDetails = {
|
|
1003
|
+
txHash: string;
|
|
1004
|
+
/**
|
|
1005
|
+
* The address that initiated the transaction which deployed this contract.
|
|
1006
|
+
*/
|
|
1007
|
+
deployerAddress: string;
|
|
1008
|
+
/**
|
|
1009
|
+
* The contract address which deployed this contract via smart contract. This field is only populated when the contract was deployed as part of smart contract execution.
|
|
1010
|
+
*/
|
|
1011
|
+
deployerContractAddress?: string;
|
|
920
1012
|
};
|
|
921
1013
|
|
|
922
|
-
type
|
|
923
|
-
|
|
924
|
-
|
|
1014
|
+
type ImageAsset = {
|
|
1015
|
+
assetId?: string;
|
|
1016
|
+
/**
|
|
1017
|
+
* OUTPUT ONLY
|
|
1018
|
+
*/
|
|
1019
|
+
imageUri?: string;
|
|
925
1020
|
};
|
|
926
1021
|
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
ERC_1155 = "ERC-1155",
|
|
931
|
-
UNKNOWN = "UNKNOWN"
|
|
932
|
-
}
|
|
1022
|
+
type PricingProviders = {
|
|
1023
|
+
coingeckoCoinId?: string;
|
|
1024
|
+
};
|
|
933
1025
|
|
|
934
1026
|
declare enum ResourceLinkType {
|
|
935
1027
|
BLOG = "Blog",
|
|
@@ -957,112 +1049,137 @@ type ResourceLink = {
|
|
|
957
1049
|
url: string;
|
|
958
1050
|
};
|
|
959
1051
|
|
|
960
|
-
type
|
|
1052
|
+
type Erc1155Contract = {
|
|
1053
|
+
/**
|
|
1054
|
+
* The contract name.
|
|
1055
|
+
*/
|
|
1056
|
+
name?: string;
|
|
1057
|
+
description?: string;
|
|
1058
|
+
officialSite?: string;
|
|
1059
|
+
email?: string;
|
|
1060
|
+
logoAsset?: ImageAsset;
|
|
1061
|
+
bannerAsset?: ImageAsset;
|
|
1062
|
+
color?: string;
|
|
1063
|
+
resourceLinks?: Array<ResourceLink>;
|
|
1064
|
+
tags?: Array<string>;
|
|
961
1065
|
/**
|
|
962
1066
|
* A wallet or contract address in mixed-case checksum encoding.
|
|
963
1067
|
*/
|
|
964
1068
|
address: string;
|
|
1069
|
+
deploymentDetails: ContractDeploymentDetails;
|
|
1070
|
+
ercType: Erc1155Contract.ercType;
|
|
965
1071
|
/**
|
|
966
|
-
* The contract
|
|
1072
|
+
* The contract symbol.
|
|
967
1073
|
*/
|
|
968
|
-
|
|
1074
|
+
symbol?: string;
|
|
1075
|
+
pricingProviders?: PricingProviders;
|
|
1076
|
+
};
|
|
1077
|
+
declare namespace Erc1155Contract {
|
|
1078
|
+
enum ercType {
|
|
1079
|
+
ERC_1155 = "ERC-1155"
|
|
1080
|
+
}
|
|
1081
|
+
}
|
|
1082
|
+
|
|
1083
|
+
type Erc20Contract = {
|
|
969
1084
|
/**
|
|
970
|
-
* The contract
|
|
1085
|
+
* The contract name.
|
|
971
1086
|
*/
|
|
972
|
-
|
|
973
|
-
ercType: ErcType;
|
|
974
|
-
bannerUri?: string;
|
|
975
|
-
logoUri?: string;
|
|
1087
|
+
name?: string;
|
|
976
1088
|
description?: string;
|
|
1089
|
+
officialSite?: string;
|
|
1090
|
+
email?: string;
|
|
1091
|
+
logoAsset?: ImageAsset;
|
|
1092
|
+
bannerAsset?: ImageAsset;
|
|
1093
|
+
color?: string;
|
|
977
1094
|
resourceLinks?: Array<ResourceLink>;
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
type Address = {
|
|
1095
|
+
tags?: Array<string>;
|
|
981
1096
|
/**
|
|
982
1097
|
* A wallet or contract address in mixed-case checksum encoding.
|
|
983
1098
|
*/
|
|
984
1099
|
address: string;
|
|
1100
|
+
deploymentDetails: ContractDeploymentDetails;
|
|
1101
|
+
ercType: Erc20Contract.ercType;
|
|
1102
|
+
/**
|
|
1103
|
+
* The contract symbol.
|
|
1104
|
+
*/
|
|
1105
|
+
symbol?: string;
|
|
1106
|
+
/**
|
|
1107
|
+
* The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
|
|
1108
|
+
*/
|
|
1109
|
+
decimals: number;
|
|
1110
|
+
pricingProviders: PricingProviders;
|
|
985
1111
|
};
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
}
|
|
991
|
-
|
|
992
|
-
declare enum ListingType {
|
|
993
|
-
SALE = "SALE",
|
|
994
|
-
AUCTION = "AUCTION"
|
|
1112
|
+
declare namespace Erc20Contract {
|
|
1113
|
+
enum ercType {
|
|
1114
|
+
ERC_20 = "ERC-20"
|
|
1115
|
+
}
|
|
995
1116
|
}
|
|
996
1117
|
|
|
997
|
-
type
|
|
1118
|
+
type Erc721Contract = {
|
|
998
1119
|
/**
|
|
999
|
-
*
|
|
1120
|
+
* The contract name.
|
|
1000
1121
|
*/
|
|
1001
|
-
|
|
1122
|
+
name?: string;
|
|
1123
|
+
description?: string;
|
|
1124
|
+
officialSite?: string;
|
|
1125
|
+
email?: string;
|
|
1126
|
+
logoAsset?: ImageAsset;
|
|
1127
|
+
bannerAsset?: ImageAsset;
|
|
1128
|
+
color?: string;
|
|
1129
|
+
resourceLinks?: Array<ResourceLink>;
|
|
1130
|
+
tags?: Array<string>;
|
|
1002
1131
|
/**
|
|
1003
|
-
*
|
|
1132
|
+
* A wallet or contract address in mixed-case checksum encoding.
|
|
1004
1133
|
*/
|
|
1005
|
-
|
|
1134
|
+
address: string;
|
|
1135
|
+
deploymentDetails: ContractDeploymentDetails;
|
|
1136
|
+
ercType: Erc721Contract.ercType;
|
|
1006
1137
|
/**
|
|
1007
1138
|
* The contract symbol.
|
|
1008
1139
|
*/
|
|
1009
|
-
symbol
|
|
1140
|
+
symbol?: string;
|
|
1141
|
+
};
|
|
1142
|
+
declare namespace Erc721Contract {
|
|
1143
|
+
enum ercType {
|
|
1144
|
+
ERC_721 = "ERC-721"
|
|
1145
|
+
}
|
|
1146
|
+
}
|
|
1147
|
+
|
|
1148
|
+
type UnknownContract = {
|
|
1010
1149
|
/**
|
|
1011
|
-
* The
|
|
1012
|
-
* means to divide the token amount by `1000000` to get its user
|
|
1013
|
-
* representation.
|
|
1150
|
+
* The contract name.
|
|
1014
1151
|
*/
|
|
1015
|
-
|
|
1152
|
+
name?: string;
|
|
1153
|
+
description?: string;
|
|
1154
|
+
officialSite?: string;
|
|
1155
|
+
email?: string;
|
|
1156
|
+
logoAsset?: ImageAsset;
|
|
1157
|
+
bannerAsset?: ImageAsset;
|
|
1158
|
+
color?: string;
|
|
1159
|
+
resourceLinks?: Array<ResourceLink>;
|
|
1160
|
+
tags?: Array<string>;
|
|
1016
1161
|
/**
|
|
1017
|
-
*
|
|
1162
|
+
* A wallet or contract address in mixed-case checksum encoding.
|
|
1018
1163
|
*/
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
type OpenListingEventResponse = {
|
|
1023
|
-
eventTimestamp: number;
|
|
1024
|
-
listingType: ListingType;
|
|
1025
|
-
listingPrice?: string;
|
|
1026
|
-
listingCurrencyType: ListingCurrencyType;
|
|
1027
|
-
listingCurrencyInfo: TokenWithPrice;
|
|
1028
|
-
sellerAddress: Address;
|
|
1029
|
-
startingPrice?: string;
|
|
1030
|
-
auctionCloseTimestamp?: number;
|
|
1031
|
-
};
|
|
1032
|
-
|
|
1033
|
-
type PurchaseListingEventResponse = {
|
|
1034
|
-
eventTimestamp: number;
|
|
1035
|
-
listingPrice: string;
|
|
1036
|
-
listingCurrencyType: ListingCurrencyType;
|
|
1037
|
-
listingCurrencyInfo: TokenWithPrice;
|
|
1038
|
-
sellerAddress: Address;
|
|
1039
|
-
salePrice: string;
|
|
1040
|
-
buyerAddress: Address;
|
|
1041
|
-
saleTimestamp: number;
|
|
1042
|
-
purchaseTxHash?: string;
|
|
1043
|
-
};
|
|
1044
|
-
|
|
1045
|
-
type ListingResponse = {
|
|
1046
|
-
marketplaceName: string;
|
|
1047
|
-
chainId: string;
|
|
1048
|
-
collection: NftCollection;
|
|
1049
|
-
token: any;
|
|
1050
|
-
listingId: string;
|
|
1051
|
-
openListingEvents?: Array<OpenListingEventResponse>;
|
|
1052
|
-
cancelListingEvents?: Array<CancelListingEventResponse>;
|
|
1053
|
-
purchaseListingEvents?: Array<PurchaseListingEventResponse>;
|
|
1054
|
-
closeAuctionEvents?: Array<CloseAuctionEventResponse>;
|
|
1164
|
+
address: string;
|
|
1165
|
+
deploymentDetails: ContractDeploymentDetails;
|
|
1166
|
+
ercType: UnknownContract.ercType;
|
|
1055
1167
|
};
|
|
1168
|
+
declare namespace UnknownContract {
|
|
1169
|
+
enum ercType {
|
|
1170
|
+
UNKNOWN = "UNKNOWN"
|
|
1171
|
+
}
|
|
1172
|
+
}
|
|
1056
1173
|
|
|
1057
|
-
type
|
|
1174
|
+
type ListContractsResponse = {
|
|
1058
1175
|
/**
|
|
1059
1176
|
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1060
1177
|
*/
|
|
1061
1178
|
nextPageToken?: string;
|
|
1062
|
-
|
|
1179
|
+
contracts: Array<(UnknownContract | Erc20Contract | Erc721Contract | Erc1155Contract)>;
|
|
1063
1180
|
};
|
|
1064
1181
|
|
|
1065
|
-
type
|
|
1182
|
+
type Erc1155Transfer = {
|
|
1066
1183
|
/**
|
|
1067
1184
|
* The block number on the chain.
|
|
1068
1185
|
*/
|
|
@@ -1075,118 +1192,182 @@ type NativeTransaction = {
|
|
|
1075
1192
|
* The block hash identifier.
|
|
1076
1193
|
*/
|
|
1077
1194
|
blockHash: string;
|
|
1078
|
-
/**
|
|
1079
|
-
* The index at which the transaction occured in the block (0-indexed).
|
|
1080
|
-
*/
|
|
1081
|
-
blockIndex: number;
|
|
1082
1195
|
/**
|
|
1083
1196
|
* The transaction hash identifier.
|
|
1084
1197
|
*/
|
|
1085
1198
|
txHash: string;
|
|
1086
|
-
/**
|
|
1087
|
-
* The transaction status, which is either 0 (failed) or 1 (successful).
|
|
1088
|
-
*/
|
|
1089
|
-
txStatus: string;
|
|
1090
|
-
/**
|
|
1091
|
-
* The transaction type.
|
|
1092
|
-
*/
|
|
1093
|
-
txType: number;
|
|
1094
|
-
/**
|
|
1095
|
-
* The gas limit set for the transaction.
|
|
1096
|
-
*/
|
|
1097
|
-
gasLimit: string;
|
|
1098
|
-
/**
|
|
1099
|
-
* The amount of gas used.
|
|
1100
|
-
*/
|
|
1101
|
-
gasUsed: string;
|
|
1102
|
-
/**
|
|
1103
|
-
* The gas price denominated by the number of decimals of the native token.
|
|
1104
|
-
*/
|
|
1105
|
-
gasPrice: string;
|
|
1106
|
-
/**
|
|
1107
|
-
* The nonce used by the sender of the transaction.
|
|
1108
|
-
*/
|
|
1109
|
-
nonce: string;
|
|
1110
1199
|
from: RichAddress;
|
|
1111
1200
|
to: RichAddress;
|
|
1112
|
-
|
|
1201
|
+
logIndex: number;
|
|
1113
1202
|
value: string;
|
|
1203
|
+
erc1155Token: Erc1155Token;
|
|
1114
1204
|
};
|
|
1115
1205
|
|
|
1116
|
-
type
|
|
1206
|
+
type ListErc1155TransactionsResponse = {
|
|
1117
1207
|
/**
|
|
1118
1208
|
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1119
1209
|
*/
|
|
1120
1210
|
nextPageToken?: string;
|
|
1121
|
-
transactions: Array<
|
|
1211
|
+
transactions: Array<Erc1155Transfer>;
|
|
1122
1212
|
};
|
|
1123
1213
|
|
|
1124
|
-
type
|
|
1214
|
+
type Erc20Transfer = {
|
|
1215
|
+
/**
|
|
1216
|
+
* The block number on the chain.
|
|
1217
|
+
*/
|
|
1218
|
+
blockNumber: string;
|
|
1219
|
+
/**
|
|
1220
|
+
* The block finality timestamp.
|
|
1221
|
+
*/
|
|
1222
|
+
blockTimestamp: number;
|
|
1125
1223
|
/**
|
|
1126
|
-
* The
|
|
1224
|
+
* The block hash identifier.
|
|
1127
1225
|
*/
|
|
1128
|
-
|
|
1226
|
+
blockHash: string;
|
|
1129
1227
|
/**
|
|
1130
|
-
* The
|
|
1228
|
+
* The transaction hash identifier.
|
|
1131
1229
|
*/
|
|
1132
|
-
|
|
1230
|
+
txHash: string;
|
|
1231
|
+
from: RichAddress;
|
|
1232
|
+
to: RichAddress;
|
|
1233
|
+
logIndex: number;
|
|
1234
|
+
value: string;
|
|
1235
|
+
erc20Token: Erc20Token;
|
|
1236
|
+
};
|
|
1237
|
+
|
|
1238
|
+
type ListErc20TransactionsResponse = {
|
|
1133
1239
|
/**
|
|
1134
|
-
*
|
|
1240
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1135
1241
|
*/
|
|
1136
|
-
|
|
1242
|
+
nextPageToken?: string;
|
|
1243
|
+
transactions: Array<Erc20Transfer>;
|
|
1244
|
+
};
|
|
1245
|
+
|
|
1246
|
+
type Erc721Transfer = {
|
|
1137
1247
|
/**
|
|
1138
|
-
* The
|
|
1248
|
+
* The block number on the chain.
|
|
1139
1249
|
*/
|
|
1140
|
-
|
|
1250
|
+
blockNumber: string;
|
|
1141
1251
|
/**
|
|
1142
|
-
* The
|
|
1252
|
+
* The block finality timestamp.
|
|
1143
1253
|
*/
|
|
1144
|
-
|
|
1254
|
+
blockTimestamp: number;
|
|
1145
1255
|
/**
|
|
1146
|
-
* The
|
|
1256
|
+
* The block hash identifier.
|
|
1147
1257
|
*/
|
|
1148
|
-
|
|
1258
|
+
blockHash: string;
|
|
1149
1259
|
/**
|
|
1150
|
-
* The
|
|
1260
|
+
* The transaction hash identifier.
|
|
1151
1261
|
*/
|
|
1152
|
-
|
|
1262
|
+
txHash: string;
|
|
1263
|
+
from: RichAddress;
|
|
1264
|
+
to: RichAddress;
|
|
1265
|
+
logIndex: number;
|
|
1266
|
+
erc721Token: Erc721Token;
|
|
1267
|
+
};
|
|
1268
|
+
|
|
1269
|
+
type ListErc721TransactionsResponse = {
|
|
1153
1270
|
/**
|
|
1154
|
-
*
|
|
1271
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1155
1272
|
*/
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
marketplaceFloorPrices: Array<string>;
|
|
1159
|
-
minFloorPrice?: string;
|
|
1160
|
-
minFloorPriceMarketplace?: string;
|
|
1273
|
+
nextPageToken?: string;
|
|
1274
|
+
transactions: Array<Erc721Transfer>;
|
|
1161
1275
|
};
|
|
1162
1276
|
|
|
1163
|
-
type
|
|
1277
|
+
type InternalTransaction = {
|
|
1164
1278
|
/**
|
|
1165
|
-
*
|
|
1279
|
+
* The block number on the chain.
|
|
1166
1280
|
*/
|
|
1167
|
-
|
|
1281
|
+
blockNumber: string;
|
|
1168
1282
|
/**
|
|
1169
|
-
* The
|
|
1283
|
+
* The block finality timestamp.
|
|
1170
1284
|
*/
|
|
1171
|
-
|
|
1285
|
+
blockTimestamp: number;
|
|
1172
1286
|
/**
|
|
1173
|
-
* The
|
|
1287
|
+
* The block hash identifier.
|
|
1174
1288
|
*/
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1289
|
+
blockHash: string;
|
|
1290
|
+
/**
|
|
1291
|
+
* The transaction hash identifier.
|
|
1292
|
+
*/
|
|
1293
|
+
txHash: string;
|
|
1294
|
+
from: RichAddress;
|
|
1295
|
+
to: RichAddress;
|
|
1296
|
+
internalTxType: InternalTransactionOpCall;
|
|
1297
|
+
value: string;
|
|
1298
|
+
/**
|
|
1299
|
+
* True if the internal transaction was reverted.
|
|
1300
|
+
*/
|
|
1301
|
+
isReverted: boolean;
|
|
1302
|
+
gasUsed: string;
|
|
1303
|
+
gasLimit: string;
|
|
1304
|
+
};
|
|
1305
|
+
|
|
1306
|
+
type ListInternalTransactionsResponse = {
|
|
1307
|
+
/**
|
|
1308
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1309
|
+
*/
|
|
1310
|
+
nextPageToken?: string;
|
|
1311
|
+
transactions: Array<InternalTransaction>;
|
|
1312
|
+
};
|
|
1313
|
+
|
|
1314
|
+
type NativeTransaction = {
|
|
1315
|
+
/**
|
|
1316
|
+
* The block number on the chain.
|
|
1317
|
+
*/
|
|
1318
|
+
blockNumber: string;
|
|
1319
|
+
/**
|
|
1320
|
+
* The block finality timestamp.
|
|
1321
|
+
*/
|
|
1322
|
+
blockTimestamp: number;
|
|
1323
|
+
/**
|
|
1324
|
+
* The block hash identifier.
|
|
1325
|
+
*/
|
|
1326
|
+
blockHash: string;
|
|
1327
|
+
/**
|
|
1328
|
+
* The index at which the transaction occured in the block (0-indexed).
|
|
1329
|
+
*/
|
|
1330
|
+
blockIndex: number;
|
|
1331
|
+
/**
|
|
1332
|
+
* The transaction hash identifier.
|
|
1333
|
+
*/
|
|
1334
|
+
txHash: string;
|
|
1335
|
+
/**
|
|
1336
|
+
* The transaction status, which is either 0 (failed) or 1 (successful).
|
|
1337
|
+
*/
|
|
1338
|
+
txStatus: string;
|
|
1339
|
+
/**
|
|
1340
|
+
* The transaction type.
|
|
1341
|
+
*/
|
|
1342
|
+
txType: number;
|
|
1343
|
+
/**
|
|
1344
|
+
* The gas limit set for the transaction.
|
|
1345
|
+
*/
|
|
1346
|
+
gasLimit: string;
|
|
1347
|
+
/**
|
|
1348
|
+
* The amount of gas used.
|
|
1349
|
+
*/
|
|
1350
|
+
gasUsed: string;
|
|
1351
|
+
/**
|
|
1352
|
+
* The gas price denominated by the number of decimals of the native token.
|
|
1353
|
+
*/
|
|
1354
|
+
gasPrice: string;
|
|
1355
|
+
/**
|
|
1356
|
+
* The nonce used by the sender of the transaction.
|
|
1357
|
+
*/
|
|
1358
|
+
nonce: string;
|
|
1359
|
+
from: RichAddress;
|
|
1360
|
+
to: RichAddress;
|
|
1361
|
+
method?: Method;
|
|
1362
|
+
value: string;
|
|
1182
1363
|
};
|
|
1183
1364
|
|
|
1184
|
-
type
|
|
1365
|
+
type ListNativeTransactionsResponse = {
|
|
1185
1366
|
/**
|
|
1186
1367
|
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1187
1368
|
*/
|
|
1188
1369
|
nextPageToken?: string;
|
|
1189
|
-
|
|
1370
|
+
transactions: Array<NativeTransaction>;
|
|
1190
1371
|
};
|
|
1191
1372
|
|
|
1192
1373
|
type TransactionDetails = {
|
|
@@ -1207,13 +1388,7 @@ type TransactionDetails = {
|
|
|
1207
1388
|
*/
|
|
1208
1389
|
erc1155Transfers?: Array<Erc1155TransferDetails>;
|
|
1209
1390
|
/**
|
|
1210
|
-
* The list of internal transactions. Note that this list only
|
|
1211
|
-
* includes CALL and
|
|
1212
|
-
* CALLCODE internal transactions that had a
|
|
1213
|
-
* non-zero value and
|
|
1214
|
-
* CREATE/CREATE2
|
|
1215
|
-
* calls. Use a client provider to recieve a full debug trace of the
|
|
1216
|
-
* transaction.
|
|
1391
|
+
* The list of internal transactions. Note that this list only includes CALL and CALLCODE internal transactions that had a non-zero value and CREATE/CREATE2 calls. Use a client provider to recieve a full debug trace of the transaction.
|
|
1217
1392
|
*/
|
|
1218
1393
|
internalTransactions?: Array<InternalTransactionDetails>;
|
|
1219
1394
|
};
|
|
@@ -1234,36 +1409,6 @@ type ListTransfersResponse = {
|
|
|
1234
1409
|
transfers: (Array<Erc20Transfer> | Array<Erc721Transfer> | Array<Erc1155Transfer>);
|
|
1235
1410
|
};
|
|
1236
1411
|
|
|
1237
|
-
declare enum NftSearchResultTypeOption {
|
|
1238
|
-
TOKEN = "token",
|
|
1239
|
-
COLLECTION = "collection"
|
|
1240
|
-
}
|
|
1241
|
-
|
|
1242
|
-
type NftFilterOptionsProperty = {
|
|
1243
|
-
/**
|
|
1244
|
-
* Filters search results by collection or token.
|
|
1245
|
-
*/
|
|
1246
|
-
resultType: NftSearchResultTypeOption;
|
|
1247
|
-
};
|
|
1248
|
-
|
|
1249
|
-
type PaginationParams = {
|
|
1250
|
-
/**
|
|
1251
|
-
* The maximum number of items to return.
|
|
1252
|
-
*/
|
|
1253
|
-
pageSize?: number;
|
|
1254
|
-
/**
|
|
1255
|
-
* A page token, received from a previous list call.
|
|
1256
|
-
* Provide this to retrieve the subsequent page.
|
|
1257
|
-
*/
|
|
1258
|
-
pageToken?: string;
|
|
1259
|
-
};
|
|
1260
|
-
|
|
1261
|
-
type NftSearchBody = {
|
|
1262
|
-
searchQuery: string;
|
|
1263
|
-
paginationParams?: PaginationParams;
|
|
1264
|
-
filterOptions: NftFilterOptionsProperty;
|
|
1265
|
-
};
|
|
1266
|
-
|
|
1267
1412
|
declare enum SortOrder {
|
|
1268
1413
|
ASC = "asc",
|
|
1269
1414
|
DESC = "desc"
|
|
@@ -1274,44 +1419,38 @@ declare enum TransactionStatus {
|
|
|
1274
1419
|
SUCCESS = "success"
|
|
1275
1420
|
}
|
|
1276
1421
|
|
|
1277
|
-
declare
|
|
1278
|
-
DAY = "day",
|
|
1279
|
-
WEEK = "week",
|
|
1280
|
-
MONTH = "month"
|
|
1281
|
-
}
|
|
1282
|
-
|
|
1283
|
-
declare class EvmService {
|
|
1422
|
+
declare class EvmTransactionsService {
|
|
1284
1423
|
readonly httpRequest: BaseHttpRequest;
|
|
1285
1424
|
constructor(httpRequest: BaseHttpRequest);
|
|
1286
1425
|
/**
|
|
1287
|
-
* Get
|
|
1288
|
-
*
|
|
1426
|
+
* Get deployment transaction
|
|
1427
|
+
* If the address is a smart contract, returns the transaction in which it was deployed.
|
|
1428
|
+
* @returns GetTransactionResponse
|
|
1289
1429
|
* @throws ApiError
|
|
1290
1430
|
*/
|
|
1291
|
-
|
|
1431
|
+
getDeploymentTransaction({ chainId, address, currency, }: {
|
|
1292
1432
|
/**
|
|
1293
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1294
|
-
* a list of supported chain ids.
|
|
1433
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1295
1434
|
*/
|
|
1296
1435
|
chainId: string;
|
|
1297
1436
|
/**
|
|
1298
|
-
*
|
|
1437
|
+
* Contract address on the relevant chain.
|
|
1299
1438
|
*/
|
|
1300
1439
|
address: string;
|
|
1301
1440
|
/**
|
|
1302
1441
|
* The currency that return values should use. Defaults to USD.
|
|
1303
1442
|
*/
|
|
1304
1443
|
currency?: CurrencyCode;
|
|
1305
|
-
}): CancelablePromise<
|
|
1444
|
+
}): CancelablePromise<GetTransactionResponse>;
|
|
1306
1445
|
/**
|
|
1307
|
-
* List
|
|
1308
|
-
*
|
|
1446
|
+
* List deployed contracts
|
|
1447
|
+
* Lists all contracts deployed by the given address.
|
|
1448
|
+
* @returns ListContractsResponse
|
|
1309
1449
|
* @throws ApiError
|
|
1310
1450
|
*/
|
|
1311
|
-
|
|
1451
|
+
listContractDeployments({ chainId, address, pageSize, pageToken, }: {
|
|
1312
1452
|
/**
|
|
1313
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1314
|
-
* a list of supported chain ids.
|
|
1453
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1315
1454
|
*/
|
|
1316
1455
|
chainId: string;
|
|
1317
1456
|
/**
|
|
@@ -1319,53 +1458,51 @@ declare class EvmService {
|
|
|
1319
1458
|
*/
|
|
1320
1459
|
address: string;
|
|
1321
1460
|
/**
|
|
1322
|
-
* The maximum number of items to return. The minimum page size
|
|
1323
|
-
* is 1. The maximum pageSize is 100.
|
|
1461
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1324
1462
|
*/
|
|
1325
1463
|
pageSize?: number;
|
|
1326
1464
|
/**
|
|
1327
1465
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1328
1466
|
*/
|
|
1329
1467
|
pageToken?: string;
|
|
1330
|
-
|
|
1331
|
-
* The currency that return values should use. Defaults to USD.
|
|
1332
|
-
*/
|
|
1333
|
-
currency?: CurrencyCode;
|
|
1334
|
-
}): CancelablePromise<ListErc20BalancesResponse>;
|
|
1468
|
+
}): CancelablePromise<ListContractsResponse>;
|
|
1335
1469
|
/**
|
|
1336
|
-
* List ERC
|
|
1337
|
-
*
|
|
1470
|
+
* List ERC transfers
|
|
1471
|
+
* Lists ERC transfers for an ERC-20, ERC-721, or ERC-1155 contract address.
|
|
1472
|
+
* @returns ListTransfersResponse
|
|
1338
1473
|
* @throws ApiError
|
|
1339
1474
|
*/
|
|
1340
|
-
|
|
1475
|
+
listTransfers({ chainId, address, startBlock, endBlock, pageSize, pageToken, }: {
|
|
1341
1476
|
/**
|
|
1342
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1343
|
-
* a list of supported chain ids.
|
|
1477
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1344
1478
|
*/
|
|
1345
1479
|
chainId: string;
|
|
1346
1480
|
/**
|
|
1347
1481
|
* A wallet address.
|
|
1348
1482
|
*/
|
|
1349
1483
|
address: string;
|
|
1484
|
+
startBlock?: number;
|
|
1485
|
+
endBlock?: number;
|
|
1350
1486
|
/**
|
|
1351
|
-
* The maximum number of items to return. The minimum page size
|
|
1352
|
-
* is 1. The maximum pageSize is 100.
|
|
1487
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1353
1488
|
*/
|
|
1354
1489
|
pageSize?: number;
|
|
1355
1490
|
/**
|
|
1356
1491
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1357
1492
|
*/
|
|
1358
1493
|
pageToken?: string;
|
|
1359
|
-
}): CancelablePromise<
|
|
1494
|
+
}): CancelablePromise<ListTransfersResponse>;
|
|
1360
1495
|
/**
|
|
1361
|
-
* List
|
|
1362
|
-
*
|
|
1496
|
+
* List transactions
|
|
1497
|
+
* Returns a list of transactions where the given wallet address had an on-chain interaction for the given chain. The ERC-20 transfers, ERC-721 transfers, ERC-1155, and internal transactions returned are only those where the input address had an interaction. Specifically, those lists only inlcude entries where the input address was the sender (`from` field) or the receiver (`to` field) for the sub-transaction. Therefore the transactions returned from this list may not be complete representations of the on-chain data. For a complete view of a transaction use the `/chains/:chainId/transactions/:txHash` endpoint.
|
|
1498
|
+
*
|
|
1499
|
+
* Filterable by block ranges.
|
|
1500
|
+
* @returns ListTransactionDetailsResponse
|
|
1363
1501
|
* @throws ApiError
|
|
1364
1502
|
*/
|
|
1365
|
-
|
|
1503
|
+
listTransactions({ chainId, address, pageSize, pageToken, startBlock, endBlock, sortOrder, }: {
|
|
1366
1504
|
/**
|
|
1367
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1368
|
-
* a list of supported chain ids.
|
|
1505
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1369
1506
|
*/
|
|
1370
1507
|
chainId: string;
|
|
1371
1508
|
/**
|
|
@@ -1373,564 +1510,1293 @@ declare class EvmService {
|
|
|
1373
1510
|
*/
|
|
1374
1511
|
address: string;
|
|
1375
1512
|
/**
|
|
1376
|
-
* The maximum number of items to return. The minimum page size
|
|
1377
|
-
* is 1. The maximum pageSize is 100.
|
|
1513
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1378
1514
|
*/
|
|
1379
1515
|
pageSize?: number;
|
|
1380
1516
|
/**
|
|
1381
1517
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1382
1518
|
*/
|
|
1383
1519
|
pageToken?: string;
|
|
1384
|
-
|
|
1520
|
+
startBlock?: number;
|
|
1521
|
+
endBlock?: number;
|
|
1522
|
+
/**
|
|
1523
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
1524
|
+
*/
|
|
1525
|
+
sortOrder?: SortOrder;
|
|
1526
|
+
}): CancelablePromise<ListTransactionDetailsResponse>;
|
|
1385
1527
|
/**
|
|
1386
|
-
* List
|
|
1387
|
-
* for
|
|
1388
|
-
* @returns
|
|
1528
|
+
* List native transactions
|
|
1529
|
+
* Lists native transactions for an address. Filterable by block range.
|
|
1530
|
+
* @returns ListNativeTransactionsResponse
|
|
1389
1531
|
* @throws ApiError
|
|
1390
1532
|
*/
|
|
1391
|
-
|
|
1533
|
+
listNativeTransactions({ chainId, address, startBlock, endBlock, pageSize, pageToken, }: {
|
|
1392
1534
|
/**
|
|
1393
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1394
|
-
* a list of supported chain ids.
|
|
1535
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1395
1536
|
*/
|
|
1396
1537
|
chainId: string;
|
|
1397
1538
|
/**
|
|
1398
1539
|
* A wallet address.
|
|
1399
1540
|
*/
|
|
1400
1541
|
address: string;
|
|
1542
|
+
startBlock?: number;
|
|
1543
|
+
endBlock?: number;
|
|
1401
1544
|
/**
|
|
1402
|
-
* The maximum number of items to return. The minimum page size
|
|
1403
|
-
* is 1. The maximum pageSize is 100.
|
|
1545
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1404
1546
|
*/
|
|
1405
1547
|
pageSize?: number;
|
|
1406
1548
|
/**
|
|
1407
1549
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1408
1550
|
*/
|
|
1409
1551
|
pageToken?: string;
|
|
1410
|
-
}): CancelablePromise<
|
|
1552
|
+
}): CancelablePromise<ListNativeTransactionsResponse>;
|
|
1411
1553
|
/**
|
|
1412
|
-
*
|
|
1413
|
-
*
|
|
1554
|
+
* List ERC-20 transfers
|
|
1555
|
+
* Lists ERC-20 transfers for an address. Filterable by block range.
|
|
1556
|
+
* @returns ListErc20TransactionsResponse
|
|
1414
1557
|
* @throws ApiError
|
|
1415
1558
|
*/
|
|
1416
|
-
|
|
1559
|
+
listErc20Transactions({ chainId, address, startBlock, endBlock, pageSize, pageToken, }: {
|
|
1417
1560
|
/**
|
|
1418
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1419
|
-
* a list of supported chain ids.
|
|
1561
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1420
1562
|
*/
|
|
1421
1563
|
chainId: string;
|
|
1422
1564
|
/**
|
|
1423
|
-
*
|
|
1424
|
-
|
|
1565
|
+
* A wallet address.
|
|
1566
|
+
*/
|
|
1567
|
+
address: string;
|
|
1568
|
+
startBlock?: number;
|
|
1569
|
+
endBlock?: number;
|
|
1570
|
+
/**
|
|
1571
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1425
1572
|
*/
|
|
1426
1573
|
pageSize?: number;
|
|
1427
1574
|
/**
|
|
1428
1575
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1429
1576
|
*/
|
|
1430
1577
|
pageToken?: string;
|
|
1431
|
-
}): CancelablePromise<
|
|
1578
|
+
}): CancelablePromise<ListErc20TransactionsResponse>;
|
|
1432
1579
|
/**
|
|
1433
|
-
*
|
|
1434
|
-
*
|
|
1580
|
+
* List ERC-721 transfers
|
|
1581
|
+
* Lists ERC-721 transfers for an address. Filterable by block range.
|
|
1582
|
+
* @returns ListErc721TransactionsResponse
|
|
1435
1583
|
* @throws ApiError
|
|
1436
1584
|
*/
|
|
1437
|
-
|
|
1585
|
+
listErc721Transactions({ chainId, address, startBlock, endBlock, pageSize, pageToken, }: {
|
|
1438
1586
|
/**
|
|
1439
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1440
|
-
* a list of supported chain ids.
|
|
1587
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1441
1588
|
*/
|
|
1442
1589
|
chainId: string;
|
|
1443
1590
|
/**
|
|
1444
|
-
* A
|
|
1445
|
-
*/
|
|
1446
|
-
blockId: string;
|
|
1447
|
-
}): CancelablePromise<GetBlockResponse>;
|
|
1448
|
-
/**
|
|
1449
|
-
* If the address is a smart contract, returns the transaction at which it was deployed.
|
|
1450
|
-
* @returns GetTransactionResponse
|
|
1451
|
-
* @throws ApiError
|
|
1452
|
-
*/
|
|
1453
|
-
getDeploymentTransaction({ chainId, address, currency, }: {
|
|
1454
|
-
/**
|
|
1455
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1456
|
-
* a list of supported chain ids.
|
|
1591
|
+
* A wallet address.
|
|
1457
1592
|
*/
|
|
1458
|
-
|
|
1593
|
+
address: string;
|
|
1594
|
+
startBlock?: number;
|
|
1595
|
+
endBlock?: number;
|
|
1459
1596
|
/**
|
|
1460
|
-
*
|
|
1597
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1461
1598
|
*/
|
|
1462
|
-
|
|
1599
|
+
pageSize?: number;
|
|
1463
1600
|
/**
|
|
1464
|
-
*
|
|
1601
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1465
1602
|
*/
|
|
1466
|
-
|
|
1467
|
-
}): CancelablePromise<
|
|
1603
|
+
pageToken?: string;
|
|
1604
|
+
}): CancelablePromise<ListErc721TransactionsResponse>;
|
|
1468
1605
|
/**
|
|
1469
|
-
*
|
|
1470
|
-
*
|
|
1471
|
-
* @returns
|
|
1606
|
+
* List ERC-1155 transfers
|
|
1607
|
+
* Lists ERC-1155 transfers for an address. Filterable by block range.
|
|
1608
|
+
* @returns ListErc1155TransactionsResponse
|
|
1472
1609
|
* @throws ApiError
|
|
1473
1610
|
*/
|
|
1474
|
-
|
|
1611
|
+
listErc1155Transactions({ chainId, address, startBlock, endBlock, pageSize, pageToken, }: {
|
|
1475
1612
|
/**
|
|
1476
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1477
|
-
* a list of supported chain ids.
|
|
1613
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1478
1614
|
*/
|
|
1479
1615
|
chainId: string;
|
|
1480
1616
|
/**
|
|
1481
1617
|
* A wallet address.
|
|
1482
1618
|
*/
|
|
1483
1619
|
address: string;
|
|
1620
|
+
startBlock?: number;
|
|
1621
|
+
endBlock?: number;
|
|
1484
1622
|
/**
|
|
1485
|
-
* The maximum number of items to return. The minimum page size
|
|
1486
|
-
* is 1. The maximum pageSize is 100.
|
|
1623
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1487
1624
|
*/
|
|
1488
1625
|
pageSize?: number;
|
|
1489
1626
|
/**
|
|
1490
1627
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1491
1628
|
*/
|
|
1492
1629
|
pageToken?: string;
|
|
1493
|
-
}): CancelablePromise<
|
|
1630
|
+
}): CancelablePromise<ListErc1155TransactionsResponse>;
|
|
1494
1631
|
/**
|
|
1495
|
-
*
|
|
1496
|
-
* Returns a list of transactions
|
|
1497
|
-
*
|
|
1498
|
-
*
|
|
1499
|
-
*
|
|
1500
|
-
* Specifically, those list only inlcude entries where the input address
|
|
1501
|
-
* was the sender (`from` field) or the receiver (`to` field) for the
|
|
1502
|
-
* sub-transaction. Therefore the transactions returned from this list may
|
|
1503
|
-
* not be complete representations of the on-chain data. For a complete
|
|
1504
|
-
* view of a transaction use the `/chains/:chainId/transactions/:txHash`
|
|
1505
|
-
* endpoint.
|
|
1506
|
-
* @returns ListTransactionDetailsResponse
|
|
1632
|
+
* List internal transactions
|
|
1633
|
+
* Returns a list of internal transactions for an address and chain. Filterable by block range.
|
|
1634
|
+
*
|
|
1635
|
+
* Note that the internal transactions list only contains `CALL` or `CALLCODE` transactions with a non-zero value and `CREATE`/`CREATE2` transactions. To get a complete list of internal transactions use the `debug_` prefixed RPC methods on an archive node.
|
|
1636
|
+
* @returns ListInternalTransactionsResponse
|
|
1507
1637
|
* @throws ApiError
|
|
1508
1638
|
*/
|
|
1509
|
-
|
|
1639
|
+
listInternalTransactions({ chainId, address, startBlock, endBlock, pageSize, pageToken, }: {
|
|
1510
1640
|
/**
|
|
1511
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1512
|
-
* a list of supported chain ids.
|
|
1641
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1513
1642
|
*/
|
|
1514
1643
|
chainId: string;
|
|
1515
1644
|
/**
|
|
1516
1645
|
* A wallet address.
|
|
1517
1646
|
*/
|
|
1518
1647
|
address: string;
|
|
1648
|
+
startBlock?: number;
|
|
1649
|
+
endBlock?: number;
|
|
1519
1650
|
/**
|
|
1520
|
-
* The maximum number of items to return. The minimum page size
|
|
1521
|
-
* is 1. The maximum pageSize is 100.
|
|
1651
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1522
1652
|
*/
|
|
1523
1653
|
pageSize?: number;
|
|
1524
1654
|
/**
|
|
1525
1655
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1526
1656
|
*/
|
|
1527
1657
|
pageToken?: string;
|
|
1658
|
+
}): CancelablePromise<ListInternalTransactionsResponse>;
|
|
1659
|
+
/**
|
|
1660
|
+
* Get transaction
|
|
1661
|
+
* Gets the details of a single transaction.
|
|
1662
|
+
* @returns GetTransactionResponse
|
|
1663
|
+
* @throws ApiError
|
|
1664
|
+
*/
|
|
1665
|
+
getTransaction({ chainId, txHash, }: {
|
|
1528
1666
|
/**
|
|
1529
|
-
*
|
|
1667
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1530
1668
|
*/
|
|
1531
|
-
|
|
1669
|
+
chainId: string;
|
|
1532
1670
|
/**
|
|
1533
|
-
*
|
|
1671
|
+
* A transaction hash.
|
|
1534
1672
|
*/
|
|
1535
|
-
|
|
1536
|
-
}): CancelablePromise<
|
|
1673
|
+
txHash: string;
|
|
1674
|
+
}): CancelablePromise<GetTransactionResponse>;
|
|
1537
1675
|
/**
|
|
1538
|
-
*
|
|
1676
|
+
* List transactions for a block
|
|
1677
|
+
* Lists the transactions that occured in a given block.
|
|
1539
1678
|
* @returns ListNativeTransactionsResponse
|
|
1540
1679
|
* @throws ApiError
|
|
1541
1680
|
*/
|
|
1542
|
-
|
|
1681
|
+
getTransactionsForBlock({ chainId, blockId, }: {
|
|
1543
1682
|
/**
|
|
1544
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1545
|
-
* a list of supported chain ids.
|
|
1683
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1546
1684
|
*/
|
|
1547
1685
|
chainId: string;
|
|
1548
1686
|
/**
|
|
1549
|
-
* A
|
|
1550
|
-
*/
|
|
1551
|
-
address: string;
|
|
1552
|
-
/**
|
|
1553
|
-
* The maximum number of items to return. The minimum page size
|
|
1554
|
-
* is 1. The maximum pageSize is 100.
|
|
1555
|
-
*/
|
|
1556
|
-
pageSize?: number;
|
|
1557
|
-
/**
|
|
1558
|
-
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1687
|
+
* A block identifier which is either a block number or the block hash.
|
|
1559
1688
|
*/
|
|
1560
|
-
|
|
1689
|
+
blockId: string;
|
|
1561
1690
|
}): CancelablePromise<ListNativeTransactionsResponse>;
|
|
1562
1691
|
/**
|
|
1563
|
-
*
|
|
1564
|
-
*
|
|
1692
|
+
* List latest transactions
|
|
1693
|
+
* Lists the latest transactions. Filterable by status.
|
|
1694
|
+
* @returns ListNativeTransactionsResponse
|
|
1565
1695
|
* @throws ApiError
|
|
1566
1696
|
*/
|
|
1567
|
-
|
|
1697
|
+
listLatestTransactions({ chainId, pageSize, pageToken, status, }: {
|
|
1568
1698
|
/**
|
|
1569
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1570
|
-
* a list of supported chain ids.
|
|
1699
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1571
1700
|
*/
|
|
1572
1701
|
chainId: string;
|
|
1573
1702
|
/**
|
|
1574
|
-
*
|
|
1575
|
-
*/
|
|
1576
|
-
address: string;
|
|
1577
|
-
/**
|
|
1578
|
-
* The maximum number of items to return. The minimum page size
|
|
1579
|
-
* is 1. The maximum pageSize is 100.
|
|
1703
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1580
1704
|
*/
|
|
1581
1705
|
pageSize?: number;
|
|
1582
1706
|
/**
|
|
1583
1707
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1584
1708
|
*/
|
|
1585
1709
|
pageToken?: string;
|
|
1586
|
-
|
|
1710
|
+
/**
|
|
1711
|
+
* A status filter for listed transactions.
|
|
1712
|
+
*/
|
|
1713
|
+
status?: TransactionStatus;
|
|
1714
|
+
}): CancelablePromise<ListNativeTransactionsResponse>;
|
|
1715
|
+
}
|
|
1716
|
+
|
|
1717
|
+
declare class HealthCheckService {
|
|
1718
|
+
readonly httpRequest: BaseHttpRequest;
|
|
1719
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
1587
1720
|
/**
|
|
1588
|
-
*
|
|
1589
|
-
* @returns
|
|
1721
|
+
* Get the health of the service
|
|
1722
|
+
* @returns any The Health Check is successful
|
|
1590
1723
|
* @throws ApiError
|
|
1591
1724
|
*/
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
* The maximum number of items to return. The minimum page size
|
|
1604
|
-
* is 1. The maximum pageSize is 100.
|
|
1605
|
-
*/
|
|
1606
|
-
pageSize?: number;
|
|
1607
|
-
/**
|
|
1608
|
-
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1609
|
-
*/
|
|
1610
|
-
pageToken?: string;
|
|
1611
|
-
}): CancelablePromise<ListErc721TransactionsResponse>;
|
|
1725
|
+
healthCheck(): CancelablePromise<{
|
|
1726
|
+
status?: string;
|
|
1727
|
+
info?: Record<string, Record<string, string>> | null;
|
|
1728
|
+
error?: Record<string, Record<string, string>> | null;
|
|
1729
|
+
details?: Record<string, Record<string, string>>;
|
|
1730
|
+
}>;
|
|
1731
|
+
}
|
|
1732
|
+
|
|
1733
|
+
declare class NfTsService {
|
|
1734
|
+
readonly httpRequest: BaseHttpRequest;
|
|
1735
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
1612
1736
|
/**
|
|
1613
|
-
*
|
|
1614
|
-
*
|
|
1737
|
+
* Reindex NFT metadata
|
|
1738
|
+
* Triggers reindexing of token metadata for an NFT token. Reindexing can only be called once per hour for each NFT token.
|
|
1739
|
+
* @returns any
|
|
1615
1740
|
* @throws ApiError
|
|
1616
1741
|
*/
|
|
1617
|
-
|
|
1742
|
+
reindexNft({ chainId, address, tokenId, }: {
|
|
1618
1743
|
/**
|
|
1619
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1620
|
-
* a list of supported chain ids.
|
|
1744
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1621
1745
|
*/
|
|
1622
1746
|
chainId: string;
|
|
1623
1747
|
/**
|
|
1624
|
-
*
|
|
1748
|
+
* Contract address on the relevant chain.
|
|
1625
1749
|
*/
|
|
1626
1750
|
address: string;
|
|
1627
1751
|
/**
|
|
1628
|
-
*
|
|
1629
|
-
* is 1. The maximum pageSize is 100.
|
|
1630
|
-
*/
|
|
1631
|
-
pageSize?: number;
|
|
1632
|
-
/**
|
|
1633
|
-
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1752
|
+
* TokenId on the contract
|
|
1634
1753
|
*/
|
|
1635
|
-
|
|
1636
|
-
}): CancelablePromise<
|
|
1754
|
+
tokenId: string;
|
|
1755
|
+
}): CancelablePromise<any>;
|
|
1637
1756
|
/**
|
|
1638
|
-
*
|
|
1639
|
-
*
|
|
1640
|
-
*
|
|
1641
|
-
* CALLCODE transactions with a non-zero value and CREATE/CREATE2
|
|
1642
|
-
* transactions. To get a complete list of internal transactions use the
|
|
1643
|
-
* `debug_` prefixed RPC methods on an archive node.
|
|
1644
|
-
* @returns ListInternalTransactionsResponse
|
|
1757
|
+
* Get token details
|
|
1758
|
+
* Gets token details for a specific token of an NFT contract.
|
|
1759
|
+
* @returns any
|
|
1645
1760
|
* @throws ApiError
|
|
1646
1761
|
*/
|
|
1647
|
-
|
|
1762
|
+
getTokenDetails({ chainId, address, tokenId, }: {
|
|
1648
1763
|
/**
|
|
1649
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1650
|
-
* a list of supported chain ids.
|
|
1764
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1651
1765
|
*/
|
|
1652
1766
|
chainId: string;
|
|
1653
1767
|
/**
|
|
1654
|
-
*
|
|
1768
|
+
* Contract address on the relevant chain.
|
|
1655
1769
|
*/
|
|
1656
1770
|
address: string;
|
|
1657
1771
|
/**
|
|
1658
|
-
*
|
|
1659
|
-
* is 1. The maximum pageSize is 100.
|
|
1660
|
-
*/
|
|
1661
|
-
pageSize?: number;
|
|
1662
|
-
/**
|
|
1663
|
-
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1772
|
+
* TokenId on the contract
|
|
1664
1773
|
*/
|
|
1665
|
-
|
|
1666
|
-
}): CancelablePromise<
|
|
1774
|
+
tokenId: string;
|
|
1775
|
+
}): CancelablePromise<(Erc721Token | Erc1155Token)>;
|
|
1667
1776
|
/**
|
|
1668
|
-
*
|
|
1669
|
-
*
|
|
1777
|
+
* Get collection details
|
|
1778
|
+
* Gets collection details for a NFT contract.
|
|
1779
|
+
* @returns any
|
|
1670
1780
|
* @throws ApiError
|
|
1671
1781
|
*/
|
|
1672
|
-
|
|
1782
|
+
getCollection({ chainId, address, }: {
|
|
1673
1783
|
/**
|
|
1674
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1675
|
-
* a list of supported chain ids.
|
|
1784
|
+
* A supported evm chain id. Use the `/chains` endpoint to get a list of supported chain ids.
|
|
1676
1785
|
*/
|
|
1677
1786
|
chainId: string;
|
|
1678
1787
|
/**
|
|
1679
|
-
*
|
|
1788
|
+
* Contract address on the relevant chain.
|
|
1680
1789
|
*/
|
|
1681
|
-
|
|
1682
|
-
}): CancelablePromise<
|
|
1790
|
+
address: string;
|
|
1791
|
+
}): CancelablePromise<(Erc721Contract | Erc1155Contract)>;
|
|
1792
|
+
}
|
|
1793
|
+
|
|
1794
|
+
type EvmNetworkOptions = {
|
|
1795
|
+
addresses: Array<string>;
|
|
1796
|
+
includeChains: Array<string>;
|
|
1797
|
+
};
|
|
1798
|
+
|
|
1799
|
+
type CreateEvmTransactionExportRequest = {
|
|
1800
|
+
type: CreateEvmTransactionExportRequest.type;
|
|
1801
|
+
firstDate: string;
|
|
1802
|
+
lastDate: string;
|
|
1683
1803
|
/**
|
|
1684
|
-
*
|
|
1685
|
-
* @returns ListNativeTransactionsResponse
|
|
1686
|
-
* @throws ApiError
|
|
1804
|
+
* @deprecated
|
|
1687
1805
|
*/
|
|
1688
|
-
|
|
1689
|
-
/**
|
|
1690
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1691
|
-
* a list of supported chain ids.
|
|
1692
|
-
*/
|
|
1693
|
-
chainId: string;
|
|
1694
|
-
/**
|
|
1695
|
-
* A block identifier which is either a block number or the block hash.
|
|
1696
|
-
*/
|
|
1697
|
-
blockId: string;
|
|
1698
|
-
}): CancelablePromise<ListNativeTransactionsResponse>;
|
|
1806
|
+
startDate: string;
|
|
1699
1807
|
/**
|
|
1700
|
-
*
|
|
1701
|
-
* @returns ListNativeTransactionsResponse
|
|
1702
|
-
* @throws ApiError
|
|
1808
|
+
* @deprecated
|
|
1703
1809
|
*/
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
}): CancelablePromise<ListNativeTransactionsResponse>;
|
|
1810
|
+
endDate: string;
|
|
1811
|
+
options: EvmNetworkOptions;
|
|
1812
|
+
};
|
|
1813
|
+
declare namespace CreateEvmTransactionExportRequest {
|
|
1814
|
+
enum type {
|
|
1815
|
+
TRANSACTION_EXPORT_EVM = "TRANSACTION_EXPORT_EVM"
|
|
1816
|
+
}
|
|
1817
|
+
}
|
|
1818
|
+
|
|
1819
|
+
type PrimaryNetworkOptions = {
|
|
1820
|
+
addresses: Array<string>;
|
|
1821
|
+
cChainEvmAddresses?: Array<string>;
|
|
1822
|
+
includeChains: Array<'11111111111111111111111111111111LpoYY' | '2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM' | '2JVSBoinj9C2J33VntvzYtVJNZdN2NKiwwKjcumHUWEb5DbBrm' | '2q9e4r6Mu3U68nU1fYjgbR6JvwrRx36CohpAX5UQxse55x1Q5' | 'yH8D7ThNJkxmtkuv2jgBa4P1Rn3Qpr4pPr7QYNfcdoS6k6HWp' | 'p-chain' | 'x-chain' | 'c-chain'>;
|
|
1823
|
+
};
|
|
1824
|
+
|
|
1825
|
+
type CreatePrimaryNetworkTransactionExportRequest = {
|
|
1826
|
+
type: CreatePrimaryNetworkTransactionExportRequest.type;
|
|
1827
|
+
firstDate: string;
|
|
1828
|
+
lastDate: string;
|
|
1724
1829
|
/**
|
|
1725
|
-
*
|
|
1726
|
-
* @returns ListChainsResponse
|
|
1727
|
-
* @throws ApiError
|
|
1830
|
+
* @deprecated
|
|
1728
1831
|
*/
|
|
1729
|
-
|
|
1832
|
+
startDate: string;
|
|
1730
1833
|
/**
|
|
1731
|
-
*
|
|
1732
|
-
|
|
1834
|
+
* @deprecated
|
|
1835
|
+
*/
|
|
1836
|
+
endDate: string;
|
|
1837
|
+
options: PrimaryNetworkOptions;
|
|
1838
|
+
};
|
|
1839
|
+
declare namespace CreatePrimaryNetworkTransactionExportRequest {
|
|
1840
|
+
enum type {
|
|
1841
|
+
TRANSACTION_EXPORT_PRIMARY_NETWORK = "TRANSACTION_EXPORT_PRIMARY_NETWORK"
|
|
1842
|
+
}
|
|
1843
|
+
}
|
|
1844
|
+
|
|
1845
|
+
declare enum OperationStatus {
|
|
1846
|
+
RUNNING = "RUNNING",
|
|
1847
|
+
COMPLETED = "COMPLETED",
|
|
1848
|
+
COMPLETED_WITH_WARNING = "COMPLETED_WITH_WARNING",
|
|
1849
|
+
FAILED = "FAILED"
|
|
1850
|
+
}
|
|
1851
|
+
|
|
1852
|
+
declare enum OperationType {
|
|
1853
|
+
TRANSACTION_EXPORT_EVM = "TRANSACTION_EXPORT_EVM",
|
|
1854
|
+
TRANSACTION_EXPORT_PRIMARY_NETWORK = "TRANSACTION_EXPORT_PRIMARY_NETWORK"
|
|
1855
|
+
}
|
|
1856
|
+
|
|
1857
|
+
declare enum OperationStatusCode {
|
|
1858
|
+
ERR_INVALID_REQUEST = "ErrInvalidRequest",
|
|
1859
|
+
ERR_INTERNAL = "ErrInternal",
|
|
1860
|
+
WARN_TRUNCATED_EXPORT = "WarnTruncatedExport"
|
|
1861
|
+
}
|
|
1862
|
+
|
|
1863
|
+
type TransactionExportMetadata = {
|
|
1864
|
+
code?: OperationStatusCode;
|
|
1865
|
+
/**
|
|
1866
|
+
* File download URL. Provided only for COMPLETED and COMPLETED_WITH_WARNING operations.
|
|
1867
|
+
*/
|
|
1868
|
+
downloadUrl?: string;
|
|
1869
|
+
/**
|
|
1870
|
+
* The next date (YYYY-MM-DD) to use as the firstDate in follow up requests if a request results in a transaction history exceeding the max size and has been reported as `COMPLETED_WITH_WARNING` with the warning 'WarnTruncatedExport'.
|
|
1871
|
+
*/
|
|
1872
|
+
nextDate?: string;
|
|
1873
|
+
};
|
|
1874
|
+
|
|
1875
|
+
type OperationStatusResponse = {
|
|
1876
|
+
operationId: string;
|
|
1877
|
+
operationType: OperationType;
|
|
1878
|
+
operationStatus: OperationStatus;
|
|
1879
|
+
message?: string;
|
|
1880
|
+
metadata: TransactionExportMetadata;
|
|
1881
|
+
createdAtTimestamp: number;
|
|
1882
|
+
updatedAtTimestamp: number;
|
|
1883
|
+
};
|
|
1884
|
+
|
|
1885
|
+
declare class OperationsService {
|
|
1886
|
+
readonly httpRequest: BaseHttpRequest;
|
|
1887
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
1888
|
+
/**
|
|
1889
|
+
* Create transaction export operation
|
|
1890
|
+
* Trigger a transaction export operation with given parameters.
|
|
1891
|
+
*
|
|
1892
|
+
* The transaction export operation runs asynchronously in the background. The status of the job can be retrieved from the `/v1/operations/:operationId` endpoint using the `operationId` returned from this endpoint.
|
|
1893
|
+
* @returns OperationStatusResponse
|
|
1733
1894
|
* @throws ApiError
|
|
1734
1895
|
*/
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
* a list of supported chain ids.
|
|
1739
|
-
*/
|
|
1740
|
-
chainId: string;
|
|
1741
|
-
}): CancelablePromise<GetChainResponse>;
|
|
1896
|
+
postTransactionExportJob({ requestBody, }: {
|
|
1897
|
+
requestBody: (CreateEvmTransactionExportRequest | CreatePrimaryNetworkTransactionExportRequest);
|
|
1898
|
+
}): CancelablePromise<OperationStatusResponse>;
|
|
1742
1899
|
/**
|
|
1743
|
-
*
|
|
1744
|
-
*
|
|
1745
|
-
*
|
|
1746
|
-
* @returns any
|
|
1900
|
+
* Get operation
|
|
1901
|
+
* Gets operation details for the given operation id.
|
|
1902
|
+
* @returns OperationStatusResponse
|
|
1747
1903
|
* @throws ApiError
|
|
1748
1904
|
*/
|
|
1749
|
-
|
|
1750
|
-
/**
|
|
1751
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1752
|
-
* a list of supported chain ids.
|
|
1753
|
-
*/
|
|
1754
|
-
chainId: string;
|
|
1755
|
-
/**
|
|
1756
|
-
* Contract address on the relevant chain.
|
|
1757
|
-
*/
|
|
1758
|
-
address: string;
|
|
1905
|
+
getOperationResult({ operationId, }: {
|
|
1759
1906
|
/**
|
|
1760
|
-
*
|
|
1907
|
+
* UUID of given operation
|
|
1761
1908
|
*/
|
|
1762
|
-
|
|
1763
|
-
}): CancelablePromise<
|
|
1909
|
+
operationId: string;
|
|
1910
|
+
}): CancelablePromise<OperationStatusResponse>;
|
|
1911
|
+
}
|
|
1912
|
+
|
|
1913
|
+
declare enum BlockchainIds {
|
|
1914
|
+
_11111111111111111111111111111111LPO_YY = "11111111111111111111111111111111LpoYY",
|
|
1915
|
+
_2O_YMBNV4E_NHYQK2FJJ_V5N_VQLDBTM_NJZQ5S3QS3LO6FTN_C6FBY_M = "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
|
|
1916
|
+
_2JVSBOINJ9C2J33VNTVZ_YT_VJNZD_N2NKIWW_KJCUM_HUWEB5DB_BRM = "2JVSBoinj9C2J33VntvzYtVJNZdN2NKiwwKjcumHUWEb5DbBrm",
|
|
1917
|
+
_2Q9E4R6MU3U68N_U1F_YJGB_R6JVWR_RX36COHP_AX5UQXSE55X1Q5 = "2q9e4r6Mu3U68nU1fYjgbR6JvwrRx36CohpAX5UQxse55x1Q5",
|
|
1918
|
+
Y_H8D7TH_NJKXMTKUV2JG_BA4P1RN3QPR4P_PR7QYNFCDO_S6K6HWP = "yH8D7ThNJkxmtkuv2jgBa4P1Rn3Qpr4pPr7QYNfcdoS6k6HWp"
|
|
1919
|
+
}
|
|
1920
|
+
|
|
1921
|
+
type ChainAddressChainIdMap = {
|
|
1922
|
+
address: string;
|
|
1923
|
+
blockchainIds: Array<BlockchainIds>;
|
|
1924
|
+
};
|
|
1925
|
+
|
|
1926
|
+
type ChainAddressChainIdMapListResponse = {
|
|
1927
|
+
addresses: Array<ChainAddressChainIdMap>;
|
|
1928
|
+
};
|
|
1929
|
+
|
|
1930
|
+
declare enum DelegationStatusType {
|
|
1931
|
+
COMPLETED = "completed",
|
|
1932
|
+
ACTIVE = "active",
|
|
1933
|
+
PENDING = "pending"
|
|
1934
|
+
}
|
|
1935
|
+
|
|
1936
|
+
type DelegatorsDetails = {
|
|
1937
|
+
delegatorCount: number;
|
|
1938
|
+
totalAmountStaked: string;
|
|
1939
|
+
};
|
|
1940
|
+
|
|
1941
|
+
type StakingDistribution = {
|
|
1942
|
+
version: string;
|
|
1943
|
+
amountStaked: string;
|
|
1944
|
+
validatorCount: number;
|
|
1945
|
+
};
|
|
1946
|
+
|
|
1947
|
+
type ValidatorsDetails = {
|
|
1948
|
+
validatorCount: number;
|
|
1949
|
+
totalAmountStaked: string;
|
|
1950
|
+
estimatedAnnualStakingReward: string;
|
|
1951
|
+
stakingDistributionByVersion: Array<StakingDistribution>;
|
|
1952
|
+
stakingRatio: string;
|
|
1953
|
+
};
|
|
1954
|
+
|
|
1955
|
+
type GetNetworkDetailsResponse = {
|
|
1956
|
+
validatorDetails: ValidatorsDetails;
|
|
1957
|
+
delegatorDetails: DelegatorsDetails;
|
|
1958
|
+
};
|
|
1959
|
+
|
|
1960
|
+
type Blockchain = {
|
|
1961
|
+
createBlockTimestamp: number;
|
|
1962
|
+
createBlockNumber: string;
|
|
1963
|
+
blockchainId: string;
|
|
1964
|
+
vmId: string;
|
|
1965
|
+
subnetId: string;
|
|
1966
|
+
blockchainName: string;
|
|
1967
|
+
};
|
|
1968
|
+
|
|
1969
|
+
type ListBlockchainsResponse = {
|
|
1970
|
+
/**
|
|
1971
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1972
|
+
*/
|
|
1973
|
+
nextPageToken?: string;
|
|
1974
|
+
blockchains: Array<Blockchain>;
|
|
1975
|
+
};
|
|
1976
|
+
|
|
1977
|
+
type ActiveDelegatorDetails = {
|
|
1978
|
+
txHash: string;
|
|
1979
|
+
rewardAddresses: Array<string>;
|
|
1980
|
+
amountDelegated: string;
|
|
1981
|
+
delegationFee: string;
|
|
1982
|
+
startTimestamp: number;
|
|
1983
|
+
endTimestamp: number;
|
|
1984
|
+
delegationStatus: DelegationStatusType;
|
|
1985
|
+
estimatedGrossReward: string;
|
|
1986
|
+
estimatedNetReward: string;
|
|
1987
|
+
};
|
|
1988
|
+
|
|
1989
|
+
type CompletedDelegatorDetails = {
|
|
1990
|
+
txHash: string;
|
|
1991
|
+
rewardAddresses: Array<string>;
|
|
1992
|
+
amountDelegated: string;
|
|
1993
|
+
delegationFee: string;
|
|
1994
|
+
startTimestamp: number;
|
|
1995
|
+
endTimestamp: number;
|
|
1996
|
+
delegationStatus: DelegationStatusType;
|
|
1997
|
+
grossReward: string;
|
|
1998
|
+
netReward: string;
|
|
1999
|
+
};
|
|
2000
|
+
|
|
2001
|
+
type PendingDelegatorDetails = {
|
|
2002
|
+
txHash: string;
|
|
2003
|
+
rewardAddresses: Array<string>;
|
|
2004
|
+
amountDelegated: string;
|
|
2005
|
+
delegationFee: string;
|
|
2006
|
+
startTimestamp: number;
|
|
2007
|
+
endTimestamp: number;
|
|
2008
|
+
delegationStatus: DelegationStatusType;
|
|
2009
|
+
estimatedGrossReward: string;
|
|
2010
|
+
estimatedNetReward: string;
|
|
2011
|
+
};
|
|
2012
|
+
|
|
2013
|
+
type ListDelegatorDetailsResponse = {
|
|
2014
|
+
/**
|
|
2015
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2016
|
+
*/
|
|
2017
|
+
nextPageToken?: string;
|
|
2018
|
+
/**
|
|
2019
|
+
* The list of Delegator Details.
|
|
2020
|
+
*/
|
|
2021
|
+
delegators: Array<(CompletedDelegatorDetails | ActiveDelegatorDetails | PendingDelegatorDetails)>;
|
|
2022
|
+
};
|
|
2023
|
+
|
|
2024
|
+
type BlockchainInfo = {
|
|
2025
|
+
blockchainId: string;
|
|
2026
|
+
};
|
|
2027
|
+
|
|
2028
|
+
type Subnet = {
|
|
2029
|
+
createBlockTimestamp: number;
|
|
2030
|
+
createBlockIndex: string;
|
|
2031
|
+
subnetId: string;
|
|
2032
|
+
ownerAddresses: Array<string>;
|
|
2033
|
+
threshold: number;
|
|
2034
|
+
locktime: number;
|
|
2035
|
+
blockchains: Array<BlockchainInfo>;
|
|
2036
|
+
};
|
|
2037
|
+
|
|
2038
|
+
type ListSubnetsResponse = {
|
|
2039
|
+
/**
|
|
2040
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2041
|
+
*/
|
|
2042
|
+
nextPageToken?: string;
|
|
2043
|
+
subnets: Array<Subnet>;
|
|
2044
|
+
};
|
|
2045
|
+
|
|
2046
|
+
type Rewards = {
|
|
2047
|
+
validationRewardAmount: string;
|
|
2048
|
+
delegationRewardAmount: string;
|
|
2049
|
+
};
|
|
2050
|
+
|
|
2051
|
+
declare enum ValidationStatusType {
|
|
2052
|
+
COMPLETED = "completed",
|
|
2053
|
+
ACTIVE = "active",
|
|
2054
|
+
PENDING = "pending"
|
|
2055
|
+
}
|
|
2056
|
+
|
|
2057
|
+
type ActiveValidatorDetails = {
|
|
2058
|
+
nodeId: string;
|
|
2059
|
+
amountStaked: string;
|
|
2060
|
+
delegationFee: string;
|
|
2061
|
+
startTimestamp: number;
|
|
2062
|
+
endTimestamp: number;
|
|
2063
|
+
validationStatus: ValidationStatusType;
|
|
2064
|
+
stakePercentage: number;
|
|
2065
|
+
delegatorCount: number;
|
|
2066
|
+
amountDelegated: string;
|
|
2067
|
+
uptimePerformance: number;
|
|
2068
|
+
avalancheGoVersion: string;
|
|
2069
|
+
delegationCapacity: string;
|
|
2070
|
+
potentialRewards: Rewards;
|
|
2071
|
+
};
|
|
2072
|
+
|
|
2073
|
+
type CompletedValidatorDetails = {
|
|
2074
|
+
nodeId: string;
|
|
2075
|
+
amountStaked: string;
|
|
2076
|
+
delegationFee: string;
|
|
2077
|
+
startTimestamp: number;
|
|
2078
|
+
endTimestamp: number;
|
|
2079
|
+
validationStatus: ValidationStatusType;
|
|
2080
|
+
delegatorCount: number;
|
|
2081
|
+
rewards: Rewards;
|
|
2082
|
+
};
|
|
2083
|
+
|
|
2084
|
+
type PendingValidatorDetails = {
|
|
2085
|
+
nodeId: string;
|
|
2086
|
+
amountStaked: string;
|
|
2087
|
+
delegationFee: string;
|
|
2088
|
+
startTimestamp: number;
|
|
2089
|
+
endTimestamp: number;
|
|
2090
|
+
validationStatus: ValidationStatusType;
|
|
2091
|
+
};
|
|
2092
|
+
|
|
2093
|
+
type ListValidatorDetailsResponse = {
|
|
2094
|
+
/**
|
|
2095
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2096
|
+
*/
|
|
2097
|
+
nextPageToken?: string;
|
|
2098
|
+
/**
|
|
2099
|
+
* The list of Validator Details.
|
|
2100
|
+
*/
|
|
2101
|
+
validators: Array<(CompletedValidatorDetails | ActiveValidatorDetails | PendingValidatorDetails)>;
|
|
2102
|
+
};
|
|
2103
|
+
|
|
2104
|
+
declare enum Network {
|
|
2105
|
+
MAINNET = "mainnet",
|
|
2106
|
+
FUJI = "fuji"
|
|
2107
|
+
}
|
|
2108
|
+
|
|
2109
|
+
type XChainAssetDetails = {
|
|
2110
|
+
/**
|
|
2111
|
+
* Unique ID for an asset.
|
|
2112
|
+
*/
|
|
2113
|
+
assetId: string;
|
|
2114
|
+
/**
|
|
2115
|
+
* Name of this asset.
|
|
2116
|
+
*/
|
|
2117
|
+
name: string;
|
|
2118
|
+
/**
|
|
2119
|
+
* Symbol for this asset (max 4 characters).
|
|
2120
|
+
*/
|
|
2121
|
+
symbol: string;
|
|
2122
|
+
/**
|
|
2123
|
+
* Denomination of this asset to represent fungibility.
|
|
2124
|
+
*/
|
|
2125
|
+
denomination: number;
|
|
2126
|
+
/**
|
|
2127
|
+
* Type of asset like SECP256K1 or NFT.
|
|
2128
|
+
*/
|
|
2129
|
+
type: string;
|
|
2130
|
+
/**
|
|
2131
|
+
* Timestamp in seconds this asset was created on.
|
|
2132
|
+
*/
|
|
2133
|
+
createdAtTimestamp: number;
|
|
2134
|
+
/**
|
|
2135
|
+
* Cap represents if an asset can be or is fixed cap.
|
|
2136
|
+
*/
|
|
2137
|
+
cap: string;
|
|
2138
|
+
};
|
|
2139
|
+
|
|
2140
|
+
declare enum XChainId {
|
|
2141
|
+
_2O_YMBNV4E_NHYQK2FJJ_V5N_VQLDBTM_NJZQ5S3QS3LO6FTN_C6FBY_M = "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
|
|
2142
|
+
_2JVSBOINJ9C2J33VNTVZ_YT_VJNZD_N2NKIWW_KJCUM_HUWEB5DB_BRM = "2JVSBoinj9C2J33VntvzYtVJNZdN2NKiwwKjcumHUWEb5DbBrm",
|
|
2143
|
+
X_CHAIN = "x-chain"
|
|
2144
|
+
}
|
|
2145
|
+
|
|
2146
|
+
declare class PrimaryNetworkService {
|
|
2147
|
+
readonly httpRequest: BaseHttpRequest;
|
|
2148
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
2149
|
+
/**
|
|
2150
|
+
* Get asset details
|
|
2151
|
+
* Gets asset details corresponding to the given asset id on the X-Chain.
|
|
2152
|
+
* @returns XChainAssetDetails
|
|
2153
|
+
* @throws ApiError
|
|
2154
|
+
*/
|
|
2155
|
+
getAssetDetails({ blockchainId, network, assetId, }: {
|
|
2156
|
+
/**
|
|
2157
|
+
* A primary network blockchain id or alias.
|
|
2158
|
+
*/
|
|
2159
|
+
blockchainId: XChainId;
|
|
2160
|
+
/**
|
|
2161
|
+
* Either mainnet or a testnet.
|
|
2162
|
+
*/
|
|
2163
|
+
network: Network;
|
|
2164
|
+
/**
|
|
2165
|
+
* Asset ID for any asset on X-Chain
|
|
2166
|
+
*/
|
|
2167
|
+
assetId: string;
|
|
2168
|
+
}): CancelablePromise<XChainAssetDetails>;
|
|
2169
|
+
/**
|
|
2170
|
+
* Get chain interactions for addresses
|
|
2171
|
+
* Returns Primary Network chains that each address has touched in the form of an address mapped array. If an address has had any on-chain interaction for a chain, that chain's chain id will be returned.
|
|
2172
|
+
* @returns ChainAddressChainIdMapListResponse
|
|
2173
|
+
* @throws ApiError
|
|
2174
|
+
*/
|
|
2175
|
+
getChainIdsForAddresses({ addresses, network, }: {
|
|
2176
|
+
/**
|
|
2177
|
+
* A comma separated list of X-Chain or P-Chain wallet addresses, starting with "avax"/"fuji", "P-avax"/"P-fuji" or "X-avax"/"X-fuji".
|
|
2178
|
+
*/
|
|
2179
|
+
addresses: string;
|
|
2180
|
+
/**
|
|
2181
|
+
* Either mainnet or a testnet.
|
|
2182
|
+
*/
|
|
2183
|
+
network: Network;
|
|
2184
|
+
}): CancelablePromise<ChainAddressChainIdMapListResponse>;
|
|
2185
|
+
/**
|
|
2186
|
+
* Get network details
|
|
2187
|
+
* Gets network details such as validator and delegator stats.
|
|
2188
|
+
* @returns GetNetworkDetailsResponse
|
|
2189
|
+
* @throws ApiError
|
|
2190
|
+
*/
|
|
2191
|
+
getNetworkDetails({ network, }: {
|
|
2192
|
+
/**
|
|
2193
|
+
* Either mainnet or a testnet.
|
|
2194
|
+
*/
|
|
2195
|
+
network: Network;
|
|
2196
|
+
}): CancelablePromise<GetNetworkDetailsResponse>;
|
|
2197
|
+
/**
|
|
2198
|
+
* List blockchains
|
|
2199
|
+
* Lists all blockchains registered on the network.
|
|
2200
|
+
* @returns ListBlockchainsResponse
|
|
2201
|
+
* @throws ApiError
|
|
2202
|
+
*/
|
|
2203
|
+
listBlockchains({ network, pageSize, pageToken, sortOrder, }: {
|
|
2204
|
+
/**
|
|
2205
|
+
* Either mainnet or a testnet.
|
|
2206
|
+
*/
|
|
2207
|
+
network: Network;
|
|
2208
|
+
/**
|
|
2209
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2210
|
+
*/
|
|
2211
|
+
pageSize?: number;
|
|
2212
|
+
/**
|
|
2213
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
2214
|
+
*/
|
|
2215
|
+
pageToken?: string;
|
|
2216
|
+
/**
|
|
2217
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
2218
|
+
*/
|
|
2219
|
+
sortOrder?: SortOrder;
|
|
2220
|
+
}): CancelablePromise<ListBlockchainsResponse>;
|
|
2221
|
+
/**
|
|
2222
|
+
* List subnets
|
|
2223
|
+
* Lists all subnets registered on the network.
|
|
2224
|
+
* @returns ListSubnetsResponse
|
|
2225
|
+
* @throws ApiError
|
|
2226
|
+
*/
|
|
2227
|
+
listSubnets({ network, pageSize, pageToken, sortOrder, }: {
|
|
2228
|
+
/**
|
|
2229
|
+
* Either mainnet or a testnet.
|
|
2230
|
+
*/
|
|
2231
|
+
network: Network;
|
|
2232
|
+
/**
|
|
2233
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2234
|
+
*/
|
|
2235
|
+
pageSize?: number;
|
|
2236
|
+
/**
|
|
2237
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
2238
|
+
*/
|
|
2239
|
+
pageToken?: string;
|
|
2240
|
+
/**
|
|
2241
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
2242
|
+
*/
|
|
2243
|
+
sortOrder?: SortOrder;
|
|
2244
|
+
}): CancelablePromise<ListSubnetsResponse>;
|
|
2245
|
+
/**
|
|
2246
|
+
* List validators
|
|
2247
|
+
* Lists details for validators. By default, returns details for all validators. Filterable by validator node ids and minimum delegation capacity.
|
|
2248
|
+
* @returns ListValidatorDetailsResponse
|
|
2249
|
+
* @throws ApiError
|
|
2250
|
+
*/
|
|
2251
|
+
listValidators({ network, pageSize, pageToken, nodeIds, sortOrder, validationStatus, minDelegationCapacity, }: {
|
|
2252
|
+
/**
|
|
2253
|
+
* Either mainnet or a testnet.
|
|
2254
|
+
*/
|
|
2255
|
+
network: Network;
|
|
2256
|
+
/**
|
|
2257
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2258
|
+
*/
|
|
2259
|
+
pageSize?: number;
|
|
2260
|
+
/**
|
|
2261
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
2262
|
+
*/
|
|
2263
|
+
pageToken?: string;
|
|
2264
|
+
/**
|
|
2265
|
+
* A comma separated list of node ids to filter by.
|
|
2266
|
+
*/
|
|
2267
|
+
nodeIds?: string;
|
|
2268
|
+
/**
|
|
2269
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
2270
|
+
*/
|
|
2271
|
+
sortOrder?: SortOrder;
|
|
2272
|
+
/**
|
|
2273
|
+
* Validation status of the node.
|
|
2274
|
+
*/
|
|
2275
|
+
validationStatus?: ValidationStatusType;
|
|
2276
|
+
/**
|
|
2277
|
+
* The minimum delegation capacity, used to filter the set of nodes being returned (Units - nAVAX). Default is 0.
|
|
2278
|
+
*/
|
|
2279
|
+
minDelegationCapacity?: any;
|
|
2280
|
+
}): CancelablePromise<ListValidatorDetailsResponse>;
|
|
2281
|
+
/**
|
|
2282
|
+
* Get single validator details
|
|
2283
|
+
* List validator details for a single validator. Filterable by validation status.
|
|
2284
|
+
* @returns ListValidatorDetailsResponse
|
|
2285
|
+
* @throws ApiError
|
|
2286
|
+
*/
|
|
2287
|
+
getSingleValidatorDetails({ network, nodeId, pageSize, pageToken, sortOrder, validationStatus, }: {
|
|
2288
|
+
/**
|
|
2289
|
+
* Either mainnet or a testnet.
|
|
2290
|
+
*/
|
|
2291
|
+
network: Network;
|
|
2292
|
+
/**
|
|
2293
|
+
* A primary network (P or X chain) nodeId.
|
|
2294
|
+
*/
|
|
2295
|
+
nodeId: string;
|
|
2296
|
+
/**
|
|
2297
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2298
|
+
*/
|
|
2299
|
+
pageSize?: number;
|
|
2300
|
+
/**
|
|
2301
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
2302
|
+
*/
|
|
2303
|
+
pageToken?: string;
|
|
2304
|
+
/**
|
|
2305
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
2306
|
+
*/
|
|
2307
|
+
sortOrder?: SortOrder;
|
|
2308
|
+
/**
|
|
2309
|
+
* Validation status of the node.
|
|
2310
|
+
*/
|
|
2311
|
+
validationStatus?: ValidationStatusType;
|
|
2312
|
+
}): CancelablePromise<ListValidatorDetailsResponse>;
|
|
2313
|
+
/**
|
|
2314
|
+
* List delegators
|
|
2315
|
+
* Lists details for delegators.
|
|
2316
|
+
* @returns ListDelegatorDetailsResponse
|
|
2317
|
+
* @throws ApiError
|
|
2318
|
+
*/
|
|
2319
|
+
listDelegators({ network, pageSize, pageToken, sortOrder, delegationStatus, rewardAddresses, nodeIds, }: {
|
|
2320
|
+
/**
|
|
2321
|
+
* Either mainnet or a testnet.
|
|
2322
|
+
*/
|
|
2323
|
+
network: Network;
|
|
2324
|
+
/**
|
|
2325
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2326
|
+
*/
|
|
2327
|
+
pageSize?: number;
|
|
2328
|
+
/**
|
|
2329
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
2330
|
+
*/
|
|
2331
|
+
pageToken?: string;
|
|
2332
|
+
/**
|
|
2333
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
2334
|
+
*/
|
|
2335
|
+
sortOrder?: SortOrder;
|
|
2336
|
+
/**
|
|
2337
|
+
* Delegation status of the node.
|
|
2338
|
+
*/
|
|
2339
|
+
delegationStatus?: DelegationStatusType;
|
|
2340
|
+
/**
|
|
2341
|
+
* A comma separated list of reward addresses to filter by.
|
|
2342
|
+
*/
|
|
2343
|
+
rewardAddresses?: string;
|
|
2344
|
+
/**
|
|
2345
|
+
* A comma separated list of node ids to filter by.
|
|
2346
|
+
*/
|
|
2347
|
+
nodeIds?: string;
|
|
2348
|
+
}): CancelablePromise<ListDelegatorDetailsResponse>;
|
|
2349
|
+
}
|
|
2350
|
+
|
|
2351
|
+
declare enum BlockchainId {
|
|
2352
|
+
_11111111111111111111111111111111LPO_YY = "11111111111111111111111111111111LpoYY",
|
|
2353
|
+
_2O_YMBNV4E_NHYQK2FJJ_V5N_VQLDBTM_NJZQ5S3QS3LO6FTN_C6FBY_M = "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
|
|
2354
|
+
_2JVSBOINJ9C2J33VNTVZ_YT_VJNZD_N2NKIWW_KJCUM_HUWEB5DB_BRM = "2JVSBoinj9C2J33VntvzYtVJNZdN2NKiwwKjcumHUWEb5DbBrm",
|
|
2355
|
+
_2Q9E4R6MU3U68N_U1F_YJGB_R6JVWR_RX36COHP_AX5UQXSE55X1Q5 = "2q9e4r6Mu3U68nU1fYjgbR6JvwrRx36CohpAX5UQxse55x1Q5",
|
|
2356
|
+
Y_H8D7TH_NJKXMTKUV2JG_BA4P1RN3QPR4P_PR7QYNFCDO_S6K6HWP = "yH8D7ThNJkxmtkuv2jgBa4P1Rn3Qpr4pPr7QYNfcdoS6k6HWp",
|
|
2357
|
+
P_CHAIN = "p-chain",
|
|
2358
|
+
X_CHAIN = "x-chain",
|
|
2359
|
+
C_CHAIN = "c-chain"
|
|
2360
|
+
}
|
|
2361
|
+
|
|
2362
|
+
type CChainSharedAssetBalance = {
|
|
2363
|
+
/**
|
|
2364
|
+
* Unique ID for an asset.
|
|
2365
|
+
*/
|
|
2366
|
+
assetId: string;
|
|
2367
|
+
/**
|
|
2368
|
+
* Name of this asset.
|
|
2369
|
+
*/
|
|
2370
|
+
name: string;
|
|
2371
|
+
/**
|
|
2372
|
+
* Symbol for this asset (max 4 characters).
|
|
2373
|
+
*/
|
|
2374
|
+
symbol: string;
|
|
2375
|
+
/**
|
|
2376
|
+
* Denomination of this asset to represent fungibility.
|
|
2377
|
+
*/
|
|
2378
|
+
denomination: number;
|
|
2379
|
+
/**
|
|
2380
|
+
* Type of asset like SECP256K1 or NFT.
|
|
2381
|
+
*/
|
|
2382
|
+
type: string;
|
|
2383
|
+
/**
|
|
2384
|
+
* Amount of the asset.
|
|
2385
|
+
*/
|
|
2386
|
+
amount: string;
|
|
2387
|
+
utxoCount: number;
|
|
2388
|
+
sharedWithChainId: string;
|
|
2389
|
+
};
|
|
2390
|
+
|
|
2391
|
+
type CChainAtomicBalances = {
|
|
2392
|
+
atomicMemoryUnlocked: Array<CChainSharedAssetBalance>;
|
|
2393
|
+
atomicMemoryLocked: Array<CChainSharedAssetBalance>;
|
|
2394
|
+
};
|
|
2395
|
+
|
|
2396
|
+
declare enum PrimaryNetwork {
|
|
2397
|
+
MAINNET = "mainnet",
|
|
2398
|
+
FUJI = "fuji"
|
|
2399
|
+
}
|
|
2400
|
+
|
|
2401
|
+
declare enum PrimaryNetworkChainName {
|
|
2402
|
+
P_CHAIN = "p-chain",
|
|
2403
|
+
X_CHAIN = "x-chain",
|
|
2404
|
+
C_CHAIN = "c-chain"
|
|
2405
|
+
}
|
|
2406
|
+
|
|
2407
|
+
type PrimaryNetworkChainInfo = {
|
|
2408
|
+
chainName: PrimaryNetworkChainName;
|
|
2409
|
+
network: PrimaryNetwork;
|
|
2410
|
+
};
|
|
2411
|
+
|
|
2412
|
+
type ListCChainAtomicBalancesResponse = {
|
|
2413
|
+
balances: CChainAtomicBalances;
|
|
2414
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
2415
|
+
};
|
|
2416
|
+
|
|
2417
|
+
type PChainAsset = {
|
|
2418
|
+
assetId: string;
|
|
2419
|
+
amount: string;
|
|
2420
|
+
};
|
|
2421
|
+
|
|
2422
|
+
type PChainSharedAsset = {
|
|
2423
|
+
assetId: string;
|
|
2424
|
+
amount: string;
|
|
2425
|
+
sharedWithChainId: string;
|
|
2426
|
+
status: string;
|
|
2427
|
+
};
|
|
2428
|
+
|
|
2429
|
+
type PChainBalance = {
|
|
2430
|
+
/**
|
|
2431
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of unstaked Avax that is consumable by any transaction.
|
|
2432
|
+
*/
|
|
2433
|
+
unlockedUnstaked: Array<PChainAsset>;
|
|
2434
|
+
/**
|
|
2435
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of staked Avax that is consumable by any transaction when the staking period ends.
|
|
2436
|
+
*/
|
|
2437
|
+
unlockedStaked: Array<PChainAsset>;
|
|
2438
|
+
/**
|
|
2439
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of unstaked Avax that is locked at the platform level and not consumable by any transaction at the current time.
|
|
2440
|
+
*/
|
|
2441
|
+
lockedPlatform: Array<PChainAsset>;
|
|
2442
|
+
/**
|
|
2443
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of unstaked Avax that is locked at the platform level and only consumeable for staking transactions.
|
|
2444
|
+
*/
|
|
2445
|
+
lockedStakeable: Array<PChainAsset>;
|
|
2446
|
+
/**
|
|
2447
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of staked Avax that will be locked when the staking period ends.
|
|
2448
|
+
*/
|
|
2449
|
+
lockedStaked: Array<PChainAsset>;
|
|
2450
|
+
/**
|
|
2451
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of staked Avax whose staking period has not yet started.
|
|
2452
|
+
*/
|
|
2453
|
+
pendingStaked: Array<PChainAsset>;
|
|
2454
|
+
/**
|
|
2455
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of unlocked Avax in the atomic memory between P-Chain and other chain.
|
|
2456
|
+
*/
|
|
2457
|
+
atomicMemoryUnlocked: Array<PChainSharedAsset>;
|
|
2458
|
+
/**
|
|
2459
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of locked Avax in the atomic memory between P-Chain and other chain.
|
|
2460
|
+
*/
|
|
2461
|
+
atomicMemoryLocked: Array<PChainSharedAsset>;
|
|
2462
|
+
};
|
|
2463
|
+
|
|
2464
|
+
type ListPChainBalancesResponse = {
|
|
2465
|
+
balances: PChainBalance;
|
|
2466
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
2467
|
+
};
|
|
2468
|
+
|
|
2469
|
+
type XChainAssetBalance = {
|
|
2470
|
+
/**
|
|
2471
|
+
* Unique ID for an asset.
|
|
2472
|
+
*/
|
|
2473
|
+
assetId: string;
|
|
2474
|
+
/**
|
|
2475
|
+
* Name of this asset.
|
|
2476
|
+
*/
|
|
2477
|
+
name: string;
|
|
2478
|
+
/**
|
|
2479
|
+
* Symbol for this asset (max 4 characters).
|
|
2480
|
+
*/
|
|
2481
|
+
symbol: string;
|
|
2482
|
+
/**
|
|
2483
|
+
* Denomination of this asset to represent fungibility.
|
|
2484
|
+
*/
|
|
2485
|
+
denomination: number;
|
|
2486
|
+
/**
|
|
2487
|
+
* Type of asset like SECP256K1 or NFT.
|
|
2488
|
+
*/
|
|
2489
|
+
type: string;
|
|
2490
|
+
/**
|
|
2491
|
+
* Amount of the asset.
|
|
2492
|
+
*/
|
|
2493
|
+
amount: string;
|
|
2494
|
+
utxoCount: number;
|
|
2495
|
+
};
|
|
2496
|
+
|
|
2497
|
+
type XChainSharedAssetBalance = {
|
|
2498
|
+
/**
|
|
2499
|
+
* Unique ID for an asset.
|
|
2500
|
+
*/
|
|
2501
|
+
assetId: string;
|
|
2502
|
+
/**
|
|
2503
|
+
* Name of this asset.
|
|
2504
|
+
*/
|
|
2505
|
+
name: string;
|
|
2506
|
+
/**
|
|
2507
|
+
* Symbol for this asset (max 4 characters).
|
|
2508
|
+
*/
|
|
2509
|
+
symbol: string;
|
|
2510
|
+
/**
|
|
2511
|
+
* Denomination of this asset to represent fungibility.
|
|
2512
|
+
*/
|
|
2513
|
+
denomination: number;
|
|
2514
|
+
/**
|
|
2515
|
+
* Type of asset like SECP256K1 or NFT.
|
|
2516
|
+
*/
|
|
2517
|
+
type: string;
|
|
2518
|
+
/**
|
|
2519
|
+
* Amount of the asset.
|
|
2520
|
+
*/
|
|
2521
|
+
amount: string;
|
|
2522
|
+
utxoCount: number;
|
|
2523
|
+
sharedWithChainId: string;
|
|
2524
|
+
};
|
|
2525
|
+
|
|
2526
|
+
type XChainBalances = {
|
|
2527
|
+
/**
|
|
2528
|
+
* A list of objects containing X-chain Asset balance information.
|
|
2529
|
+
*/
|
|
2530
|
+
locked: Array<XChainAssetBalance>;
|
|
2531
|
+
/**
|
|
2532
|
+
* A list of objects containing X-chain Asset balance information.
|
|
2533
|
+
*/
|
|
2534
|
+
unlocked: Array<XChainAssetBalance>;
|
|
2535
|
+
atomicMemoryUnlocked: Array<XChainSharedAssetBalance>;
|
|
2536
|
+
atomicMemoryLocked: Array<XChainSharedAssetBalance>;
|
|
2537
|
+
};
|
|
2538
|
+
|
|
2539
|
+
type ListXChainBalancesResponse = {
|
|
2540
|
+
balances: XChainBalances;
|
|
2541
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
2542
|
+
};
|
|
2543
|
+
|
|
2544
|
+
declare class PrimaryNetworkBalancesService {
|
|
2545
|
+
readonly httpRequest: BaseHttpRequest;
|
|
2546
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
2547
|
+
/**
|
|
2548
|
+
* Get balances
|
|
2549
|
+
* Gets primary network balances for one of the Primary Network chains for the supplied addresses.
|
|
2550
|
+
*
|
|
2551
|
+
* C-Chain balances returned are only the shared atomic memory balance. For EVM balance, use the `/v1/chains/:chainId/addresses/:addressId/balances:getNative` endpoint.
|
|
2552
|
+
* @returns any
|
|
2553
|
+
* @throws ApiError
|
|
2554
|
+
*/
|
|
2555
|
+
getBalancesByAddresses({ blockchainId, network, blockTimestamp, addresses, }: {
|
|
2556
|
+
/**
|
|
2557
|
+
* A primary network blockchain id or alias.
|
|
2558
|
+
*/
|
|
2559
|
+
blockchainId: BlockchainId;
|
|
2560
|
+
/**
|
|
2561
|
+
* Either mainnet or a testnet.
|
|
2562
|
+
*/
|
|
2563
|
+
network: Network;
|
|
2564
|
+
/**
|
|
2565
|
+
* An epoch timestamp in seconds. Balance will be calculated at this timestamp.
|
|
2566
|
+
*/
|
|
2567
|
+
blockTimestamp?: number;
|
|
2568
|
+
/**
|
|
2569
|
+
* A comma separated list of X-Chain or P-Chain wallet addresses, starting with "avax"/"fuji", "P-avax"/"P-fuji" or "X-avax"/"X-fuji".
|
|
2570
|
+
*/
|
|
2571
|
+
addresses?: string;
|
|
2572
|
+
}): CancelablePromise<(ListPChainBalancesResponse | ListXChainBalancesResponse | ListCChainAtomicBalancesResponse)>;
|
|
2573
|
+
}
|
|
2574
|
+
|
|
2575
|
+
type ProposerDetails = {
|
|
2576
|
+
proposerId?: string;
|
|
2577
|
+
proposerParentId?: string;
|
|
2578
|
+
proposerNodeId?: string;
|
|
2579
|
+
proposerPChainHeight?: number;
|
|
2580
|
+
proposerTimestamp?: number;
|
|
2581
|
+
};
|
|
2582
|
+
|
|
2583
|
+
type GetPrimaryNetworkBlockResponse = {
|
|
2584
|
+
blockNumber: string;
|
|
2585
|
+
blockHash: string;
|
|
2586
|
+
parentHash: string;
|
|
2587
|
+
blockTimestamp: number;
|
|
2588
|
+
blockType: string;
|
|
2589
|
+
txCount: number;
|
|
2590
|
+
transactions: Array<string>;
|
|
2591
|
+
blockSizeBytes: number;
|
|
2592
|
+
proposerDetails?: ProposerDetails;
|
|
2593
|
+
};
|
|
2594
|
+
|
|
2595
|
+
type PrimaryNetworkBlock = {
|
|
2596
|
+
blockNumber: string;
|
|
2597
|
+
blockHash: string;
|
|
2598
|
+
parentHash: string;
|
|
2599
|
+
blockTimestamp: number;
|
|
2600
|
+
blockType: string;
|
|
2601
|
+
txCount: number;
|
|
2602
|
+
transactions: Array<string>;
|
|
2603
|
+
blockSizeBytes: number;
|
|
2604
|
+
proposerDetails?: ProposerDetails;
|
|
2605
|
+
};
|
|
2606
|
+
|
|
2607
|
+
type ListPrimaryNetworkBlocksResponse = {
|
|
1764
2608
|
/**
|
|
1765
|
-
*
|
|
1766
|
-
* @returns any
|
|
1767
|
-
* @throws ApiError
|
|
2609
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
1768
2610
|
*/
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
*/
|
|
1778
|
-
address: string;
|
|
1779
|
-
/**
|
|
1780
|
-
* TokenId on the contract
|
|
1781
|
-
*/
|
|
1782
|
-
tokenId: string;
|
|
1783
|
-
}): CancelablePromise<(Erc721Token | Erc1155Token)>;
|
|
2611
|
+
nextPageToken?: string;
|
|
2612
|
+
blocks: Array<PrimaryNetworkBlock>;
|
|
2613
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
2614
|
+
};
|
|
2615
|
+
|
|
2616
|
+
declare class PrimaryNetworkBlocksService {
|
|
2617
|
+
readonly httpRequest: BaseHttpRequest;
|
|
2618
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
1784
2619
|
/**
|
|
1785
|
-
* Get
|
|
1786
|
-
*
|
|
2620
|
+
* Get block
|
|
2621
|
+
* Gets a block by block height or block hash on one of the Primary Network chains.
|
|
2622
|
+
* @returns GetPrimaryNetworkBlockResponse
|
|
1787
2623
|
* @throws ApiError
|
|
1788
2624
|
*/
|
|
1789
|
-
|
|
2625
|
+
getBlockById({ blockchainId, network, blockId, }: {
|
|
1790
2626
|
/**
|
|
1791
|
-
* A
|
|
1792
|
-
* a list of supported chain ids.
|
|
2627
|
+
* A primary network blockchain id or alias.
|
|
1793
2628
|
*/
|
|
1794
|
-
|
|
2629
|
+
blockchainId: BlockchainId;
|
|
1795
2630
|
/**
|
|
1796
|
-
*
|
|
2631
|
+
* Either mainnet or a testnet.
|
|
1797
2632
|
*/
|
|
1798
|
-
|
|
2633
|
+
network: Network;
|
|
1799
2634
|
/**
|
|
1800
|
-
*
|
|
2635
|
+
* A block identifier which is either a block number or the block hash.
|
|
1801
2636
|
*/
|
|
1802
|
-
|
|
1803
|
-
}): CancelablePromise<
|
|
2637
|
+
blockId: string;
|
|
2638
|
+
}): CancelablePromise<GetPrimaryNetworkBlockResponse>;
|
|
1804
2639
|
/**
|
|
1805
|
-
* List
|
|
1806
|
-
*
|
|
2640
|
+
* List blocks proposed by node
|
|
2641
|
+
* Lists the latest blocks proposed by a given NodeID on one of the Primary Network chains.
|
|
2642
|
+
* @returns ListPrimaryNetworkBlocksResponse
|
|
1807
2643
|
* @throws ApiError
|
|
1808
2644
|
*/
|
|
1809
|
-
|
|
2645
|
+
listPrimaryNetworkBlocksByNodeId({ blockchainId, network, nodeId, pageSize, pageToken, }: {
|
|
1810
2646
|
/**
|
|
1811
|
-
* A
|
|
1812
|
-
* a list of supported chain ids.
|
|
2647
|
+
* A primary network blockchain id or alias.
|
|
1813
2648
|
*/
|
|
1814
|
-
|
|
2649
|
+
blockchainId: BlockchainId;
|
|
1815
2650
|
/**
|
|
1816
|
-
*
|
|
2651
|
+
* Either mainnet or a testnet.
|
|
1817
2652
|
*/
|
|
1818
|
-
|
|
2653
|
+
network: Network;
|
|
1819
2654
|
/**
|
|
1820
|
-
*
|
|
2655
|
+
* A primary network (P or X chain) nodeId.
|
|
1821
2656
|
*/
|
|
1822
|
-
|
|
2657
|
+
nodeId: string;
|
|
1823
2658
|
/**
|
|
1824
|
-
* The maximum number of items to return. The minimum page size
|
|
1825
|
-
* is 1. The maximum pageSize is 100.
|
|
2659
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1826
2660
|
*/
|
|
1827
2661
|
pageSize?: number;
|
|
1828
2662
|
/**
|
|
1829
2663
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1830
2664
|
*/
|
|
1831
2665
|
pageToken?: string;
|
|
1832
|
-
|
|
1833
|
-
* Which property to sort by, in conjunction with sortOrder.
|
|
1834
|
-
*/
|
|
1835
|
-
sortBy?: ListingsSortByOption;
|
|
1836
|
-
/**
|
|
1837
|
-
* The order by which to sort results. Use "asc" for ascending
|
|
1838
|
-
* order, "desc" for descending order. Sorted by timestamp or the `sortBy`
|
|
1839
|
-
* query parameter, if provided.
|
|
1840
|
-
*/
|
|
1841
|
-
sortOrder?: SortOrder;
|
|
1842
|
-
/**
|
|
1843
|
-
* The currency that return values should use. Defaults to USD.
|
|
1844
|
-
*/
|
|
1845
|
-
currency?: CurrencyCode;
|
|
1846
|
-
/**
|
|
1847
|
-
* Determines whether to return full transaction history for listings.
|
|
1848
|
-
*/
|
|
1849
|
-
includeHistory?: boolean;
|
|
1850
|
-
}): CancelablePromise<ListListingsResponse>;
|
|
2666
|
+
}): CancelablePromise<ListPrimaryNetworkBlocksResponse>;
|
|
1851
2667
|
/**
|
|
1852
|
-
* List
|
|
1853
|
-
*
|
|
2668
|
+
* List latest blocks
|
|
2669
|
+
* Lists latest blocks on one of the Primary Network chains.
|
|
2670
|
+
* @returns ListPrimaryNetworkBlocksResponse
|
|
1854
2671
|
* @throws ApiError
|
|
1855
2672
|
*/
|
|
1856
|
-
|
|
2673
|
+
listLatestPrimaryNetworkBlocks({ blockchainId, network, pageSize, pageToken, }: {
|
|
1857
2674
|
/**
|
|
1858
|
-
* A
|
|
1859
|
-
* a list of supported chain ids.
|
|
2675
|
+
* A primary network blockchain id or alias.
|
|
1860
2676
|
*/
|
|
1861
|
-
|
|
2677
|
+
blockchainId: BlockchainId;
|
|
1862
2678
|
/**
|
|
1863
|
-
*
|
|
2679
|
+
* Either mainnet or a testnet.
|
|
1864
2680
|
*/
|
|
1865
|
-
|
|
2681
|
+
network: Network;
|
|
1866
2682
|
/**
|
|
1867
|
-
* The maximum number of items to return. The minimum page size
|
|
1868
|
-
* is 1. The maximum pageSize is 100.
|
|
2683
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1869
2684
|
*/
|
|
1870
2685
|
pageSize?: number;
|
|
1871
2686
|
/**
|
|
1872
2687
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1873
2688
|
*/
|
|
1874
2689
|
pageToken?: string;
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
2690
|
+
}): CancelablePromise<ListPrimaryNetworkBlocksResponse>;
|
|
2691
|
+
}
|
|
2692
|
+
|
|
2693
|
+
declare enum RewardType {
|
|
2694
|
+
VALIDATOR = "VALIDATOR",
|
|
2695
|
+
DELEGATOR = "DELEGATOR"
|
|
2696
|
+
}
|
|
2697
|
+
|
|
2698
|
+
type HistoricalReward = {
|
|
2699
|
+
/**
|
|
2700
|
+
* An array of P-Chain wallet addresses.
|
|
2701
|
+
*/
|
|
2702
|
+
addresses: Array<string>;
|
|
2703
|
+
txHash: string;
|
|
2704
|
+
amountStaked: string;
|
|
2705
|
+
nodeId: string;
|
|
2706
|
+
startTimestamp: number;
|
|
2707
|
+
endTimestamp: number;
|
|
2708
|
+
rewardType: RewardType;
|
|
2709
|
+
utxoId: string;
|
|
2710
|
+
outputIndex: number;
|
|
2711
|
+
/**
|
|
2712
|
+
* An object containing P-chain Asset ID and the amount of that Asset ID.
|
|
2713
|
+
*/
|
|
2714
|
+
reward: PChainAsset;
|
|
2715
|
+
rewardTxHash: string;
|
|
2716
|
+
};
|
|
2717
|
+
|
|
2718
|
+
type ListHistoricalRewardsResponse = {
|
|
2719
|
+
/**
|
|
2720
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2721
|
+
*/
|
|
2722
|
+
nextPageToken?: string;
|
|
2723
|
+
historicalRewards: Array<HistoricalReward>;
|
|
2724
|
+
};
|
|
2725
|
+
|
|
2726
|
+
type PendingReward = {
|
|
2727
|
+
/**
|
|
2728
|
+
* An array of P-Chain wallet addresses.
|
|
2729
|
+
*/
|
|
2730
|
+
addresses: Array<string>;
|
|
2731
|
+
txHash: string;
|
|
2732
|
+
amountStaked: string;
|
|
2733
|
+
nodeId: string;
|
|
2734
|
+
startTimestamp: number;
|
|
2735
|
+
endTimestamp: number;
|
|
2736
|
+
rewardType: RewardType;
|
|
2737
|
+
progress: number;
|
|
2738
|
+
/**
|
|
2739
|
+
* An object containing P-chain Asset ID and the amount of that Asset ID.
|
|
2740
|
+
*/
|
|
2741
|
+
estimatedReward: PChainAsset;
|
|
2742
|
+
};
|
|
2743
|
+
|
|
2744
|
+
type ListPendingRewardsResponse = {
|
|
2745
|
+
/**
|
|
2746
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2747
|
+
*/
|
|
2748
|
+
nextPageToken?: string;
|
|
2749
|
+
pendingRewards: Array<PendingReward>;
|
|
2750
|
+
};
|
|
2751
|
+
|
|
2752
|
+
declare class PrimaryNetworkRewardsService {
|
|
2753
|
+
readonly httpRequest: BaseHttpRequest;
|
|
2754
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
1894
2755
|
/**
|
|
1895
|
-
* List
|
|
1896
|
-
*
|
|
2756
|
+
* List pending rewards
|
|
2757
|
+
* Lists pending rewards on the Primary Network for the supplied addresses.
|
|
2758
|
+
* @returns ListPendingRewardsResponse
|
|
1897
2759
|
* @throws ApiError
|
|
1898
2760
|
*/
|
|
1899
|
-
|
|
2761
|
+
listPendingPrimaryNetworkRewards({ network, addresses, pageSize, pageToken, sortOrder, }: {
|
|
1900
2762
|
/**
|
|
1901
|
-
*
|
|
1902
|
-
* a list of supported chain ids.
|
|
2763
|
+
* Either mainnet or a testnet.
|
|
1903
2764
|
*/
|
|
1904
|
-
|
|
2765
|
+
network: Network;
|
|
2766
|
+
/**
|
|
2767
|
+
* A comma separated list of X-Chain or P-Chain wallet addresses, starting with "avax"/"fuji", "P-avax"/"P-fuji" or "X-avax"/"X-fuji".
|
|
2768
|
+
*/
|
|
2769
|
+
addresses?: string;
|
|
1905
2770
|
/**
|
|
1906
|
-
* The maximum number of items to return. The minimum page size
|
|
1907
|
-
* is 1. The maximum pageSize is 100.
|
|
2771
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1908
2772
|
*/
|
|
1909
2773
|
pageSize?: number;
|
|
1910
2774
|
/**
|
|
1911
2775
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
1912
2776
|
*/
|
|
1913
2777
|
pageToken?: string;
|
|
1914
|
-
eventType?: ListingEventType;
|
|
1915
2778
|
/**
|
|
1916
|
-
* The
|
|
2779
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
1917
2780
|
*/
|
|
1918
|
-
|
|
1919
|
-
}): CancelablePromise<
|
|
2781
|
+
sortOrder?: SortOrder;
|
|
2782
|
+
}): CancelablePromise<ListPendingRewardsResponse>;
|
|
1920
2783
|
/**
|
|
1921
|
-
* List
|
|
1922
|
-
*
|
|
2784
|
+
* List historical rewards
|
|
2785
|
+
* Lists historical rewards on the Primary Network for the supplied addresses.
|
|
2786
|
+
* @returns ListHistoricalRewardsResponse
|
|
1923
2787
|
* @throws ApiError
|
|
1924
2788
|
*/
|
|
1925
|
-
|
|
2789
|
+
listHistoricalPrimaryNetworkRewards({ network, addresses, pageSize, pageToken, sortOrder, }: {
|
|
1926
2790
|
/**
|
|
1927
|
-
*
|
|
1928
|
-
* a list of supported chain ids.
|
|
2791
|
+
* Either mainnet or a testnet.
|
|
1929
2792
|
*/
|
|
1930
|
-
|
|
2793
|
+
network: Network;
|
|
2794
|
+
/**
|
|
2795
|
+
* A comma separated list of X-Chain or P-Chain wallet addresses, starting with "avax"/"fuji", "P-avax"/"P-fuji" or "X-avax"/"X-fuji".
|
|
2796
|
+
*/
|
|
2797
|
+
addresses?: string;
|
|
1931
2798
|
/**
|
|
1932
|
-
* The maximum number of items to return. The minimum page size
|
|
1933
|
-
* is 1. The maximum pageSize is 100.
|
|
2799
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
1934
2800
|
*/
|
|
1935
2801
|
pageSize?: number;
|
|
1936
2802
|
/**
|
|
@@ -1938,142 +2804,10 @@ declare class EvmService {
|
|
|
1938
2804
|
*/
|
|
1939
2805
|
pageToken?: string;
|
|
1940
2806
|
/**
|
|
1941
|
-
* The
|
|
1942
|
-
*/
|
|
1943
|
-
timeframe?: TrendingTimeframe;
|
|
1944
|
-
/**
|
|
1945
|
-
* Which property to sort by, in conjunction with sortOrder.
|
|
1946
|
-
*/
|
|
1947
|
-
sortBy?: CollectionSortByOption;
|
|
1948
|
-
/**
|
|
1949
|
-
* The order by which to sort results. Use "asc" for ascending
|
|
1950
|
-
* order, "desc" for descending order. Sorted by timestamp or the `sortBy`
|
|
1951
|
-
* query parameter, if provided.
|
|
2807
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
1952
2808
|
*/
|
|
1953
2809
|
sortOrder?: SortOrder;
|
|
1954
|
-
}): CancelablePromise<
|
|
1955
|
-
/**
|
|
1956
|
-
* Search for token by name and contract name.
|
|
1957
|
-
* @returns any
|
|
1958
|
-
* @throws ApiError
|
|
1959
|
-
*/
|
|
1960
|
-
search({ chainId, requestBody, }: {
|
|
1961
|
-
/**
|
|
1962
|
-
* A supported evm chain id. Use the `/chains` endpoint to get
|
|
1963
|
-
* a list of supported chain ids.
|
|
1964
|
-
*/
|
|
1965
|
-
chainId: string;
|
|
1966
|
-
requestBody: NftSearchBody;
|
|
1967
|
-
}): CancelablePromise<{
|
|
1968
|
-
results?: Array<NftCollection>;
|
|
1969
|
-
}>;
|
|
1970
|
-
}
|
|
1971
|
-
|
|
1972
|
-
declare class HealthCheckService {
|
|
1973
|
-
readonly httpRequest: BaseHttpRequest;
|
|
1974
|
-
constructor(httpRequest: BaseHttpRequest);
|
|
1975
|
-
/**
|
|
1976
|
-
* Get the health of the service.
|
|
1977
|
-
* @returns any The Health Check is successful
|
|
1978
|
-
* @throws ApiError
|
|
1979
|
-
*/
|
|
1980
|
-
healthCheck(): CancelablePromise<{
|
|
1981
|
-
status?: string;
|
|
1982
|
-
info?: Record<string, Record<string, string>> | null;
|
|
1983
|
-
error?: Record<string, Record<string, string>> | null;
|
|
1984
|
-
details?: Record<string, Record<string, string>>;
|
|
1985
|
-
}>;
|
|
1986
|
-
}
|
|
1987
|
-
|
|
1988
|
-
type EvmNetworkOptions = {
|
|
1989
|
-
addresses: Array<string>;
|
|
1990
|
-
includeChainIds: Array<string>;
|
|
1991
|
-
};
|
|
1992
|
-
|
|
1993
|
-
type PrimaryNetworkOptions = {
|
|
1994
|
-
addresses: Array<string>;
|
|
1995
|
-
includeChains: Array<'p-chain' | 'x-chain' | 'c-chain' | '11111111111111111111111111111111LpoYY' | '2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM'>;
|
|
1996
|
-
};
|
|
1997
|
-
|
|
1998
|
-
type CreateTransactionExportRequest = {
|
|
1999
|
-
startDate: string;
|
|
2000
|
-
endDate: string;
|
|
2001
|
-
primaryNetwork?: PrimaryNetworkOptions;
|
|
2002
|
-
evmNetwork?: EvmNetworkOptions;
|
|
2003
|
-
};
|
|
2004
|
-
|
|
2005
|
-
declare enum OperationStatus {
|
|
2006
|
-
RUNNING = "RUNNING",
|
|
2007
|
-
COMPLETED = "COMPLETED",
|
|
2008
|
-
COMPLETED_WITH_WARNING = "COMPLETED_WITH_WARNING",
|
|
2009
|
-
FAILED = "FAILED"
|
|
2010
|
-
}
|
|
2011
|
-
|
|
2012
|
-
declare enum OperationStatusCode {
|
|
2013
|
-
ERR_INVALID_REQUEST = "ErrInvalidRequest",
|
|
2014
|
-
ERR_INTERNAL = "ErrInternal",
|
|
2015
|
-
WARN_TRUNCATED_EXPORT = "WarnTruncatedExport"
|
|
2016
|
-
}
|
|
2017
|
-
|
|
2018
|
-
type OperationTransactionExportMetadata = {
|
|
2019
|
-
code: OperationStatusCode;
|
|
2020
|
-
/**
|
|
2021
|
-
* File download URL. Provided only for COMPLETED operations.
|
|
2022
|
-
*/
|
|
2023
|
-
downloadUrl?: string;
|
|
2024
|
-
/**
|
|
2025
|
-
* The next date to use as the startDate in follow up requests
|
|
2026
|
-
* if a request results in a transaction history exceeding the max size and
|
|
2027
|
-
* has been reported as COMPLETED_WITH_WARNING with the warning
|
|
2028
|
-
* WarnTruncatedExport.
|
|
2029
|
-
*/
|
|
2030
|
-
nextDate?: string;
|
|
2031
|
-
};
|
|
2032
|
-
|
|
2033
|
-
declare enum OperationType {
|
|
2034
|
-
TRANSACTION_EXPORT = "TRANSACTION_EXPORT"
|
|
2035
|
-
}
|
|
2036
|
-
|
|
2037
|
-
type OperationStatusResponse = {
|
|
2038
|
-
operationId: string;
|
|
2039
|
-
operationType: OperationType;
|
|
2040
|
-
operationStatus: OperationStatus;
|
|
2041
|
-
message?: string;
|
|
2042
|
-
metadata: OperationTransactionExportMetadata;
|
|
2043
|
-
createdAtTimestamp: number;
|
|
2044
|
-
updatedAtTimestamp: number;
|
|
2045
|
-
};
|
|
2046
|
-
|
|
2047
|
-
declare class OperationsService {
|
|
2048
|
-
readonly httpRequest: BaseHttpRequest;
|
|
2049
|
-
constructor(httpRequest: BaseHttpRequest);
|
|
2050
|
-
/**
|
|
2051
|
-
* Trigger a transaction export operation with given parameters.
|
|
2052
|
-
* @returns OperationStatusResponse
|
|
2053
|
-
* @throws ApiError
|
|
2054
|
-
*/
|
|
2055
|
-
postTransactionExportJob({ requestBody, }: {
|
|
2056
|
-
requestBody: CreateTransactionExportRequest;
|
|
2057
|
-
}): CancelablePromise<OperationStatusResponse>;
|
|
2058
|
-
/**
|
|
2059
|
-
* Retrieve operation result with given operation id
|
|
2060
|
-
* @returns OperationStatusResponse
|
|
2061
|
-
* @throws ApiError
|
|
2062
|
-
*/
|
|
2063
|
-
getOperationResult({ operationId, }: {
|
|
2064
|
-
/**
|
|
2065
|
-
* UUID of given operation
|
|
2066
|
-
*/
|
|
2067
|
-
operationId: string;
|
|
2068
|
-
}): CancelablePromise<OperationStatusResponse>;
|
|
2069
|
-
}
|
|
2070
|
-
|
|
2071
|
-
declare enum BlockchainId {
|
|
2072
|
-
P_CHAIN = "p-chain",
|
|
2073
|
-
X_CHAIN = "x-chain",
|
|
2074
|
-
C_CHAIN = "c-chain",
|
|
2075
|
-
_11111111111111111111111111111111LPO_YY = "11111111111111111111111111111111LpoYY",
|
|
2076
|
-
_2O_YMBNV4E_NHYQK2FJJ_V5N_VQLDBTM_NJZQ5S3QS3LO6FTN_C6FBY_M = "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
|
|
2810
|
+
}): CancelablePromise<ListHistoricalRewardsResponse>;
|
|
2077
2811
|
}
|
|
2078
2812
|
|
|
2079
2813
|
type Asset = {
|
|
@@ -2103,6 +2837,17 @@ type Asset = {
|
|
|
2103
2837
|
amount: string;
|
|
2104
2838
|
};
|
|
2105
2839
|
|
|
2840
|
+
type UtxoCredential = {
|
|
2841
|
+
/**
|
|
2842
|
+
* Signature provided to consume the output
|
|
2843
|
+
*/
|
|
2844
|
+
signature?: string;
|
|
2845
|
+
/**
|
|
2846
|
+
* Public key associated with the signature
|
|
2847
|
+
*/
|
|
2848
|
+
publicKey?: string;
|
|
2849
|
+
};
|
|
2850
|
+
|
|
2106
2851
|
type EVMInput = {
|
|
2107
2852
|
/**
|
|
2108
2853
|
* EVM address from which the asset is exported in ExportTx.
|
|
@@ -2112,17 +2857,10 @@ type EVMInput = {
|
|
|
2112
2857
|
* Asset details for the asset being transferred.
|
|
2113
2858
|
*/
|
|
2114
2859
|
asset: Asset;
|
|
2115
|
-
};
|
|
2116
|
-
|
|
2117
|
-
type UtxoCredential = {
|
|
2118
|
-
/**
|
|
2119
|
-
* Signature provided to consume the output
|
|
2120
|
-
*/
|
|
2121
|
-
signature?: string;
|
|
2122
2860
|
/**
|
|
2123
|
-
*
|
|
2861
|
+
* Credentials that signed this transaction.
|
|
2124
2862
|
*/
|
|
2125
|
-
|
|
2863
|
+
credentials: Array<UtxoCredential>;
|
|
2126
2864
|
};
|
|
2127
2865
|
|
|
2128
2866
|
type Utxo = {
|
|
@@ -2175,10 +2913,18 @@ type Utxo = {
|
|
|
2175
2913
|
* Addresses that are eligible to sign the consumption of this output.
|
|
2176
2914
|
*/
|
|
2177
2915
|
addresses: Array<string>;
|
|
2916
|
+
/**
|
|
2917
|
+
* Hex encoded data for NFT assets
|
|
2918
|
+
*/
|
|
2919
|
+
payload?: string;
|
|
2920
|
+
/**
|
|
2921
|
+
* Index representing the minting set for the NFT mint output
|
|
2922
|
+
*/
|
|
2923
|
+
groupId?: number;
|
|
2178
2924
|
/**
|
|
2179
2925
|
* Credentials that signed the transaction to consume this utxo
|
|
2180
2926
|
*/
|
|
2181
|
-
credentials
|
|
2927
|
+
credentials?: Array<UtxoCredential>;
|
|
2182
2928
|
};
|
|
2183
2929
|
|
|
2184
2930
|
type CChainExportTransaction = {
|
|
@@ -2298,204 +3044,34 @@ declare namespace CChainImportTransaction {
|
|
|
2298
3044
|
}
|
|
2299
3045
|
}
|
|
2300
3046
|
|
|
2301
|
-
type ChainAddressChainIdMap = {
|
|
2302
|
-
address: string;
|
|
2303
|
-
blockchainIds: BlockchainId;
|
|
2304
|
-
};
|
|
2305
|
-
|
|
2306
|
-
type ChainAddressChainIdMapListResponse = {
|
|
2307
|
-
addresses: Array<ChainAddressChainIdMap>;
|
|
2308
|
-
};
|
|
2309
|
-
|
|
2310
|
-
type CChainSharedAssetBalance = {
|
|
2311
|
-
/**
|
|
2312
|
-
* Unique ID for an asset.
|
|
2313
|
-
*/
|
|
2314
|
-
assetId: string;
|
|
2315
|
-
/**
|
|
2316
|
-
* Name of this asset.
|
|
2317
|
-
*/
|
|
2318
|
-
name: string;
|
|
2319
|
-
/**
|
|
2320
|
-
* Symbol for this asset (max 4 characters).
|
|
2321
|
-
*/
|
|
2322
|
-
symbol: string;
|
|
2323
|
-
/**
|
|
2324
|
-
* Denomination of this asset to represent fungibility.
|
|
2325
|
-
*/
|
|
2326
|
-
denomination: number;
|
|
2327
|
-
/**
|
|
2328
|
-
* Type of asset like SECP256K1 or NFT.
|
|
2329
|
-
*/
|
|
2330
|
-
type: string;
|
|
2331
|
-
/**
|
|
2332
|
-
* Amount of the asset.
|
|
2333
|
-
*/
|
|
2334
|
-
amount: string;
|
|
2335
|
-
utxoCount: number;
|
|
2336
|
-
sharedWithChainId: string;
|
|
2337
|
-
};
|
|
2338
|
-
|
|
2339
|
-
type CChainAtomicBalances = {
|
|
2340
|
-
atomicMemoryUnlocked: Array<CChainSharedAssetBalance>;
|
|
2341
|
-
atomicMemoryLocked: Array<CChainSharedAssetBalance>;
|
|
2342
|
-
};
|
|
2343
|
-
|
|
2344
|
-
type ListCChainAtomicBalancesResponse = {
|
|
2345
|
-
balances: CChainAtomicBalances;
|
|
2346
|
-
};
|
|
2347
|
-
|
|
2348
3047
|
type ListCChainAtomicTransactionsResponse = {
|
|
2349
3048
|
/**
|
|
2350
3049
|
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2351
3050
|
*/
|
|
2352
3051
|
nextPageToken?: string;
|
|
2353
3052
|
transactions: Array<(CChainExportTransaction | CChainImportTransaction)>;
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of unstaked Avax that is locked at the platform level and not consumable by any transaction at the current time.
|
|
2372
|
-
*/
|
|
2373
|
-
lockedPlatform?: Array<PChainAsset>;
|
|
2374
|
-
/**
|
|
2375
|
-
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of unstaked Avax that is locked at the platform level and only consumeable for staking transactions.
|
|
2376
|
-
*/
|
|
2377
|
-
lockedStakeable?: Array<PChainAsset>;
|
|
2378
|
-
/**
|
|
2379
|
-
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of staked Avax that will be locked when the staking period ends.
|
|
2380
|
-
*/
|
|
2381
|
-
lockedStaked?: Array<PChainAsset>;
|
|
2382
|
-
/**
|
|
2383
|
-
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Denotes the amount of unstaked Avax that is locked. Sum of lockedPlatform and lockedStakeable. TO BE DEPRECATED.
|
|
2384
|
-
*/
|
|
2385
|
-
lockedUnstaked?: Array<PChainAsset>;
|
|
2386
|
-
};
|
|
2387
|
-
|
|
2388
|
-
type ListPChainBalancesResponse = {
|
|
2389
|
-
balances: PChainBalance;
|
|
2390
|
-
};
|
|
2391
|
-
|
|
2392
|
-
type PChainConsumedUtxo = {
|
|
2393
|
-
addresses: Array<string>;
|
|
2394
|
-
amount: string;
|
|
2395
|
-
assetId: string;
|
|
2396
|
-
utxoId: string;
|
|
2397
|
-
createdOnChainId: string;
|
|
2398
|
-
consumedOnChainId: string;
|
|
2399
|
-
fromTx: string;
|
|
2400
|
-
};
|
|
2401
|
-
|
|
2402
|
-
type PChainEmittedUtxo = {
|
|
2403
|
-
addresses: Array<string>;
|
|
2404
|
-
amount: string;
|
|
2405
|
-
assetId: string;
|
|
2406
|
-
utxoId: string;
|
|
2407
|
-
createdOnChainId: string;
|
|
2408
|
-
consumedOnChainId: string;
|
|
2409
|
-
staked: boolean;
|
|
2410
|
-
/**
|
|
2411
|
-
* This field is only present if the UTXO has been consumed by another transaction.
|
|
2412
|
-
*/
|
|
2413
|
-
toTx?: string;
|
|
2414
|
-
/**
|
|
2415
|
-
* This field is only present if the UTXO is a transaction reward and denotes whether the reward is for the validator or delegator.
|
|
2416
|
-
*/
|
|
2417
|
-
rewardType?: string;
|
|
2418
|
-
};
|
|
2419
|
-
|
|
2420
|
-
type PChainTransaction = {
|
|
2421
|
-
/**
|
|
2422
|
-
* A P-Chain transaction hash.
|
|
2423
|
-
*/
|
|
2424
|
-
txHash: string;
|
|
2425
|
-
txType: string;
|
|
2426
|
-
/**
|
|
2427
|
-
* The block finality timestamp.
|
|
2428
|
-
*/
|
|
2429
|
-
blockTimestamp: number;
|
|
2430
|
-
blockNumber: string;
|
|
2431
|
-
blockHash: string;
|
|
2432
|
-
/**
|
|
2433
|
-
* A list of objects containing consumed UTXO info pertaining to a given transaction.
|
|
2434
|
-
*/
|
|
2435
|
-
consumedUtxos?: Array<PChainConsumedUtxo>;
|
|
2436
|
-
/**
|
|
2437
|
-
* A list of objects containing emitted UTXO info pertaining to a given transaction.
|
|
2438
|
-
*/
|
|
2439
|
-
emittedUtxos?: Array<PChainEmittedUtxo>;
|
|
2440
|
-
/**
|
|
2441
|
-
* Source chain for an atomic transaction.
|
|
2442
|
-
*/
|
|
2443
|
-
sourceChain?: string;
|
|
2444
|
-
/**
|
|
2445
|
-
* Destination chain for an atomic transaction.
|
|
2446
|
-
*/
|
|
2447
|
-
destinationChain?: string;
|
|
2448
|
-
/**
|
|
2449
|
-
* A list of objects containing P-chain Asset ID and the amount of that Asset ID.
|
|
2450
|
-
*/
|
|
2451
|
-
value?: Array<PChainAsset>;
|
|
2452
|
-
/**
|
|
2453
|
-
* A list of objects containing P-chain Asset ID and the amount of that Asset ID.
|
|
2454
|
-
*/
|
|
2455
|
-
amountBurned?: Array<PChainAsset>;
|
|
2456
|
-
/**
|
|
2457
|
-
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Present for AddValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2458
|
-
*/
|
|
2459
|
-
amountStaked?: Array<PChainAsset>;
|
|
2460
|
-
/**
|
|
2461
|
-
* Present for AddValidatorTx, AddSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2462
|
-
*/
|
|
2463
|
-
startTimestamp?: number;
|
|
2464
|
-
/**
|
|
2465
|
-
* Present for AddValidatorTx, AddSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2466
|
-
*/
|
|
2467
|
-
endTimestamp?: number;
|
|
2468
|
-
/**
|
|
2469
|
-
* Present for AddValidatorTx, AddPermissionlessValidatorTx
|
|
2470
|
-
*/
|
|
2471
|
-
delegationFeePercent?: string;
|
|
2472
|
-
/**
|
|
2473
|
-
* Present for AddValidatorTx, AddSubnetValidatorTx, RemoveSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2474
|
-
*/
|
|
2475
|
-
nodeId?: string;
|
|
2476
|
-
/**
|
|
2477
|
-
* Present for AddValidatorTx, AddSubnetValidatorTx, RemoveSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx, CreateChainTx, CreateSubnetTx
|
|
2478
|
-
*/
|
|
2479
|
-
subnetId?: string;
|
|
2480
|
-
/**
|
|
2481
|
-
* Present for AddValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2482
|
-
*/
|
|
2483
|
-
estimatedReward?: string;
|
|
2484
|
-
rewardTx?: string;
|
|
2485
|
-
memo?: string;
|
|
2486
|
-
/**
|
|
2487
|
-
* Present for RewardValidatorTx
|
|
2488
|
-
*/
|
|
2489
|
-
stakingTxHash?: string;
|
|
2490
|
-
};
|
|
3053
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
3054
|
+
};
|
|
3055
|
+
|
|
3056
|
+
declare enum PChainTransactionType {
|
|
3057
|
+
ADD_VALIDATOR_TX = "AddValidatorTx",
|
|
3058
|
+
ADD_DELEGATOR_TX = "AddDelegatorTx",
|
|
3059
|
+
ADD_PERMISSIONLESS_VALIDATOR_TX = "AddPermissionlessValidatorTx",
|
|
3060
|
+
ADD_SUBNET_VALIDATOR_TX = "AddSubnetValidatorTx",
|
|
3061
|
+
REMOVE_SUBNET_VALIDATOR_TX = "RemoveSubnetValidatorTx",
|
|
3062
|
+
REWARD_VALIDATOR_TX = "RewardValidatorTx",
|
|
3063
|
+
CREATE_CHAIN_TX = "CreateChainTx",
|
|
3064
|
+
CREATE_SUBNET_TX = "CreateSubnetTx",
|
|
3065
|
+
IMPORT_TX = "ImportTx",
|
|
3066
|
+
EXPORT_TX = "ExportTx",
|
|
3067
|
+
ADVANCE_TIME_TX = "AdvanceTimeTx",
|
|
3068
|
+
UNKNOWN = "UNKNOWN"
|
|
3069
|
+
}
|
|
2491
3070
|
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
nextPageToken?: string;
|
|
2497
|
-
transactions: Array<PChainTransaction>;
|
|
2498
|
-
};
|
|
3071
|
+
declare enum UtxoType {
|
|
3072
|
+
STAKE = "STAKE",
|
|
3073
|
+
TRANSFER = "TRANSFER"
|
|
3074
|
+
}
|
|
2499
3075
|
|
|
2500
3076
|
type PChainUtxo = {
|
|
2501
3077
|
/**
|
|
@@ -2505,138 +3081,98 @@ type PChainUtxo = {
|
|
|
2505
3081
|
utxoId: string;
|
|
2506
3082
|
txHash: string;
|
|
2507
3083
|
outputIndex: number;
|
|
3084
|
+
blockNumber: string;
|
|
2508
3085
|
blockTimestamp: number;
|
|
2509
3086
|
consumingTxHash?: string;
|
|
2510
3087
|
consumingBlockTimestamp?: number;
|
|
3088
|
+
consumingBlockNumber?: string;
|
|
2511
3089
|
assetId: string;
|
|
2512
|
-
utxoType:
|
|
3090
|
+
utxoType: UtxoType;
|
|
2513
3091
|
amount: string;
|
|
2514
3092
|
stakeableLocktime?: number;
|
|
2515
3093
|
platformLocktime?: number;
|
|
2516
3094
|
threshold?: number;
|
|
2517
3095
|
createdOnChainId: string;
|
|
2518
3096
|
consumedOnChainId: string;
|
|
3097
|
+
staked?: boolean;
|
|
3098
|
+
utxoStartTimestamp?: number;
|
|
3099
|
+
utxoEndTimestamp?: number;
|
|
3100
|
+
rewardType?: RewardType;
|
|
2519
3101
|
};
|
|
2520
3102
|
|
|
2521
|
-
type
|
|
2522
|
-
/**
|
|
2523
|
-
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2524
|
-
*/
|
|
2525
|
-
nextPageToken?: string;
|
|
2526
|
-
utxos: Array<PChainUtxo>;
|
|
2527
|
-
};
|
|
2528
|
-
|
|
2529
|
-
type ListUtxosResponse = {
|
|
2530
|
-
/**
|
|
2531
|
-
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2532
|
-
*/
|
|
2533
|
-
nextPageToken?: string;
|
|
2534
|
-
utxos: Array<Utxo>;
|
|
2535
|
-
};
|
|
2536
|
-
|
|
2537
|
-
type XChainAssetBalance = {
|
|
2538
|
-
/**
|
|
2539
|
-
* Unique ID for an asset.
|
|
2540
|
-
*/
|
|
2541
|
-
assetId: string;
|
|
2542
|
-
/**
|
|
2543
|
-
* Name of this asset.
|
|
2544
|
-
*/
|
|
2545
|
-
name: string;
|
|
2546
|
-
/**
|
|
2547
|
-
* Symbol for this asset (max 4 characters).
|
|
2548
|
-
*/
|
|
2549
|
-
symbol: string;
|
|
2550
|
-
/**
|
|
2551
|
-
* Denomination of this asset to represent fungibility.
|
|
2552
|
-
*/
|
|
2553
|
-
denomination: number;
|
|
2554
|
-
/**
|
|
2555
|
-
* Type of asset like SECP256K1 or NFT.
|
|
2556
|
-
*/
|
|
2557
|
-
type: string;
|
|
2558
|
-
/**
|
|
2559
|
-
* Amount of the asset.
|
|
2560
|
-
*/
|
|
2561
|
-
amount: string;
|
|
2562
|
-
utxoCount: number;
|
|
2563
|
-
};
|
|
2564
|
-
|
|
2565
|
-
type XChainSharedAssetBalance = {
|
|
2566
|
-
/**
|
|
2567
|
-
* Unique ID for an asset.
|
|
2568
|
-
*/
|
|
2569
|
-
assetId: string;
|
|
3103
|
+
type PChainTransaction = {
|
|
2570
3104
|
/**
|
|
2571
|
-
*
|
|
3105
|
+
* A P-Chain transaction hash.
|
|
2572
3106
|
*/
|
|
2573
|
-
|
|
3107
|
+
txHash: string;
|
|
3108
|
+
txType: PChainTransactionType;
|
|
2574
3109
|
/**
|
|
2575
|
-
*
|
|
3110
|
+
* The block finality timestamp.
|
|
2576
3111
|
*/
|
|
2577
|
-
|
|
3112
|
+
blockTimestamp: number;
|
|
3113
|
+
blockNumber: string;
|
|
3114
|
+
blockHash: string;
|
|
3115
|
+
consumedUtxos: Array<PChainUtxo>;
|
|
3116
|
+
emittedUtxos: Array<PChainUtxo>;
|
|
2578
3117
|
/**
|
|
2579
|
-
*
|
|
3118
|
+
* Source chain for an atomic transaction.
|
|
2580
3119
|
*/
|
|
2581
|
-
|
|
3120
|
+
sourceChain?: string;
|
|
2582
3121
|
/**
|
|
2583
|
-
*
|
|
3122
|
+
* Destination chain for an atomic transaction.
|
|
2584
3123
|
*/
|
|
2585
|
-
|
|
3124
|
+
destinationChain?: string;
|
|
2586
3125
|
/**
|
|
2587
|
-
*
|
|
2588
|
-
*/
|
|
2589
|
-
|
|
2590
|
-
utxoCount: number;
|
|
2591
|
-
sharedWithChainId: string;
|
|
2592
|
-
};
|
|
2593
|
-
|
|
2594
|
-
type XChainBalances = {
|
|
3126
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID.
|
|
3127
|
+
*/
|
|
3128
|
+
value: Array<PChainAsset>;
|
|
2595
3129
|
/**
|
|
2596
|
-
* A list of objects containing
|
|
3130
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID.
|
|
2597
3131
|
*/
|
|
2598
|
-
|
|
3132
|
+
amountBurned: Array<PChainAsset>;
|
|
2599
3133
|
/**
|
|
2600
|
-
* A list of objects containing
|
|
3134
|
+
* A list of objects containing P-chain Asset ID and the amount of that Asset ID. Present for AddValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2601
3135
|
*/
|
|
2602
|
-
|
|
2603
|
-
atomicMemoryUnlocked: Array<XChainSharedAssetBalance>;
|
|
2604
|
-
atomicMemoryLocked: Array<XChainSharedAssetBalance>;
|
|
2605
|
-
};
|
|
2606
|
-
|
|
2607
|
-
type ListXChainBalancesResponse = {
|
|
2608
|
-
balances: XChainBalances;
|
|
2609
|
-
};
|
|
2610
|
-
|
|
2611
|
-
type XChainAssetDetails = {
|
|
3136
|
+
amountStaked: Array<PChainAsset>;
|
|
2612
3137
|
/**
|
|
2613
|
-
*
|
|
3138
|
+
* Present for AddValidatorTx, AddSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2614
3139
|
*/
|
|
2615
|
-
|
|
3140
|
+
startTimestamp?: number;
|
|
2616
3141
|
/**
|
|
2617
|
-
*
|
|
3142
|
+
* Present for AddValidatorTx, AddSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2618
3143
|
*/
|
|
2619
|
-
|
|
3144
|
+
endTimestamp?: number;
|
|
2620
3145
|
/**
|
|
2621
|
-
*
|
|
3146
|
+
* Present for AddValidatorTx, AddPermissionlessValidatorTx
|
|
2622
3147
|
*/
|
|
2623
|
-
|
|
3148
|
+
delegationFeePercent?: string;
|
|
2624
3149
|
/**
|
|
2625
|
-
*
|
|
3150
|
+
* Present for AddValidatorTx, AddSubnetValidatorTx, RemoveSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2626
3151
|
*/
|
|
2627
|
-
|
|
3152
|
+
nodeId?: string;
|
|
2628
3153
|
/**
|
|
2629
|
-
*
|
|
3154
|
+
* Present for AddValidatorTx, AddSubnetValidatorTx, RemoveSubnetValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx, CreateChainTx, CreateSubnetTx
|
|
2630
3155
|
*/
|
|
2631
|
-
|
|
3156
|
+
subnetId?: string;
|
|
2632
3157
|
/**
|
|
2633
|
-
*
|
|
3158
|
+
* Present for AddValidatorTx, AddPermissionlessValidatorTx, AddDelegatorTx
|
|
2634
3159
|
*/
|
|
2635
|
-
|
|
3160
|
+
estimatedReward?: string;
|
|
3161
|
+
rewardTxHash?: string;
|
|
3162
|
+
memo?: string;
|
|
2636
3163
|
/**
|
|
2637
|
-
*
|
|
3164
|
+
* Present for RewardValidatorTx
|
|
2638
3165
|
*/
|
|
2639
|
-
|
|
3166
|
+
stakingTxHash?: string;
|
|
3167
|
+
};
|
|
3168
|
+
|
|
3169
|
+
type ListPChainTransactionsResponse = {
|
|
3170
|
+
/**
|
|
3171
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
3172
|
+
*/
|
|
3173
|
+
nextPageToken?: string;
|
|
3174
|
+
transactions: Array<PChainTransaction>;
|
|
3175
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
2640
3176
|
};
|
|
2641
3177
|
|
|
2642
3178
|
type XChainLinearTransaction = {
|
|
@@ -2645,7 +3181,7 @@ type XChainLinearTransaction = {
|
|
|
2645
3181
|
*/
|
|
2646
3182
|
txHash: string;
|
|
2647
3183
|
/**
|
|
2648
|
-
* Represents
|
|
3184
|
+
* Represents chain format this transaction is included in.
|
|
2649
3185
|
*/
|
|
2650
3186
|
chainFormat: XChainLinearTransaction.chainFormat;
|
|
2651
3187
|
/**
|
|
@@ -2693,11 +3229,11 @@ type XChainLinearTransaction = {
|
|
|
2693
3229
|
};
|
|
2694
3230
|
declare namespace XChainLinearTransaction {
|
|
2695
3231
|
/**
|
|
2696
|
-
* Represents
|
|
3232
|
+
* Represents chain format this transaction is included in.
|
|
2697
3233
|
*/
|
|
2698
3234
|
enum chainFormat {
|
|
2699
|
-
|
|
2700
|
-
|
|
3235
|
+
NON_LINEAR = "non-linear",
|
|
3236
|
+
LINEAR = "linear"
|
|
2701
3237
|
}
|
|
2702
3238
|
}
|
|
2703
3239
|
|
|
@@ -2722,7 +3258,7 @@ type XChainNonLinearTransaction = {
|
|
|
2722
3258
|
*/
|
|
2723
3259
|
txHash: string;
|
|
2724
3260
|
/**
|
|
2725
|
-
* Represents
|
|
3261
|
+
* Represents chain format this transaction is included in.
|
|
2726
3262
|
*/
|
|
2727
3263
|
chainFormat: XChainNonLinearTransaction.chainFormat;
|
|
2728
3264
|
/**
|
|
@@ -2766,11 +3302,11 @@ type XChainNonLinearTransaction = {
|
|
|
2766
3302
|
};
|
|
2767
3303
|
declare namespace XChainNonLinearTransaction {
|
|
2768
3304
|
/**
|
|
2769
|
-
* Represents
|
|
3305
|
+
* Represents chain format this transaction is included in.
|
|
2770
3306
|
*/
|
|
2771
3307
|
enum chainFormat {
|
|
2772
|
-
|
|
2773
|
-
|
|
3308
|
+
NON_LINEAR = "non-linear",
|
|
3309
|
+
LINEAR = "linear"
|
|
2774
3310
|
}
|
|
2775
3311
|
}
|
|
2776
3312
|
|
|
@@ -2780,53 +3316,44 @@ type ListXChainTransactionsResponse = {
|
|
|
2780
3316
|
*/
|
|
2781
3317
|
nextPageToken?: string;
|
|
2782
3318
|
transactions: Array<(XChainNonLinearTransaction | XChainLinearTransaction)>;
|
|
3319
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
2783
3320
|
};
|
|
2784
3321
|
|
|
2785
|
-
type XChainVertex = {
|
|
2786
|
-
vertexHash: string;
|
|
2787
|
-
parentHashes: Array<string>;
|
|
2788
|
-
vertexHeight: number;
|
|
2789
|
-
vertexIndex: number;
|
|
2790
|
-
vertexTimestamp: number;
|
|
2791
|
-
txCount: number;
|
|
2792
|
-
transactions: Array<string>;
|
|
2793
|
-
vertexSizeBytes: number;
|
|
2794
|
-
};
|
|
2795
|
-
|
|
2796
|
-
type ListXChainVerticesResponse = {
|
|
2797
|
-
/**
|
|
2798
|
-
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2799
|
-
*/
|
|
2800
|
-
nextPageToken?: string;
|
|
2801
|
-
vertices: Array<XChainVertex>;
|
|
2802
|
-
};
|
|
2803
|
-
|
|
2804
|
-
declare enum Network {
|
|
2805
|
-
MAINNET = "mainnet",
|
|
2806
|
-
FUJI = "fuji"
|
|
2807
|
-
}
|
|
2808
|
-
|
|
2809
3322
|
declare enum PChainId {
|
|
2810
|
-
|
|
2811
|
-
|
|
3323
|
+
_11111111111111111111111111111111LPO_YY = "11111111111111111111111111111111LpoYY",
|
|
3324
|
+
P_CHAIN = "p-chain"
|
|
2812
3325
|
}
|
|
2813
3326
|
|
|
2814
|
-
declare enum
|
|
2815
|
-
|
|
2816
|
-
|
|
3327
|
+
declare enum PrimaryNetworkTxType {
|
|
3328
|
+
ADD_VALIDATOR_TX = "AddValidatorTx",
|
|
3329
|
+
ADD_DELEGATOR_TX = "AddDelegatorTx",
|
|
3330
|
+
ADD_PERMISSIONLESS_VALIDATOR_TX = "AddPermissionlessValidatorTx",
|
|
3331
|
+
ADD_SUBNET_VALIDATOR_TX = "AddSubnetValidatorTx",
|
|
3332
|
+
REMOVE_SUBNET_VALIDATOR_TX = "RemoveSubnetValidatorTx",
|
|
3333
|
+
REWARD_VALIDATOR_TX = "RewardValidatorTx",
|
|
3334
|
+
CREATE_CHAIN_TX = "CreateChainTx",
|
|
3335
|
+
CREATE_SUBNET_TX = "CreateSubnetTx",
|
|
3336
|
+
IMPORT_TX = "ImportTx",
|
|
3337
|
+
EXPORT_TX = "ExportTx",
|
|
3338
|
+
ADVANCE_TIME_TX = "AdvanceTimeTx",
|
|
3339
|
+
UNKNOWN = "UNKNOWN",
|
|
3340
|
+
BASE_TX = "BaseTx",
|
|
3341
|
+
CREATE_ASSET_TX = "CreateAssetTx",
|
|
3342
|
+
OPERATION_TX = "OperationTx"
|
|
2817
3343
|
}
|
|
2818
3344
|
|
|
2819
|
-
declare class
|
|
3345
|
+
declare class PrimaryNetworkTransactionsService {
|
|
2820
3346
|
readonly httpRequest: BaseHttpRequest;
|
|
2821
3347
|
constructor(httpRequest: BaseHttpRequest);
|
|
2822
3348
|
/**
|
|
2823
|
-
*
|
|
3349
|
+
* Get transaction
|
|
3350
|
+
* Gets the details of a single transaction on one of the Primary Network chains.
|
|
2824
3351
|
* @returns any
|
|
2825
3352
|
* @throws ApiError
|
|
2826
3353
|
*/
|
|
2827
3354
|
getTxByHash({ blockchainId, network, txHash, }: {
|
|
2828
3355
|
/**
|
|
2829
|
-
* A
|
|
3356
|
+
* A primary network blockchain id or alias.
|
|
2830
3357
|
*/
|
|
2831
3358
|
blockchainId: BlockchainId;
|
|
2832
3359
|
/**
|
|
@@ -2839,13 +3366,18 @@ declare class PrimaryNetworkService {
|
|
|
2839
3366
|
txHash: string;
|
|
2840
3367
|
}): CancelablePromise<(PChainTransaction | XChainNonLinearTransaction | XChainLinearTransaction | CChainExportTransaction | CChainImportTransaction)>;
|
|
2841
3368
|
/**
|
|
2842
|
-
*
|
|
3369
|
+
* List latest transactions
|
|
3370
|
+
* Lists the latest transactions on one of the Primary Network chains.
|
|
3371
|
+
*
|
|
3372
|
+
* Transactions are filterable by addresses.
|
|
3373
|
+
*
|
|
3374
|
+
* Given that each transaction may return a large number of UTXO objects, bounded only by the maximum transaction size, the query may return less transactions than the provided page size. The result will contain less results than the page size if the number of utxos contained in the resulting transactions reach a performance threshold.
|
|
2843
3375
|
* @returns any
|
|
2844
3376
|
* @throws ApiError
|
|
2845
3377
|
*/
|
|
2846
|
-
listLatestPrimaryNetworkTransactions({ blockchainId, network, addresses, pageSize, pageToken, sortOrder, }: {
|
|
3378
|
+
listLatestPrimaryNetworkTransactions({ blockchainId, network, addresses, txTypes, startTimestamp, endTimestamp, pageSize, pageToken, sortOrder, }: {
|
|
2847
3379
|
/**
|
|
2848
|
-
* A
|
|
3380
|
+
* A primary network blockchain id or alias.
|
|
2849
3381
|
*/
|
|
2850
3382
|
blockchainId: BlockchainId;
|
|
2851
3383
|
/**
|
|
@@ -2857,8 +3389,19 @@ declare class PrimaryNetworkService {
|
|
|
2857
3389
|
*/
|
|
2858
3390
|
addresses?: string;
|
|
2859
3391
|
/**
|
|
2860
|
-
*
|
|
2861
|
-
|
|
3392
|
+
* Query param for filtering items based on transaction types.
|
|
3393
|
+
*/
|
|
3394
|
+
txTypes?: Array<PrimaryNetworkTxType>;
|
|
3395
|
+
/**
|
|
3396
|
+
* Query param for retrieving items after a specific timestamp.
|
|
3397
|
+
*/
|
|
3398
|
+
startTimestamp?: number;
|
|
3399
|
+
/**
|
|
3400
|
+
* Query param for retrieving items before a specific timestamp.
|
|
3401
|
+
*/
|
|
3402
|
+
endTimestamp?: number;
|
|
3403
|
+
/**
|
|
3404
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2862
3405
|
*/
|
|
2863
3406
|
pageSize?: number;
|
|
2864
3407
|
/**
|
|
@@ -2866,20 +3409,19 @@ declare class PrimaryNetworkService {
|
|
|
2866
3409
|
*/
|
|
2867
3410
|
pageToken?: string;
|
|
2868
3411
|
/**
|
|
2869
|
-
* The order by which to sort results. Use "asc" for ascending
|
|
2870
|
-
* order, "desc" for descending order. Sorted by timestamp or the `sortBy`
|
|
2871
|
-
* query parameter, if provided.
|
|
3412
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
2872
3413
|
*/
|
|
2873
3414
|
sortOrder?: SortOrder;
|
|
2874
3415
|
}): CancelablePromise<(ListPChainTransactionsResponse | ListXChainTransactionsResponse | ListCChainAtomicTransactionsResponse)>;
|
|
2875
3416
|
/**
|
|
2876
|
-
*
|
|
3417
|
+
* List staking transactions
|
|
3418
|
+
* Lists active staking transactions on the P-Chain for the supplied addresses.
|
|
2877
3419
|
* @returns ListPChainTransactionsResponse
|
|
2878
3420
|
* @throws ApiError
|
|
2879
3421
|
*/
|
|
2880
|
-
listActivePrimaryNetworkStakingTransactions({ blockchainId, network, addresses, pageSize, pageToken, sortOrder, }: {
|
|
3422
|
+
listActivePrimaryNetworkStakingTransactions({ blockchainId, network, addresses, txTypes, startTimestamp, endTimestamp, pageSize, pageToken, sortOrder, }: {
|
|
2881
3423
|
/**
|
|
2882
|
-
* A
|
|
3424
|
+
* A primary network blockchain id or alias.
|
|
2883
3425
|
*/
|
|
2884
3426
|
blockchainId: PChainId;
|
|
2885
3427
|
/**
|
|
@@ -2891,8 +3433,19 @@ declare class PrimaryNetworkService {
|
|
|
2891
3433
|
*/
|
|
2892
3434
|
addresses?: string;
|
|
2893
3435
|
/**
|
|
2894
|
-
*
|
|
2895
|
-
|
|
3436
|
+
* Query param for filtering items based on transaction types.
|
|
3437
|
+
*/
|
|
3438
|
+
txTypes?: Array<PrimaryNetworkTxType>;
|
|
3439
|
+
/**
|
|
3440
|
+
* Query param for retrieving items after a specific timestamp.
|
|
3441
|
+
*/
|
|
3442
|
+
startTimestamp?: number;
|
|
3443
|
+
/**
|
|
3444
|
+
* Query param for retrieving items before a specific timestamp.
|
|
3445
|
+
*/
|
|
3446
|
+
endTimestamp?: number;
|
|
3447
|
+
/**
|
|
3448
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2896
3449
|
*/
|
|
2897
3450
|
pageSize?: number;
|
|
2898
3451
|
/**
|
|
@@ -2900,96 +3453,82 @@ declare class PrimaryNetworkService {
|
|
|
2900
3453
|
*/
|
|
2901
3454
|
pageToken?: string;
|
|
2902
3455
|
/**
|
|
2903
|
-
* The order by which to sort results. Use "asc" for ascending
|
|
2904
|
-
* order, "desc" for descending order. Sorted by timestamp or the `sortBy`
|
|
2905
|
-
* query parameter, if provided.
|
|
3456
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
2906
3457
|
*/
|
|
2907
3458
|
sortOrder?: SortOrder;
|
|
2908
3459
|
}): CancelablePromise<ListPChainTransactionsResponse>;
|
|
2909
3460
|
/**
|
|
2910
|
-
*
|
|
2911
|
-
*
|
|
3461
|
+
* List asset transactions
|
|
3462
|
+
* Lists asset transactions corresponding to the given asset id on the X-Chain.
|
|
3463
|
+
* @returns ListXChainTransactionsResponse
|
|
2912
3464
|
* @throws ApiError
|
|
2913
3465
|
*/
|
|
2914
|
-
|
|
3466
|
+
listAssetTransactions({ blockchainId, network, assetId, txTypes, startTimestamp, endTimestamp, pageSize, pageToken, }: {
|
|
2915
3467
|
/**
|
|
2916
|
-
* A
|
|
3468
|
+
* A primary network blockchain id or alias.
|
|
2917
3469
|
*/
|
|
2918
|
-
blockchainId:
|
|
3470
|
+
blockchainId: XChainId;
|
|
2919
3471
|
/**
|
|
2920
3472
|
* Either mainnet or a testnet.
|
|
2921
3473
|
*/
|
|
2922
3474
|
network: Network;
|
|
2923
3475
|
/**
|
|
2924
|
-
*
|
|
2925
|
-
*/
|
|
2926
|
-
addresses?: string;
|
|
2927
|
-
/**
|
|
2928
|
-
* The maximum number of items to return. The minimum page size
|
|
2929
|
-
* is 1. The maximum pageSize is 100.
|
|
2930
|
-
*/
|
|
2931
|
-
pageSize?: number;
|
|
2932
|
-
/**
|
|
2933
|
-
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
3476
|
+
* Asset ID for any asset on X-Chain
|
|
2934
3477
|
*/
|
|
2935
|
-
|
|
3478
|
+
assetId: string;
|
|
2936
3479
|
/**
|
|
2937
|
-
*
|
|
3480
|
+
* Query param for filtering items based on transaction types.
|
|
2938
3481
|
*/
|
|
2939
|
-
|
|
3482
|
+
txTypes?: Array<PrimaryNetworkTxType>;
|
|
2940
3483
|
/**
|
|
2941
|
-
*
|
|
2942
|
-
* order, "desc" for descending order. Sorted by timestamp or the `sortBy`
|
|
2943
|
-
* query parameter, if provided.
|
|
3484
|
+
* Query param for retrieving items after a specific timestamp.
|
|
2944
3485
|
*/
|
|
2945
|
-
|
|
2946
|
-
}): CancelablePromise<(ListPChainUtxosResponse | ListUtxosResponse)>;
|
|
2947
|
-
/**
|
|
2948
|
-
* Returns balance for P-Chain, X-Chain, and C-Chain (only shared memory balance for C-Chain).
|
|
2949
|
-
* @returns any
|
|
2950
|
-
* @throws ApiError
|
|
2951
|
-
*/
|
|
2952
|
-
getBalancesByAddresses({ blockchainId, network, addresses, }: {
|
|
3486
|
+
startTimestamp?: number;
|
|
2953
3487
|
/**
|
|
2954
|
-
*
|
|
3488
|
+
* Query param for retrieving items before a specific timestamp.
|
|
2955
3489
|
*/
|
|
2956
|
-
|
|
3490
|
+
endTimestamp?: number;
|
|
2957
3491
|
/**
|
|
2958
|
-
*
|
|
3492
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
2959
3493
|
*/
|
|
2960
|
-
|
|
3494
|
+
pageSize?: number;
|
|
2961
3495
|
/**
|
|
2962
|
-
* A
|
|
3496
|
+
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
2963
3497
|
*/
|
|
2964
|
-
|
|
2965
|
-
}): CancelablePromise<
|
|
3498
|
+
pageToken?: string;
|
|
3499
|
+
}): CancelablePromise<ListXChainTransactionsResponse>;
|
|
3500
|
+
}
|
|
3501
|
+
|
|
3502
|
+
type ListPChainUtxosResponse = {
|
|
2966
3503
|
/**
|
|
2967
|
-
*
|
|
2968
|
-
* @returns Block
|
|
2969
|
-
* @throws ApiError
|
|
3504
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
2970
3505
|
*/
|
|
2971
|
-
|
|
2972
|
-
|
|
2973
|
-
|
|
2974
|
-
|
|
2975
|
-
|
|
2976
|
-
|
|
2977
|
-
|
|
2978
|
-
|
|
2979
|
-
|
|
2980
|
-
|
|
2981
|
-
|
|
2982
|
-
|
|
2983
|
-
|
|
2984
|
-
|
|
3506
|
+
nextPageToken?: string;
|
|
3507
|
+
utxos: Array<PChainUtxo>;
|
|
3508
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
3509
|
+
};
|
|
3510
|
+
|
|
3511
|
+
type ListUtxosResponse = {
|
|
3512
|
+
/**
|
|
3513
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
3514
|
+
*/
|
|
3515
|
+
nextPageToken?: string;
|
|
3516
|
+
utxos: Array<Utxo>;
|
|
3517
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
3518
|
+
};
|
|
3519
|
+
|
|
3520
|
+
declare class PrimaryNetworkUtxOsService {
|
|
3521
|
+
readonly httpRequest: BaseHttpRequest;
|
|
3522
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
2985
3523
|
/**
|
|
2986
|
-
*
|
|
2987
|
-
*
|
|
3524
|
+
* List UTXOs
|
|
3525
|
+
* Lists UTXOs on one of the Primary Network chains for the supplied addresses.
|
|
3526
|
+
* @returns any
|
|
2988
3527
|
* @throws ApiError
|
|
2989
3528
|
*/
|
|
2990
|
-
|
|
3529
|
+
getUtxosByAddresses({ blockchainId, network, addresses, pageSize, pageToken, assetId, includeSpent, sortOrder, }: {
|
|
2991
3530
|
/**
|
|
2992
|
-
* A
|
|
3531
|
+
* A primary network blockchain id or alias.
|
|
2993
3532
|
*/
|
|
2994
3533
|
blockchainId: BlockchainId;
|
|
2995
3534
|
/**
|
|
@@ -2997,51 +3536,64 @@ declare class PrimaryNetworkService {
|
|
|
2997
3536
|
*/
|
|
2998
3537
|
network: Network;
|
|
2999
3538
|
/**
|
|
3000
|
-
* A
|
|
3539
|
+
* A comma separated list of X-Chain or P-Chain wallet addresses, starting with "avax"/"fuji", "P-avax"/"P-fuji" or "X-avax"/"X-fuji".
|
|
3001
3540
|
*/
|
|
3002
|
-
|
|
3541
|
+
addresses?: string;
|
|
3003
3542
|
/**
|
|
3004
|
-
* The maximum number of items to return. The minimum page size
|
|
3005
|
-
* is 1. The maximum pageSize is 100.
|
|
3543
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
3006
3544
|
*/
|
|
3007
3545
|
pageSize?: number;
|
|
3008
3546
|
/**
|
|
3009
3547
|
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
3010
3548
|
*/
|
|
3011
3549
|
pageToken?: string;
|
|
3012
|
-
}): CancelablePromise<ListBlocksResponse>;
|
|
3013
|
-
/**
|
|
3014
|
-
* Returns latest blocks, up to user defined limit on P-Chain, X-Chain or C-Chain.
|
|
3015
|
-
* @returns ListBlocksResponse
|
|
3016
|
-
* @throws ApiError
|
|
3017
|
-
*/
|
|
3018
|
-
listLatestPrimaryNetworkBlocks({ blockchainId, network, pageSize, pageToken, }: {
|
|
3019
3550
|
/**
|
|
3020
|
-
*
|
|
3021
|
-
*/
|
|
3022
|
-
blockchainId: BlockchainId;
|
|
3023
|
-
/**
|
|
3024
|
-
* Either mainnet or a testnet.
|
|
3551
|
+
* Asset ID for any asset (only applicable X-Chain)
|
|
3025
3552
|
*/
|
|
3026
|
-
|
|
3553
|
+
assetId?: string;
|
|
3027
3554
|
/**
|
|
3028
|
-
*
|
|
3029
|
-
* is 1. The maximum pageSize is 100.
|
|
3555
|
+
* Boolean filter to include spent UTXOs.
|
|
3030
3556
|
*/
|
|
3031
|
-
|
|
3557
|
+
includeSpent?: boolean;
|
|
3032
3558
|
/**
|
|
3033
|
-
*
|
|
3559
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
3034
3560
|
*/
|
|
3035
|
-
|
|
3036
|
-
}): CancelablePromise<
|
|
3561
|
+
sortOrder?: SortOrder;
|
|
3562
|
+
}): CancelablePromise<(ListPChainUtxosResponse | ListUtxosResponse)>;
|
|
3563
|
+
}
|
|
3564
|
+
|
|
3565
|
+
type XChainVertex = {
|
|
3566
|
+
vertexHash: string;
|
|
3567
|
+
parentHashes: Array<string>;
|
|
3568
|
+
vertexHeight: number;
|
|
3569
|
+
vertexIndex: number;
|
|
3570
|
+
vertexTimestamp: number;
|
|
3571
|
+
txCount: number;
|
|
3572
|
+
transactions: Array<string>;
|
|
3573
|
+
vertexSizeBytes: number;
|
|
3574
|
+
};
|
|
3575
|
+
|
|
3576
|
+
type ListXChainVerticesResponse = {
|
|
3577
|
+
/**
|
|
3578
|
+
* A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
|
|
3579
|
+
*/
|
|
3580
|
+
nextPageToken?: string;
|
|
3581
|
+
vertices: Array<XChainVertex>;
|
|
3582
|
+
chainInfo: PrimaryNetworkChainInfo;
|
|
3583
|
+
};
|
|
3584
|
+
|
|
3585
|
+
declare class PrimaryNetworkVerticesService {
|
|
3586
|
+
readonly httpRequest: BaseHttpRequest;
|
|
3587
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
3037
3588
|
/**
|
|
3038
|
-
*
|
|
3589
|
+
* List vertices
|
|
3590
|
+
* Lists latest vertices on the X-Chain.
|
|
3039
3591
|
* @returns ListXChainVerticesResponse
|
|
3040
3592
|
* @throws ApiError
|
|
3041
3593
|
*/
|
|
3042
3594
|
listLatestXChainVertices({ blockchainId, network, pageSize, pageToken, }: {
|
|
3043
3595
|
/**
|
|
3044
|
-
* A
|
|
3596
|
+
* A primary network blockchain id or alias.
|
|
3045
3597
|
*/
|
|
3046
3598
|
blockchainId: XChainId;
|
|
3047
3599
|
/**
|
|
@@ -3049,8 +3601,7 @@ declare class PrimaryNetworkService {
|
|
|
3049
3601
|
*/
|
|
3050
3602
|
network: Network;
|
|
3051
3603
|
/**
|
|
3052
|
-
* The maximum number of items to return. The minimum page size
|
|
3053
|
-
* is 1. The maximum pageSize is 100.
|
|
3604
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
3054
3605
|
*/
|
|
3055
3606
|
pageSize?: number;
|
|
3056
3607
|
/**
|
|
@@ -3059,7 +3610,8 @@ declare class PrimaryNetworkService {
|
|
|
3059
3610
|
pageToken?: string;
|
|
3060
3611
|
}): CancelablePromise<ListXChainVerticesResponse>;
|
|
3061
3612
|
/**
|
|
3062
|
-
*
|
|
3613
|
+
* Get vertex
|
|
3614
|
+
* Gets a single vertex on the X-Chain.
|
|
3063
3615
|
* @returns XChainVertex
|
|
3064
3616
|
* @throws ApiError
|
|
3065
3617
|
*/
|
|
@@ -3069,7 +3621,7 @@ declare class PrimaryNetworkService {
|
|
|
3069
3621
|
*/
|
|
3070
3622
|
vertexHash: string;
|
|
3071
3623
|
/**
|
|
3072
|
-
* A
|
|
3624
|
+
* A primary network blockchain id or alias.
|
|
3073
3625
|
*/
|
|
3074
3626
|
blockchainId: XChainId;
|
|
3075
3627
|
/**
|
|
@@ -3078,7 +3630,8 @@ declare class PrimaryNetworkService {
|
|
|
3078
3630
|
network: Network;
|
|
3079
3631
|
}): CancelablePromise<XChainVertex>;
|
|
3080
3632
|
/**
|
|
3081
|
-
*
|
|
3633
|
+
* List vertices by height
|
|
3634
|
+
* Lists vertices at the given vertex height on the X-Chain.
|
|
3082
3635
|
* @returns ListXChainVerticesResponse
|
|
3083
3636
|
* @throws ApiError
|
|
3084
3637
|
*/
|
|
@@ -3088,7 +3641,7 @@ declare class PrimaryNetworkService {
|
|
|
3088
3641
|
*/
|
|
3089
3642
|
vertexHeight: number;
|
|
3090
3643
|
/**
|
|
3091
|
-
* A
|
|
3644
|
+
* A primary network blockchain id or alias.
|
|
3092
3645
|
*/
|
|
3093
3646
|
blockchainId: XChainId;
|
|
3094
3647
|
/**
|
|
@@ -3096,8 +3649,7 @@ declare class PrimaryNetworkService {
|
|
|
3096
3649
|
*/
|
|
3097
3650
|
network: Network;
|
|
3098
3651
|
/**
|
|
3099
|
-
* The maximum number of items to return. The minimum page size
|
|
3100
|
-
* is 1. The maximum pageSize is 100.
|
|
3652
|
+
* The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
|
|
3101
3653
|
*/
|
|
3102
3654
|
pageSize?: number;
|
|
3103
3655
|
/**
|
|
@@ -3105,82 +3657,28 @@ declare class PrimaryNetworkService {
|
|
|
3105
3657
|
*/
|
|
3106
3658
|
pageToken?: string;
|
|
3107
3659
|
/**
|
|
3108
|
-
* The order by which to sort results. Use "asc" for ascending
|
|
3109
|
-
* order, "desc" for descending order. Sorted by timestamp or the `sortBy`
|
|
3110
|
-
* query parameter, if provided.
|
|
3660
|
+
* The order by which to sort results. Use "asc" for ascending order, "desc" for descending order. Sorted by timestamp or the `sortBy` query parameter, if provided.
|
|
3111
3661
|
*/
|
|
3112
3662
|
sortOrder?: SortOrder;
|
|
3113
3663
|
}): CancelablePromise<ListXChainVerticesResponse>;
|
|
3114
|
-
/**
|
|
3115
|
-
* Returns asset details corresponding to the asset id on X-Chain.
|
|
3116
|
-
* @returns XChainAssetDetails
|
|
3117
|
-
* @throws ApiError
|
|
3118
|
-
*/
|
|
3119
|
-
getAssetDetails({ blockchainId, network, assetId, }: {
|
|
3120
|
-
/**
|
|
3121
|
-
* A supported chain name for X-Chain. BlockchainId values will be deprecated in a future release. Please use chain names like x-chain instead!
|
|
3122
|
-
*/
|
|
3123
|
-
blockchainId: XChainId;
|
|
3124
|
-
/**
|
|
3125
|
-
* Either mainnet or a testnet.
|
|
3126
|
-
*/
|
|
3127
|
-
network: Network;
|
|
3128
|
-
/**
|
|
3129
|
-
* Asset ID for any asset on X-Chain
|
|
3130
|
-
*/
|
|
3131
|
-
assetId: string;
|
|
3132
|
-
}): CancelablePromise<XChainAssetDetails>;
|
|
3133
|
-
/**
|
|
3134
|
-
* Returns asset transactions corresponding to the asset id on X-Chain.
|
|
3135
|
-
* @returns ListXChainTransactionsResponse
|
|
3136
|
-
* @throws ApiError
|
|
3137
|
-
*/
|
|
3138
|
-
getAssetTransactions({ blockchainId, network, assetId, pageSize, pageToken, }: {
|
|
3139
|
-
/**
|
|
3140
|
-
* A supported chain name for X-Chain. BlockchainId values will be deprecated in a future release. Please use chain names like x-chain instead!
|
|
3141
|
-
*/
|
|
3142
|
-
blockchainId: XChainId;
|
|
3143
|
-
/**
|
|
3144
|
-
* Either mainnet or a testnet.
|
|
3145
|
-
*/
|
|
3146
|
-
network: Network;
|
|
3147
|
-
/**
|
|
3148
|
-
* Asset ID for any asset on X-Chain
|
|
3149
|
-
*/
|
|
3150
|
-
assetId: string;
|
|
3151
|
-
/**
|
|
3152
|
-
* The maximum number of items to return. The minimum page size
|
|
3153
|
-
* is 1. The maximum pageSize is 100.
|
|
3154
|
-
*/
|
|
3155
|
-
pageSize?: number;
|
|
3156
|
-
/**
|
|
3157
|
-
* A page token, received from a previous list call. Provide this to retrieve the subsequent page.
|
|
3158
|
-
*/
|
|
3159
|
-
pageToken?: string;
|
|
3160
|
-
}): CancelablePromise<ListXChainTransactionsResponse>;
|
|
3161
|
-
/**
|
|
3162
|
-
* Return all address-mapped chain IDs that an address has been seen on chain before.
|
|
3163
|
-
* @returns ChainAddressChainIdMapListResponse
|
|
3164
|
-
* @throws ApiError
|
|
3165
|
-
*/
|
|
3166
|
-
getChainAddresses({ addresses, network, }: {
|
|
3167
|
-
/**
|
|
3168
|
-
* A comma separated list of X-Chain or P-Chain wallet addresses, starting with "avax"/"fuji", "P-avax"/"P-fuji" or "X-avax"/"X-fuji".
|
|
3169
|
-
*/
|
|
3170
|
-
addresses: string;
|
|
3171
|
-
/**
|
|
3172
|
-
* Either mainnet or a testnet.
|
|
3173
|
-
*/
|
|
3174
|
-
network: Network;
|
|
3175
|
-
}): CancelablePromise<ChainAddressChainIdMapListResponse>;
|
|
3176
3664
|
}
|
|
3177
3665
|
|
|
3178
3666
|
type HttpRequestConstructor = new (config: OpenAPIConfig) => BaseHttpRequest;
|
|
3179
3667
|
declare class Glacier {
|
|
3180
|
-
readonly
|
|
3668
|
+
readonly evmBalances: EvmBalancesService;
|
|
3669
|
+
readonly evmBlocks: EvmBlocksService;
|
|
3670
|
+
readonly evmChains: EvmChainsService;
|
|
3671
|
+
readonly evmTransactions: EvmTransactionsService;
|
|
3181
3672
|
readonly healthCheck: HealthCheckService;
|
|
3673
|
+
readonly nfTs: NfTsService;
|
|
3182
3674
|
readonly operations: OperationsService;
|
|
3183
3675
|
readonly primaryNetwork: PrimaryNetworkService;
|
|
3676
|
+
readonly primaryNetworkBalances: PrimaryNetworkBalancesService;
|
|
3677
|
+
readonly primaryNetworkBlocks: PrimaryNetworkBlocksService;
|
|
3678
|
+
readonly primaryNetworkRewards: PrimaryNetworkRewardsService;
|
|
3679
|
+
readonly primaryNetworkTransactions: PrimaryNetworkTransactionsService;
|
|
3680
|
+
readonly primaryNetworkUtxOs: PrimaryNetworkUtxOsService;
|
|
3681
|
+
readonly primaryNetworkVertices: PrimaryNetworkVerticesService;
|
|
3184
3682
|
readonly request: BaseHttpRequest;
|
|
3185
3683
|
constructor(config?: Partial<OpenAPIConfig>, HttpRequest?: HttpRequestConstructor);
|
|
3186
3684
|
}
|
|
@@ -3202,4 +3700,4 @@ declare class ApiError extends Error {
|
|
|
3202
3700
|
constructor(request: ApiRequestOptions, response: ApiResult, message: string);
|
|
3203
3701
|
}
|
|
3204
3702
|
|
|
3205
|
-
export {
|
|
3703
|
+
export { ActiveDelegatorDetails, ActiveValidatorDetails, ApiError, Asset, BaseHttpRequest, Blockchain, BlockchainId, BlockchainIds, BlockchainInfo, CChainAtomicBalances, CChainExportTransaction, CChainImportTransaction, CChainSharedAssetBalance, CancelError, CancelablePromise, ChainAddressChainIdMap, ChainAddressChainIdMapListResponse, ChainInfo, ChainStatus, CompletedDelegatorDetails, CompletedValidatorDetails, ContractDeploymentDetails, CreateEvmTransactionExportRequest, CreatePrimaryNetworkTransactionExportRequest, CurrencyCode, DelegationStatusType, DelegatorsDetails, EVMInput, EVMOutput, Erc1155Contract, Erc1155Token, Erc1155TokenBalance, Erc1155TokenMetadata, Erc1155Transfer, Erc1155TransferDetails, Erc20Contract, Erc20Token, Erc20TokenBalance, Erc20Transfer, Erc20TransferDetails, Erc721Contract, Erc721Token, Erc721TokenBalance, Erc721TokenMetadata, Erc721Transfer, Erc721TransferDetails, EvmBalancesService, EvmBlock, EvmBlocksService, EvmChainsService, EvmNetworkOptions, EvmTransactionsService, FullNativeTransactionDetails, GetChainResponse, GetEvmBlockResponse, GetNativeBalanceResponse, GetNetworkDetailsResponse, GetPrimaryNetworkBlockResponse, GetTransactionResponse, Glacier, HealthCheckService, HistoricalReward, ImageAsset, InternalTransaction, InternalTransactionDetails, InternalTransactionOpCall, ListBlockchainsResponse, ListCChainAtomicBalancesResponse, ListCChainAtomicTransactionsResponse, ListChainsResponse, ListCollectibleBalancesResponse, ListContractsResponse, ListDelegatorDetailsResponse, ListErc1155BalancesResponse, ListErc1155TransactionsResponse, ListErc20BalancesResponse, ListErc20TransactionsResponse, ListErc721BalancesResponse, ListErc721TransactionsResponse, ListEvmBlocksResponse, ListHistoricalRewardsResponse, ListInternalTransactionsResponse, ListNativeTransactionsResponse, ListPChainBalancesResponse, ListPChainTransactionsResponse, ListPChainUtxosResponse, ListPendingRewardsResponse, ListPrimaryNetworkBlocksResponse, ListSubnetsResponse, ListTransactionDetailsResponse, ListTransfersResponse, ListUtxosResponse, ListValidatorDetailsResponse, ListXChainBalancesResponse, ListXChainTransactionsResponse, ListXChainVerticesResponse, Method, Money, NativeTokenBalance, NativeTransaction, Network, NetworkToken, NetworkTokenDetails, NetworkType, NfTsService, NftTokenMetadataStatus, OpenAPI, OpenAPIConfig, OperationStatus, OperationStatusCode, OperationStatusResponse, OperationType, OperationsService, PChainAsset, PChainBalance, PChainId, PChainSharedAsset, PChainTransaction, PChainTransactionType, PChainUtxo, PendingDelegatorDetails, PendingReward, PendingValidatorDetails, PricingProviders, PrimaryNetwork, PrimaryNetworkBalancesService, PrimaryNetworkBlock, PrimaryNetworkBlocksService, PrimaryNetworkChainInfo, PrimaryNetworkChainName, PrimaryNetworkOptions, PrimaryNetworkRewardsService, PrimaryNetworkService, PrimaryNetworkTransactionsService, PrimaryNetworkTxType, PrimaryNetworkUtxOsService, PrimaryNetworkVerticesService, ProposerDetails, ResourceLink, ResourceLinkType, RewardType, Rewards, RichAddress, SortOrder, StakingDistribution, Subnet, TransactionDetails, TransactionExportMetadata, TransactionMethodType, TransactionStatus, TransactionVertexDetail, UnknownContract, UtilityAddresses, Utxo, UtxoCredential, UtxoType, ValidationStatusType, ValidatorsDetails, VmName, XChainAssetBalance, XChainAssetDetails, XChainBalances, XChainId, XChainLinearTransaction, XChainNonLinearTransaction, XChainSharedAssetBalance, XChainVertex };
|