@avalabs/glacier-sdk 2.8.0-canary.bf2dc9b.0 → 2.8.0-canary.c4e2f70.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. package/dist/index.d.ts +241 -13
  2. package/dist/index.js +85 -2
  3. package/esm/generated/Glacier.d.ts +2 -0
  4. package/esm/generated/Glacier.js +3 -0
  5. package/esm/generated/models/AddressActivityMetadata.d.ts +4 -1
  6. package/esm/generated/models/AssetWithPriceInfo.d.ts +34 -0
  7. package/esm/generated/models/DeliveredSourceNotIndexedTeleporterMessage.d.ts +24 -0
  8. package/esm/generated/models/DeliveredSourceNotIndexedTeleporterMessage.js +8 -0
  9. package/esm/generated/models/DeliveredTeleporterMessage.d.ts +26 -0
  10. package/esm/generated/models/DeliveredTeleporterMessage.js +8 -0
  11. package/esm/generated/models/HistoricalReward.d.ts +2 -5
  12. package/esm/generated/models/ListValidatorDetailsResponse.d.ts +2 -1
  13. package/esm/generated/models/NextPageToken.d.ts +8 -0
  14. package/esm/generated/models/PendingTeleporterMessage.d.ts +24 -0
  15. package/esm/generated/models/PendingTeleporterMessage.js +8 -0
  16. package/esm/generated/models/RemovedValidatorDetails.d.ts +19 -0
  17. package/esm/generated/models/RemovedValidatorDetails.js +8 -0
  18. package/esm/generated/models/TeleporterDestinationTransaction.d.ts +9 -0
  19. package/esm/generated/models/TeleporterRewardDetails.d.ts +37 -0
  20. package/esm/generated/models/TeleporterRewardDetails.js +8 -0
  21. package/esm/generated/models/TeleporterSourceTransaction.d.ts +7 -0
  22. package/esm/generated/models/ValidationStatusType.d.ts +2 -1
  23. package/esm/generated/models/ValidationStatusType.js +1 -0
  24. package/esm/generated/services/PrimaryNetworkRewardsService.d.ts +10 -5
  25. package/esm/generated/services/PrimaryNetworkRewardsService.js +4 -2
  26. package/esm/generated/services/TeleporterService.d.ts +65 -0
  27. package/esm/generated/services/TeleporterService.js +43 -0
  28. package/esm/index.d.ts +10 -0
  29. package/esm/index.js +6 -0
  30. package/package.json +2 -2
package/dist/index.d.ts CHANGED
@@ -65,7 +65,10 @@ type AddressActivityMetadata = {
65
65
  * Ethereum address for the address_activity event type
66
66
  */
67
67
  address: string;
68
- topic0?: string;
68
+ /**
69
+ * Array of hexadecimal strings of the event signatures.
70
+ */
71
+ eventSignatures?: Array<string>;
69
72
  };
70
73
 
71
74
  declare enum EventType {
@@ -2461,6 +2464,24 @@ declare namespace PendingValidatorDetails {
2461
2464
  }
2462
2465
  }
2463
2466
 
2467
+ type RemovedValidatorDetails = {
2468
+ txHash: string;
2469
+ nodeId: string;
2470
+ subnetId: string;
2471
+ amountStaked: string;
2472
+ delegationFee?: string;
2473
+ startTimestamp: number;
2474
+ endTimestamp: number;
2475
+ removeTxHash: string;
2476
+ removeTimestamp: number;
2477
+ validationStatus: RemovedValidatorDetails.validationStatus;
2478
+ };
2479
+ declare namespace RemovedValidatorDetails {
2480
+ enum validationStatus {
2481
+ REMOVED = "removed"
2482
+ }
2483
+ }
2484
+
2464
2485
  type ListValidatorDetailsResponse = {
2465
2486
  /**
2466
2487
  * 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.
@@ -2469,7 +2490,7 @@ type ListValidatorDetailsResponse = {
2469
2490
  /**
2470
2491
  * The list of validator Details.
2471
2492
  */
2472
- validators: Array<(CompletedValidatorDetails | ActiveValidatorDetails | PendingValidatorDetails)>;
2493
+ validators: Array<(CompletedValidatorDetails | ActiveValidatorDetails | PendingValidatorDetails | RemovedValidatorDetails)>;
2473
2494
  };
2474
2495
 
