routing

Cheapest fuel along a route (see module docs).

post/v1/fuel/along

Request

  • Base URL: https://api.mapmap.ai
  • URL: https://api.mapmap.ai/v1/fuel/along
  • Auth: one of:
    • HTTP bearer
    • API key in query parameter api_key

Request body

object required

Response

Stations selling the requested fuel within the detour budget, freshest-priced first and cheapest within that: {fuel, costing, route: {duration_s, distance_m, length_m, detour_baseline_s, detour_baseline_m}, max_detour_minutes, candidates: {considered, costed, cap, selection}, coverage: {stations, countries, sources}, note (only when results is empty, naming which of the several causes applies), baseline: {<currency>: {value, station_id, brand, name, updated_at}}, results[]: {station_id, source, brand, name, lat, lon, price: {value, currency, updated_at, fetched_at}, stale, detour_minutes, detour_km, along_route_position, off_route_m, saving_per_litre, saving_total}, say, fuel_attribution}. route.duration_s/distance_mare the path search's own figures, the same journey POST /route answers;detour_baseline_* is the matrix leg every detour is computed against. The 25 costed candidates are those nearest the route by the straight-line detour bound (candidates.selection), and the baseline is a station that passed the detour filter, so a saving is never quoted against one the results could not contain. sayis the whole answer as one short spoken line, present on every response including an empty one. Detours are engine-computed, never crow-flies.staleis true unless BOTH the price's ownupdated_atand the snapshot's fetch time are within 24 hours; a stale price is ranked after every fresh one, is never thebaseline, and carries no saving_per_litre`

object required

Changes

No recorded changes to this operation across all 1 revision of this API.