travel_time
Get travel time and distance between two points. Traffic-aware for driving, step-by-step for transit; specify departure or arrival time to know when to leave.
Instructions
Route duration and distance between two points — traffic-aware for driving, step-by-step for transit. THE tool for "when do I need to leave?".
origin/destination: address, 'lat,lng', or 'place_id:'. mode: drive (default) / walk / bicycle / transit / two_wheeler. departure_time: RFC3339 (e.g. '2026-07-05T08:30:00+10:00'), must be now-or-future; empty means now. For driving, the result includes the delay vs the no-traffic baseline. arrival_time: RFC3339 "be there by" time — transit mode only (the Routes API restriction). The transit answer lists each leg: line, stops, and clock times, so "leave by" falls straight out. include_tolls: for drive/two_wheeler, adds an estimated toll cost (requests an extra computation — off by default).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | drive | |
| origin | Yes | ||
| avoid_tolls | No | ||
| destination | Yes | ||
| arrival_time | No | ||
| include_tolls | No | ||
| departure_time | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |