GET /api/v1/regions
Every WA region, with how many suburbs and stations have current prices.
Example: /api/v1/regions
FuelCompass serves Western Australian fuel prices from FuelWatch as JSON: today’s price at every station, and tomorrow’s once FuelWatch publishes them at 2:30pm, by suburb, region or location. Or put a small price card for your town on your website, with no code at all.
curl -H "Authorization: Bearer fc_live_…" \
"https://fuel-compass.com/api/v1/cheapest?fuel=diesel®ion=perth"
Send the key as Authorization: Bearer <key> or X-API-Key: <key>. Keys look like fc_live_ followed by 52 letters and digits. We show a key once, when you make it, and keep only a scrambled copy, so store it somewhere safe. If one leaks, revoke it in your account and make another.
Never put a key in a URL. Requests with a key in the query string are refused, because URLs end up in logs and browser history.
The API answers requests from any website (CORS, without cookies), but a key in a web page’s JavaScript is visible to everyone who opens the page. Call the API from your server and cache the answers there.
429 with a Retry-After header in seconds. Every answer carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset for the daily quota.ETag; send it back as If-None-Match and you get a 304 when nothing changed.The prices come from FuelWatch, Government of Western Australia. Their condition for reuse is that FuelWatch is acknowledged as the source with a link to www.fuelwatch.wa.gov.au, so wherever you show prices from this API, show that credit too. Every answer includes it in attribution:
Fuel prices from FuelWatch (https://www.fuelwatch.wa.gov.au), Government of Western Australia. Historic prices © State of Western Australia (FuelWatch), licensed under CC BY 4.0; aggregated and processed by FuelCompass. FuelCompass is not affiliated with or endorsed by FuelWatch.
Every answer is JSON with the same four fields. Prices are cents per litre, as an exact decimal string and as whole tenths of a cent.
{
"price_date": "2026-10-16",
"generated_at": "2026-10-16T02:00:00Z",
"attribution": { "text": "Fuel prices from FuelWatch …", "source_url": "https://www.fuelwatch.wa.gov.au", … },
"data": { …, "prices": [ { "station": { … }, "fuel": "diesel", "price": { "cents_per_litre": "189.9", "tenths": 1899 } } ] }
}
price_date is the day the prices are for: each price applies from 6am that day until 6am the next. With day=tomorrow before 2:30pm, lists are empty and published is false.
Errors look like {"error": {"code": "invalid_parameter", "message": "…"}}: 401 for a missing or unknown key, 403 for a revoked key, 400 for a key in the URL, 404 for an unknown place, station or endpoint, 422 for a bad or unknown parameter, and 429 over a limit.
All are GET, relative to https://fuel-compass.com, and every one needs a key.
Every WA region, with how many suburbs and stations have current prices.
Example: /api/v1/regions
The suburbs in a region with stations reporting prices, and the fuels they sell.
Example: /api/v1/regions/goldfields-esperance/suburbs
Every station’s price in a suburb, cheapest first within each fuel.
| Parameter | Description |
|---|---|
fuel | Fuel slug: diesel, premium-diesel, unleaded-91, premium-95, premium-98, lpg or e85. Every fuel when left out. |
day | today (the default: the price in force now, 6am to 6am) or tomorrow (the next day’s price, published each afternoon, WA time). |
Example: /api/v1/suburbs/goldfields-esperance/kalgoorlie/prices?fuel=diesel&day=today
One station: where it is, and today’s and tomorrow’s price for every fuel it sells.
Example: /api/v1/stations/ampol-kalgoorlie
Stations within a radius of a point, nearest first.
| Parameter | Description |
|---|---|
nearRequired | lat,lon in decimal degrees, inside WA, e.g. -31.95,115.86. |
radius_km | Search radius in km, above 0 and at most 50 (default 10). |
fuel | Fuel slug: diesel, premium-diesel, unleaded-91, premium-95, premium-98, lpg or e85. Every fuel when left out. |
day | today (the default: the price in force now, 6am to 6am) or tomorrow (the next day’s price, published each afternoon, WA time). |
limit | How many results, 1 to 100 (default 20). |
Example: /api/v1/stations?near=-30.7489,121.4658&radius_km=10&fuel=diesel&limit=20
The cheapest stations for one fuel, statewide or in one region.
| Parameter | Description |
|---|---|
fuelRequired | Fuel slug: diesel, premium-diesel, unleaded-91, premium-95, premium-98, lpg or e85. |
region | Region slug from /api/v1/regions. The whole state when left out. |
day | today (the default: the price in force now, 6am to 6am) or tomorrow (the next day’s price, published each afternoon, WA time). |
limit | How many results, 1 to 100 (default 10). |
Example: /api/v1/cheapest?fuel=diesel®ion=goldfields-esperance&day=today
Every published next-day price, with today’s beside it. Empty, with published: false, until FuelWatch publishes each afternoon, WA time.
| Parameter | Description |
|---|---|
fuel | Fuel slug: diesel, premium-diesel, unleaded-91, premium-95, premium-98, lpg or e85. Every fuel when left out. |
region | Region slug from /api/v1/regions. The whole state when left out. |
Example: /api/v1/tomorrow?fuel=diesel
The price window, when prices last loaded, the fuels, your key’s quota and the attribution.
Example: /api/v1/meta
A small card with the three cheapest stations in a town today, and tomorrow’s prices once they are out. It updates by itself, follows your visitors’ light or dark setting, sets no cookies, runs no scripts and needs no key. Pick a place and a fuel, then copy the code into your page.