tfl-ts
v2.17.1Read-only Transport for London data: line status, arrivals, journeys, stop lookup.
Values you need
| Variable | What it is | |
|---|---|---|
TFL_APP_KEY | required secret | TfL API primary key. Live tools need it. Static tools (docs, resolve_line_id, get_supported_modes) do not. |
TFL_MCP_MIN_INTERVAL_MS | optional | Minimum milliseconds between outbound TfL requests. Default 250. Cache hits do not count. |
npm (npx) discovery passed
Requires Node.js 18+
Run in a terminal
claude mcp add tfl-ts -e 'TFL_APP_KEY=<TFL_APP_KEY>' -- npx -y --package=tfl-ts@2.17.1 tfl mcpAdd to
claude_desktop_config.json{
"mcpServers": {
"tfl-ts": {
"args": [
"-y",
"--package=tfl-ts@2.17.1",
"tfl",
"mcp"
],
"command": "npx",
"env": {
"TFL_APP_KEY": "<TFL_APP_KEY>"
}
}
}
}Add to
~/.cursor/mcp.json{
"mcpServers": {
"tfl-ts": {
"args": [
"-y",
"--package=tfl-ts@2.17.1",
"tfl",
"mcp"
],
"command": "npx",
"env": {
"TFL_APP_KEY": "<TFL_APP_KEY>"
}
}
}
}Add to
.vscode/mcp.json{
"inputs": [
{
"description": "TFL_APP_KEY",
"id": "tfl-app-key",
"password": true,
"type": "promptString"
}
],
"servers": {
"tfl-ts": {
"args": [
"-y",
"--package=tfl-ts@2.17.1",
"tfl",
"mcp"
],
"command": "npx",
"env": {
"TFL_APP_KEY": "${input:tfl-app-key}"
},
"type": "stdio"
}
}
}Add to
~/.codex/config.toml[mcp_servers.tfl-ts]
command = "npx"
args = ["-y", "--package=tfl-ts@2.17.1", "tfl", "mcp"]
env = { "TFL_APP_KEY" = "<TFL_APP_KEY>" }For AI agents
- Ask the user for: TFL_APP_KEY. Never invent or guess these values; secrets go into the client config, not into chat logs.
- Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
- Restart or reload the client so it starts the server.
- Verify: the server should expose these tools: get_supported_modes, resolve_line_id, docs, resolve_stop_id, get_line_status, get_arrivals, plan_journey.
- If it fails, check that the required runtime is installed (Node.js 18+) and that the values above are set.
Machine-readable: install.md · manifest.json