MCP.so
ログイン
1

12306 MCP Server

@xpfyg

基本情報

カテゴリ

その他

トランスポート

stdio

作者

xpfyg

投稿者

xpfyg

12306 MCP Server について

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

#12306#ticket

12306 MCP Server の設定

標準の設定はありません

このサーバーの README には解析可能な MCP 設定ブロックが含まれていません。インストール手順はリポジトリをご確認ください。

リポジトリ

12306 MCP Server のツール

ツール一覧はまだありません

この掲載には表示できるツール一覧がまだありません。サーバーにツールがないという意味ではありません。対応機能はプロジェクトのドキュメントをご確認ください。

ツールは README から自動的に抽出されます。メンテナーは ## Tools という見出しの下に記載することで、このタブに反映できます。

概要

What is 12306 Mcp?

12306 Mcp is a Model Context Protocol (MCP) server that provides a simple API interface for searching 12306 train ticket information. It allows large language models to query real-time ticket availability and pricing data from China's official railway ticketing platform.

How to use 12306 Mcp?

Clone the repository, run go mod init 12306-mcp, go mod tidy, then go run main.go to start the server. For use in Cursor IDE, add a "12306-mcp" entry to your local mcp.json with the URL http://127.0.0.1:8080/sse, then ask natural language queries like "查询杭州到武汉明天的高铁票".

Key features of 12306 Mcp

  • Query 12306 ticket purchase information in real time
  • Supports searching by departure station, arrival station, and date
  • Returns train number, departure/arrival times, and duration
  • Provides seat type availability and pricing details
  • Integrates with Cursor IDE via MCP protocol

Use cases of 12306 Mcp

  • Ask an AI assistant to check available trains between two cities on a specific date
  • Compare ticket prices and seat availability across different trains
  • Quickly retrieve train schedules without manually visiting the 12306 website

よくある質問

1

What data does 12306 Mcp provide?

It returns real-time train schedules including train number, departure and arrival stations, departure/arrival times, journey duration, and seat-specific availability and prices (e.g., business class, first class, second class).

2

What are the runtime requirements?

The server requires Go to build and run. It is designed to work with MCP-compatible clients like Cursor IDE, connecting via SSE at `http://127.0.0.1:8080/sse`.

3

Does 12306 Mcp support transfer or intermediate station queries?

Not yet. The current version only supports direct station-to-station queries; transfer and pass-through station queries are listed as planned TODO items.

4

What authentication or credentials are needed?

The README does not mention any authentication — the server runs locally and connects to the public 12306 system without requiring user credentials.

5

What transport protocol does 12306 Mcp use?

It uses Server-Sent Events (SSE) transport. The client connects to the server's SSE endpoint to send queries and receive ticket data.

コメント

「その他」の他のコンテンツ