Get day-by-day trip plans backed by research on current prices, visas, weather, and local events.
Coding
Fly Flight
Query China domestic transport options through one skill. Use when a user wants domestic flight or high-speed rail results, departure and arrival times, stat...
What it does
Query China domestic transport options through one skill. Use when a user wants domestic flight or high-speed rail results, departure and arrival times, stat...
The skill document
Fly Flight
Use the unified transport entrypoint in this skill to handle China domestic trip lookup for both flights and high-speed rail.
这是一个统一的中国境内出行查询 skill,同时支持航班和高铁。 它通过同一个 transport 入口按 mode 路由到底层 provider。
Requirements
Require the following runtime environment before using this skill:
python3node- Network access to Tongcheng public flight pages and official 12306 public endpoints
使用这个 skill 前,运行环境必须具备:
python3node- 能访问同程公开航班页面和 12306 官方公开接口的网络环境
These dependencies are required whether the skill is installed from GitHub or from ClawHub.
无论这个 skill 是从 GitHub 安装还是从 ClawHub 安装,这些依赖都必须满足。
Current implementation status:
flightmode is implemented through Tongcheng public flight pages.trainmode is implemented through official 12306 public high-speed rail query and public price endpoints.
Quick Start
Flight query:
python3 {baseDir}/scripts/transport_service.py search \
--mode flight --from 北京 --to 上海 --date 2026-03-20 --sort-by price --pretty
High-speed rail query:
python3 {baseDir}/scripts/transport_service.py search \
--mode train --from 北京 --to 上海 --date 2026-03-20 \
--seat-type second_class --sort-by price --pretty
The legacy flight-only entrypoint remains available for backward compatibility:
python3 {baseDir}/scripts/domestic_flight_public_service.py search \
--from 北京 --to 上海 --date 2026-03-20 --sort-by price --pretty
Optional local HTTP mode:
python3 {baseDir}/scripts/transport_service.py serve --port 8766
Workflow
-
Determine transport mode. Use
flightfor flights, airports, airlines, or plane tickets. Usetrainfor high-speed rail, rail tickets, stations, or train numbers. If the user is ambiguous, infer conservatively from their wording or ask. -
Route to the correct provider. Use scripts/transport_service.py as the shared entrypoint. Flight mode delegates to scripts/providers/flight_public_service.py. Train mode delegates to scripts/providers/train_public_service.py.
-
Preserve a shared outer response shape. Return
mode,provider,trip_type,outbound, and optionalreturn. Keep mode-specific fields inside each leg'soptions. -
Apply only mode-specific filters that make sense. Flight filters: airline, direct-only, preferred airports. Train filters: train type, seat type, preferred stations.
-
Summarize results with the mode label. Clearly say whether the result is a flight result or a train result. Treat public-source prices as reference prices that can differ from final checkout prices.
Output Rules
- Prefer up to 5 options unless the user asked for more.
- State the exact travel date in
YYYY-MM-DD. - Keep the outer response consistent across modes.
- Do not force a single shared field schema for airports and stations; keep mode-specific details inside
options. - For round trips, clearly separate
outboundandreturn. - For train mode, explain that prices come from official public fare data and seat availability comes from public query results.
Resources
- Use scripts/transport_service.py as the unified CLI and HTTP entrypoint.
- Use scripts/providers/flight_public_service.py for flight lookups.
- Use scripts/providers/train_public_service.py for high-speed rail lookups.
- Use scripts/domestic_flight_public_service.py only for backward compatibility.
- Use scripts/extract_tongcheng_state.js to decode the Tongcheng public page payload.
- Use references/provider-public-web.md for public-source notes and limitations.
Related skills
Variflight Global Flight Fares searches one-way flight fares from the Variflight ticket API by departure IATA city code, arrival IATA city code, and departur...
A persistent travel archive carried across every trip: destinations, documents, bookings, points and costs.
Generate complete, image-rich travel plans from trip dates and destination, including day-by-day itinerary, transportation, lodging area guidance, budget ran...
Find, price, and fix flights with the total cost and the deadline that bites next.
美团酒旅官方 Skill,您的专属 AI 旅行管家。酒店、机票、火车票、景点门票、度假一站搞定,还能帮你找优惠、比价格、定行程。美团海量真实点评加持,出行每一步都更放心。