eth_gasPrice

Returns the current price per gas in wei.

Request

curl 'https://rpc.web3api.io?x-api-key=YOUR-API-KEY' \
    -X POST \
    -H 'x-amberdata-blockchain-id: ethereum-mainnet' \
    -d '{"jsonrpc":"2.0","id":1,"method":"eth_gasPrice","params":[]}'

Response

{
  "id":1,
  "jsonrpc": "2.0",
  "result": "0x09184e72a000" // 10000000000000
}
TypeDescription
stringThe integer of the current gas price in wei.