by anoopt
Get real-time London transport updates, plan journeys across London’s underground & bus routes, and manage your Oyster c
Get real-time London transport data including tube status, disruptions, and journey planning between any UK locations.
Transport for London is a community-built MCP server published by anoopt that provides AI assistants with tools and capabilities via the Model Context Protocol. Get real-time London transport updates, plan journeys across London’s underground & bus routes, and manage your Oyster c It is categorized under developer tools.
You can install Transport for London in your AI client of choice. Use the install panel on this page to get one-click setup for Cursor, Claude Desktop, VS Code, and other MCP-compatible clients. This server runs locally on your machine via the stdio transport.
MIT
Transport for London is released under the MIT license. This is a permissive open-source license, meaning you can freely use, modify, and distribute the software.
Add new capabilities to Claude beyond text generation
Example
Access external data sources, execute code, interact with tools and services
Transform Claude from chatbot to action-taking agent
Provide Claude with access to relevant context and data
Example
Load project documentation, access knowledge bases, query databases
Get more accurate, context-aware responses
Automate multi-step workflows combining AI and external tools
Example
Research → Summarize → Create document → Send notification
Complete complex tasks end-to-end without manual steps
Share your MCP server with the developer community
We wired Transport for London into a staging workspace; the listing’s GitHub and npm pointers saved time versus hunting across READMEs.
I recommend Transport for London for teams standardizing on MCP; the explainx.ai page compares cleanly with sibling servers.
Transport for London reduced integration guesswork — categories and install configs on the listing matched the upstream repo.
Useful MCP listing: Transport for London is the kind of server we cite when onboarding engineers to host + tool permissions.
Transport for London is a well-scoped MCP server in the explainx.ai directory — install snippets and categories matched our Claude Code setup.
Transport for London has been reliable for tool-calling workflows; the MCP profile page is a good permalink for internal docs.
Strong directory entry: Transport for London surfaces stars and publisher context so we could sanity-check maintenance before adopting.
Strong directory entry: Transport for London surfaces stars and publisher context so we could sanity-check maintenance before adopting.
We evaluated Transport for London against two servers with overlapping tools; this profile had the clearer scope statement.
Transport for London is a well-scoped MCP server in the explainx.ai directory — install snippets and categories matched our Claude Code setup.
showing 1-10 of 71
This Model Context Protocol (MCP) server provides AI assistants with access to real-time Transport for London data through a set of automated tools.
⚠️ Important Disclaimer: This is not an official Transport for London (TfL) MCP server. This is an independent project that uses the publicly available TfL Unified API to provide transport data. It is not affiliated with, endorsed by, or officially supported by Transport for London.

