External integration - "Fuel prices"

I’d love to, but I’m not at all « ripe » to understand everything!! I’m already trying to figure out how GitHub works…

It was the same for me not long ago :sweat_smile:
And by watching Pierre Gilles’ videos, I’m getting there little by little :winking_face_with_tongue:

@prohand
Is it possible to delete/hide stations that don’t have a particular fuel?
I’m on E85 and stations without E85 show this -:

• Système U - xxx (0.8 km) — E85 (Superethanol): -
• 5 ALLEE DE L’ECONOMIE - xxx (0.8 km) — E85 (Superethanol): 0.824 EUR/L
• TotalEnergies Access - xxx (6.7 km) — E85 (Superethanol): 0.839 EUR/L
• TotalEnergies - xxx (7.9 km) — E85 (Superethanol): 0.839 EUR/L
• Auchan - xxx (8.2 km) — E85 (Superethanol): 0.839 EUR/L
• Système U - xxx (8.5 km) — E85 (Superethanol): -
• TotalEnergies - xxx (8.9 km) — E85 (Superethanol): -
• Carrefour - xxx (9.0 km) — E85 (Superethanol): -
… +12

EDIT: My mistake, they don’t appear in Discovery, so perfect :wink:

Hello @prohand,

Thank you for this integration :heart_hands:

I do have a comment though: at least 4 stations are available around my place, but when I test the integration, none appear (though I don’t live in the middle of nowhere…):

[2026-08-10T07:39:25.435Z] [INFO] Starting the fuel prices integration...
[2026-08-10T07:39:26.839Z] [INFO] [gladys-sdk] connected to Gladys (http://172.30.0.1:8082)
[2026-08-10T07:39:27.143Z] [INFO] 0 station device(s) tracked
[2026-08-10T07:39:27.146Z] [WARN] No postal code configured yet: nothing to discover
[2026-08-10T07:39:27.149Z] [INFO] [refresh] Prices will be refreshed every 3600s
[2026-08-10T07:41:07.825Z] [INFO] onConfigUpdated -> new configuration received
[2026-08-10T07:41:07.827Z] [INFO] [refresh] Prices will be refreshed every 3600s
[2026-08-10T07:41:08.278Z] [WARN] [provider-fr] No station found in postal code 67750: cannot widen the search around it
[2026-08-10T07:41:08.338Z] [INFO] [devices] Discovery: 0 station(s) around 67750, 1 device(s) published for Diesel, SP95, SP98, E10 (SP95-E10)
[2026-08-10T07:41:10.772Z] [WARN] [provider-fr] No station found in postal code 67750: cannot widen the search around it

In doubt, the integration was restarted, but no improvement…

Any ideas?

Thanks in advance,

Have a nice day,

Jean

Thanks for reporting the issue.

The new version 1.0.3 that just came out should fix your problem
I also took the opportunity to fix a bug I was encountering as well and here is Claude’s feedback on the fix:

XXXXX — no stations, regardless of radius

The center of the search circle was the average position of stations with this postal code. « NOM VILLE » has none in the national feed → no center → src/countries/france.js:125 simply skipped the « radius » step. Increasing the radius couldn’t change anything: there was no circle to expand.

When the feed doesn’t know the location of the postal code, it is now geocoded via the National Address Database (src/countries/franceGeocode.js, official, no key). Best effort and cached, in the spirit of franceNames.js: an unreachable geocoder costs stations around the postal code, never those that are inside.

XXXXX — only certain stations (NOM STATION)

The radius query was limited to 300 records, and the API responds to within_distance in the order of the dataset — that is, by station ID, that is, by postal code. A truncated circle therefore does not lose the furthest stations, it loses the highest postal codes: around Lyon, XXXXX and XXXXX fall after 69000/69100. And increasing the radius worsened the problem, by adding competitors to the same truncated response.

The search now goes through concentric circles starting from 5 km, doubling until the configured radius, and stops at the first complete circle containing at least limit stations — this circle then necessarily contains the closest ones. In the city it’s also cheaper than before: a query from a small circle instead of three pages of a large one.