-
Notifications
You must be signed in to change notification settings - Fork 25
Description
Detailed Description
We have lines. We have stops. But the way they're related is totally random. Turns out there's an API endpoint on TransitLand that contains this information!
Possible Implementation
We have a rake task that pulls a bunch of data from TransitLand and uploads it into a database: that's called set_up_transitland. You can see that in that task we make a bunch of GET calls to transit land and create instances of the Stop and Line models.
The same way that we can reach out to
https://transit.land/api/v1/stops?served_by={AGENCY_ID}
to get stops, we can also reach out to
https://transit.land/api/v1/route_stop_patterns?traversed_by=r-dp3w-brownline&per_page=false
to get a bunch of patterns of stops for a line.
This ticket should encompass the effort to simply import the infomation into our database such that we don't relate stops to Lines directly, but relate Lines to stop patterns.
More Info
You can use this website to see the information live:
https://mobility-explorer.interline.io/
What's more, you can use the built in dev console in your browser to see what calls are being made to transit land to get the data which will show on the screen.