Mcporter Railway Query
Skill by lancenas
Why use this skill?
Efficiently query and track China Railway 12306 tickets using the Mcporter Railway Query skill. Search schedules, check availability, and plan trips easily.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/lancenas/mcporter-railway-queryWhat This Skill Does
The Mcporter Railway Query skill is a powerful automation tool designed for travelers and commuters in China to interact with the 12306 railway ticketing system via the OpenClaw AI agent. It abstracts complex CLI commands into a simplified interface, allowing users to search for train schedules, check ticket availability, and filter results based on specific preferences such as train types (G/D series), departure windows, and sorting criteria. Whether you are planning a business trip from Shanghai to Hangzhou or commuting across regional lines, this skill automates the data retrieval process, providing real-time status updates directly in your chat interface.
Installation
To integrate this skill, ensure you have the OpenClaw environment configured. Use the following command in your terminal: clawhub install openclaw/skills/skills/lancenas/mcporter-railway-query. After installation, verify that the mcporter CLI is globally installed via npm. You must also establish a valid ~/.mcporter/mcporter.json configuration file, which serves as the bridge between your machine and the 12306 railway data servers. If the tool is not found, verify your environment path by running npm install -g mcporter.
Use Cases
This skill is perfect for scenarios where efficiency is key. Use it to:
- Quickly verify if there are high-speed seats available for a last-minute trip.
- Compare travel times between different train options during peak hours.
- Automate the lookup of station codes for unfamiliar cities before booking.
- Plan inter-city travel itineraries by narrowing down trains that fit within a preferred time block (e.g., afternoon departures).
Example Prompts
- "Can you check if there are any high-speed trains from Shanghai Hong桥 to Hangzhou East on 2026-02-18 between 2 PM and 6 PM?"
- "Help me find the station code for Nanjing South so I can look up tickets for next week."
- "Show me all available trains from AOH to HZH for tomorrow, sorted by arrival time."
Tips & Limitations
- Accuracy: Always verify station codes if the search returns no results, as minor typos in city names can lead to query failures. Use the
get-station-code-of-citystool if you are unsure. - Data Refresh: As ticket availability on 12306 changes rapidly, rely on the agent to perform real-time queries rather than caching results.
- Filtering: Use the
trainFilterFlagsparameter effectively to reduce noise by focusing only on 'G' (High-speed) or 'D' (Dynamic) trains. - Limitations: This skill focuses on querying; it does not replace the official 12306 app for secure payment or official booking authentication. Use it as a discovery tool to streamline your booking workflow.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-lancenas-mcporter-railway-query": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-read, external-api, code-execution
Related Skills
mcporter-railway-query
Query and book Chinese railway tickets via 12306 using mcporter CLI. Use when user wants to search for G/D/C train tickets, check train schedules, query seat availability, or plan rail travel between Chinese cities. Supports filtering by date, time range, train type, and sorting results.
variflight-aviation
飞常准航班信息查询 - 实时航班动态、航线搜索、舒适度评估、机场天气、飞机追踪