US gas prices API
Prices at individual gas stations, searched by ZIP code.
What each station near a ZIP code charges for regular, mid-grade, premium and diesel. “Gas” here is gasoline at the pump, not natural gas.
Unit
USD per gallon.
Every response carries its unit. Nothing is converted between countries.
Access
Professional plan and above
Same Energy API key. Each call counts as 1 request; Free and Starter get 403.
Endpoints
GET
/api/v1/retail/us/prices
What each station near a ZIP code charges. A ZIP not asked for recently is fetched live and can take up to half a minute; those answers start with the area’s average and lowest price.
| zip | required | Five-digit US ZIP code, e.g. 10001. |
| type | optional | regular (default), mid-grade, premium or diesel. |
https://energy-api.com/api/v1/retail/us/prices?zip=10001&type=regular&api_key=YOUR_API_KEY
GET
/api/v1/retail/us/station
One station: address, coordinates, opening hours, fuels, brands and amenities.
| station_id | required | The station_id returned by /retail/us/prices. |
https://energy-api.com/api/v1/retail/us/station?station_id=56273&api_key=YOUR_API_KEY