Get Block List#
Get the TradeZone block list with optional filtering by block height.
Request Path#
GET
https://web3.okx200.com/api/v5/xlayer/tz/block/block-listRequest Parameters#
| Parameter | Type | Required | Description |
|---|---|---|---|
| chainShortName | String | Yes | The abbreviated name of the blockchain network, e.g, TRADE_ZONE |
| height | String | No | The block height to filter by |
| limit | Integer | No | The number of results returned per request. The maximum is 100. The default is 20. |
| page | Integer | No | Page number, default 1 |
Response Parameters#
| Parameter | Type | Description |
|---|---|---|
| page | String | Current page number |
| limit | String | Number of results per page |
| totalPage | String | Total number of pages |
| total | String | Total number of records |
| data | Array | Block list |
| > hash | String | Block hash |
| > height | String | Block height |
| > miner | String | Block producer address |
| > blockTime | String | Block time (ms) |
| > transactionCount | String | Number of transactions in the block |
Request Example#
shell
curl --location --request GET 'https://web3.okx200.com/api/v5/xlayer/tz/block/block-list?chainShortName=TRADE_ZONE&limit=1' \
--header 'OK-ACCESS-KEY: 37c541a1-****-****-****-10fe7a038418' \
--header 'OK-ACCESS-SIGN: leaV********3uw=' \
--header 'OK-ACCESS-PASSPHRASE: 1****6' \
--header 'OK-ACCESS-TIMESTAMP: 2023-10-18T12:21:41.274Z'
Response Example#
json
{
"code": "0",
"msg": "",
"data": [
{
"page": "1",
"limit": "1",
"totalPage": "13107437",
"total": "13107437",
"data": [
{
"hash": "0x0aa0d3d8e43f9b75260eaac71e73091377c5c2142d93e47433428900071955b2",
"height": "21324075",
"miner": "0x4d3b3c2eea46467131ecdf6bd4a8787612651408",
"blockTime": "1779167409217",
"transactionCount": "0"
}
]
}
]
}
