SRT
SRT(Super Rapid Train) application python wrapper
With SRTrain, you can:
- Search SRT train schedules.
- Reserve SRT trains.
- Find your reservations/tickets information.
- Cancel reservations/tickets.
while you can't:
- Pay for a ticket.
- Search or reserve non-SRT trains (KTX, ITX, ... ) (use korail2 instead)
This project was inspired from korail2 of carpedm20.
Quickstart
pip install SRTrain
>>> from SRT import SRT
>>> srt = SRT("010-1234-xxxx", YOUR_PASSWORD)
>>> dep = '수서'
>>> arr = '부산'
>>> date = '20190930'
>>> time = '144000'
>>> trains = srt.search_train(dep, arr, date, time)
>>> trains
# [[SRT] 09월 30일, 수서~부산(15:00~17:34) 특실 예약가능, 일반실 예약가능,
# [SRT] 09월 30일, 수서~부산(15:30~18:06) 특실 예약가능, 일반실 예약가능,
# [SRT] 09월 30일, 수서~부산(16:00~18:24) 특실 매진, 일반실 예약가능,
# [SRT] 09월 30일, 수서~부산(16:25~18:45) 특실 예약가능, 일반실 예약가능, ...]
>>> reservation = srt.reserve(trains[1])
>>> reservation
# [SRT] 09월 30일, 수서~부산(15:30~18:06) 53700원(1석), 구입기한 09월 20일 23:38
Documentation
See documentation.
See Also
- go-SRT: SRT golang wrapper
Release files for SRTrain 2.6.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| srtrain-2.6.7.tar.gz | 30.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| srtrain-2.6.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 49.7 kB
Release files / srtrain-2.6.7.tar.gz
| Download URL | srtrain-2.6.7.tar.gz |
|---|---|
| Size | 30.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b5ab9ceb4a1eb8eb813bde81cdaf582b5d406c08da6b4f916c1027199ec1b405
|
|
BLAKE2b-256 checksum How to use checksums |
f32b44bbf0e2cb829831a987c65ba6f4f8ac5972f655711f32d100262865b337
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|
Release files / srtrain-2.6.7-py3-none-any.whl
| Download URL | srtrain-2.6.7-py3-none-any.whl |
|---|---|
| Size | 19.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f85e5a271e382a8df41484c001885f2257f08c9e6117cdb2b173f1e043c1ef7a
|
|
BLAKE2b-256 checksum How to use checksums |
f567ad8279399a20aeb7d01fe32f38a98bd4c6af818e1f55fa40e0565396f43d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|