- Rust 100%
Charron
Get RATP Traffic data from the command line!
This talks to the PRIM APIs to retrieve data
about next stops etc
It will probably also support bonjour-ratp private API so you don't have to get a key for the public one
The final goal of this project is to provide a simple framework to easily fetch data from any transport API thanks to internal structures. You'd only have to create the bindings between the API and this project. For that reason, the RATP API bindings have been moved to a new crate
Building
This is a rust project. Install the rust toolchain and run
cargo build --release
Usage
For now it's got a very basic TUI that allows searching and fetching (though displaying
stuff is not finished)
Work is currently being done on the program's internal data handling so it's more
flexible and allows for more apis on top of relying less on copying data
Though it is mostly functional. You'll need to get an API key from https://prim.iledefrance-mobilites.fr/ and put it in the charron config file.
Just run charron and you'll get a nice tui. Cli is not yet stabilized
Data structures
would make sense to have: station data Vec station line data Vec train data
or Vec train data here directly (this is what we are doing rn)
for info line ig we'd need a different data structure
Misc
the file data/zdcname_to_zdcid.json was created with
jq -c 'map([.zdcname, .zdcid])' data/zdc.json > data/zdcname_to_zdcid.json
where zdc.json was fetched on https://data.iledefrance-mobilites.fr/explore/dataset/referentiel-des-lignes/
the file data/zdaname_to_zdaid.json was created with
jq -c 'map([.arrname, .arrid])' data/zda.json > data/zdaname_to_zdaid.json
where zdc.json was fetched on https://data.iledefrance-mobilites.fr/explore/dataset/arrets