diff --git a/packages/api-client/src/generated/models/CountryCode.ts b/packages/api-client/src/generated/models/CountryCode.ts index 024221c68..8dbc3af43 100644 --- a/packages/api-client/src/generated/models/CountryCode.ts +++ b/packages/api-client/src/generated/models/CountryCode.ts @@ -2,4 +2,4 @@ /* tslint:disable */ /* eslint-disable */ -export type CountryCode = 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AX' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BQ' | 'BR' | 'BL' | 'BM' | 'BN' | 'BO' | 'BS' | 'BT' | 'BV' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'EH' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GS' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HM' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IO' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TF' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'UM' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW'; +export type CountryCode = 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AX' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BQ' | 'BR' | 'BL' | 'BM' | 'BN' | 'BO' | 'BS' | 'BT' | 'BV' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'EH' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GS' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HM' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IO' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TF' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'UM' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW'; \ No newline at end of file diff --git a/packages/api-client/src/generated/models/CreateContractAddressLogEventSubscription.ts b/packages/api-client/src/generated/models/CreateContractAddressLogEventSubscription.ts new file mode 100644 index 000000000..320d60b29 --- /dev/null +++ b/packages/api-client/src/generated/models/CreateContractAddressLogEventSubscription.ts @@ -0,0 +1,31 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ + +export type CreateContractAddressLogEventSubscription = { + /** + * Type of the subscription. + */ + type: string; + /** + * Additional attributes based on the subscription type. + */ + attr: { + /** + * Blockchain address to watch. + */ + contractAddress: string; + /** + * Blockchain of the address. + */ + chain: 'ETH' | 'MATIC' | 'CELO' | 'KLAY' | 'BSC' | 'TEZOS' | 'FLR'; + /** + * URL of the endpoint, where HTTP POST request will be sent, when transaction is detected on the address. + */ + url: string; + /** + * Event to watch. In case of EVM chains it is usually a hash of the event signature. In case of Tezos it is a name of the event and max length is not enforced. + */ + event: string; + }; +} diff --git a/packages/api-client/src/generated/services/AccountService.ts b/packages/api-client/src/generated/services/AccountService.ts index f3ffb3636..733930ba5 100644 --- a/packages/api-client/src/generated/services/AccountService.ts +++ b/packages/api-client/src/generated/services/AccountService.ts @@ -559,4 +559,4 @@ export class AccountService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/AlgorandService.ts b/packages/api-client/src/generated/services/AlgorandService.ts index 02d8338b6..ec0161da8 100644 --- a/packages/api-client/src/generated/services/AlgorandService.ts +++ b/packages/api-client/src/generated/services/AlgorandService.ts @@ -401,4 +401,4 @@ export class AlgorandService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/AuctionService.ts b/packages/api-client/src/generated/services/AuctionService.ts index 10a1af4d5..a0207b984 100644 --- a/packages/api-client/src/generated/services/AuctionService.ts +++ b/packages/api-client/src/generated/services/AuctionService.ts @@ -537,4 +537,4 @@ export class AuctionService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/AvalancheService.ts b/packages/api-client/src/generated/services/AvalancheService.ts index e9a5acde8..048a11a07 100644 --- a/packages/api-client/src/generated/services/AvalancheService.ts +++ b/packages/api-client/src/generated/services/AvalancheService.ts @@ -340,4 +340,4 @@ export class AvalancheService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BaseService.ts b/packages/api-client/src/generated/services/BaseService.ts index 5b3e85c9e..989af1bd8 100644 --- a/packages/api-client/src/generated/services/BaseService.ts +++ b/packages/api-client/src/generated/services/BaseService.ts @@ -340,4 +340,4 @@ export class BaseService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BitcoinCashService.ts b/packages/api-client/src/generated/services/BitcoinCashService.ts index b1869dd23..1f7efe2db 100644 --- a/packages/api-client/src/generated/services/BitcoinCashService.ts +++ b/packages/api-client/src/generated/services/BitcoinCashService.ts @@ -325,4 +325,4 @@ export class BitcoinCashService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BitcoinService.ts b/packages/api-client/src/generated/services/BitcoinService.ts index 0a0654437..8072655ca 100644 --- a/packages/api-client/src/generated/services/BitcoinService.ts +++ b/packages/api-client/src/generated/services/BitcoinService.ts @@ -490,4 +490,4 @@ export class BitcoinService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BlockchainAddressesService.ts b/packages/api-client/src/generated/services/BlockchainAddressesService.ts index 89d4c2aec..ee6e123f6 100644 --- a/packages/api-client/src/generated/services/BlockchainAddressesService.ts +++ b/packages/api-client/src/generated/services/BlockchainAddressesService.ts @@ -216,4 +216,4 @@ export class BlockchainAddressesService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BlockchainFeesService.ts b/packages/api-client/src/generated/services/BlockchainFeesService.ts index 849d719c3..0fa449d24 100644 --- a/packages/api-client/src/generated/services/BlockchainFeesService.ts +++ b/packages/api-client/src/generated/services/BlockchainFeesService.ts @@ -546,4 +546,4 @@ export class BlockchainFeesService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BlockchainOperationsService.ts b/packages/api-client/src/generated/services/BlockchainOperationsService.ts index 5b3ef1218..bd4fe8624 100644 --- a/packages/api-client/src/generated/services/BlockchainOperationsService.ts +++ b/packages/api-client/src/generated/services/BlockchainOperationsService.ts @@ -1721,4 +1721,4 @@ export class BlockchainOperationsService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BlockchainStorageService.ts b/packages/api-client/src/generated/services/BlockchainStorageService.ts index ce927fa01..32eab7a19 100644 --- a/packages/api-client/src/generated/services/BlockchainStorageService.ts +++ b/packages/api-client/src/generated/services/BlockchainStorageService.ts @@ -84,4 +84,4 @@ export class BlockchainStorageService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BlockchainUtilsService.ts b/packages/api-client/src/generated/services/BlockchainUtilsService.ts index 3038a5b47..4cc00d9cb 100644 --- a/packages/api-client/src/generated/services/BlockchainUtilsService.ts +++ b/packages/api-client/src/generated/services/BlockchainUtilsService.ts @@ -87,4 +87,4 @@ export class BlockchainUtilsService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BnbBeaconChainService.ts b/packages/api-client/src/generated/services/BnbBeaconChainService.ts index 436b8b0d3..39dc406a8 100644 --- a/packages/api-client/src/generated/services/BnbBeaconChainService.ts +++ b/packages/api-client/src/generated/services/BnbBeaconChainService.ts @@ -220,4 +220,4 @@ export class BnbBeaconChainService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/BnbSmartChainService.ts b/packages/api-client/src/generated/services/BnbSmartChainService.ts index cc27c9fb0..40b293f53 100644 --- a/packages/api-client/src/generated/services/BnbSmartChainService.ts +++ b/packages/api-client/src/generated/services/BnbSmartChainService.ts @@ -343,4 +343,4 @@ export class BnbSmartChainService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/CardanoService.ts b/packages/api-client/src/generated/services/CardanoService.ts index ef4afaff1..90ba0a5bd 100644 --- a/packages/api-client/src/generated/services/CardanoService.ts +++ b/packages/api-client/src/generated/services/CardanoService.ts @@ -322,4 +322,4 @@ export class CardanoService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/CeloService.ts b/packages/api-client/src/generated/services/CeloService.ts index 0fa10efe5..816fd74dc 100644 --- a/packages/api-client/src/generated/services/CeloService.ts +++ b/packages/api-client/src/generated/services/CeloService.ts @@ -400,4 +400,4 @@ export class CeloService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/CronosService.ts b/packages/api-client/src/generated/services/CronosService.ts index 68802f93e..f1f6522a0 100644 --- a/packages/api-client/src/generated/services/CronosService.ts +++ b/packages/api-client/src/generated/services/CronosService.ts @@ -340,4 +340,4 @@ export class CronosService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/CustodialManagedWalletsService.ts b/packages/api-client/src/generated/services/CustodialManagedWalletsService.ts index 3ecad20d7..ba56d4b67 100644 --- a/packages/api-client/src/generated/services/CustodialManagedWalletsService.ts +++ b/packages/api-client/src/generated/services/CustodialManagedWalletsService.ts @@ -207,4 +207,4 @@ export class CustodialManagedWalletsService { }); } - } + } \ No newline at end of file diff --git a/packages/api-client/src/generated/services/CustomerService.ts b/packages/api-client/src/generated/services/CustomerService.ts index af087deed..784fa3de8 100644 --- a/packages/api-client/src/generated/services/CustomerService.ts +++ b/packages/api-client/src/generated/services/CustomerService.ts @@ -173,4 +173,4 @@ export class CustomerService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/DeFiApiService.ts b/packages/api-client/src/generated/services/DeFiApiService.ts new file mode 100644 index 000000000..37842f10f --- /dev/null +++ b/packages/api-client/src/generated/services/DeFiApiService.ts @@ -0,0 +1,375 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +import type { BlockItem } from '../models/BlockItem'; +import type { BlockNumber } from '../models/BlockNumber'; +import type { BlockNumberTo } from '../models/BlockNumberTo'; +import type { ChainEnum } from '../models/ChainEnum'; +import type { Event } from '../models/Event'; +import type { Offset } from '../models/Offset'; +import type { PageSize } from '../models/PageSize'; +import type { CancelablePromise } from '../core/CancelablePromise'; +import { request as __request } from '../core/request'; + +export class DeFiApiService { + + /** + * Get specified events + *

20 credits per API call

+ *

Get all events on given addresses and / or in the requested block range on the following blockchains:

+ * + *

To get started:

+ * + *

As noted above, aside from general info and hashed event data, the API also decodes them for you in case you filter by one of the following supported event types:

+ * + * + * @param chain The blockchain to work with. + * @param contractAddresses The blockchain addresses of the contracts where requested events were emitted. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param blockFrom First block to start from (including this one). + * @param blockTo Last block to finish on (including this one). + * @param eventType The type of events that should be returned, which comes with decoded data in the response + * (cannot be used together with signatures). + * + * @param signatures The types of events that should be returned, specified by hashed signature + * (cannot be used together with eventType). + * It is possible to enter list of multiple signatures as a comma separated string. + * + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns Event OK + * @throws ApiError + */ + public static getEventsV4( + chain: ChainEnum, + contractAddresses: string, + blockFrom: BlockNumber, + blockTo: BlockNumberTo, + eventType: 'tokenTransfer' | 'multitokenTransfer' | 'stablecoinTransfer' | 'uniswapTrade', + signatures?: string, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise { + return __request({ + method: 'GET', + path: `/v4/data/events`, + query: { + 'chain': chain, + 'contractAddresses': contractAddresses, + 'blockFrom': blockFrom, + 'blockTo': blockTo, + 'eventType': eventType, + 'signatures': signatures, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get specified events + *

20 credits per API call

+ *

Get all events on given addresses and / or in the requested block range on the following blockchains:

+ * + *

To get started:

+ * + *

As noted above, aside from general info and hashed event data, the API also decodes them for you in case you filter by one of the following supported event types:

+ * + * + * @param chain The blockchain to work with. + * @param contractAddresses The blockchain addresses of the contracts where requested events were emitted. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param blockFrom First block to start from (including this one). + * @param blockTo Last block to finish on (including this one). + * @param eventType The type of events that should be returned, which comes with decoded data in the response + * (cannot be used together with signatures). + * + * @param signatures The types of events that should be returned, specified by hashed signature + * (cannot be used together with eventType). + * It is possible to enter list of multiple signatures as a comma separated string. + * + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns Event OK + * @throws ApiError + */ + public static getEvents( + chain: ChainEnum, + contractAddresses: string, + blockFrom: BlockNumber, + blockTo: BlockNumberTo, + eventType: 'tokenTransfer' | 'multitokenTransfer' | 'stablecoinTransfer' | 'uniswapTrade', + signatures?: string, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise { + return __request({ + method: 'GET', + path: `/v3/data/events`, + query: { + 'chain': chain, + 'contractAddresses': contractAddresses, + 'blockFrom': blockFrom, + 'blockTo': blockTo, + 'eventType': eventType, + 'signatures': signatures, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Get specified blocks + *

10 credits per API call

+ *

Get information about blocks (when they were added, how many NFTs and events were ingested and list of transaction hashes that were processed within them) on the following blockchains:

+ * + *

To get started, provide a chain and specify one of the filters listed below (combination of these filters is not allowed):

+ * + * + * @param chain The blockchain to work with. + * @param blockIds List of block numbers, separated by comma. + * @param blockFrom Range of block numbers. Both blockFrom and blockTo need to be specified. + * @param blockTo Range of block numbers. Both blockFrom and blockTo need to be specified. + * @param timeFrom Date range when blocks were processed. Both timeFrom and timeTo need to be specified. + * @param timeTo Date range when blocks were processed. Both timeFrom and timeTo need to be specified. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns BlockItem OK + * @throws ApiError + */ + public static getBlocksV4( + chain: ChainEnum, + blockIds?: Array, + blockFrom?: BlockNumber, + blockTo?: BlockNumber, + timeFrom?: string, + timeTo?: string, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v4/data/blocks`, + query: { + 'chain': chain, + 'blockIds': blockIds, + 'blockFrom': blockFrom, + 'blockTo': blockTo, + 'timeFrom': timeFrom, + 'timeTo': timeTo, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get specified blocks + *

10 credits per API call

+ *

Get information about blocks (when they were added, how many NFTs and events were ingested and list of transaction hashes that were processed within them) on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started, provide a chain and specify one of the filters listed below (combination of these filters is not allowed):

+ *
    + *
  • List of block numbers separated by comma
  • + *
  • Range of block numbers
  • + *
  • Date range when blocks were processed
  • + *
  • When you are filtering data using blockFrom and not using blockTo, blockTo is automatically added as blockFrom + 1000. The same applies when blockTo is present and blockFrom is not. In that case blockFrom is automatically added as blockTo - 1000.
  • + *
+ * + * @param chain The blockchain to work with. + * @param blockIds List of block numbers, separated by comma. + * @param blockFrom Range of block numbers. Both blockFrom and blockTo need to be specified. + * @param blockTo Range of block numbers. Both blockFrom and blockTo need to be specified. + * @param timeFrom Date range when blocks were processed. Both timeFrom and timeTo need to be specified. + * @param timeTo Date range when blocks were processed. Both timeFrom and timeTo need to be specified. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns BlockItem OK + * @throws ApiError + */ + public static getBlocks( + chain: ChainEnum, + blockIds?: Array, + blockFrom?: BlockNumber, + blockTo?: BlockNumber, + timeFrom?: string, + timeTo?: string, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v3/data/blocks`, + query: { + 'chain': chain, + 'blockIds': blockIds, + 'blockFrom': blockFrom, + 'blockTo': blockTo, + 'timeFrom': timeFrom, + 'timeTo': timeTo, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Get latest block + *

1 credit per API call

+ *

Get information about latest added block on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started, you can just provide a chain.

+ * + * @param chain The blockchain to work with. + * @returns BlockItem OK + * @throws ApiError + */ + public static getLatestBlockV4( + chain: ChainEnum, + ): CancelablePromise { + return __request({ + method: 'GET', + path: `/v4/data/blocks/latest`, + query: { + 'chain': chain, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get latest block + *

1 credit per API call

+ *

Get information about latest added block on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started, you can just provide a chain.

+ * + * @param chain The blockchain to work with. + * @returns BlockItem OK + * @throws ApiError + */ + public static getLatestBlock( + chain: ChainEnum, + ): CancelablePromise { + return __request({ + method: 'GET', + path: `/v3/data/blocks/latest`, + query: { + 'chain': chain, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/DepositService.ts b/packages/api-client/src/generated/services/DepositService.ts index 630bcffcf..414d33c78 100644 --- a/packages/api-client/src/generated/services/DepositService.ts +++ b/packages/api-client/src/generated/services/DepositService.ts @@ -98,4 +98,4 @@ export class DepositService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/DogecoinService.ts b/packages/api-client/src/generated/services/DogecoinService.ts index 0c216c1f4..9561a68b7 100644 --- a/packages/api-client/src/generated/services/DogecoinService.ts +++ b/packages/api-client/src/generated/services/DogecoinService.ts @@ -449,4 +449,4 @@ export class DogecoinService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/ElrondService.ts b/packages/api-client/src/generated/services/ElrondService.ts index c466359ca..e0a2ed7a0 100644 --- a/packages/api-client/src/generated/services/ElrondService.ts +++ b/packages/api-client/src/generated/services/ElrondService.ts @@ -362,4 +362,4 @@ export class ElrondService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/EthereumService.ts b/packages/api-client/src/generated/services/EthereumService.ts index 3c8eaf188..5752b1ec3 100644 --- a/packages/api-client/src/generated/services/EthereumService.ts +++ b/packages/api-client/src/generated/services/EthereumService.ts @@ -544,4 +544,4 @@ export class EthereumService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/ExchangeRateService.ts b/packages/api-client/src/generated/services/ExchangeRateService.ts index 5e8ebc400..83fca4631 100644 --- a/packages/api-client/src/generated/services/ExchangeRateService.ts +++ b/packages/api-client/src/generated/services/ExchangeRateService.ts @@ -65,4 +65,4 @@ export class ExchangeRateService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/FlareService.ts b/packages/api-client/src/generated/services/FlareService.ts index 20d504c37..412f65db1 100644 --- a/packages/api-client/src/generated/services/FlareService.ts +++ b/packages/api-client/src/generated/services/FlareService.ts @@ -460,4 +460,4 @@ export class FlareService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/FlowService.ts b/packages/api-client/src/generated/services/FlowService.ts index 020672e63..2453f38c7 100644 --- a/packages/api-client/src/generated/services/FlowService.ts +++ b/packages/api-client/src/generated/services/FlowService.ts @@ -411,4 +411,4 @@ export class FlowService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/FungibleTokensErc20OrCompatibleService.ts b/packages/api-client/src/generated/services/FungibleTokensErc20OrCompatibleService.ts index de3661bc3..6689d3494 100644 --- a/packages/api-client/src/generated/services/FungibleTokensErc20OrCompatibleService.ts +++ b/packages/api-client/src/generated/services/FungibleTokensErc20OrCompatibleService.ts @@ -491,4 +491,4 @@ export class FungibleTokensErc20OrCompatibleService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/GasPumpService.ts b/packages/api-client/src/generated/services/GasPumpService.ts index 044c44f38..e856213b6 100644 --- a/packages/api-client/src/generated/services/GasPumpService.ts +++ b/packages/api-client/src/generated/services/GasPumpService.ts @@ -531,4 +531,4 @@ export class GasPumpService { }); } - } + } \ No newline at end of file diff --git a/packages/api-client/src/generated/services/HarmonyService.ts b/packages/api-client/src/generated/services/HarmonyService.ts index 97be029d5..89bca6d61 100644 --- a/packages/api-client/src/generated/services/HarmonyService.ts +++ b/packages/api-client/src/generated/services/HarmonyService.ts @@ -407,4 +407,4 @@ export class HarmonyService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/IpfsService.ts b/packages/api-client/src/generated/services/IpfsService.ts index 90e2041c7..dfe1d7072 100644 --- a/packages/api-client/src/generated/services/IpfsService.ts +++ b/packages/api-client/src/generated/services/IpfsService.ts @@ -64,4 +64,4 @@ export class IpfsService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/KeyManagementSystemService.ts b/packages/api-client/src/generated/services/KeyManagementSystemService.ts index aec934b1a..4b3c222e8 100644 --- a/packages/api-client/src/generated/services/KeyManagementSystemService.ts +++ b/packages/api-client/src/generated/services/KeyManagementSystemService.ts @@ -141,4 +141,4 @@ export class KeyManagementSystemService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/KlaytnService.ts b/packages/api-client/src/generated/services/KlaytnService.ts index 72000aec0..2bde6477f 100644 --- a/packages/api-client/src/generated/services/KlaytnService.ts +++ b/packages/api-client/src/generated/services/KlaytnService.ts @@ -347,4 +347,4 @@ export class KlaytnService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/KuCoinService.ts b/packages/api-client/src/generated/services/KuCoinService.ts index 228534dd7..b96a4a7ae 100644 --- a/packages/api-client/src/generated/services/KuCoinService.ts +++ b/packages/api-client/src/generated/services/KuCoinService.ts @@ -350,4 +350,4 @@ export class KuCoinService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/LitecoinService.ts b/packages/api-client/src/generated/services/LitecoinService.ts index 76f5c829c..51578d6c2 100644 --- a/packages/api-client/src/generated/services/LitecoinService.ts +++ b/packages/api-client/src/generated/services/LitecoinService.ts @@ -470,4 +470,4 @@ export class LitecoinService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/MaliciousAddressService.ts b/packages/api-client/src/generated/services/MaliciousAddressService.ts index 54cd4ab0e..f9bc5e9ca 100644 --- a/packages/api-client/src/generated/services/MaliciousAddressService.ts +++ b/packages/api-client/src/generated/services/MaliciousAddressService.ts @@ -36,4 +36,4 @@ export class MaliciousAddressService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/MarketplaceService.ts b/packages/api-client/src/generated/services/MarketplaceService.ts index 1bd9e23b7..d4c938a43 100644 --- a/packages/api-client/src/generated/services/MarketplaceService.ts +++ b/packages/api-client/src/generated/services/MarketplaceService.ts @@ -644,4 +644,4 @@ export class MarketplaceService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/MultiTokensErc1155OrCompatibleService.ts b/packages/api-client/src/generated/services/MultiTokensErc1155OrCompatibleService.ts index 6614c258d..f0d74a43d 100644 --- a/packages/api-client/src/generated/services/MultiTokensErc1155OrCompatibleService.ts +++ b/packages/api-client/src/generated/services/MultiTokensErc1155OrCompatibleService.ts @@ -866,4 +866,4 @@ export class MultiTokensErc1155OrCompatibleService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/NftApiService.ts b/packages/api-client/src/generated/services/NftApiService.ts new file mode 100644 index 000000000..f481bd8a8 --- /dev/null +++ b/packages/api-client/src/generated/services/NftApiService.ts @@ -0,0 +1,466 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +import type { Chain } from '../models/Chain'; +import type { ChainEnum } from '../models/ChainEnum'; +import type { ExcludeMetadata } from '../models/ExcludeMetadata'; +import type { NftMetadata } from '../models/NftMetadata'; +import type { NftMetadataURI } from '../models/NftMetadataURI'; +import type { Offset } from '../models/Offset'; +import type { PageSize } from '../models/PageSize'; +import type { Token } from '../models/Token'; +import type { TokenAddress } from '../models/TokenAddress'; +import type { TokenId } from '../models/TokenId'; +import type { TokenIds } from '../models/TokenIds'; +import type { TokenTezos } from '../models/TokenTezos'; +import type { TokenType } from '../models/TokenType'; +import type { CancelablePromise } from '../core/CancelablePromise'; +import { request as __request } from '../core/request'; + +export class NftApiService { + + /** + * Get tokens from a collection + *

10 credits per API call

+ *

Get all NFTs (ERC-721 and ERC-1155) and multitokens (ERC-1155 only) of your favorite collections! Our API lets you search for all tokens on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon / polygon-amoy
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
  • Tezos - tezos-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and comma-separated list of collection addresses. Our API will return relevant information about each token, including its name, description, image, and more.
  • + *
  • Aside from relevant information about each token, the response also contains metadata (they can, however, be excluded by setting excludeMetadata to true).
  • + *
  • If not specified, the API returns results for all supported types of tokens (nft, multitokens), but you can also choose to filter only one tokenType.
  • + *
  • For Tezos blockchain query parameters excludeMetadata and tokenType won't have any effect on filtering data.
  • + *
+ * + * @param chain The blockchain to work with. + * @param collectionAddresses The blockchain addresses of the collections. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param tokenTypes The option to select only specific token types. + * It is possible to enter list of multiple types as a comma separated string. + * Use nft (includes ERC-721 and ERC-1155) or multitoken (ERC-1155 only). + * + * @param excludeMetadata The option to exclude metadata from the response. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns any OK + * @throws ApiError + */ + public static getCollectionsV4( + chain: ChainEnum, + collectionAddresses: TokenAddress, + tokenTypes?: 'nft' | 'multitoken', + excludeMetadata?: ExcludeMetadata, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v4/data/collections`, + query: { + 'chain': chain, + 'collectionAddresses': collectionAddresses, + 'tokenTypes': tokenTypes, + 'excludeMetadata': excludeMetadata, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get tokens from a collection + *

10 credits per API call

+ *

Get all NFTs (ERC-721 and ERC-1155) and multitokens (ERC-1155 only) of your favorite collections! Our API lets you search for all tokens on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon / polygon-amoy
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
  • Tezos - tezos-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and comma-separated list of collection addresses. Our API will return relevant information about each token, including its name, description, image, and more.
  • + *
  • Aside from relevant information about each token, the response also contains metadata (they can, however, be excluded by setting excludeMetadata to true).
  • + *
  • If not specified, the API returns results for all supported types of tokens (nft, multitokens), but you can also choose to filter only one tokenType.
  • + *
  • For Tezos blockchain query parameters excludeMetadata and tokenType won't have any effect on filtering data.
  • + *
+ * + * @param chain The blockchain to work with. + * @param collectionAddresses The blockchain addresses of the collections. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param tokenTypes The option to select only specific token types. + * It is possible to enter list of multiple types as a comma separated string. + * Use nft (includes ERC-721 and ERC-1155) or multitoken (ERC-1155 only). + * + * @param excludeMetadata The option to exclude metadata from the response. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns any OK + * @throws ApiError + */ + public static getCollections( + chain: ChainEnum, + collectionAddresses: TokenAddress, + tokenTypes?: 'nft' | 'multitoken', + excludeMetadata?: ExcludeMetadata, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v3/data/collections`, + query: { + 'chain': chain, + 'collectionAddresses': collectionAddresses, + 'tokenTypes': tokenTypes, + 'excludeMetadata': excludeMetadata, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Get token metadata + *

5 credits per API call

+ *

Get metadata of NFTs (ERC-721 and ERC-1155) or multitokens (ERC-1155 only) by IDs for a given token address! Our API lets you search for all tokens on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name, token address and comma-separated list of IDs. Our API will return relevant metadata about each specified token, including its name, description, image, and more.
  • + *
  • Aside from the metadata information, the response also contains token types and metadata url minted in each token.
  • + *
+ * + * @param chain The blockchain to work with. + * @param tokenAddress The blockchain address of the NFT to get metadata for. + * @param tokenIds The IDs of the tokens to get metadata for. + * It is possible to enter list of multiple IDs as a comma separated string. + * + * @returns any OK + * @throws ApiError + */ + public static getMetadataV4( + chain: ChainEnum, + tokenAddress: TokenAddress, + tokenIds: TokenIds, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v4/data/metadata`, + query: { + 'chain': chain, + 'tokenAddress': tokenAddress, + 'tokenIds': tokenIds, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get token metadata + *

5 credits per API call

+ *

Get metadata of NFTs (ERC-721 and ERC-1155) or multitokens (ERC-1155 only) by IDs for a given token address! Our API lets you search for all tokens on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name, token address and comma-separated list of IDs. Our API will return relevant metadata about each specified token, including its name, description, image, and more.
  • + *
  • Aside from the metadata information, the response also contains token types and metadata url minted in each token.
  • + *
+ * + * @param chain The blockchain to work with. + * @param tokenAddress The blockchain address of the NFT to get metadata for. + * @param tokenIds The IDs of the tokens to get metadata for. + * It is possible to enter list of multiple IDs as a comma separated string. + * + * @returns any OK + * @throws ApiError + */ + public static getMetadata( + chain: ChainEnum, + tokenAddress: TokenAddress, + tokenIds: TokenIds, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v3/data/metadata`, + query: { + 'chain': chain, + 'tokenAddress': tokenAddress, + 'tokenIds': tokenIds, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Get owners of a token + *

20 credits per API call

+ *

Get all addresses that own your favorite token (ERC-20, ERC-721 or ERC-1155)! Our API lets you search for all token owners on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and address of any fungible token, NFT or multitoken collection. Our API will return a list of addresses of all of their owners.
  • + *
  • You can also get an owner of a specific NFT by specifying tokenId. In case of multitoken, result is an array of addresses.
  • + *
+ * + * @param chain The blockchain to work with. + * @param tokenAddress The blockchain address of the token (NFT collection or any fungible token). + * @param tokenId The ID of a specific NFT token. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns string OK + * @throws ApiError + */ + public static getOwnersV4( + chain: ChainEnum, + tokenAddress: TokenAddress, + tokenId?: TokenId, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v4/data/owners`, + query: { + 'chain': chain, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get owners of a token + *

20 credits per API call

+ *

Get all addresses that own your favorite token (ERC-20, ERC-721 or ERC-1155)! Our API lets you search for all token owners on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and address of any fungible token, NFT or multitoken collection. Our API will return a list of addresses of all of their owners.
  • + *
  • You can also get an owner of a specific NFT by specifying tokenId. In case of multitoken, result is an array of addresses.
  • + *
+ * + * @param chain The blockchain to work with. + * @param tokenAddress The blockchain address of the token (NFT collection or any fungible token). + * @param tokenId The ID of a specific NFT token. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns string OK + * @throws ApiError + */ + public static getOwners( + chain: ChainEnum, + tokenAddress: TokenAddress, + tokenId?: TokenId, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v3/data/owners`, + query: { + 'chain': chain, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Check owner of token + *

1 credit per API call

+ *

Check if wallet address owns any specified token (ERC-20, ERC-721 or ERC-1155) on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name, wallet address and address of any fungible token, NFT or multitoken collection. Our API will return true if provided wallet address owns them.
  • + *
  • If wallet address does not own the specific token, response body is false and status code is 200.
  • + *
  • It is also possible to check if wallet address owns a specific NFT by specifying a tokenId.
  • + *
+ * + * @param chain The blockchain to work with. + * @param address The blockchain address of the wallet. + * @param tokenAddress The blockchain address of the token (NFT collection or any fungible token). + * @param tokenId The ID of a specific NFT token. + * @returns boolean OK + * @throws ApiError + */ + public static checkOwnerV4( + chain: ChainEnum, + address: string, + tokenAddress: TokenAddress, + tokenId?: TokenId, + ): CancelablePromise { + return __request({ + method: 'GET', + path: `/v4/data/owners/address`, + query: { + 'chain': chain, + 'address': address, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Check owner of token + *

1 credit per API call

+ *

Check if wallet address owns any specified token (ERC-20, ERC-721 or ERC-1155) on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name, wallet address and address of any fungible token, NFT or multitoken collection. Our API will return true if provided wallet address owns them.
  • + *
  • If wallet address does not own the specific token, response body is false and status code is 200.
  • + *
  • It is also possible to check if wallet address owns a specific NFT by specifying a tokenId.
  • + *
+ * + * @param chain The blockchain to work with. + * @param address The blockchain address of the wallet. + * @param tokenAddress The blockchain address of the token (NFT collection or any fungible token). + * @param tokenId The ID of a specific NFT token. + * @returns boolean OK + * @throws ApiError + */ + public static checkOwner( + chain: ChainEnum, + address: string, + tokenAddress: TokenAddress, + tokenId?: TokenId, + ): CancelablePromise { + return __request({ + method: 'GET', + path: `/v3/data/owners/address`, + query: { + 'chain': chain, + 'address': address, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/NftErc721OrCompatibleService.ts b/packages/api-client/src/generated/services/NftErc721OrCompatibleService.ts index 6244c838e..9636971a7 100644 --- a/packages/api-client/src/generated/services/NftErc721OrCompatibleService.ts +++ b/packages/api-client/src/generated/services/NftErc721OrCompatibleService.ts @@ -1112,4 +1112,4 @@ export class NftErc721OrCompatibleService { }); } - } + } \ No newline at end of file diff --git a/packages/api-client/src/generated/services/NodeRpcService.ts b/packages/api-client/src/generated/services/NodeRpcService.ts index a375b8e21..08c19f320 100644 --- a/packages/api-client/src/generated/services/NodeRpcService.ts +++ b/packages/api-client/src/generated/services/NodeRpcService.ts @@ -108,4 +108,4 @@ export class NodeRpcService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/NotificationSubscriptionsService.ts b/packages/api-client/src/generated/services/NotificationSubscriptionsService.ts index 2344b4c75..4b30481fa 100644 --- a/packages/api-client/src/generated/services/NotificationSubscriptionsService.ts +++ b/packages/api-client/src/generated/services/NotificationSubscriptionsService.ts @@ -801,4 +801,4 @@ export class NotificationSubscriptionsService { }); } - } + } \ No newline at end of file diff --git a/packages/api-client/src/generated/services/OrderBookService.ts b/packages/api-client/src/generated/services/OrderBookService.ts index c24e59841..6031f42e2 100644 --- a/packages/api-client/src/generated/services/OrderBookService.ts +++ b/packages/api-client/src/generated/services/OrderBookService.ts @@ -415,4 +415,4 @@ export class OrderBookService { }); } - } + } \ No newline at end of file diff --git a/packages/api-client/src/generated/services/PolygonService.ts b/packages/api-client/src/generated/services/PolygonService.ts index 19fb5e182..edbe1834b 100644 --- a/packages/api-client/src/generated/services/PolygonService.ts +++ b/packages/api-client/src/generated/services/PolygonService.ts @@ -385,4 +385,4 @@ export class PolygonService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/ServiceUtilsService.ts b/packages/api-client/src/generated/services/ServiceUtilsService.ts index c9eac1f5d..29b6785b4 100644 --- a/packages/api-client/src/generated/services/ServiceUtilsService.ts +++ b/packages/api-client/src/generated/services/ServiceUtilsService.ts @@ -94,4 +94,4 @@ export class ServiceUtilsService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/SolanaService.ts b/packages/api-client/src/generated/services/SolanaService.ts index 0301880b8..fe1828cde 100644 --- a/packages/api-client/src/generated/services/SolanaService.ts +++ b/packages/api-client/src/generated/services/SolanaService.ts @@ -217,4 +217,4 @@ export class SolanaService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/StellarService.ts b/packages/api-client/src/generated/services/StellarService.ts index 3428e78f2..c31b0a8b5 100644 --- a/packages/api-client/src/generated/services/StellarService.ts +++ b/packages/api-client/src/generated/services/StellarService.ts @@ -282,4 +282,4 @@ export class StellarService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/TokenApiService.ts b/packages/api-client/src/generated/services/TokenApiService.ts new file mode 100644 index 000000000..c0a7ef8d8 --- /dev/null +++ b/packages/api-client/src/generated/services/TokenApiService.ts @@ -0,0 +1,115 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +import type { ChainEnum } from '../models/ChainEnum'; +import type { FungibleInfo } from '../models/FungibleInfo'; +import type { FungibleInfoTezos } from '../models/FungibleInfoTezos'; +import type { MultitokenInfo } from '../models/MultitokenInfo'; +import type { NftInfo } from '../models/NftInfo'; +import type { NftInfoTezos } from '../models/NftInfoTezos'; +import type { NftTokenInfo } from '../models/NftTokenInfo'; +import type { TokenAddress } from '../models/TokenAddress'; +import type { TokenId } from '../models/TokenId'; +import type { CancelablePromise } from '../core/CancelablePromise'; +import { request as __request } from '../core/request'; + +export class TokenApiService { + + /** + * Get information about collection or token + *

1 credit per API call

+ *

Get information about your favorite token! Our API lets you search for all tokens on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
  • Tezos - tezos-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain and address of any fungible token, NFT or multitoken collection. If available, our API will return information about them such as their name, symbol, supply, and more.
  • + *
  • You can also get extra infomation (such as metadata) of a specific NFT or multitoken by passing tokenId as a query parameter.
  • + *
+ * + * @param chain The blockchain to work with. + * @param tokenAddress The blockchain address of the token (NFT collection or any fungible token). + * @param tokenId The ID of a specific NFT token. + * @returns any OK + * @throws ApiError + */ + public static getTokensV4( + chain: ChainEnum, + tokenAddress: TokenAddress, + tokenId?: TokenId, + ): CancelablePromise<(FungibleInfo | NftInfo | MultitokenInfo | NftTokenInfo | NftInfoTezos | FungibleInfoTezos)> { + return __request({ + method: 'GET', + path: `/v4/data/tokens`, + query: { + 'chain': chain, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 404: `Collection or token not found.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get information about collection or token + *

1 credit per API call

+ *

Get information about your favorite token! Our API lets you search for all tokens on:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
  • Tezos - tezos-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain and address of any fungible token, NFT or multitoken collection. If available, our API will return information about them such as their name, symbol, supply, and more.
  • + *
  • You can also get extra infomation (such as metadata) of a specific NFT or multitoken by passing tokenId as a query parameter.
  • + *
+ * + * @param chain The blockchain to work with. + * @param tokenAddress The blockchain address of the token (NFT collection or any fungible token). + * @param tokenId The ID of a specific NFT token. + * @returns any OK + * @throws ApiError + */ + public static getTokens( + chain: ChainEnum, + tokenAddress: TokenAddress, + tokenId?: TokenId, + ): CancelablePromise<(FungibleInfo | NftInfo | MultitokenInfo | NftTokenInfo | NftInfoTezos | FungibleInfoTezos)> { + return __request({ + method: 'GET', + path: `/v3/data/tokens`, + query: { + 'chain': chain, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 404: `Collection or token not found.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/TransactionService.ts b/packages/api-client/src/generated/services/TransactionService.ts index a5495af14..86b8e9296 100644 --- a/packages/api-client/src/generated/services/TransactionService.ts +++ b/packages/api-client/src/generated/services/TransactionService.ts @@ -199,4 +199,4 @@ export class TransactionService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/TransactionsApiService.ts b/packages/api-client/src/generated/services/TransactionsApiService.ts new file mode 100644 index 000000000..a22002250 --- /dev/null +++ b/packages/api-client/src/generated/services/TransactionsApiService.ts @@ -0,0 +1,296 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +import type { BlockNumber } from '../models/BlockNumber'; +import type { BlockNumberTo } from '../models/BlockNumberTo'; +import type { ChainEnumExtended } from '../models/ChainEnumExtended'; +import type { Cursor } from '../models/Cursor'; +import type { Offset } from '../models/Offset'; +import type { PageSize } from '../models/PageSize'; +import type { TokenAddress } from '../models/TokenAddress'; +import type { TokenId } from '../models/TokenId'; +import type { TxData } from '../models/TxData'; +import type { CancelablePromise } from '../core/CancelablePromise'; +import { request as __request } from '../core/request'; + +export class TransactionsApiService { + + /** + * Get transactions + *

20 credits per API call

+ *

Get transactions on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Tezos - tezos-mainnet
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and comma-separated list of addresses. Our API will return all of their transactions along with further information such as their block number, ID of involved token, and more.
  • + *
  • If not specified, the API returns transactions of various types (fungible, nft, multitoken, native), but you can also choose to filter specific transactionTypes and even transactionSubtype (incoming, outgoing, zero-transfer).
  • + *
  • On top of that, you can add further filters such as specifying block range where the transactions should have occurred, or address and ID of involved tokens.
  • + *
  • For Tezos blockchain, the API accepts only one wallet address in addresses query parameter. Following query parameters won't have any effect on filtering data: transactionTypes, transactionSubtype, tokenId, blockTo.
  • + *
  • When querying Tezos transactions for a specified wallet or contract address, pagination is supported via pageSize and offset query parameters. + *
  • When querying Tezos transactions for a specified block, pagination is supported via cursor query parameter, by filling in the value from prevPage or nextPage field in the response body.
  • + *
  • When you are filtering data using blockFrom and not using blockTo, blockTo is automatically added as blockFrom + 1000. The same applies when blockTo is present and blockFrom is not. In that case blockFrom is automatically added as blockTo - 1000.
  • + *
+ * + * @param chain The blockchain to work with. + * @param addresses The blockchain public wallet addresses. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param transactionTypes The option to filter transaction based on types. + * It is possible to enter list of multiple types as a comma separated string. + * Use fungible (ERC-20), nft (ERC-721 and ERC-1155), multitoken (ERC-1155) or native. + * + * @param transactionSubtype The option to filter transaction based on subtype. + * @param tokenAddress Address of a token (smart contract). + * @param tokenId ID of a token. + * @param blockFrom Transactions from this block onwards will be included. If blockTo is not specified, it is automatically calculated as blockFrom + 1000. + * @param blockTo Transactions up to this block will be included. If blockFrom is not specified, it is automatically calculated as blockTo - 1000. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @param cursor The cursor to obtain previous page or next page of the data. Available only for Tezos blockchain. + * @returns any OK + * @throws ApiError + */ + public static getTransactionsV4( + chain: ChainEnumExtended, + addresses?: string, + transactionTypes?: 'fungible' | 'nft' | 'multitoken' | 'native', + transactionSubtype?: 'incoming' | 'outgoing' | 'zero-transfer', + tokenAddress?: TokenAddress, + tokenId?: TokenId, + blockFrom?: BlockNumber, + blockTo?: BlockNumberTo, + pageSize?: PageSize, + offset?: Offset, + cursor?: Cursor, + ): CancelablePromise<{ + /** + * List of all selected transactions. + */ + result?: Array; + /** + * Cursor pagination, used to get previous page of results (only relevant for Tezos). + */ + prevPage?: string; + /** + * Cursor pagination, used to get next page of results (only relevant for Tezos). + */ + nextPage?: string; + }> { + return __request({ + method: 'GET', + path: `/v4/data/transactions`, + query: { + 'chain': chain, + 'addresses': addresses, + 'transactionTypes': transactionTypes, + 'transactionSubtype': transactionSubtype, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + 'blockFrom': blockFrom, + 'blockTo': blockTo, + 'pageSize': pageSize, + 'offset': offset, + 'cursor': cursor, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get transactions + *

20 credits per API call

+ *

Get transactions on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Tezos - tezos-mainnet
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and comma-separated list of addresses. Our API will return all of their transactions along with further information such as their block number, ID of involved token, and more.
  • + *
  • If not specified, the API returns transactions of various types (fungible, nft, multitoken, native), but you can also choose to filter specific transactionTypes and even transactionSubtype (incoming, outgoing, zero-transfer).
  • + *
  • On top of that, you can add further filters such as specifying block range where the transactions should have occurred, or address and ID of involved tokens.
  • + *
  • For Tezos blockchain, the API accepts only one wallet address in addresses query parameter. Following query parameters won't have any effect on filtering data: transactionTypes, transactionSubtype, tokenId, blockTo.
  • + *
  • When querying Tezos transactions for a specified wallet or contract address, pagination is supported via pageSize and offset query parameters. + *
  • When querying Tezos transactions for a specified block, pagination is supported via cursor query parameter, by filling in the value from prevPage or nextPage field in the response body.
  • + *
  • When you are filtering data using blockFrom and not using blockTo, blockTo is automatically added as blockFrom + 1000. The same applies when blockTo is present and blockFrom is not. In that case blockFrom is automatically added as blockTo - 1000.
  • + *
+ * + * @param chain The blockchain to work with. + * @param addresses The blockchain public wallet addresses. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param transactionTypes The option to filter transaction based on types. + * It is possible to enter list of multiple types as a comma separated string. + * Use fungible (ERC-20), nft (ERC-721 and ERC-1155), multitoken (ERC-1155) or native. + * + * @param transactionSubtype The option to filter transaction based on subtype. + * @param tokenAddress Address of a token (smart contract). + * @param tokenId ID of a token. + * @param blockFrom Transactions from this block onwards will be included. If blockTo is not specified, it is automatically calculated as blockFrom + 1000. + * @param blockTo Transactions up to this block will be included. If blockFrom is not specified, it is automatically calculated as blockTo - 1000. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @param cursor The cursor to obtain previous page or next page of the data. Available only for Tezos blockchain. + * @returns any OK + * @throws ApiError + */ + public static getTransactions( + chain: ChainEnumExtended, + addresses?: string, + transactionTypes?: 'fungible' | 'nft' | 'multitoken' | 'native', + transactionSubtype?: 'incoming' | 'outgoing' | 'zero-transfer', + tokenAddress?: TokenAddress, + tokenId?: TokenId, + blockFrom?: BlockNumber, + blockTo?: BlockNumberTo, + pageSize?: PageSize, + offset?: Offset, + cursor?: Cursor, + ): CancelablePromise<{ + /** + * List of all selected transactions. + */ + result?: Array; + /** + * Cursor pagination, used to get previous page of results (only relevant for Tezos). + */ + prevPage?: string; + /** + * Cursor pagination, used to get next page of results (only relevant for Tezos). + */ + nextPage?: string; + }> { + return __request({ + method: 'GET', + path: `/v3/data/transactions`, + query: { + 'chain': chain, + 'addresses': addresses, + 'transactionTypes': transactionTypes, + 'transactionSubtype': transactionSubtype, + 'tokenAddress': tokenAddress, + 'tokenId': tokenId, + 'blockFrom': blockFrom, + 'blockTo': blockTo, + 'pageSize': pageSize, + 'offset': offset, + 'cursor': cursor, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Get transactions by hash + *

5 credits per API call

+ *

Get transactions by hash on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Tezos - tezos-mainnet
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and transaction hash, and our API will return a list of transactions with that hash.
  • + *
  • The response will contain all the relevant information about specified transactions such as their block number, IDs of involved token, and more.
  • + *
+ * + * @param chain The blockchain to work with. + * @param hash Hash of the transaction. + * @returns TxData OK + * @throws ApiError + */ + public static getTransactionsByHashV4( + chain: ChainEnumExtended, + hash: string, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v4/data/transactions/hash`, + query: { + 'chain': chain, + 'hash': hash, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get transactions by hash + *

5 credits per API call

+ *

Get transactions by hash on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Tezos - tezos-mainnet
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and transaction hash, and our API will return a list of transactions with that hash.
  • + *
  • The response will contain all the relevant information about specified transactions such as their block number, IDs of involved token, and more.
  • + *
+ * + * @param chain The blockchain to work with. + * @param hash Hash of the transaction. + * @returns TxData OK + * @throws ApiError + */ + public static getTransactionsByHash( + chain: ChainEnumExtended, + hash: string, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v3/data/transactions/hash`, + query: { + 'chain': chain, + 'hash': hash, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/TronService.ts b/packages/api-client/src/generated/services/TronService.ts index 58aa8782c..55b37700d 100644 --- a/packages/api-client/src/generated/services/TronService.ts +++ b/packages/api-client/src/generated/services/TronService.ts @@ -609,4 +609,4 @@ export class TronService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/VeChainService.ts b/packages/api-client/src/generated/services/VeChainService.ts index ede0208ef..82c2e2f55 100644 --- a/packages/api-client/src/generated/services/VeChainService.ts +++ b/packages/api-client/src/generated/services/VeChainService.ts @@ -300,4 +300,4 @@ export class VeChainService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/VirtualAccountBlockchainFeesService.ts b/packages/api-client/src/generated/services/VirtualAccountBlockchainFeesService.ts index cedaa2d48..613d5a658 100644 --- a/packages/api-client/src/generated/services/VirtualAccountBlockchainFeesService.ts +++ b/packages/api-client/src/generated/services/VirtualAccountBlockchainFeesService.ts @@ -41,4 +41,4 @@ export class VirtualAccountBlockchainFeesService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/VirtualCurrencyService.ts b/packages/api-client/src/generated/services/VirtualCurrencyService.ts index 12ff97314..f53410ee4 100644 --- a/packages/api-client/src/generated/services/VirtualCurrencyService.ts +++ b/packages/api-client/src/generated/services/VirtualCurrencyService.ts @@ -148,4 +148,4 @@ export class VirtualCurrencyService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/WalletApiService.ts b/packages/api-client/src/generated/services/WalletApiService.ts new file mode 100644 index 000000000..5d030c7f0 --- /dev/null +++ b/packages/api-client/src/generated/services/WalletApiService.ts @@ -0,0 +1,383 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +import type { BalanceItem } from '../models/BalanceItem'; +import type { ChainEnumExtended } from '../models/ChainEnumExtended'; +import type { ChainUtxoEnum } from '../models/ChainUtxoEnum'; +import type { ExcludeMetadata } from '../models/ExcludeMetadata'; +import type { Offset } from '../models/Offset'; +import type { PageSize } from '../models/PageSize'; +import type { Utxo } from '../models/Utxo'; +import type { CancelablePromise } from '../core/CancelablePromise'; +import { request as __request } from '../core/request'; + +export class WalletApiService { + + /** + * Get balances of addresses + *

50 credits per API call

+ *

Get balances of fungible tokens (ERC-20), NFTs (ERC-721 and ERC-1155) or multitokens (ERC-1155 only) for a specific wallet address on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Tezos - tezos-mainnet
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and comma-separated list of addresses. Our API will return balances of each token along with further information such as its type, id, and more.
  • + *
  • Aside from relevant information about each token and its balance, the response also contains metadata (they can, however, be excluded by setting excludeMetadata to true).
  • + *
  • If not specified, the API returns balances for all supported types of tokens (fungible tokens, nft, multitokens), but you can also choose to filter specific tokenTypes.
  • + *
  • For Tezos blockchain, the API returns balance of any tokens including native token (XTZ) for specified wallet addresses. Following query parameters won't have any effect on filtering data excludeMetadata.
  • + *
+ * + * @param chain The blockchain to work with. + * @param addresses The blockchain public wallet addresses. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param tokenTypes The option to select only specific token types. + * It is possible to enter list of multiple types as a comma separated string. + * Use fungible (ERC-20), nft (includes ERC-721 and ERC-1155) or multitoken (ERC-1155 only). + * + * @param excludeMetadata The option to exclude metadata from the response. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns any OK + * @throws ApiError + */ + public static getBalancesV4( + chain: ChainEnumExtended, + addresses: string, + tokenTypes?: 'nft' | 'multitoken' | 'fungible', + excludeMetadata?: ExcludeMetadata, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise<{ + /** + * List of all balances for all selected tokens. + */ + result?: Array; + /** + * Cursor pagination, used to get previous page of results (work in progress, not used right now). + */ + prevPage?: string; + /** + * Cursor pagination, used to get next page of results (work in progress, not used right now). + */ + nextPage?: string; + }> { + return __request({ + method: 'GET', + path: `/v4/data/balances`, + query: { + 'chain': chain, + 'addresses': addresses, + 'tokenTypes': tokenTypes, + 'excludeMetadata': excludeMetadata, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get balances of addresses + *

50 credits per API call

+ *

Get balances of fungible tokens (ERC-20), NFTs (ERC-721 and ERC-1155) or multitokens (ERC-1155 only) for a specific wallet address on the following blockchains:

+ *
    + *
  • Celo - celo / celo-testnet
  • + *
  • Ethereum - ethereum / ethereum-sepolia / ethereum-holesky
  • + *
  • BNB (Binance) Smart Chain - bsc / bsc-testnet
  • + *
  • Polygon - polygon
  • + *
  • Tezos - tezos-mainnet
  • + *
  • Horizen EON - eon-mainnet
  • + *
  • Chiliz - chiliz-mainnet
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain name and comma-separated list of addresses. Our API will return balances of each token along with further information such as its type, id, and more.
  • + *
  • Aside from relevant information about each token and its balance, the response also contains metadata (they can, however, be excluded by setting excludeMetadata to true).
  • + *
  • If not specified, the API returns balances for all supported types of tokens (fungible tokens, nft, multitokens), but you can also choose to filter specific tokenTypes.
  • + *
  • For Tezos blockchain, the API returns balance of any tokens including native token (XTZ) for specified wallet addresses. Following query parameters won't have any effect on filtering data excludeMetadata.
  • + *
+ * + * @param chain The blockchain to work with. + * @param addresses The blockchain public wallet addresses. + * It is possible to enter list of up to 10 addresses as a comma separated string. + * + * @param tokenTypes The option to select only specific token types. + * It is possible to enter list of multiple types as a comma separated string. + * Use fungible (ERC-20), nft (includes ERC-721 and ERC-1155) or multitoken (ERC-1155 only). + * + * @param excludeMetadata The option to exclude metadata from the response. + * @param pageSize The number of items per page (default is 50). + * @param offset The offset to obtain next page of the data. + * @returns any OK + * @throws ApiError + */ + public static getBalances( + chain: ChainEnumExtended, + addresses: string, + tokenTypes?: 'nft' | 'multitoken' | 'fungible', + excludeMetadata?: ExcludeMetadata, + pageSize?: PageSize, + offset?: Offset, + ): CancelablePromise<{ + /** + * List of all balances for all selected tokens. + */ + result?: Array; + /** + * Cursor pagination, used to get previous page of results (work in progress, not used right now). + */ + prevPage?: string; + /** + * Cursor pagination, used to get next page of results (work in progress, not used right now). + */ + nextPage?: string; + }> { + return __request({ + method: 'GET', + path: `/v3/data/balances`, + query: { + 'chain': chain, + 'addresses': addresses, + 'tokenTypes': tokenTypes, + 'excludeMetadata': excludeMetadata, + 'pageSize': pageSize, + 'offset': offset, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Get unspent UTXOs for an address + *

100 credits per API call

+ *

Get unspent UTXOs for a specific address up to a specific total amount. + * If you want to prepare a transaction on UTXO-based chains like Bitcoin, you need to enter unspent UTXOs to be able to perform a transaction. By providing ```totalValue``` as a total, our API will return a list of UTXOs that will be enough to cover the transaction.

+ * Our API lets you get the unpenst UTXOs for a specific address on:

+ *
    + *
  • Bitcoin - bitcoin / bitcoin-testnet
  • + *
  • Litecoin - litecoin / litecoin-testnet
  • + *
  • Dogecoin - doge / doge-testnet
  • + *
  • Cardano - cardano / cardano-preprod
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain and address you want to list unspent UTXOs for. If available, our API will return information about the unspent UTXOs for a specific address. API traverses latest 200k incoming transactions.
  • + *
+ * + * @param chain The blockchain to work with. + * @param address The blockchain address. + * @param totalValue The total amount of transaction you want to send. Only UTXOs up to this amount will be returned, so you will not spend more than you need. + * @returns Utxo OK + * @throws ApiError + */ + public static getUtxosByAddressV4( + chain: ChainUtxoEnum, + address: string, + totalValue: number, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v4/data/utxos`, + query: { + 'chain': chain, + 'address': address, + 'totalValue': totalValue, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get unspent UTXOs for an address + *

100 credits per API call

+ *

Get unspent UTXOs for a specific address up to a specific total amount. + * If you want to prepare a transaction on UTXO-based chains like Bitcoin, you need to enter unspent UTXOs to be able to perform a transaction. By providing ```totalValue``` as a total, our API will return a list of UTXOs that will be enough to cover the transaction.

+ * Our API lets you get the unpenst UTXOs for a specific address on:

+ *
    + *
  • Bitcoin - bitcoin / bitcoin-testnet
  • + *
  • Litecoin - litecoin / litecoin-testnet
  • + *
  • Dogecoin - doge / doge-testnet
  • + *
  • Cardano - cardano / cardano-preprod
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain and address you want to list unspent UTXOs for. If available, our API will return information about the unspent UTXOs for a specific address. API traverses latest 200k incoming transactions.
  • + *
+ * + * @param chain The blockchain to work with. + * @param address The blockchain address. + * @param totalValue The total amount of transaction you want to send. Only UTXOs up to this amount will be returned, so you will not spend more than you need. + * @returns Utxo OK + * @throws ApiError + */ + public static getUtxosByAddress( + chain: ChainUtxoEnum, + address: string, + totalValue: number, + ): CancelablePromise> { + return __request({ + method: 'GET', + path: `/v3/data/utxos`, + query: { + 'chain': chain, + 'address': address, + 'totalValue': totalValue, + }, + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * Get unspent UTXOs for a batch of addresses + *

100 credits per address for each API call.

+ *

Retrieve unspent UTXOs for each provided address, up to a specified total amount. + * If you want to prepare a transaction on UTXO-based chains like Bitcoin, you need to enter unspent UTXOs to be able to perform a transaction. By providing ```totalValue``` as a total, our API will return a list of UTXOs that will be enough to cover the transaction.

+ * Our API lets you get the unpenst UTXOs for a specific address on:

+ *
    + *
  • Bitcoin - bitcoin / bitcoin-testnet
  • + *
  • Litecoin - litecoin / litecoin-testnet
  • + *
  • Dogecoin - doge / doge-testnet
  • + *
  • Cardano - cardano / cardano-preprod
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain and addresses you want to list unspent UTXOs for. If available, our API will return information about the unspent UTXOs for each address. API traverses latest 200k incoming transactions.
  • + *
+ * + * @param requestBody + * @returns any OK + * @throws ApiError + */ + public static getUtxosByAddressBatchV4( + requestBody: { + chain?: ChainUtxoEnum; + /** + * Addresses + */ + addresses: Array; + /** + * The total amount of transaction you want to send. Only UTXOs up to this amount will be returned, so you will not spend more than you need. + */ + totalValue: number; + }, + ): CancelablePromise; + /** + * Indicate whether the total value of UTXOs is sufficient for the transaction. + */ + transactionPossible?: boolean; + }>> { + return __request({ + method: 'POST', + path: `/v4/data/utxos/batch`, + body: requestBody, + mediaType: 'application/json', + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + + /** + * @deprecated + * Get unspent UTXOs for a batch of addresses + *

100 credits per address for each API call.

+ *

Retrieve unspent UTXOs for each provided address, up to a specified total amount. + * If you want to prepare a transaction on UTXO-based chains like Bitcoin, you need to enter unspent UTXOs to be able to perform a transaction. By providing ```totalValue``` as a total, our API will return a list of UTXOs that will be enough to cover the transaction.

+ * Our API lets you get the unpenst UTXOs for a specific address on:

+ *
    + *
  • Bitcoin - bitcoin / bitcoin-testnet
  • + *
  • Litecoin - litecoin / litecoin-testnet
  • + *
  • Dogecoin - doge / doge-testnet
  • + *
  • Cardano - cardano / cardano-preprod
  • + *
+ *

To get started:

+ *
    + *
  • Provide a chain and addresses you want to list unspent UTXOs for. If available, our API will return information about the unspent UTXOs for each address. API traverses latest 200k incoming transactions.
  • + *
+ * + * @param requestBody + * @returns any OK + * @throws ApiError + */ + public static getUtxosByAddressBatch( + requestBody: { + chain?: ChainUtxoEnum; + /** + * Addresses + */ + addresses: Array; + /** + * The total amount of transaction you want to send. Only UTXOs up to this amount will be returned, so you will not spend more than you need. + */ + totalValue: number; + }, + ): CancelablePromise; + /** + * Indicate whether the total value of UTXOs is sufficient for the transaction. + */ + transactionPossible?: boolean; + }>> { + return __request({ + method: 'POST', + path: `/v3/data/utxos/batch`, + body: requestBody, + mediaType: 'application/json', + errors: { + 400: `Bad Request`, + 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, + 403: `Forbidden. The request is authenticated, but it is not possible to perform the operation due to logical error or invalid permissions.`, + 500: `Internal server error. There was an error on the server during the processing of the request.`, + }, + }); + } + +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/WithdrawalService.ts b/packages/api-client/src/generated/services/WithdrawalService.ts index fa322840e..fcf8db918 100644 --- a/packages/api-client/src/generated/services/WithdrawalService.ts +++ b/packages/api-client/src/generated/services/WithdrawalService.ts @@ -199,4 +199,4 @@ export class WithdrawalService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/XinFinService.ts b/packages/api-client/src/generated/services/XinFinService.ts index 550cc75ee..2d1c603a7 100644 --- a/packages/api-client/src/generated/services/XinFinService.ts +++ b/packages/api-client/src/generated/services/XinFinService.ts @@ -359,4 +359,4 @@ export class XinFinService { }); } -} +} \ No newline at end of file diff --git a/packages/api-client/src/generated/services/XrpService.ts b/packages/api-client/src/generated/services/XrpService.ts index e7d194e93..836629cf2 100644 --- a/packages/api-client/src/generated/services/XrpService.ts +++ b/packages/api-client/src/generated/services/XrpService.ts @@ -328,4 +328,4 @@ export class XrpService { }); } -} +} \ No newline at end of file