Ankr End-Point

How to obtain the Ankr End-Point and make a simple request

Obtain Ankr End-point

After successfully deploying a Matic Full node, the End-point can be found on the application details, on the Information screen:

The RPC Endpoint has the following format:

Heimdall: http://<your-app-id>.ankr.com

Bor: http://bor-<your-app-id>.ankr.com

Example (as shown in the image above):

http://app-82026c54-a336-4ce4-bcae-352824351322.cls-593f3f46-316e-4f00-8ebd-9a45cfde390d.ankr.com

http://bor-app-82026c54-a336-4ce4-bcae-352824351322.cls-593f3f46-316e-4f00-8ebd-9a45cfde390d.ankr.com

Simple Json-RPC Request on Bor

// Request
curl -H "Content-Type: application/json" -d '{"id":1, "jsonrpc":"2.0", "method": "web3_clientVersion","params": []}' http://bor-<your-app-id>.ankr.com
// Result
{
"jsonrpc":"2.0",
"id":1,
"result":"Bor/v1.9.16-stable-a1b7e2fc/linux-amd64/go1.13.14"
}

Simple Rest Request on Heimdall

// Request
curl http://<your-app-id>.ankr.com/status
// Result
{
"jsonrpc": "2.0",
"id": "",
"result": {
"node_info": {
"protocol_version": {
"p2p": "7",
"block": "10",
"app": "0"
},
"id": "108dfef8b07641498491948ee86413091bb0ee42",
"listen_addr": "tcp://0.0.0.0:26656",
"network": "heimdall-80001",
"version": "0.32.7",
"channels": "4020212223303800",
"moniker": "AnkrTest",
"other": {
"tx_index": "on",
"rpc_address": "tcp://0.0.0.0:26657"
}
},
"sync_info": {
"latest_block_hash": "436403B4D18A961DCA541AF058B0763FD433E202716F2F100FAA2DE9FA4937A5",
"latest_app_hash": "F3BD1E1DB6752D1DB56BD98673EA8929DF7CA5B9868DDE69A3FFDCF180E49BD0",
"latest_block_height": "1572575",
"latest_block_time": "2020-09-10T04:59:26.323787911Z",
"catching_up": false
},
"validator_info": {
"address": "05A118FEB71CB11A32D4F4CBFB9DA12DED1517F9",
"pub_key": {
"type": "tendermint/PubKeySecp256k1",
"value": "BHucQWu3ddHCQyDz9StirC++ctUSIQNAjKPoEt+zZDoCAWwdcWRGKSu7yKoIcwVxnfklx8LOJQVk14yKabcJ8Oc="
},
"voting_power": "0"
}
}
}