chairemobilite / transition

Transition is a modern new approach to transit planning. It's a web application to model, simulate and plan public transit and alternative transportation.
http://transition.city
MIT License
20 stars 13 forks source link

Accessibility map endpoint, routing endpoint and error handling added to public API #891

Closed shymkom45 closed 2 months ago

shymkom45 commented 3 months ago

Two new endpoints have been added to the public API: one for obtaining the result of a route calculation between an origin and a destination (POST /route), and one for obtaining the result of an accessibility map calculation (POST /accessibility). Most relevant logic for these endpoints in within the RoutingCalculator module. The logic for all endpoints are also now properly encapsulated between try/catch statements, and a default custom error handler has been added for the API.

shymkom45 commented 3 months ago

Il nous resterait encore à faire la documentation, ce qui devrait venir bientôt dans une PR séparée. D'ici-là, je vais fournir ici des exemples de corps de requêtes que vous pouvez utiliser pour tester les nouveaux endpoints. Le endpoint à utiliser pour chacune des requêtes est indiquée en préfixe de chacun des noms de fichiers: