# CTA MCP for AI Agents AI Agent Connect

> CTA MCP provides real-time access to Chicago's public transit data. It lets your AI agent track L trains and buses, check arrival predictions, monitor service disruptions, and plan routes across the city. Whether you're a daily commuter or a transit researcher, you can get live updates on the Red Line, Blue Line, and all CTA bus routes instantly.

## Overview
- **Category:** government-public-data
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_8ueRqAm68ulWomrillKp4F4nu0NNlhP88klbOPLG/ai-agent-connect
- **Tags:** public-transit, real-time-tracking, arrival-predictions, transportation-data, route-planning, service-alerts

## Description

Imagine you're standing on a freezing Chicago street corner, trying to figure out if the next bus is actually coming or if the Red Line is stuck in a tunnel. Instead of flipping between three different apps and refreshing a website, you just ask your agent for the status. This Connector connects your AI client directly to the Chicago Transit Authority's data feed. It pulls in live GPS positions for buses, real-time arrival predictions for L stations, and active service alerts for the entire city. You can ask for the next train at a specific station, check if a bus route is running on time, or find out why a specific line is delayed. It turns your AI into a local transit expert that knows exactly what's happening on the tracks and the roads. When you find a tool like this in the Vinkius catalog, it changes the way you navigate the city. You stop guessing and start moving. You get precise data on route directions, stop locations, and system-wide health checks without ever leaving your chat interface. It's about getting the right information at the exact moment you need to make a decision about your commute.

## Tools

### get_system_time
Verify the official server timestamp to synchronize clocks and check API connectivity. Use this as a quick heartbeat check for your connection.

### get_bus_predictions
Get predicted arrival times for a specific bus stop including route IDs and destination info. Use this for real-time passenger waiting time estimation.

### get_bus_routes
List all CTA bus routes across Chicago neighborhoods with names, colors, and directions. This is perfect for identifying route IDs.

### get_bus_stops
Find all stops for a specific bus route along with their coordinates and direction info. Use this to locate specific boarding points.

### get_bus_vehicles
Track live GPS positions, speed, and headings for all active buses or specific routes. Use this to see where the fleet is right now.

### get_route_directions
Identify the direction patterns like northbound or southbound for any given bus route. This helps in planning trips in the correct direction.

### get_route_status
Check the current health of all train lines and bus routes for delays or service disruptions. This provides a quick system-wide health check.

### get_service_alerts
Retrieve active disruptions including severity, causes like weather, and suggested alternatives. This is essential for avoiding delays.

### get_stop_details
Get specific location info and metadata for any individual CTA bus stop. Use this to contextualize transit queries and trip planning.

### get_train_arrivals
Fetch real-time arrival predictions, run numbers, and status for a specific L station. This tells you exactly when the next train is coming.

### get_train_positions
Track the live locations, headings, and delay statuses of all active trains system-wide. Use this to visualize train distribution across the L system.

## Prompt Examples

**Prompt:** 
```
Is the Red Line running on time right now?
```

**Response:** 
```
Checking the current status of the CTA Red Line...

| Line | Status | Details |
| :--- | :--- | :--- |
| **Red Line** | ✅ GOOD | Running on schedule with no major delays reported.

All other L lines are also currently reporting good status. Would you like me to check for specific service alerts on the Red Line instead?
```

**Prompt:** 
```
What's the next train at Clark/Lake?
```

**Response:** 
```
**Clark/Lake Station (Map ID: 40360)**

Here are the next upcoming trains:
* **Red Line** — Howard: 3 mins (Approaching)
* **Red Line** — Howard: 10 mins (Scheduled)
* **Red Line** — 95th/Dan Ryan: 6 mins (On-time)

All trains are currently running on schedule.
```

**Prompt:** 
```
Are there any delays on the bus routes near downtown?
```

**Response:** 
```
I found 3 active service alerts for the downtown area:

* **Route 22 Clark**: Minor delay due to construction on State St. (Expected delay: 5-10 mins).
* **Route 151 Michigan**: Detour in effect near Wacker Dr.
* **Route 66 Chicago**: Service disruption near LaSalle St. due to a vehicle incident.

Would you like more details on any of these specific alerts?
```

## Capabilities

### Track live bus locations
Get real-time GPS coordinates for all active buses system-wide or on specific routes.

