Directions

Get Direction from A to B.

URL: /Direction

Method: GET

ParamDescriptionExample
originThe origin (start) coordinate string (Required)20.981971,105.864323
destinationThe destination coordinate string. Split by ; for more than 2 destinations (Required)21.03876,105.79810
alternativesBoolean, if true, Directions service may return several routestrue
vehicleVehicle type. Options are car, bike, taxi, truck, hd (for ride hailing vehicles)car

Example request

$ curl "https://rsapi.goong.io/Direction?origin=21.046623224000029,105.790168203000060&destination=21.046666732000062,105.790169569000060&vehicle=car&api_key={YOUR_API_KEY}"

Example response

application/json

{
"geocoded_waypoints": [],
"routes": [
{
"bounds": {},
"legs": [
{
"distance": {
"text": "5 m",
"value": 5
},
"duration": {
"text": "1 giây",
"value": 1
},
"steps": []
}
],
"overview_polyline": {
"points": "mtm_C{cudSG@"
},
"warnings": [],
"waypoint_order": []
}
]
}