Get Current Channels and Peers Joined on Each Channel

get

/console/admin/api/v2/dashboard/statistics/channelInfo

Gets a list of the currently existing channels and the peers joined on each channel.

Request

Supported Media Types
Query Parameters
Back to Top

Response

Supported Media Types

200 Response

Response with channel infos by restriction
Body ()
Root Schema : schema
Type: object
Show Source
Nested Schema : data
Type: array
Show Source
Nested Schema : StatsChannelInfo
Type: object
Show Source
Nested Schema : peers
Type: array
Show Source

400 Response

Invalid arguments
Body ()
Root Schema : 400errorModels
Type: object
Show Source
Example:
{
    "respMesg":"invalid argument"
}

Default Response

Unexpected error
Body ()
Root Schema : errorModel
Type: object
Show Source
Back to Top

Examples

This endpoint is used to get the number of currently existing channels and the list of channel names. For each channel the peers joined on the channel are returned. Time range is not supported for channelInfo.

The following example shows how to generate the channel information report by submitting a GET request on the REST resource using cURL.

curl -X GET -u username:password -k 
"http://<rest_server_url>:port/console/admin/api/v2/dashboard/statistics/channelInfo?channel=<channel>"

For example,

curl -X GET -u myname@oracle.com:mypswd -k 
"http://server.oracle.com:10000/console/admin/api/v2/dashboard/statistics/channelInfo?channel=default"

Example of the Response Body

The following example shows the contents of the response body in JSON format:

{
  "data": [
    {
      "channelName": "default",
      "peerNum": 4,
      "peers": [
        "peer0",
        "peer1",
        "peer2"
      ]
    }
  ]
}
Back to Top