This server enables AI assistants (like Claude Desktop and VS Code GitHub Copilot) to access live TfL data by providing three main capabilities:
get_line_status - Get the current status of any TfL line (e.g., Central, Victoria, Piccadilly)get_line_status_detail - Get detailed status information including disruption details for a TfL lineplan_journey - Plan journeys between two locations using the TfL Journey PlannerWith this MCP server connected, AI assistants can help users:
Example interactions:
Let's set things up!
Choose your preferred installation method:
The easiest way to use this MCP server is through npm:
npm install -g london-transport-mcp
You can get a free API key from the TfL API Portal.
Method 1: Environment Variable (Recommended) Set the environment variable in your system:
# Windows (PowerShell)
$env:TFL_API_KEY="your_actual_tfl_api_key_here"
# macOS/Linux
export TFL_API_KEY="your_actual_tfl_api_key_here"
Method 2: MCP Configuration Include the API key directly in your MCP configuration (see examples below).
For Claude Desktop (Settings → Developers → Edit Config):
{
"mcpServers": {
"london-transport": {
"command": "npx",
"args": ["london-transport-mcp"],
"env": {
"TFL_API_KEY": "your_actual_tfl_api_key_here"
}
}
}
}
For VS Code GitHub Copilot (Settings → GitHub Copilot › MCP: Servers):
{
"london-transport": {
"command": "npx",
"args": ["london-transport-mcp"],
"env": {
"TFL_API_KEY": "your_actual_tfl_api_key_here"
}
}
}
That's it! No manual installation or path configuration required.
For developers who want to modify the code or contribute:
Before starting, please ensure you have:
Warning: if you run with a lower version of Node, fetch won't be present. Tools use fetch to make HTTP calls. To work around this, you can modify the tools to use node-fetch instead. Make sure that node-fetch is installed as a dependency and then import it as fetch into each tool file.
1. Clone the repository
git clone https://github.com/anoopt/london-tfl-journey-status-mcp-server.git
cd london-tfl-journey-status-mcp-server
2. Install dependencies
npm install
3. Configure your TfL API key
Create a .env file in the project root with your TfL API key:
TFL_API_KEY=your_actual_tfl_api_key_here
You can get a free API key from the TfL API Portal.
We strongly recommend testing your MCP server with Postman before connecting it to an AI assistant. The Postman Desktop Application provides the easiest way to run and test MCP servers.
Download the latest Postman Desktop Application from postman.com/downloads.
mcpServer.jsTo get the required paths, run these commands in your terminal:
# Get the full path to node
which node
# Get the full path to mcpServer.js
realpath mcpServer.js
# Check your node version (should be 18+)
node --version
Example command format:
/usr/local/bin/node /full/path/to/TfL-Status-MCP-Server/mcpServer.js
get_line_status with lineId: "central"plan_journey with fromLocation: "King's Cross" and toLocation: "Westminster"get_line_status_detail with lineId: "piccadilly"If all tools work correctly in Postman, you're ready to connect to an AI assistant!
Once you've tested with Postman, you can connect your MCP server to AI assistants:
If you're using the local development setup, you'll need to specify full paths:
Step 1: Use the same node and mcpServer.js paths from the Postman testing step.
Step 2: Open Claude Desktop → Settings → Developers → Edit Config and add:
{
"mcpServers": {
"london-transport": {
"command": "node",
"args": ["/full/path/to/mcpServer.js"]
}
}
}
Step 3: Restart Claude Desktop and verify the MCP server shows with a green circle.
Step 1: Install the GitHub Copilot extension in VS Code if you haven't already.
Step 2: Open VS Code → Settings (Ctrl+,) → Search for "MCP" → GitHub Copilot › MCP: Servers
Step 3: Add your TfL MCP server configuration:
{
"london-transport": {
"command": "node",
"args": ["/full/path/to/mcpServer.js"]
}
}
Step 4: Restart VS Code and the MCP server will be available to GitHub Copilot.
Now you can ask your AI assistant things like:
View all available tools and their parameters:
npm run list-tools
Open Postman with the correct MCP configuration automatically:
npm run postman
For production deployments, you can use Docker:
1. Build Docker image
docker build -t <your_server_name> .
2. AI Assistant Integration
Add Docker server configuration to your AI assistant:
For Claude Desktop (Settings → Developers → Edit Config):
{
"mcpServers": {
"tfl-status": {
"command": "docker",
"args": ["run", "-i", "--rm", "--env-file=.env", "tfl-mcp-server"]
}
}
}
For VS Code GitHub Copilot (Settings → GitHub Copilot › MCP: Servers):
{
"tfl-status": {
"command": "docker",
"args": ["run", "-i", "--rm", "--env-file=.env", "tfl-mcp-server"]
}
}
Add your environment variables (API keys, etc.) inside the
.envfile.
The project comes bundled with the following minimal Docker setup:
FROM node:22.12-alpine AS builder
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm install
COPY . .
ENTRYPOINT ["node", "mcpServer.js"]
To run the server with Streamable HTTP support, use the --streamable-http flag. This launches the server with the /mcp endpoint enabled:
node mcpServer.js --streamable-http
To run the server with Server-Sent Events (SSE) support, use the --sse flag. This launches the server with the /sse and /messages endpoints enabled:
node mcpServer.js --sse
To run the server using standard input/output (stdio), simply run the script without any flags. This mode is ideal for CLI tools or programmatic integration via stdin and stdout.
node mcpServer.js
To add more TfL API endpoints or other transport APIs:
tools/tfl/ directorytools/tfl/status.jstools/paths.jsThis server uses the Transport for London Unified API. All tools automatically include your API key from the .env file.
Extend your MCP server with more tools easily:
tools/ folder.tools/paths.js file to include new tool references.Visit the Postman MCP Generator page for updates and new capabilities.
Join the #mcp-lab channel in the Postman Discord to sh
Prerequisites
Time Estimate
15-60 minutes depending on server complexity
Steps
Troubleshooting
✓ Do
✗ Don't
💡 Pro Tips
Architecture
Model Context Protocol standardizes how AI hosts (Claude, Cursor) communicate with external tools and data sources through server implementations.
Protocols
Compatibility
✓ Use when
Use when you need Claude to access external data, execute actions, or integrate with tools. Best for extending AI capabilities beyond conversation.
✗ Avoid when
Avoid when native integrations exist (use official APIs directly), for real-time critical systems, or when security/compliance requires zero external dependencies.