get_transit_commute
get_transit_commuteCalculate commute routes and travel times between two addresses using real-time Google Maps data across transit, driving, walking, bicycling, and two-wheeler modes.
Instructions
Returns commute routes between two addresses using real-time Google Maps data. Use this when the user asks about commute, travel time, or exact travel times between two addresses. Supports transit, driving, walking, bicycling, and two_wheeler modes. Supports multi-leg trips via the intermediates parameter (e.g. A→B→C). Returns up to 3 alternative routes, each with duration in minutes, transit lines used, number of transfers, and walking time.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | The mode of transportation to use. If not provided, the default mode will be transit. | |
| origin | Yes | The origin address or neighbourhood (e.g. '123 Main St, Anytown, USA') | |
| avoid_tolls | No | When true, instructs Google Maps to avoid toll roads where possible. Applies to driving and two_wheeler modes. | |
| destination | Yes | The destination address or neighbourhood (e.g. '456 Main St, Anytown, USA') | |
| intermediates | No | Optional ordered list of intermediate stops between origin and destination, e.g. ['Stop B', 'Stop C']. Use this for multi-leg trips like A→B→C. | |
| departure_time | No | ISO 8601 datetime for departure (e.g. '2026-04-02T17:00:00-05:00'). If provided, uses Google Maps predicted/historical traffic for that future time. If omitted, uses the current time with live real-time traffic data. Omit for current conditions, provide for future trip planning. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| routes | Yes |