Download data from the NRE DTD
Project description
nre-dtd
A tool for downloading data from the National Rail Enquiries' data feed.
This code is licensed under the WTFPL or the CC0 (at your discretion), but its output is not. Any NRE data included in the output of this program is subject to these terms and conditions.
Useful links
- DTD on the Open Rail Data Wiki
- Fares and Associated Data Feed Interface Specification by the Rail Delivery Group
- National Routeing Guide Data Feed Specification by the Rail Delivery Group
- Timetable Information Data Feed Interface Specification by the Rail Delivery Group
- How to use the National Routeing Guide by the Rail Delivery Group (not HTTPS)
- The National Routeing Guide in detail by the Rail Delivery Group (not HTTPS)
Get started
Get an account
- Register for an account on the National Rail Data Portal.
- Subscribe to the Fares, Routeing and Timetable feed.
Use the tool
From PyPI
- Run
python3 -m pip install nre-dtd
.
From source
- Run
python3 -m pip install poetry
if you have not got Poetry. - Run
poetry init
to set up the environment. - Run
poetry shell
to enter the environment. - Or, prepend
poetry run --
to every command.
Examples
Get usage instructions
nre-dtd --help
Download everything
nre-dtd --fares <filename>.zip --routeing <filename>.zip --timetable <filename>.zip
This will ask you for a password. The downloaded files are zipped.
Supply the username and password on the command line
nre-dtd --username sarah@example.com --password "correct-horse-battery-staple" <...>
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
nre_dtd-1.1.1.tar.gz
(3.9 kB
view hashes)