4.2.3 提交区块监测信息

1、接口描述:提交区块监测信息

2、接口地址:/api/openapi/v1/chain/block/save

3、请求方式:POST

4、consumes:["application/json"]

5、produces:["/"]

6、请求示例:


{
    "blockHash": "0x0000000",
    "blockHeight": 1000,
    "blockSize": 123,
    "blockTime": "2023-05-05 11:11:11",
    "miner": "0x0000000",
    "parentBlockHash": "0x0000000",
    "txCount": 10,
    "txList": [
        {
            "miner": "0x0000000",
            "txDetail": "",
            "txHash": "0x0000000",
            "txTime": "2023-05-05 11:11:11"
        }
    ]
}

7、请求参数:

参数名称 参数说明 in 必填 数据类型 schema
accessKey accessKey header true string
blockAndTxPushVO blockAndTxPushVO body true BlockAndTxPushReqVO BlockAndTxPushReqVO

schema属性说明

BlockAndTxPushReqVO

参数名称 参数说明 in 是否必须 数据类型 schema
blockHash 区块hash:长度限制66 body true string
blockHeight 区块高度 body true number
blockSize 区块大小(bytes) body false integer(int64)
blockTime 落块时间 body true string
miner 区块签名者:长度限制100 body false string
parentBlockHash 父区块hash:长度限制100 body false string
txCount 区块内交易数量 body false integer(int32)
txList 区块内交易信息 body false array TxListInfo

TxListInfo

参数名称 参数说明 in 是否必须 数据类型 schema
miner 交易签名者:长度限制100 body true string
txDetail 交易详情:长度限制5000 body false string
txHash 交易hash:长度限制100 body true string
txTime 交易时间 body true string

8、响应示例

{
    "code": 0,
    "data": {},
    "message": "MSG_00_0000"
}

9、响应参数:

参数名称 参数说明 类型 schema
code code integer(int32) integer(int32)
data data object
message message string

results matching ""

    No results matching ""

    results matching ""

      No results matching ""