### Predict train arrivals
See exactly when the next train will reach an L station including its destination and line color.

### Monitor service alerts
Stay informed about delays, maintenance, and construction across the entire CTA network.

### Map bus routes
View all bus routes in Chicago neighborhoods to understand the full transit network.

### Check route health
Get a quick overview of which lines are running on time or experiencing significant delays.

## Use Cases

### Missing the bus
A commuter asks 'Is the 22 Clark bus running late?' and the agent uses get_bus_predictions to confirm the next arrival.

### Planning a tour
A tourist asks for all bus routes near Millennium Park, and the agent uses get_bus_routes to provide a list of options.

### Avoiding delays
A rider asks 'Is the Blue Line running okay?' and the agent uses get_route_status to report on current delays and issues.

### Transit research
An analyst asks for the positions of all Red Line trains to see how they are distributed across the system using get_train_positions.

## Benefits

- Stop guessing bus arrival times with get_bus_predictions, which gives you accurate minutes and seconds for your specific stop.
- Stay ahead of transit issues by using get_service_alerts to see delays and suggested detours instantly before you leave.
- Map out your entire trip with get_bus_routes and get_bus_stops to see every available connection in the city.
- Know exactly where your ride is with get_bus_vehicles and get_train_positions for live fleet tracking across the city.
- Plan your commute with confidence by checking the overall system health via get_route_status to see which lines are on time.

## How It Works

The bottom line is you get a real-time Chicago transit dashboard inside any chat interface you already use.

1. Subscribe to the CTA MCP and grab your free API keys from the Chicago Transit Authority Developer Portal.
2. Plug those keys into your AI client's configuration to establish a secure connection.
3. Ask your agent questions about train times, bus locations, or system alerts to get instant data.

## Frequently Asked Questions

**Can I use the CTA MCP to see if my bus is coming?**
Yes, you can get real-time arrival predictions for any specific bus stop. Your agent will tell you exactly how many minutes away the next bus is, including the route number and destination.

**Does the CTA MCP show train delays?**
Yes, it provides a quick overview of the health of all train lines. You can ask your agent to check if specific lines are running on time or experiencing delays.

**Can I find bus stops near me with CTA MCP?**
You can list all stops for any specific bus route. This helps you find the best boarding points and see the geographic coordinates for each stop.

**Does the CTA MCP work for all Chicago trains?**
It covers the entire CTA L system, including the Red, Blue, Brown, Green, Orange, Purple, Pink, and Yellow lines.

**Can I check for service alerts with CTA MCP?**
Yes, the Connector pulls live alerts for the whole city. It can tell you about construction, weather delays, and incidents across both buses and trains.

**Can I track the live location of buses?**
Yes, your agent can pull live GPS positions, headings, and speeds for all active buses or filter it down to a specific route.

**Can my AI check when the next L train is arriving at my station?**
Yes! Use the `get_train_arrivals` tool with the station mapId (a 5-digit parent station ID, e.g., 40360 for Clark/Lake, 40900 for Jackson). Your AI will return all upcoming trains with destination names, line colors (Red, Blue, Brown, Green, Orange, Purple, Pink, Yellow), predicted arrival times in minutes, operating status (on-time, delayed, approaching, boarding, departing), and whether the train is scheduled or real-time tracked. If you do not know the mapId, it can be found in the CTA GTFS static data feed.

**How do I check when the next CTA bus is arriving at a specific stop?**
First use `get_bus_stops` with a route ID to find the stop ID (stpid) for your location. Then use `get_bus_predictions` with that stop ID to get real-time estimated arrival times, route information, destination descriptions, and vehicle IDs. For route-filtered predictions, you can also pass the route ID to narrow results to a specific bus line. Stop IDs are numeric identifiers assigned by CTA to each physical bus stop across Chicago.

**Are there any service disruptions affecting the Red Line or my bus route right now?**
Use `get_service_alerts` to check all active service disruptions across the CTA system. This returns alerts with affected routes and stations, disruption descriptions, severity levels, cause types (maintenance, incident, weather, special events, construction), and detour information. You can also use `get_route_status` for a quick system-wide health check showing which L lines and bus routes are running on-time, delayed, or have planned work. Always check this before planning any CTA journey.