Don't miss Build Games$1M Builder Competition

avm.getHeight

Returns the height of the last accepted block.

POST
/ext/bc/X#avm.getHeight

Request Body

application/json

JSON-RPC request

jsonrpc*string
method*string
params*object
id*integer

Response Body

application/json

application/json

curl -X POST "https://api.avax.network/ext/bc/X#avm.getHeight" \  -H "Content-Type: application/json" \  -d '{    "jsonrpc": "2.0",    "method": "avm.getHeight",    "params": {},    "id": 1  }'
{
  "jsonrpc": "2.0",
  "result": {
    "height": "5094088"
  },
  "id": 1
}
{
  "jsonrpc": "2.0",
  "error": {
    "code": 0,
    "message": "string",
    "data": null
  },
  "id": 1
}

Is this guide helpful?