ETH Gas Station API

Access gas price data from http://ethgasstation.info

Gas Price
GET Request
https://ethgasstation.info/json/ethgasAPI.json

Returns the fast, standard and safelow prices, along with the current block.

Params: no params

Response Object Details:

fast: Recommended fast(expected to be mined in < 2 minutes) gas price in x10 Gwei(divite by 10 to convert it to gwei)
fastest: Recommended fastest(expected to be mined in < 30 seconds) gas price in x10 Gwei(divite by 10 to convert it to gwei)
safeLow: Recommended safe(expected to be mined in < 30 minutes) gas price in x10 Gwei(divite by 10 to convert it to gwei)
average: Recommended average(expected to be mined in < 5 minutes) gas price in x10 Gwei(divite by 10 to convert it to gwei)
block_time: Average time(in seconds) to mine one single block
blockNum: Latest block number
speed: Smallest value of (gasUsed / gaslimit) from last 10 blocks
safeLowWait: Waiting time(in minutes) for safeLow gas price
avgWait: Waiting time(in minutes) for average gas price
fastWait: Waiting time(in minutes) for fast gas price
fastestWait: Waiting time(in minutes) for fastest gas price

Note: To convert the provided values to gwei, divide by 10

Sample Response Object:

{
"fast":50.0,
"fastest":200.0,
"safeLow":10.0,
"average":20.0,
"block_time":13.942307692307692,
"blockNum":7403346,
"speed":0.7090284960673774,
"safeLowWait":13.4,
"avgWait":1.8,
"fastWait":0.5,
"fastestWait":0.5
}
Prediction Table
GET Request
https://ethgasstation.info/json/predictTable.json

Returns estimate confirmation times for a range of gas prices from the EGS Prediction Page

[
{
"gasprice":0.1,
"hashpower_accepting":0.0,
"hashpower_accepting2":0.0,
"tx_atabove":231.0,
"age":4.0,
"pct_remaining5m":0.0,
"pct_mined_5m":0.0,
"total_seen_5m":3.0,
"average":300,
"safelow":100,
"nomine":null,
"avgdiff":0,
"intercept":4.8015,
"hpa_coef":-0.0243,
"avgdiff_coef":-1.6459,
"tx_atabove_coef":0.0006,
"int2":6.9238,
"hpa_coef2":-0.067,
"sum":6.9238,
"expectedWait":1000.0,
"unsafe":1,
"expectedTime":135.29
},
.......
]