Updated on 2023-10-09 GMT+08:00

Querying an Appchain

Function

This API is used to query the channel information.

URI

GET /v2/agent/apis/channel/{channel_name}/summary

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

channel_name

Yes

String

Channel name.

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token, which is obtained by calling an API.

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

peer_num

Number

Peer quantity.

chaincodes

Number

Contract quantity.

block_num

Number

Block quantity.

transaction_num

Number

Transaction quantity.

bph

Array of bph objects

Statistics on the number of blocks generated each hour.

bpm

Array of bpm objects

Statistics on the number of blocks generated every 5 minutes.

tph

Array of tph objects

Statistics on the number of contract transactions by hour.

tpm

Array of tpm objects

Statistics on the number of contract transactions every 5 minutes.

orgs_map

Array of orgs_map objects

Organization transaction statistics.

peers_list

Array of peers_list objects

Peer list.

Table 4 bph

Parameter

Type

Description

block

Number

Block quantity.

time

String

Time.

Table 5 bpm

Parameter

Type

Description

block

Number

Block quantity.

time

String

Time.

Table 6 tph

Parameter

Type

Description

tx

Number

Transaction quantity.

time

String

Time.

Table 7 tpm

Parameter

Type

Description

tx

Number

Transaction quantity.

time

String

Time.

Table 8 orgs_map

Parameter

Type

Description

org_name

String

Organization name.

tx_num

Number

Transaction quantity.

Table 9 peers_list

Parameter

Type

Description

org_name

String

Organization name.

org_id

String

Organization ID.

peer

String

Peer name.

url

String

PeerURL

status

String

Peer status.

Status code: 400

Table 10 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_message

String

Error description.

error_msg

String

Error description.

Example Requests

GET https://192.168.0.90:30603/v2/agent/apis/channel/channel/summary

Example Responses

Status code: 400

Bad Request

{
  "error_code" : "BCS.4000013",
  "error_message" : "request body is too large"
}

Status Codes

Status Code

Description

200

Success

400

Bad Request

Error Codes

See Error Codes.