Returns the gas price for a specific block_height or block_hash.
Supported on NEAR (mainnet) only.
Parameters
block_height
- string - (optional) The height of the blockblock_hash
- string - (optional) The hash of the blocknull
- Using [null] will return the most recent block's gas price
Note: You can either use block_height, block_hash or null. Using null will return the most recent block's gas price.
Returns
gas_price
- Integer value of the gas price for the specified block
API Endpoint
The format of a Near API endpoint is
https://open-platform.nodereal.io/{{apiKey}}/near/
Here is an example:
https://open-platform.nodereal.io/4c0a1c23661a4e26bcbcwed461e34ea9/near/
Example
Request
curl https://open-platform.nodereal.io/{{apiKey}}/near/ \
-X POST \
-H "Content-Type: application/json" \
--data '{"jsonrpc": "2.0", "method": "gas_price", "params": [null],"id":1}'
Result