fetchBusPositionsForRoute function
Fetches bus positions for a specific route.
apiKey
is your API key for the WMATA API.
routeId
is the base route name as shown on the bus. Note that the base
route name could also refer to any variant, so a RouteID of 10A could
refer to 10A, 10Av1, 10Av2, etc.
Implementation
Future<List<BusPosition>> fetchBusPositionsForRoute(
String apiKey, {
required String routeId,
}) async =>
await BusPositionService.fetchBusPositions(apiKey, routeId: routeId);