mcp-server-12306

by @drfccv

12306 MCP Server

Official 12306 rail data is available to AI assistants and automation workflows through mcp-server-12306. Its tools query ticket availability, fares, stations, train stops, and transfers, with date utilities for planning.

Maps & Travel413pythonMIT

Server facts

mcp-server-12306

GitHub stars

413

Last commit

Sep 30, 2026

Runtime

python

License

MIT

Project

Author
drfccv
License
MIT

Tech

Runtime
python
Transports
stdio
Remote access
No

Activity

GitHub stars
413
Last commit
Data as of

Overview

Rail journey lookup can begin with search-stations, which accepts Chinese station names, full or abbreviated pinyin, and station codes. Given a departure station, destination, and date, query-tickets returns train services, arrival and departure times, journey durations, and remaining seats by class. The separate query-ticket-price tool retrieves fares and can filter results for a specified train. Ticket and fare results may include related stations within the departure and arrival cities rather than only an exact station-name match.

For journeys requiring a change, query-transfer retrieves official connection options, with optional settings for a transfer station, no-seat tickets, and student tickets. The get-train-route-stations tool provides stops, arrival and departure times, and dwell times, while get-train-no-by-train-code converts a service code into its official train identifier for route lookup. Date selection is supported by get-current-time through current date and time information and relative-date calculations. These tools serve AI assistants and automation workflows; local MCP clients such as Claude Desktop can connect over Stdio. The README restricts use to learning, research, and technical exchange and prohibits commercial use.

mcp-server-12306 setup notes

  • mcp-server-12306 records stdio only; confirm a network transport upstream before planning remote access.

Related MCP servers