How motis-project/motis works
MOTIS is a multimodal transport-routing platform with a C++ service and a Svelte web interface. Its documented operational path is configuration from OSM and timetable inputs, preprocessing into runtime data, then serving HTTP requests. The principal journey path resolves places and combines transit routing with street and shared-mobility routing; geocoding, map tiles, real-time updates, flexible transit, and elevator data are additional capabilities. The README documents product features and command flow; source excerpts show routing interfaces, loaded data, and server startup, but not all endpoint registrations or import internals.
Main entry points: routing.cc Journey endpoint · server.cc HTTP server · data.h Loaded data · config.h Configuration
Components 19
Data and service
- Configuration
include/motis/config.h - Data import
src/import.cc - Loaded data
include/motis/data.h - HTTP server
src/server.cc
Journey routing
- Place resolution
src/place.cc - Transit routing
include/motis/endpoints/routing.h - Street routing
src/osr/street_routing.cc - Platform matching
include/motis/match_platforms.h
Mobility extensions
- Flexible transit
src/flex/flex.cc - Shared mobility
src/gbfs/routing_data.cc - Real-time updates
src/rt_update.cc - Elevator data
src/elevators/update_elevators.cc
API and map
- Journey endpoint
src/endpoints/routing.cc - Geocoding
src/endpoints/adr/geocode.cc - Map tiles
src/endpoints/tiles.cc - Web interface
ui/src/routes/+page.svelte
Other components
- Operator
- OSM and feeds
- API client
Connections 19
- Operator → Configuration: configures
README.md - OSM and feeds → Configuration: supplies files
README.md - Configuration → Data import: prepares import
README.md - OSM and feeds → Data import: preprocessed
README.md - Operator → HTTP server: starts service
README.md - HTTP server → Loaded data: loads data
src/server.cc - API client → HTTP server: sends requests
- HTTP server → Journey endpoint: routes requests
- Journey endpoint → Place resolution: resolves places
src/endpoints/routing.cc - Journey endpoint → Transit routing: plans journeys
src/endpoints/routing.cc - Journey endpoint → Street routing: routes streets
src/endpoints/routing.cc - Journey endpoint → Flexible transit: uses flex
src/endpoints/routing.cc - Journey endpoint → Shared mobility: uses rentals
src/endpoints/routing.cc - Journey endpoint → Platform matching: uses matches
src/endpoints/routing.cc - Loaded data → Real-time updates: holds updates
include/motis/data.h - Loaded data → Elevator data: holds elevator state
include/motis/data.h - API client → Geocoding: geocodes places
- API client → Map tiles: requests tiles
- Web interface → API client: uses API