Chain API offers the information about the available blockchain network.
Get Chain Information
Gets the information of the currently available blockchain network.
Request URL
Live URL | https://bc-api.qpyou.cn/core/v0/chain/info |
---|---|
Sandbox URL | https://sandbox-bc-api.qpyou.cn/core/v0/chain/info |
HTTP Method | GET |
Content-Type | application/json |
Header Parameters
Field Name | Description | Type | Required |
---|---|---|---|
Authorization | Authentication token required to call the API | string | Y |
Responses
Field Name | Description | Type |
---|---|---|
code | api request result code, 0: success | number |
message | the result message | String |
data | API response data | array |
data.network | the blockchain networks {ploygon, xpla} | string |
data.chainID | the blockchain ID | string |
Request Sample
1 2 3 4 |
curl -X 'GET' \ 'https://sandbox-bc-api.qpyou.cn/core/v0/chain/info' \ -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJrZXlObyI6MSwiaWQiOiJwbGF0Zm9ybSIsImNvbXBhbnkiO' \ -H 'accept: application/json' |
Response Sample
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
{ "code": 0, "message": "success", "data": [ { "network": "xpla", "chainID": "cube_47-5" }, { "network": "polygon", "chainID": "80001" } ] } |