enroute web service on heroku!
Recently I pushed a development version of the enroute web service to heroku! Enroute is an idea born of several road trips: we wanted something that would tell us not what’s around us right now, or just near our destination, but what’s on the way.
While the concept is quite simple, the execution was, as is typical, a bit more difficult. After playing with a number of the relevant technologies out there, it became clear that the proof-of-concept app would have to interface with and/or provide three underlying services:
- Mapping and directions to generate a path along which to search
- “Boxing,” or decomposing the route into boxes within which one may search
- Venue searching within those boxes
Architectural Notes
After investigating the available APIs and technologies, I chose to implement the web service in a manner that could be indifferent as to the map and directions provider as well as the underlying venue provider. Moreover, I decided that the web service should provide only boxing and venue search services, and not the map and directions. Thus, the proof-of-concept app obtains its map and directions information (as well as the majority of its user interface) on the client side in a browser, independently of the enroute web service.
The web service is implemented as a Python 3.4 flask web application. (I will not justify the choice of Python 3 here; rather, I intend to compose an additional post on the subject.) Currently, it provides two endpoints (“/boxer” and “/venues”) which must be called in sequence, so I hope in the near future to combine them into one stateless endpoint and provide a truly RESTful web service.
The front end is entirely in HTML, CSS, and JavaScript. After attempting to use MapQuest, I went back to Google for maps and directions. However, it should be possible to implement a front end using entirely open data and APIs.
Screenshot
Links
Possibly live app (this is a development server, so it may go up and down)