Route
POST /route (or GET) returns the driving route between an origin and a destination.
curl https://api.argamin.ai/v1/route \ -H "Authorization: Bearer am_test_..." \ -H "Content-Type: application/json" \ -d '{ "waypoints": [ { "lat": 51.5072, "lng": -0.1276 }, { "lat": 51.5155, "lng": -0.0922 } ], "geometry": "polyline6"}'{ "distance": 4900, "duration": 880, "geometry": "<encoded polyline6 string>", "legs": [ { "distance": 4900, "duration": 880 } ], "request_id": "req_2b9d6f1e0c8a4e7f9a3b5c7d1e2f4a6b"}- 2 to 25
waypoints, visited in the given order. geometryispolyline6by default; you can also ask forgeojsonornone. Setsteps: truefor turn-by-turn steps per leg.- Billed per request, only on success.
- Durations do not include live traffic.
| Service | Unit | Free / month | 0 - 100K | 100K - 500K | 500K - 1M | 1M - 5M | 5M+ |
|---|---|---|---|---|---|---|---|
| Route | request | 10,000 | $1.60 | $1.30 | $1.00 | $0.50 | $0.13 |