get_vehicle
Retrieve real-time location data for a specific bus using its vehicle ID. No caching ensures up-to-date position, and the pattern ID can be used to overlay the vehicle's route on a map.
Instructions
Fetch a vehicle's live location based on its id. This is real-time data and is always live, never cached. The returned 'pid' field can be passed to get_patterns to draw the vehicle's route shape.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"vid": "<vid>"
},
"name": "get_vehicle"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| vid | Yes | Vehicle id, e.g. the 'vid' field from a get_predictions_for_stop result. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |