google.maps.DirectionsRequest interface
A directions query to be sent to the DirectionsService.
Properties
Type: boolean optional
If true, instructs the Directions service to avoid ferries where possible. Optional.
Type: boolean optional
If true, instructs the Directions service to avoid highways where possible. Optional.
Type: boolean optional
If true, instructs the Directions service to avoid toll roads where possible. Optional.
Type: string|LatLng|Place|LatLngLiteral
Location of destination. This can be specified as either a string to be geocoded, or a LatLng, or a Place. Required.
Type: DrivingOptions optional
Settings that apply only to requests where travelMode is DRIVING. This object will have no effect for other travel modes.
Type: boolean optional
If set to true, the DirectionsService will attempt to re-order the supplied intermediate waypoints to minimize overall cost of the route. If waypoints are optimized, inspect DirectionsRoute.waypoint_order in the response to determine the new ordering.
Type: string|LatLng|Place|LatLngLiteral
Location of origin. This can be specified as either a string to be geocoded, or a LatLng, or a Place. Required.
Type: boolean optional
Whether or not route alternatives should be provided. Optional.
Type: string optional
Region code used as a bias for geocoding requests. Optional.
Type: TransitOptions optional
Settings that apply only to requests where travelMode is TRANSIT. This object will have no effect for other travel modes.
Type: TravelMode
Type of routing requested. Required.
Type: UnitSystem optional
Preferred unit system to use when displaying distance. Defaults to the unit system used in the country of origin.
Type: Array<DirectionsWaypoint> optional
Array of intermediate waypoints. Directions are calculated from the origin to the destination by way of each waypoint in this array. See the developer's guide for the maximum number of waypoints allowed. Waypoints are not supported for transit directions. Optional.