2475
2496
  declare enum Network {
@@ -2480,7 +2501,8 @@ declare enum Network {
2480
2501
  declare enum ValidationStatusType {
2481
2502
  COMPLETED = "completed",
2482
2503
  ACTIVE = "active",
2483
- PENDING = "pending"
2504
+ PENDING = "pending",
2505
+ REMOVED = "removed"
2484
2506
  }
2485
2507
 
2486
2508
  type XChainAssetDetails = {
@@ -3137,6 +3159,37 @@ declare class PrimaryNetworkBlocksService {
3137
3159
  }): CancelablePromise<ListPrimaryNetworkBlocksResponse>;
3138
3160
  }
3139
3161
 
3162
+ type AssetWithPriceInfo = {
3163
+ /**
3164
+ * Unique ID for an asset.
3165
+ */
3166
+ assetId: string;
3167
+ /**
3168
+ * Name of this asset.
3169
+ */
3170
+ name: string;
3171
+ /**
3172
+ * Symbol for this asset (max 4 characters).
3173
+ */
3174
+ symbol: string;
3175
+ /**
3176
+ * Denomination of this asset to represent fungibility.
3177
+ */
3178
+ denomination: number;
3179
+ /**
3180
+ * Type of asset like SECP256K1 or NFT.
3181
+ */
3182
+ type: string;
3183
+ /**
3184
+ * Amount of the asset.
3185
+ */
3186
+ amount: string;
3187
+ /**
3188
+ * The historical asset price at the time the reward was granted, if available. Note, this is only provided if the reward occured more than 24 hours ago.
3189
+ */
3190
+ historicalPrice?: Money;
3191
+ };
3192
+
3140
3193
  declare enum RewardType {
3141
3194
  VALIDATOR = "VALIDATOR",
3142
3195
  DELEGATOR = "DELEGATOR",
@@ -3156,10 +3209,7 @@ type HistoricalReward = {
3156
3209
  rewardType: RewardType;
3157
3210
  utxoId: string;
3158
3211
  outputIndex: number;
3159
- /**
3160
- * An object containing P-chain Asset ID and the amount of that Asset ID.
3161
- */
3162
- reward: Asset;
3212
+ reward: AssetWithPriceInfo;
3163
3213
  rewardTxHash: string;
3164
3214
  };
3165
3215
 
@@ -3212,7 +3262,7 @@ declare class PrimaryNetworkRewardsService {
3212
3262
  */
3213
3263
  network: Network;
3214
3264
  /**
3215
- * 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".
3265
+ * 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". Optional, but at least one of addresses or nodeIds is required.
3216
3266
  */
3217
3267
  addresses?: string;
3218
3268
  /**
@@ -3224,7 +3274,7 @@ declare class PrimaryNetworkRewardsService {
3224
3274
  */
3225
3275
  pageToken?: string;
3226
3276
  /**
3227
- * A comma separated list of node ids to filter by.
3277
+ * A comma separated list of node ids to filter by. Optional, but at least one of addresses or nodeIds is required.
3228
3278
  */
3229
3279
  nodeIds?: string;
3230
3280
  /**
@@ -3238,13 +3288,13 @@ declare class PrimaryNetworkRewardsService {
3238
3288
  * @returns ListHistoricalRewardsResponse
3239
3289
  * @throws ApiError
3240
3290
  */
3241
- listHistoricalPrimaryNetworkRewards({ network, addresses, pageSize, pageToken, nodeIds, sortOrder, }: {
3291
+ listHistoricalPrimaryNetworkRewards({ network, addresses, pageSize, pageToken, nodeIds, sortOrder, currency, }: {
3242
3292
  /**
3243
3293
  * Either mainnet or a testnet.
3244
3294
  */
3245
3295
  network: Network;
3246
3296
  /**
3247
- * 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".
3297
+ * 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". Optional, but at least one of addresses or nodeIds is required.
3248
3298
  */
3249
3299
  addresses?: string;
3250
3300
  /**
@@ -3256,13 +3306,17 @@ declare class PrimaryNetworkRewardsService {
3256
3306
  */
3257
3307
  pageToken?: string;
3258
3308
  /**
3259
- * A comma separated list of node ids to filter by.
3309
+ * A comma separated list of node ids to filter by. Optional, but at least one of addresses or nodeIds is required.
3260
3310
  */
3261
3311
  nodeIds?: string;
3262
3312
  /**
3263
3313
  * 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.
3264
3314
  */
3265
3315
  sortOrder?: SortOrder;
3316
+ /**
3317
+ * The currency that return values should use. Defaults to USD.
3318
+ */
3319
+ currency?: CurrencyCode;
3266
3320
  }): CancelablePromise<ListHistoricalRewardsResponse>;
3267
3321
  }
3268
3322
 
@@ -4125,6 +4179,179 @@ declare class PrimaryNetworkVerticesService {
4125
4179
  }): CancelablePromise<ListXChainVerticesResponse>;
4126
4180
  }
4127
4181
 
4182
+ type TeleporterDestinationTransaction = {
4183
+ txHash: string;
4184
+ timestamp: number;
4185
+ gasSpent: string;
4186
+ rewardRedeemer: string;
4187
+ delivererAddress: string;
4188
+ };
4189
+
4190
+ type TeleporterRewardDetails = {
4191
+ /**
4192
+ * A wallet or contract address in mixed-case checksum encoding.
4193
+ */
4194
+ address: string;
4195
+ /**
4196
+ * The contract name.
4197
+ */
4198
+ name: string;
4199
+ /**
4200
+ * The contract symbol.
4201
+ */
4202
+ symbol: string;
4203
+ /**
4204
+ * The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
4205
+ */
4206
+ decimals: number;
4207
+ /**
4208
+ * The logo uri for the address.
4209
+ */
4210
+ logoUri?: string;
4211
+ ercType: TeleporterRewardDetails.ercType;
4212
+ /**
4213
+ * The token price, if available.
4214
+ */
4215
+ price?: Money;
4216
+ value: string;
4217
+ };
4218
+ declare namespace TeleporterRewardDetails {
4219
+ enum ercType {
4220
+ ERC_20 = "ERC-20"
4221
+ }
4222
+ }
4223
+
4224
+ type DeliveredSourceNotIndexedTeleporterMessage = {
4225
+ sourceBlockchainId: string;
4226
+ destinationBlockchainId: string;
4227
+ messageId: string;
4228
+ from: string;
4229
+ to: string;
4230
+ data?: string;
4231
+ messageExecuted: boolean;
4232
+ receipts: Array<string>;
4233
+ receiptDelivered: boolean;
4234
+ rewardDetails: TeleporterRewardDetails;
4235
+ destinationTransaction: TeleporterDestinationTransaction;
4236
+ status: DeliveredSourceNotIndexedTeleporterMessage.status;
4237
+ };
4238
+ declare namespace DeliveredSourceNotIndexedTeleporterMessage {
4239
+ enum status {
4240
+ DELIVERED_SOURCE_NOT_INDEXED = "delivered_source_not_indexed"
4241
+ }
4242
+ }
4243
+
4244
+ type TeleporterSourceTransaction = {
4245
+ txHash: string;
4246
+ timestamp: number;
4247
+ gasSpent: string;
4248
+ };
4249
+
4250
+ type DeliveredTeleporterMessage = {
4251
+ sourceBlockchainId: string;
4252
+ destinationBlockchainId: string;
4253
+ messageId: string;
4254
+ from: string;
4255
+ to: string;
4256
+ data?: string;
4257
+ messageExecuted: boolean;
4258
+ receipts: Array<string>;
4259
+ receiptDelivered: boolean;
4260
+ rewardDetails: TeleporterRewardDetails;
4261
+ sourceTransaction: TeleporterSourceTransaction;
4262
+ destinationTransaction: TeleporterDestinationTransaction;
4263
+ status: DeliveredTeleporterMessage.status;
4264
+ };
4265
+ declare namespace DeliveredTeleporterMessage {
4266
+ enum status {
4267
+ DELIVERED = "delivered"
4268
+ }
4269
+ }
4270
+
4271
+ type NextPageToken = {
4272
+ /**
4273
+ * 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.
4274
+ */
4275
+ nextPageToken?: string;
4276
+ };
4277
+
4278
+ type PendingTeleporterMessage = {
4279
+ sourceBlockchainId: string;
4280
+ destinationBlockchainId: string;
4281
+ messageId: string;
4282
+ from: string;
4283
+ to: string;
4284
+ data?: string;
4285
+ messageExecuted: boolean;
4286
+ receipts: Array<string>;
4287
+ receiptDelivered: boolean;
4288
+ rewardDetails: TeleporterRewardDetails;
4289
+ sourceTransaction: TeleporterSourceTransaction;
4290
+ status: PendingTeleporterMessage.status;
4291
+ };
4292
+ declare namespace PendingTeleporterMessage {
4293
+ enum status {
4294
+ PENDING = "pending"
4295
+ }
4296
+ }
4297
+
4298
+ declare class TeleporterService {
4299
+ readonly httpRequest: BaseHttpRequest;
4300
+ constructor(httpRequest: BaseHttpRequest);
4301
+ /**
4302
+ * Get a teleporter message
4303
+ * Gets a teleporter message by source chain, destination chain, and message ID.
4304
+ * @returns any
4305
+ * @throws ApiError
4306
+ */
4307
+ getTeleporterMessage({ sourceBlockchainId, destinationBlockchainId, messageId, }: {
4308
+ /**
4309
+ * The base58 encoded blockchain ID of the source chain that the teleporter message was sent from.
4310
+ */
4311
+ sourceBlockchainId: any;
4312
+ /**
4313
+ * The base58 encoded blockchain ID of the destination chain that the teleporter message was sent to.
4314
+ */
4315
+ destinationBlockchainId: any;
4316
+ /**
4317
+ * The message ID of the teleporter message.
4318
+ */
4319
+ messageId: any;
4320
+ }): CancelablePromise<(PendingTeleporterMessage | DeliveredTeleporterMessage | DeliveredSourceNotIndexedTeleporterMessage)>;
4321
+ /**
4322
+ * List teleporter messages
4323
+ * Lists teleporter messages. Ordered by timestamp in descending order.
4324
+ * @returns any
4325
+ * @throws ApiError
4326
+ */
4327
+ listTeleporterMessages({ pageSize, pageToken, sourceBlockchainId, destinationBlockchainId, to, from, }: {
4328
+ /**
4329
+ * The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
4330
+ */
4331
+ pageSize?: number;
4332
+ /**
4333
+ * A page token, received from a previous list call. Provide this to retrieve the subsequent page.
4334
+ */
4335
+ pageToken?: string;
4336
+ /**
4337
+ * The base58 encoded blockchain ID of the source chain that the teleporter message was sent from.
4338
+ */
4339
+ sourceBlockchainId?: any;
4340
+ /**
4341
+ * The base58 encoded blockchain ID of the destination chain that the teleporter message was sent to.
4342
+ */
4343
+ destinationBlockchainId?: any;
4344
+ /**
4345
+ * The address of the recipient of the teleporter message.
4346
+ */
4347
+ to?: any;
4348
+ /**
4349
+ * The address of the sender of the teleporter message.
4350
+ */
4351
+ from?: any;
4352
+ }): CancelablePromise<NextPageToken>;
4353
+ }
4354
+
4128
4355
  type HttpRequestConstructor = new (config: OpenAPIConfig) => BaseHttpRequest;
4129
4356
  declare class Glacier {
4130
4357
  readonly default: DefaultService;
@@ -4143,6 +4370,7 @@ declare class Glacier {
4143
4370
  readonly primaryNetworkTransactions: PrimaryNetworkTransactionsService;
4144
4371
  readonly primaryNetworkUtxOs: PrimaryNetworkUtxOsService;
4145
4372
  readonly primaryNetworkVertices: PrimaryNetworkVerticesService;
4373
+ readonly teleporter: TeleporterService;
4146
4374
  readonly request: BaseHttpRequest;
4147
4375
  constructor(config?: Partial<OpenAPIConfig>, HttpRequest?: HttpRequestConstructor);
4148
4376
  }
@@ -4164,4 +4392,4 @@ declare class ApiError extends Error {
4164
4392
  constructor(request: ApiRequestOptions, response: ApiResult, message: string);
4165
4393
  }
4166
4394
 
4167
- export { ActiveDelegatorDetails, ActiveValidatorDetails, AddressActivityMetadata, ApiError, Asset, BaseHttpRequest, Blockchain, BlockchainId, BlockchainIds, BlockchainInfo, CChainAtomicBalances, CChainExportTransaction, CChainImportTransaction, CChainSharedAssetBalance, CancelError, CancelablePromise, ChainAddressChainIdMap, ChainAddressChainIdMapListResponse, ChainInfo, ChainStatus, CompletedDelegatorDetails, CompletedValidatorDetails, ContractDeploymentDetails, ContractSubmissionBody, ContractSubmissionErc1155, ContractSubmissionErc20, ContractSubmissionErc721, ContractSubmissionUnknown, CreateEvmTransactionExportRequest, CreatePrimaryNetworkTransactionExportRequest, CurrencyCode, DefaultService, DelegationStatusType, DelegatorsDetails, EVMInput, EVMOutput, Erc1155Contract, Erc1155Token, Erc1155TokenBalance, Erc1155TokenMetadata, Erc1155Transfer, Erc1155TransferDetails, Erc20Contract, Erc20Token, Erc20TokenBalance, Erc20Transfer, Erc20TransferDetails, Erc721Contract, Erc721Token, Erc721TokenBalance, Erc721TokenMetadata, Erc721Transfer, Erc721TransferDetails, EventType, EvmBalancesService, EvmBlock, EvmBlocksService, EvmChainsService, EvmContractsService, 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, ListNftTokens, ListPChainBalancesResponse, ListPChainTransactionsResponse, ListPChainUtxosResponse, ListPendingRewardsResponse, ListPrimaryNetworkBlocksResponse, ListSubnetsResponse, ListTransactionDetailsResponse, ListTransfersResponse, ListUtxosResponse, ListValidatorDetailsResponse, ListWebhooksResponse, ListXChainBalancesResponse, ListXChainTransactionsResponse, ListXChainVerticesResponse, Method, Money, NativeTokenBalance, NativeTransaction, Network, NetworkToken, NetworkTokenDetails, NetworkType, NfTsService, NftTokenMetadataStatus, OpenAPI, OpenAPIConfig, OperationStatus, OperationStatusCode, OperationStatusResponse, OperationType, OperationsService, PChainBalance, PChainId, PChainSharedAsset, PChainTransaction, PChainTransactionType, PChainUtxo, PendingDelegatorDetails, PendingReward, PendingValidatorDetails, PricingProviders, PrimaryNetwork, PrimaryNetworkBalancesService, PrimaryNetworkBlock, PrimaryNetworkBlocksService, PrimaryNetworkChainInfo, PrimaryNetworkChainName, PrimaryNetworkOptions, PrimaryNetworkRewardsService, PrimaryNetworkService, PrimaryNetworkTransactionsService, PrimaryNetworkTxType, PrimaryNetworkUtxOsService, PrimaryNetworkVerticesService, ProposerDetails, RegisterWebhookRequest, ResourceLink, ResourceLinkType, RewardType, Rewards, RichAddress, SharedSecretsResponse, SortOrder, StakingDistribution, Subnet, TransactionDetails, TransactionExportMetadata, TransactionMethodType, TransactionStatus, TransactionVertexDetail, UnknownContract, UpdateContractResponse, UtilityAddresses, Utxo, UtxoCredential, UtxoType, ValidationStatusType, ValidatorHealthDetails, ValidatorsDetails, VmName, WebhookResponse, WebhookStatus, WebhookStatusType, XChainAssetBalance, XChainAssetDetails, XChainBalances, XChainId, XChainLinearTransaction, XChainNonLinearTransaction, XChainSharedAssetBalance, XChainTransactionType, XChainVertex };
4395
+ export { ActiveDelegatorDetails, ActiveValidatorDetails, AddressActivityMetadata, ApiError, Asset, AssetWithPriceInfo, BaseHttpRequest, Blockchain, BlockchainId, BlockchainIds, BlockchainInfo, CChainAtomicBalances, CChainExportTransaction, CChainImportTransaction, CChainSharedAssetBalance, CancelError, CancelablePromise, ChainAddressChainIdMap, ChainAddressChainIdMapListResponse, ChainInfo, ChainStatus, CompletedDelegatorDetails, CompletedValidatorDetails, ContractDeploymentDetails, ContractSubmissionBody, ContractSubmissionErc1155, ContractSubmissionErc20, ContractSubmissionErc721, ContractSubmissionUnknown, CreateEvmTransactionExportRequest, CreatePrimaryNetworkTransactionExportRequest, CurrencyCode, DefaultService, DelegationStatusType, DelegatorsDetails, DeliveredSourceNotIndexedTeleporterMessage, DeliveredTeleporterMessage, EVMInput, EVMOutput, Erc1155Contract, Erc1155Token, Erc1155TokenBalance, Erc1155TokenMetadata, Erc1155Transfer, Erc1155TransferDetails, Erc20Contract, Erc20Token, Erc20TokenBalance, Erc20Transfer, Erc20TransferDetails, Erc721Contract, Erc721Token, Erc721TokenBalance, Erc721TokenMetadata, Erc721Transfer, Erc721TransferDetails, EventType, EvmBalancesService, EvmBlock, EvmBlocksService, EvmChainsService, EvmContractsService, 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, ListNftTokens, ListPChainBalancesResponse, ListPChainTransactionsResponse, ListPChainUtxosResponse, ListPendingRewardsResponse, ListPrimaryNetworkBlocksResponse, ListSubnetsResponse, ListTransactionDetailsResponse, ListTransfersResponse, ListUtxosResponse, ListValidatorDetailsResponse, ListWebhooksResponse, ListXChainBalancesResponse, ListXChainTransactionsResponse, ListXChainVerticesResponse, Method, Money, NativeTokenBalance, NativeTransaction, Network, NetworkToken, NetworkTokenDetails, NetworkType, NextPageToken, NfTsService, NftTokenMetadataStatus, OpenAPI, OpenAPIConfig, OperationStatus, OperationStatusCode, OperationStatusResponse, OperationType, OperationsService, PChainBalance, PChainId, PChainSharedAsset, PChainTransaction, PChainTransactionType, PChainUtxo, PendingDelegatorDetails, PendingReward, PendingTeleporterMessage, PendingValidatorDetails, PricingProviders, PrimaryNetwork, PrimaryNetworkBalancesService, PrimaryNetworkBlock, PrimaryNetworkBlocksService, PrimaryNetworkChainInfo, PrimaryNetworkChainName, PrimaryNetworkOptions, PrimaryNetworkRewardsService, PrimaryNetworkService, PrimaryNetworkTransactionsService, PrimaryNetworkTxType, PrimaryNetworkUtxOsService, PrimaryNetworkVerticesService, ProposerDetails, RegisterWebhookRequest, RemovedValidatorDetails, ResourceLink, ResourceLinkType, RewardType, Rewards, RichAddress, SharedSecretsResponse, SortOrder, StakingDistribution, Subnet, TeleporterDestinationTransaction, TeleporterRewardDetails, TeleporterService, TeleporterSourceTransaction, TransactionDetails, TransactionExportMetadata, TransactionMethodType, TransactionStatus, TransactionVertexDetail, UnknownContract, UpdateContractResponse, UtilityAddresses, Utxo, UtxoCredential, UtxoType, ValidationStatusType, ValidatorHealthDetails, ValidatorsDetails, VmName, WebhookResponse, WebhookStatus, WebhookStatusType, XChainAssetBalance, XChainAssetDetails, XChainBalances, XChainId, XChainLinearTransaction, XChainNonLinearTransaction, XChainSharedAssetBalance, XChainTransactionType, XChainVertex };
package/dist/index.js CHANGED
@@ -1249,7 +1249,8 @@ class PrimaryNetworkRewardsService {
1249
1249
  pageSize = 10,
1250
1250
  pageToken,
1251
1251
  nodeIds,
1252
- sortOrder
1252
+ sortOrder,
1253
+ currency
1253
1254
  }) {
1254
1255
  return this.httpRequest.request({
1255
1256
  method: "GET",
@@ -1262,7 +1263,8 @@ class PrimaryNetworkRewardsService {
1262
1263
  "pageSize": pageSize,
1263
1264
  "pageToken": pageToken,
1264
1265
  "nodeIds": nodeIds,
1265
- "sortOrder": sortOrder
1266
+ "sortOrder": sortOrder,
1267
+ "currency": currency
1266
1268
  }
1267
1269
  });
1268
1270
  }
@@ -1470,6 +1472,48 @@ class PrimaryNetworkVerticesService {
1470
1472
  }
1471
1473
  }
1472
1474
 
1475
+ class TeleporterService {
1476
+ constructor(httpRequest) {
1477
+ this.httpRequest = httpRequest;
1478
+ }
1479
+ getTeleporterMessage({
1480
+ sourceBlockchainId,
1481
+ destinationBlockchainId,
1482
+ messageId
1483
+ }) {
1484
+ return this.httpRequest.request({
1485
+ method: "GET",
1486
+ url: "/v1/teleporter/messages:getMessage",
1487
+ query: {
1488
+ "sourceBlockchainId": sourceBlockchainId,
1489
+ "destinationBlockchainId": destinationBlockchainId,
1490
+ "messageId": messageId
1491
+ }
1492
+ });
1493
+ }
1494
+ listTeleporterMessages({
1495
+ pageSize = 10,
1496
+ pageToken,
1497
+ sourceBlockchainId,
1498
+ destinationBlockchainId,
1499
+ to,
1500
+ from
1501
+ }) {
1502
+ return this.httpRequest.request({
1503
+ method: "GET",
1504
+ url: "/v1/teleporter/messages",
1505
+ query: {
1506
+ "pageSize": pageSize,
1507
+ "pageToken": pageToken,
1508
+ "sourceBlockchainId": sourceBlockchainId,
1509
+ "destinationBlockchainId": destinationBlockchainId,
1510
+ "to": to,
1511
+ "from": from
1512
+ }
1513
+ });
1514
+ }
1515
+ }
1516
+
1473
1517
  class Glacier {
1474
1518
  default;
1475
1519
  evmBalances;
@@ -1487,6 +1531,7 @@ class Glacier {
1487
1531
  primaryNetworkTransactions;
1488
1532
  primaryNetworkUtxOs;
1489
1533
  primaryNetworkVertices;
1534
+ teleporter;
1490
1535
  request;
1491
1536
  constructor(config, HttpRequest = FetchHttpRequest) {
1492
1537
  this.request = new HttpRequest({
@@ -1516,6 +1561,7 @@ class Glacier {
1516
1561
  this.primaryNetworkTransactions = new PrimaryNetworkTransactionsService(this.request);
1517
1562
  this.primaryNetworkUtxOs = new PrimaryNetworkUtxOsService(this.request);
1518
1563
  this.primaryNetworkVertices = new PrimaryNetworkVerticesService(this.request);
1564
+ this.teleporter = new TeleporterService(this.request);
1519
1565
  }
1520
1566
  }
1521
1567
 
@@ -1667,6 +1713,20 @@ var DelegationStatusType = /* @__PURE__ */ ((DelegationStatusType2) => {
1667
1713
  return DelegationStatusType2;
1668
1714
  })(DelegationStatusType || {});
1669
1715
 
1716
+ exports.DeliveredSourceNotIndexedTeleporterMessage = void 0;
1717
+ ((DeliveredSourceNotIndexedTeleporterMessage2) => {
1718
+ ((status2) => {
1719
+ status2["DELIVERED_SOURCE_NOT_INDEXED"] = "delivered_source_not_indexed";
1720
+ })(DeliveredSourceNotIndexedTeleporterMessage2.status || (DeliveredSourceNotIndexedTeleporterMessage2.status = {}));
1721
+ })(exports.DeliveredSourceNotIndexedTeleporterMessage || (exports.DeliveredSourceNotIndexedTeleporterMessage = {}));
1722
+
1723
+ exports.DeliveredTeleporterMessage = void 0;
1724
+ ((DeliveredTeleporterMessage2) => {
1725
+ ((status2) => {
1726
+ status2["DELIVERED"] = "delivered";
1727
+ })(DeliveredTeleporterMessage2.status || (DeliveredTeleporterMessage2.status = {}));
1728
+ })(exports.DeliveredTeleporterMessage || (exports.DeliveredTeleporterMessage = {}));
1729
+
1670
1730
  exports.Erc1155Contract = void 0;
1671
1731
  ((Erc1155Contract2) => {
1672
1732
  ((ercType2) => {
@@ -1825,6 +1885,13 @@ exports.PendingDelegatorDetails = void 0;
1825
1885
  })(PendingDelegatorDetails2.delegationStatus || (PendingDelegatorDetails2.delegationStatus = {}));
1826
1886
  })(exports.PendingDelegatorDetails || (exports.PendingDelegatorDetails = {}));
1827
1887
 
1888
+ exports.PendingTeleporterMessage = void 0;
1889
+ ((PendingTeleporterMessage2) => {
1890
+ ((status2) => {
1891
+ status2["PENDING"] = "pending";
1892
+ })(PendingTeleporterMessage2.status || (PendingTeleporterMessage2.status = {}));
1893
+ })(exports.PendingTeleporterMessage || (exports.PendingTeleporterMessage = {}));
1894
+
1828
1895
  exports.PendingValidatorDetails = void 0;
1829
1896
  ((PendingValidatorDetails2) => {
1830
1897
  ((validationStatus2) => {
@@ -1866,6 +1933,13 @@ var PrimaryNetworkTxType = /* @__PURE__ */ ((PrimaryNetworkTxType2) => {
1866
1933
  return PrimaryNetworkTxType2;
1867
1934
  })(PrimaryNetworkTxType || {});
1868
1935
 
1936
+ exports.RemovedValidatorDetails = void 0;
1937
+ ((RemovedValidatorDetails2) => {
1938
+ ((validationStatus2) => {
1939
+ validationStatus2["REMOVED"] = "removed";
1940
+ })(RemovedValidatorDetails2.validationStatus || (RemovedValidatorDetails2.validationStatus = {}));
1941
+ })(exports.RemovedValidatorDetails || (exports.RemovedValidatorDetails = {}));
1942
+
1869
1943
  var ResourceLinkType = /* @__PURE__ */ ((ResourceLinkType2) => {
1870
1944
  ResourceLinkType2["BLOG"] = "Blog";
1871
1945
  ResourceLinkType2["COIN_GECKO"] = "CoinGecko";
@@ -1901,6 +1975,13 @@ var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
1901
1975
  return SortOrder2;
1902
1976
  })(SortOrder || {});
1903
1977
 
1978
+ exports.TeleporterRewardDetails = void 0;
1979
+ ((TeleporterRewardDetails2) => {
1980
+ ((ercType2) => {
1981
+ ercType2["ERC_20"] = "ERC-20";
1982
+ })(TeleporterRewardDetails2.ercType || (TeleporterRewardDetails2.ercType = {}));
1983
+ })(exports.TeleporterRewardDetails || (exports.TeleporterRewardDetails = {}));
1984
+
1904
1985
  var TransactionMethodType = /* @__PURE__ */ ((TransactionMethodType2) => {
1905
1986
  TransactionMethodType2["NATIVE_TRANSFER"] = "NATIVE_TRANSFER";
1906
1987
  TransactionMethodType2["CONTRACT_CALL"] = "CONTRACT_CALL";
@@ -1931,6 +2012,7 @@ var ValidationStatusType = /* @__PURE__ */ ((ValidationStatusType2) => {
1931
2012
  ValidationStatusType2["COMPLETED"] = "completed";
1932
2013
  ValidationStatusType2["ACTIVE"] = "active";
1933
2014
  ValidationStatusType2["PENDING"] = "pending";
2015
+ ValidationStatusType2["REMOVED"] = "removed";
1934
2016
  return ValidationStatusType2;
1935
2017
  })(ValidationStatusType || {});
1936
2018
 
@@ -2029,6 +2111,7 @@ exports.PrimaryNetworkVerticesService = PrimaryNetworkVerticesService;
2029
2111
  exports.ResourceLinkType = ResourceLinkType;
2030
2112
  exports.RewardType = RewardType;
2031
2113
  exports.SortOrder = SortOrder;
2114
+ exports.TeleporterService = TeleporterService;
2032
2115
  exports.TransactionMethodType = TransactionMethodType;
2033
2116
  exports.TransactionStatus = TransactionStatus;
2034
2117
  exports.UtxoType = UtxoType;
@@ -16,6 +16,7 @@ import { PrimaryNetworkRewardsService } from './services/PrimaryNetworkRewardsSe
16
16
  import { PrimaryNetworkTransactionsService } from './services/PrimaryNetworkTransactionsService.js';
17
17
  import { PrimaryNetworkUtxOsService } from './services/PrimaryNetworkUtxOsService.js';
18
18
  import { PrimaryNetworkVerticesService } from './services/PrimaryNetworkVerticesService.js';
19
+ import { TeleporterService } from './services/TeleporterService.js';
19
20
 
20
21
  type HttpRequestConstructor = new (config: OpenAPIConfig) => BaseHttpRequest;
21
22
  declare class Glacier {
@@ -35,6 +36,7 @@ declare class Glacier {
35
36
  readonly primaryNetworkTransactions: PrimaryNetworkTransactionsService;
36
37
  readonly primaryNetworkUtxOs: PrimaryNetworkUtxOsService;
37
38
  readonly primaryNetworkVertices: PrimaryNetworkVerticesService;
39
+ readonly teleporter: TeleporterService;
38
40
  readonly request: BaseHttpRequest;
39
41
  constructor(config?: Partial<OpenAPIConfig>, HttpRequest?: HttpRequestConstructor);
40
42
  }
@@ -15,6 +15,7 @@ import { PrimaryNetworkRewardsService } from './services/PrimaryNetworkRewardsSe
15
15
  import { PrimaryNetworkTransactionsService } from './services/PrimaryNetworkTransactionsService.js';
16
16
  import { PrimaryNetworkUtxOsService } from './services/PrimaryNetworkUtxOsService.js';
17
17
  import { PrimaryNetworkVerticesService } from './services/PrimaryNetworkVerticesService.js';
18
+ import { TeleporterService } from './services/TeleporterService.js';
18
19
 
19
20
  class Glacier {
20
21
  default;
@@ -33,6 +34,7 @@ class Glacier {
33
34
  primaryNetworkTransactions;
34
35
  primaryNetworkUtxOs;
35
36
  primaryNetworkVertices;
37
+ teleporter;
36
38
  request;
37
39
  constructor(config, HttpRequest = FetchHttpRequest) {
38
40
  this.request = new HttpRequest({
@@ -62,6 +64,7 @@ class Glacier {
62
64
  this.primaryNetworkTransactions = new PrimaryNetworkTransactionsService(this.request);
63
65
  this.primaryNetworkUtxOs = new PrimaryNetworkUtxOsService(this.request);
64
66
  this.primaryNetworkVertices = new PrimaryNetworkVerticesService(this.request);
67
+ this.teleporter = new TeleporterService(this.request);
65
68
  }
66
69
  }
67
70
 
@@ -3,7 +3,10 @@ type AddressActivityMetadata = {
3
3
  * Ethereum address for the address_activity event type
4
4
  */
5
5
  address: string;
6
- topic0?: string;
6
+ /**
7
+ * Array of hexadecimal strings of the event signatures.
8
+ */
9
+ eventSignatures?: Array<string>;
7
10
  };
8
11
 
9
12
  export { AddressActivityMetadata };
@@ -0,0 +1,34 @@
1
+ import { Money } from './Money.js';
2
+
3
+ type AssetWithPriceInfo = {
4
+ /**
5
+ * Unique ID for an asset.
6
+ */
7
+ assetId: string;
8
+ /**
9
+ * Name of this asset.
10
+ */
11
+ name: string;
12
+ /**
13
+ * Symbol for this asset (max 4 characters).
14
+ */
15
+ symbol: string;
16
+ /**
17
+ * Denomination of this asset to represent fungibility.
18
+ */
19
+ denomination: number;
20
+ /**
21
+ * Type of asset like SECP256K1 or NFT.
22
+ */
23
+ type: string;
24
+ /**
25
+ * Amount of the asset.
26
+ */
27
+ amount: string;
28
+ /**
29
+ * The historical asset price at the time the reward was granted, if available. Note, this is only provided if the reward occured more than 24 hours ago.
30
+ */
31
+ historicalPrice?: Money;
32
+ };
33
+
34
+ export { AssetWithPriceInfo };
@@ -0,0 +1,24 @@
1
+ import { TeleporterDestinationTransaction } from './TeleporterDestinationTransaction.js';
2
+ import { TeleporterRewardDetails } from './TeleporterRewardDetails.js';
3
+
4
+ type DeliveredSourceNotIndexedTeleporterMessage = {
5
+ sourceBlockchainId: string;
6
+ destinationBlockchainId: string;
7
+ messageId: string;
8
+ from: string;
9
+ to: string;
10
+ data?: string;
11
+ messageExecuted: boolean;
12
+ receipts: Array<string>;
13
+ receiptDelivered: boolean;
14
+ rewardDetails: TeleporterRewardDetails;
15
+ destinationTransaction: TeleporterDestinationTransaction;
16
+ status: DeliveredSourceNotIndexedTeleporterMessage.status;
17
+ };
18
+ declare namespace DeliveredSourceNotIndexedTeleporterMessage {
19
+ enum status {
20
+ DELIVERED_SOURCE_NOT_INDEXED = "delivered_source_not_indexed"
21
+ }
22
+ }
23
+
24
+ export { DeliveredSourceNotIndexedTeleporterMessage };
@@ -0,0 +1,8 @@
1
+ var DeliveredSourceNotIndexedTeleporterMessage;
2
+ ((DeliveredSourceNotIndexedTeleporterMessage2) => {
3
+ ((status2) => {
4
+ status2["DELIVERED_SOURCE_NOT_INDEXED"] = "delivered_source_not_indexed";
5
+ })(DeliveredSourceNotIndexedTeleporterMessage2.status || (DeliveredSourceNotIndexedTeleporterMessage2.status = {}));
6
+ })(DeliveredSourceNotIndexedTeleporterMessage || (DeliveredSourceNotIndexedTeleporterMessage = {}));
7
+
8
+ export { DeliveredSourceNotIndexedTeleporterMessage };
@@ -0,0 +1,26 @@
1
+ import { TeleporterDestinationTransaction } from './TeleporterDestinationTransaction.js';
2
+ import { TeleporterRewardDetails } from './TeleporterRewardDetails.js';
3
+ import { TeleporterSourceTransaction } from './TeleporterSourceTransaction.js';
4
+
5
+ type DeliveredTeleporterMessage = {
6
+ sourceBlockchainId: string;
7
+ destinationBlockchainId: string;
8
+ messageId: string;
9
+ from: string;
10
+ to: string;
11
+ data?: string;
12
+ messageExecuted: boolean;
13
+ receipts: Array<string>;
14
+ receiptDelivered: boolean;
15
+ rewardDetails: TeleporterRewardDetails;
16
+ sourceTransaction: TeleporterSourceTransaction;
17
+ destinationTransaction: TeleporterDestinationTransaction;
18
+ status: DeliveredTeleporterMessage.status;
19
+ };
20
+ declare namespace DeliveredTeleporterMessage {
21
+ enum status {
22
+ DELIVERED = "delivered"
23
+ }
24
+ }
25
+
26
+ export { DeliveredTeleporterMessage };
@@ -0,0 +1,8 @@
1
+ var DeliveredTeleporterMessage;
2
+ ((DeliveredTeleporterMessage2) => {
3
+ ((status2) => {
4
+ status2["DELIVERED"] = "delivered";
5
+ })(DeliveredTeleporterMessage2.status || (DeliveredTeleporterMessage2.status = {}));
6
+ })(DeliveredTeleporterMessage || (DeliveredTeleporterMessage = {}));
7
+
8
+ export { DeliveredTeleporterMessage };
@@ -1,4 +1,4 @@
1
- import { Asset } from './Asset.js';
1
+ import { AssetWithPriceInfo } from './AssetWithPriceInfo.js';
2
2
  import { RewardType } from './RewardType.js';
3
3
 
4
4
  type HistoricalReward = {
@@ -14,10 +14,7 @@ type HistoricalReward = {
14
14
  rewardType: RewardType;
15
15
  utxoId: string;
16
16
  outputIndex: number;
17
- /**
18
- * An object containing P-chain Asset ID and the amount of that Asset ID.
19
- */
20
- reward: Asset;
17
+ reward: AssetWithPriceInfo;
21
18
  rewardTxHash: string;
22
19
  };
23
20
 
@@ -1,6 +1,7 @@
1
1
  import { ActiveValidatorDetails } from './ActiveValidatorDetails.js';
2
2
  import { CompletedValidatorDetails } from './CompletedValidatorDetails.js';
3
3
  import { PendingValidatorDetails } from './PendingValidatorDetails.js';
4
+ import { RemovedValidatorDetails } from './RemovedValidatorDetails.js';
4
5
 
5
6
  type ListValidatorDetailsResponse = {
6
7
  /**
@@ -10,7 +11,7 @@ type ListValidatorDetailsResponse = {
10
11
  /**
11
12
  * The list of validator Details.
12
13
  */
13
- validators: Array<(CompletedValidatorDetails | ActiveValidatorDetails | PendingValidatorDetails)>;
14
+ validators: Array<(CompletedValidatorDetails | ActiveValidatorDetails | PendingValidatorDetails | RemovedValidatorDetails)>;
14
15
  };
15
16
 
16
17
  export { ListValidatorDetailsResponse };
@@ -0,0 +1,8 @@
1
+ type NextPageToken = {
2
+ /**
3
+ * 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.
4
+ */
5
+ nextPageToken?: string;
6
+ };
7
+
8
+ export { NextPageToken };
@@ -0,0 +1,24 @@
1
+ import { TeleporterRewardDetails } from './TeleporterRewardDetails.js';
2
+ import { TeleporterSourceTransaction } from './TeleporterSourceTransaction.js';
3
+
4
+ type PendingTeleporterMessage = {
5
+ sourceBlockchainId: string;
6
+ destinationBlockchainId: string;
7
+ messageId: string;
8
+ from: string;
9
+ to: string;
10
+ data?: string;
11
+ messageExecuted: boolean;
12
+ receipts: Array<string>;
13
+ receiptDelivered: boolean;
14
+ rewardDetails: TeleporterRewardDetails;
15
+ sourceTransaction: TeleporterSourceTransaction;
16
+ status: PendingTeleporterMessage.status;
17
+ };
18
+ declare namespace PendingTeleporterMessage {
19
+ enum status {
20
+ PENDING = "pending"
21
+ }
22
+ }
23
+
24
+ export { PendingTeleporterMessage };
@@ -0,0 +1,8 @@
1
+ var PendingTeleporterMessage;
2
+ ((PendingTeleporterMessage2) => {
3
+ ((status2) => {
4
+ status2["PENDING"] = "pending";
5
+ })(PendingTeleporterMessage2.status || (PendingTeleporterMessage2.status = {}));
6
+ })(PendingTeleporterMessage || (PendingTeleporterMessage = {}));
7
+
8
+ export { PendingTeleporterMessage };
@@ -0,0 +1,19 @@
1
+ type RemovedValidatorDetails = {
2
+ txHash: string;
3
+ nodeId: string;
4
+ subnetId: string;
5
+ amountStaked: string;
6
+ delegationFee?: string;
7
+ startTimestamp: number;
8
+ endTimestamp: number;
9
+ removeTxHash: string;
10
+ removeTimestamp: number;
11
+ validationStatus: RemovedValidatorDetails.validationStatus;
12
+ };
13
+ declare namespace RemovedValidatorDetails {
14
+ enum validationStatus {
15
+ REMOVED = "removed"
16
+ }
17
+ }
18
+
19
+ export { RemovedValidatorDetails };
@@ -0,0 +1,8 @@
1
+ var RemovedValidatorDetails;
2
+ ((RemovedValidatorDetails2) => {
3
+ ((validationStatus2) => {
4
+ validationStatus2["REMOVED"] = "removed";
5
+ })(RemovedValidatorDetails2.validationStatus || (RemovedValidatorDetails2.validationStatus = {}));
6
+ })(RemovedValidatorDetails || (RemovedValidatorDetails = {}));
7
+
8
+ export { RemovedValidatorDetails };
@@ -0,0 +1,9 @@
1
+ type TeleporterDestinationTransaction = {
2
+ txHash: string;
3
+ timestamp: number;
4
+ gasSpent: string;
5
+ rewardRedeemer: string;
6
+ delivererAddress: string;
7
+ };
8
+
9
+ export { TeleporterDestinationTransaction };
@@ -0,0 +1,37 @@
1
+ import { Money } from './Money.js';
2
+
3
+ type TeleporterRewardDetails = {
4
+ /**
5
+ * A wallet or contract address in mixed-case checksum encoding.
6
+ */
7
+ address: string;
8
+ /**
9
+ * The contract name.
10
+ */
11
+ name: string;
12
+ /**
13
+ * The contract symbol.
14
+ */
15
+ symbol: string;
16
+ /**
17
+ * The number of decimals the token uses. For example `6`, means to divide the token amount by `1000000` to get its user representation.
18
+ */
19
+ decimals: number;
20
+ /**
21
+ * The logo uri for the address.
22
+ */
23
+ logoUri?: string;
24
+ ercType: TeleporterRewardDetails.ercType;
25
+ /**
26
+ * The token price, if available.
27
+ */
28
+ price?: Money;
29
+ value: string;
30
+ };
31
+ declare namespace TeleporterRewardDetails {
32
+ enum ercType {
33
+ ERC_20 = "ERC-20"
34
+ }
35
+ }
36
+
37
+ export { TeleporterRewardDetails };
@@ -0,0 +1,8 @@
1
+ var TeleporterRewardDetails;
2
+ ((TeleporterRewardDetails2) => {
3
+ ((ercType2) => {
4
+ ercType2["ERC_20"] = "ERC-20";
5
+ })(TeleporterRewardDetails2.ercType || (TeleporterRewardDetails2.ercType = {}));
6
+ })(TeleporterRewardDetails || (TeleporterRewardDetails = {}));
7
+
8
+ export { TeleporterRewardDetails };
@@ -0,0 +1,7 @@
1
+ type TeleporterSourceTransaction = {
2
+ txHash: string;
3
+ timestamp: number;
4
+ gasSpent: string;
5
+ };
6
+
7
+ export { TeleporterSourceTransaction };
@@ -1,7 +1,8 @@
1
1
  declare enum ValidationStatusType {
2
2
  COMPLETED = "completed",
3
3
  ACTIVE = "active",
4
- PENDING = "pending"
4
+ PENDING = "pending",
5
+ REMOVED = "removed"
5
6
  }
6
7
 
7
8
  export { ValidationStatusType };
@@ -2,6 +2,7 @@ var ValidationStatusType = /* @__PURE__ */ ((ValidationStatusType2) => {
2
2
  ValidationStatusType2["COMPLETED"] = "completed";
3
3
  ValidationStatusType2["ACTIVE"] = "active";
4
4
  ValidationStatusType2["PENDING"] = "pending";
5
+ ValidationStatusType2["REMOVED"] = "removed";
5
6
  return ValidationStatusType2;
6
7
  })(ValidationStatusType || {});
7
8
 
@@ -1,3 +1,4 @@
1
+ import { CurrencyCode } from '../models/CurrencyCode.js';
1
2
  import { ListHistoricalRewardsResponse } from '../models/ListHistoricalRewardsResponse.js';
2
3
  import { ListPendingRewardsResponse } from '../models/ListPendingRewardsResponse.js';
3
4
  import { Network } from '../models/Network.js';
@@ -20,7 +21,7 @@ declare class PrimaryNetworkRewardsService {
20
21
  */
21
22
  network: Network;
22
23
  /**
23
- * 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".
24
+ * 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". Optional, but at least one of addresses or nodeIds is required.
24
25
  */
25
26
  addresses?: string;
26
27
  /**
@@ -32,7 +33,7 @@ declare class PrimaryNetworkRewardsService {
32
33
  */
33
34
  pageToken?: string;
34
35
  /**
35
- * A comma separated list of node ids to filter by.
36
+ * A comma separated list of node ids to filter by. Optional, but at least one of addresses or nodeIds is required.
36
37
  */
37
38
  nodeIds?: string;
38
39
  /**
@@ -46,13 +47,13 @@ declare class PrimaryNetworkRewardsService {
46
47
  * @returns ListHistoricalRewardsResponse
47
48
  * @throws ApiError
48
49
  */
49
- listHistoricalPrimaryNetworkRewards({ network, addresses, pageSize, pageToken, nodeIds, sortOrder, }: {
50
+ listHistoricalPrimaryNetworkRewards({ network, addresses, pageSize, pageToken, nodeIds, sortOrder, currency, }: {
50
51
  /**
51
52
  * Either mainnet or a testnet.
52
53
  */
53
54
  network: Network;
54
55
  /**
55
- * 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".
56
+ * 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". Optional, but at least one of addresses or nodeIds is required.
56
57
  */
57
58
  addresses?: string;
58
59
  /**
@@ -64,13 +65,17 @@ declare class PrimaryNetworkRewardsService {
64
65
  */
65
66
  pageToken?: string;
66
67
  /**
67
- * A comma separated list of node ids to filter by.
68
+ * A comma separated list of node ids to filter by. Optional, but at least one of addresses or nodeIds is required.
68
69
  */
69
70
  nodeIds?: string;
70
71
  /**
71
72
  * 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.
72
73
  */
73
74
  sortOrder?: SortOrder;
75
+ /**
76
+ * The currency that return values should use. Defaults to USD.
77
+ */
78
+ currency?: CurrencyCode;
74
79
  }): CancelablePromise<ListHistoricalRewardsResponse>;
75
80
  }
76
81
 
@@ -31,7 +31,8 @@ class PrimaryNetworkRewardsService {
31
31
  pageSize = 10,
32
32
  pageToken,
33
33
  nodeIds,
34
- sortOrder
34
+ sortOrder,
35
+ currency
35
36
  }) {
36
37
  return this.httpRequest.request({
37
38
  method: "GET",
@@ -44,7 +45,8 @@ class PrimaryNetworkRewardsService {
44
45
  "pageSize": pageSize,
45
46
  "pageToken": pageToken,
46
47
  "nodeIds": nodeIds,
47
- "sortOrder": sortOrder
48
+ "sortOrder": sortOrder,
49
+ "currency": currency
48
50
  }
49
51
  });
50
52
  }
@@ -0,0 +1,65 @@
1
+ import { DeliveredSourceNotIndexedTeleporterMessage } from '../models/DeliveredSourceNotIndexedTeleporterMessage.js';
2
+ import { DeliveredTeleporterMessage } from '../models/DeliveredTeleporterMessage.js';
3
+ import { NextPageToken } from '../models/NextPageToken.js';
4
+ import { PendingTeleporterMessage } from '../models/PendingTeleporterMessage.js';
5
+ import { CancelablePromise } from '../core/CancelablePromise.js';
6
+ import { BaseHttpRequest } from '../core/BaseHttpRequest.js';
7
+
8
+ declare class TeleporterService {
9
+ readonly httpRequest: BaseHttpRequest;
10
+ constructor(httpRequest: BaseHttpRequest);
11
+ /**
12
+ * Get a teleporter message
13
+ * Gets a teleporter message by source chain, destination chain, and message ID.
14
+ * @returns any
15
+ * @throws ApiError
16
+ */
17
+ getTeleporterMessage({ sourceBlockchainId, destinationBlockchainId, messageId, }: {
18
+ /**
19
+ * The base58 encoded blockchain ID of the source chain that the teleporter message was sent from.
20
+ */
21
+ sourceBlockchainId: any;
22
+ /**
23
+ * The base58 encoded blockchain ID of the destination chain that the teleporter message was sent to.
24
+ */
25
+ destinationBlockchainId: any;
26
+ /**
27
+ * The message ID of the teleporter message.
28
+ */
29
+ messageId: any;
30
+ }): CancelablePromise<(PendingTeleporterMessage | DeliveredTeleporterMessage | DeliveredSourceNotIndexedTeleporterMessage)>;
31
+ /**
32
+ * List teleporter messages
33
+ * Lists teleporter messages. Ordered by timestamp in descending order.
34
+ * @returns any
35
+ * @throws ApiError
36
+ */
37
+ listTeleporterMessages({ pageSize, pageToken, sourceBlockchainId, destinationBlockchainId, to, from, }: {
38
+ /**
39
+ * The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
40
+ */
41
+ pageSize?: number;
42
+ /**
43
+ * A page token, received from a previous list call. Provide this to retrieve the subsequent page.
44
+ */
45
+ pageToken?: string;
46
+ /**
47
+ * The base58 encoded blockchain ID of the source chain that the teleporter message was sent from.
48
+ */
49
+ sourceBlockchainId?: any;
50
+ /**
51
+ * The base58 encoded blockchain ID of the destination chain that the teleporter message was sent to.
52
+ */
53
+ destinationBlockchainId?: any;
54
+ /**
55
+ * The address of the recipient of the teleporter message.
56
+ */
57
+ to?: any;
58
+ /**
59
+ * The address of the sender of the teleporter message.
60
+ */
61
+ from?: any;
62
+ }): CancelablePromise<NextPageToken>;
63
+ }
64
+
65
+ export { TeleporterService };
@@ -0,0 +1,43 @@
1
+ class TeleporterService {
2
+ constructor(httpRequest) {
3
+ this.httpRequest = httpRequest;
4
+ }
5
+ getTeleporterMessage({
6
+ sourceBlockchainId,
7
+ destinationBlockchainId,
8
+ messageId
9
+ }) {
10
+ return this.httpRequest.request({
11
+ method: "GET",
12
+ url: "/v1/teleporter/messages:getMessage",
13
+ query: {
14
+ "sourceBlockchainId": sourceBlockchainId,
15
+ "destinationBlockchainId": destinationBlockchainId,
16
+ "messageId": messageId
17
+ }
18
+ });
19
+ }
20
+ listTeleporterMessages({
21
+ pageSize = 10,
22
+ pageToken,
23
+ sourceBlockchainId,
24
+ destinationBlockchainId,
25
+ to,
26
+ from
27
+ }) {
28
+ return this.httpRequest.request({
29
+ method: "GET",
30
+ url: "/v1/teleporter/messages",
31
+ query: {
32
+ "pageSize": pageSize,
33
+ "pageToken": pageToken,
34
+ "sourceBlockchainId": sourceBlockchainId,
35
+ "destinationBlockchainId": destinationBlockchainId,
36
+ "to": to,
37
+ "from": from
38
+ }
39
+ });
40
+ }
41
+ }
42
+
43
+ export { TeleporterService };
package/esm/index.d.ts CHANGED
@@ -7,6 +7,7 @@ export { ActiveDelegatorDetails } from './generated/models/ActiveDelegatorDetail
7
7
  export { ActiveValidatorDetails } from './generated/models/ActiveValidatorDetails.js';
8
8
  export { AddressActivityMetadata } from './generated/models/AddressActivityMetadata.js';
9
9
  export { Asset } from './generated/models/Asset.js';
10
+ export { AssetWithPriceInfo } from './generated/models/AssetWithPriceInfo.js';
10
11
  export { Blockchain } from './generated/models/Blockchain.js';
11
12
  export { BlockchainId } from './generated/models/BlockchainId.js';
12
13
  export { BlockchainIds } from './generated/models/BlockchainIds.js';
@@ -32,6 +33,8 @@ export { CreatePrimaryNetworkTransactionExportRequest } from './generated/models
32
33
  export { CurrencyCode } from './generated/models/CurrencyCode.js';
33
34
  export { DelegationStatusType } from './generated/models/DelegationStatusType.js';
34
35
  export { DelegatorsDetails } from './generated/models/DelegatorsDetails.js';
36
+ export { DeliveredSourceNotIndexedTeleporterMessage } from './generated/models/DeliveredSourceNotIndexedTeleporterMessage.js';
37
+ export { DeliveredTeleporterMessage } from './generated/models/DeliveredTeleporterMessage.js';
35
38
  export { Erc1155Contract } from './generated/models/Erc1155Contract.js';
36
39
  export { Erc1155Token } from './generated/models/Erc1155Token.js';
37
40
  export { Erc1155TokenBalance } from './generated/models/Erc1155TokenBalance.js';
@@ -106,6 +109,7 @@ export { Network } from './generated/models/Network.js';
106
109
  export { NetworkToken } from './generated/models/NetworkToken.js';
107
110
  export { NetworkTokenDetails } from './generated/models/NetworkTokenDetails.js';
108
111
  export { NetworkType } from './generated/models/NetworkType.js';
112
+ export { NextPageToken } from './generated/models/NextPageToken.js';
109
113
  export { NftTokenMetadataStatus } from './generated/models/NftTokenMetadataStatus.js';
110
114
  export { OperationStatus } from './generated/models/OperationStatus.js';
111
115
  export { OperationStatusCode } from './generated/models/OperationStatusCode.js';
@@ -119,6 +123,7 @@ export { PChainTransactionType } from './generated/models/PChainTransactionType.
119
123
  export { PChainUtxo } from './generated/models/PChainUtxo.js';
120
124
  export { PendingDelegatorDetails } from './generated/models/PendingDelegatorDetails.js';
121
125
  export { PendingReward } from './generated/models/PendingReward.js';
126
+ export { PendingTeleporterMessage } from './generated/models/PendingTeleporterMessage.js';
122
127
  export { PendingValidatorDetails } from './generated/models/PendingValidatorDetails.js';
123
128
  export { PricingProviders } from './generated/models/PricingProviders.js';
124
129
  export { PrimaryNetwork } from './generated/models/PrimaryNetwork.js';
@@ -129,6 +134,7 @@ export { PrimaryNetworkOptions } from './generated/models/PrimaryNetworkOptions.
129
134
  export { PrimaryNetworkTxType } from './generated/models/PrimaryNetworkTxType.js';
130
135
  export { ProposerDetails } from './generated/models/ProposerDetails.js';
131
136
  export { RegisterWebhookRequest } from './generated/models/RegisterWebhookRequest.js';
137
+ export { RemovedValidatorDetails } from './generated/models/RemovedValidatorDetails.js';
132
138
  export { ResourceLink } from './generated/models/ResourceLink.js';
133
139
  export { ResourceLinkType } from './generated/models/ResourceLinkType.js';
134
140
  export { Rewards } from './generated/models/Rewards.js';
@@ -138,6 +144,9 @@ export { SharedSecretsResponse } from './generated/models/SharedSecretsResponse.
138
144
  export { SortOrder } from './generated/models/SortOrder.js';
139
145
  export { StakingDistribution } from './generated/models/StakingDistribution.js';
140
146
  export { Subnet } from './generated/models/Subnet.js';
147
+ export { TeleporterDestinationTransaction } from './generated/models/TeleporterDestinationTransaction.js';
148
+ export { TeleporterRewardDetails } from './generated/models/TeleporterRewardDetails.js';
149
+ export { TeleporterSourceTransaction } from './generated/models/TeleporterSourceTransaction.js';
141
150
  export { TransactionDetails } from './generated/models/TransactionDetails.js';
142
151
  export { TransactionExportMetadata } from './generated/models/TransactionExportMetadata.js';
143
152
  export { TransactionMethodType } from './generated/models/TransactionMethodType.js';
@@ -181,3 +190,4 @@ export { PrimaryNetworkRewardsService } from './generated/services/PrimaryNetwor
181
190
  export { PrimaryNetworkTransactionsService } from './generated/services/PrimaryNetworkTransactionsService.js';
182
191
  export { PrimaryNetworkUtxOsService } from './generated/services/PrimaryNetworkUtxOsService.js';
183
192
  export { PrimaryNetworkVerticesService } from './generated/services/PrimaryNetworkVerticesService.js';
193
+ export { TeleporterService } from './generated/services/TeleporterService.js';
package/esm/index.js CHANGED
@@ -20,6 +20,8 @@ export { CreateEvmTransactionExportRequest } from './generated/models/CreateEvmT
20
20
  export { CreatePrimaryNetworkTransactionExportRequest } from './generated/models/CreatePrimaryNetworkTransactionExportRequest.js';
21
21
  export { CurrencyCode } from './generated/models/CurrencyCode.js';
22
22
  export { DelegationStatusType } from './generated/models/DelegationStatusType.js';
23
+ export { DeliveredSourceNotIndexedTeleporterMessage } from './generated/models/DeliveredSourceNotIndexedTeleporterMessage.js';
24
+ export { DeliveredTeleporterMessage } from './generated/models/DeliveredTeleporterMessage.js';
23
25
  export { Erc1155Contract } from './generated/models/Erc1155Contract.js';
24
26
  export { Erc1155Token } from './generated/models/Erc1155Token.js';
25
27
  export { Erc1155TokenBalance } from './generated/models/Erc1155TokenBalance.js';
@@ -40,13 +42,16 @@ export { OperationType } from './generated/models/OperationType.js';
40
42
  export { PChainId } from './generated/models/PChainId.js';
41
43
  export { PChainTransactionType } from './generated/models/PChainTransactionType.js';
42
44
  export { PendingDelegatorDetails } from './generated/models/PendingDelegatorDetails.js';
45
+ export { PendingTeleporterMessage } from './generated/models/PendingTeleporterMessage.js';
43
46
  export { PendingValidatorDetails } from './generated/models/PendingValidatorDetails.js';
44
47
  export { PrimaryNetwork } from './generated/models/PrimaryNetwork.js';
45
48
  export { PrimaryNetworkChainName } from './generated/models/PrimaryNetworkChainName.js';
46
49
  export { PrimaryNetworkTxType } from './generated/models/PrimaryNetworkTxType.js';
50
+ export { RemovedValidatorDetails } from './generated/models/RemovedValidatorDetails.js';
47
51
  export { ResourceLinkType } from './generated/models/ResourceLinkType.js';
48
52
  export { RewardType } from './generated/models/RewardType.js';
49
53
  export { SortOrder } from './generated/models/SortOrder.js';
54
+ export { TeleporterRewardDetails } from './generated/models/TeleporterRewardDetails.js';
50
55
  export { TransactionMethodType } from './generated/models/TransactionMethodType.js';
51
56
  export { TransactionStatus } from './generated/models/TransactionStatus.js';
52
57
  export { UnknownContract } from './generated/models/UnknownContract.js';
@@ -75,3 +80,4 @@ export { PrimaryNetworkRewardsService } from './generated/services/PrimaryNetwor
75
80
  export { PrimaryNetworkTransactionsService } from './generated/services/PrimaryNetworkTransactionsService.js';
76
81
  export { PrimaryNetworkUtxOsService } from './generated/services/PrimaryNetworkUtxOsService.js';
77
82
  export { PrimaryNetworkVerticesService } from './generated/services/PrimaryNetworkVerticesService.js';
83
+ export { TeleporterService } from './generated/services/TeleporterService.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@avalabs/glacier-sdk",
3
- "version": "2.8.0-canary.bf2dc9b.0+bf2dc9b",
3
+ "version": "2.8.0-canary.c4e2f70.0+c4e2f70",
4
4
  "description": "sdk for interacting with glacier-api",
5
5
  "author": "Oliver Wang <oliver.wang@avalabs.org>",
6
6
  "homepage": "https://github.com/ava-labs/avalanche-sdks#readme",
@@ -29,5 +29,5 @@
29
29
  "bugs": {
30
30
  "url": "https://github.com/ava-labs/avalanche-sdks/issues"
31
31
  },
32
- "gitHead": "bf2dc9ba98207999948fc0e7988581f78d14c86b"
32
+ "gitHead": "c4e2f701e8ba85d2c5402ba133497b06d38795a8"
33
33
  }