trackmcp
Back to directory

This is a 12306 ticket search server based on the Model Context Protocol (MCP).

1,232 stars JavaScriptOthers Updated Sep 4, 2026
12306mcpmcp-servertrain-tickets

Documentation

#

A 12306 ticket search server based on the Model Context Protocol (MCP). The server provides a simple API interface that allows users to search for 12306 tickets.

基于 Model Context Protocol (MCP) 的12306购票搜索服务器。提供了简单的API接口,允许大模型利用接口搜索12306购票信息。

如需Skill -> https://github.com/Joooook/12306-skill

##

##

~~~bash

git clone https://github.com/Joooook/12306-mcp.git

npm i

~~~

##

CLI-stdio

~~~bash

npx -y 12306-mcp

~~~

CLI-http

~~~bash

npx -y 12306-mcp --port [端口号]

~~~

Runtime requirements

The server requires Node.js 18 or newer. The `npm run debug` command uses

MCP Inspector 2.0.0, which requires Node.js 22.19.0 or newer.

MCP sever configuration

~~~json

{

"mcpServers": {

"12306-mcp": {

"command": "npx",

"args": [

"-y",

"12306-mcp"

]

}

}

}

~~~

Docker-stdio

~~~bash

docker build . -t 12306-mcp

docker run --rm -it 12306-mcp npx 12306-mcp

~~~

Docker-http

~~~bash

docker build . -t 12306-mcp

docker run -p [your_port]:8080 -d 12306-mcp npx 12306-mcp --port 8080

~~~

##

12306-MCP 服务架构图

##

##

本项目仅用于学习,欢迎催更。

##

##

请我喝杯奶茶吧。

Frequently asked questions

What is 12306-mcp?

12306-mcp is This is a 12306 ticket search server based on the Model Context Protocol (MCP).

How do I install 12306-mcp?

Open the GitHub repository and follow its README. Most MCP servers are added to your client's MCP config, then called by your agent.

Is 12306-mcp open source?

Yes — it is hosted on GitHub at https://github.com/Joooook/12306-mcp and has 1,232 stars.

Related MCP tools

Run your own MCP server? See who uses it and what to fix.

Measure it with TrackMCP