XFI Scan API - Testnet
Queries
txs - queries for transactions
GET /api/1.0/txs
Retrieving a list of transactions.
Example of an answer: https://test.xfiscan.com/api/1.0/txs
Queries Parameters:
GET /api/1.0/txs/{hash} Getting the transaction hash.
Example of an answer: https://test.xfiscan.com/api/1.0/txs/D64C8804B101996F92F57603166CF2852C48DDDA959316034280088F1FF99731
blocks - query for blocks
GET /api/1.0/blocks
Getting a list of blocks.
Example of an answer: https://test.xfiscan.com/api/1.0/blocks
GET /api/1.0/blocks/latest Receiving the current confirmed block
Example of an answer: https://test.xfiscan.com/api/1.0/blocks/latest
Getting a specific block. Example of an answer: https://test.xfiscan.com/api/1.0/blocks/1
addresses - queries for account addresses
Retrieve a list of account addresses Example of an answer: https://test.xfiscan.com/api/1.0/addresses
GET /api/1.0/addresses/{address}
Get address by hash of account address. Example of an answer: https://test.xfiscan.com/api/1.0/addresses/mx1j3ys0zehrles4y8vxmlxry03vnx4yltyg2alsv
GET /api/1.0/addresses/rich-list/{type}
Getting a list of addresses by the number of tokens purchased.
Example of an answer: https://test.xfiscan.com/api/1.0/addresses/rich-list/mpx
validators - queries for validators.
Getting a list of validators.
Example of an answer: https://test.xfiscan.com/api/1.0/validators
GET /api/1.0/validators/{address}
Getting the validator by the address.
Example of an answer: https://test.xfiscan.com/api/1.0/validators/mxvaloper1902re99ggp60q58z4nhcc9jqutp3xmaq6jlx0u
GET /api/1.0/tokens-erc20/{address}
Receiving a token.
Example of an answer: https://test.xfiscan.com/api/1.0/tokens-erc20/0x739fD25CaeFe272DFf9dbab25f161cE36301BF14
stat - getting statistics
GET /api/1.0/stat
Example of an answer: https://test.xfiscan.com/api/1.0/stat
event-logs - smart contracts logs
Getting smart contracts logs.
Example of an answer: https://test.xfiscan.com/api/1.0/event-logs
contracts - smart contracts queries
Getting smart contracts. Example of an answer: https://test.xfiscan.com/api/1.0/contracts
tokens-erc20-transfers
GET /api/1.0/token-erc20-transfers
Query for tokenized transfers.
Example of an answer: https://test.xfiscan.com/api/1.0/token-erc20-transfers
tokens-erc20 - list of tokens of ERC-20 standard.
Getting a list of tokens.
Example of an answer: https://test.xfiscan.com/api/1.0/tokens-erc20
GET /api/1.0/tokens-erc20/{address}
Receiving a token.
Example of an answer: https://test.xfiscan.com/api/1.0/tokens-erc20/0x739fD25CaeFe272DFf9dbab25f161cE36301BF14
tokens-erc20-holders
GET /api/1.0/token-erc20-holders
Getting a list of token holders. Example of an answer: https://test.xfiscan.com/api/1.0/token-erc20-holders
search
GET /api/1.0/search
Searching an address, block, transaction, or token based on a passed value.
Example of an answer: https://test.xfiscan.com/api/1.0/search?value=0xf58941E4258320D76BdAb72C5eD8d47c25604e94
stream
OPTIONS /api/1.0/stream/new-block Getting a data stream of new block data. OPTIONS /api/1.0/stream/new-txs
Getting a data stream of new transactions.
Per socketio protocol.
Example for js:
where
url connection: https://test.xfiscan.com/stream, handshake path /api/1.0/stream, new-block - subscribe to receive new blocks, new-txs - subscribe to receive new transactions.
Last updated