Skip to content

50,000 free calls a month, card-free. Get an API key →

Documentation menu
docs / api / post-v1-fuel-along
routing

POST/v1/fuel/along

API key required, sent as Authorization: Bearer snk_… or ?api_key=snk_….

Call it

bash
curl -fsS -X POST "https://api.mapmap.ai/v1/fuel/along" \
  -H "Authorization: Bearer $MAPMAP_KEY" \
  -H "Content-Type: application/json" \
  -d @request.json

Request body

application/json

Cheapest-fuel search: a route (geometry_polyline6, or origin + destination + costing), a fuel code (default diesel), optional max_detour_minutes (default 10, max 120), max_results (default 5, max 25), fill_litres (adds saving_total per result), Valhalla costing_options and an optional top-level adr profile

The OpenAPI document declares this body as a free-form JSON object with no field list, so there is nothing here to generate a table from. The prose above is what the gateway states about it; the raw document is the authority.

Responses

200Stations selling the requested fuel within the detour budget, freshest-priced first and cheapest within that: {fuel, costing, route, max_detour_minutes, candidates: {considered, costed, cap}, 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}, stale, detour_minutes, detour_km, along_route_position, off_route_m, saving_per_litre, saving_total}, fuel_attribution}. Detours are engine-computed, never crow-flies. stale is true unless BOTH the price's own updated_at and the snapshot's fetch time are within 24 hours; a stale price is ranked after every fresh one, is never the baseline, and carries no saving_per_litre
400Invalid request
401Missing or invalid API key
429Quota or rate limit exceeded
501The fuel-price dataset is not enabled (SN_FUEL_PRICES unset)
502Upstream routing engine failed

Error bodies follow the shared problem model documented on API conventions.

Also under routing

Generated from https://api.mapmap.ai/openapi.json on 2026-09-17 · operationId post_fuel_along