12306 API guide
kyfw.12306.cn
Use 12306 to check train departures, seat availability, and fares by class, and review in-progress ticket orders.
Actions and inputs
trainsList departures and seat availability by class.
Inputs origin, destination, travel date, optional limit
trainShow stops, arrival and departure times, and stopover durations for a train segment.
Inputs train ID, origin, destination, travel date
priceShow fares in CNY by seat class for a train segment.
Inputs train ID, origin, destination, travel date
ordersView in-progress ticket orders for your signed-in account.
Saved passengers
- Create
Add an authorized traveler to your account's passenger list, subject to 12306 identity verification.
Inputs Traveler consent and identity details entered through the official site
- Read
Review your saved passengers and their verification status without displaying full identity numbers.
Inputs Signed-in account and optional passenger selection
- Update
Update editable passenger details without altering verified identity records or existing tickets.
Inputs Passenger selection and permitted field changes
- Delete
Remove a saved passenger if 12306 allows it; this does not cancel any tickets.
Inputs Passenger selection and confirmation