TON
POST
GET
Last updated on January 1, 1970
1 min read
Method /jsonRPC undefined ()
connect with JSON-RPC protocol
/jsonRPC
All methods in the API are available through JSON-RPC protocol.
Parameters
jsonprc
- string
jsonrpc version
id
- string
request id
method
- string
method name
params
- json body
json body with method params
Request
curl --location --request POST 'https://ton.getblock.io/mainnet/jsonRPC'
--header 'x-api-key: YOUR-API-KEY'
--header 'Content-Type: application/json'
--data-raw '{"jsonrpc": "2.0",
"method": "getConsensusBlock",
"id": "getblock.io"}'
Response
{
"ok": true,
"result": {
"consensus_block": 30517987,
"timestamp": 1687339459.355614
},
"jsonrpc": "2.0",
"id": "getblock"
}
Start Building with GetBlock RPCs for Free
Previous
{ "overview": "Overview", "guides": "Guides", "get-started": "Get Started", "rpc-service": "Nodes Methods", "getblock-explorer": "Explorer API", "getblock-tracker": "Tracker API", "nodes-endpoints": "Nodes Endpoints" }
Next
{ "overview": "Overview", "guides": "Guides", "get-started": "Get Started", "rpc-service": "Nodes Methods", "getblock-explorer": "Explorer API", "getblock-tracker": "Tracker API", "nodes-endpoints": "Nodes Endpoints" }