After discovering a handful of Open311 API feeds, we wanted to develop some prototypes that demonstrate how you can quickly make 311 incidents data streaming using Server-Sent Events (SSE) in any browser, or mobile device. Not every city supports Open311, making non-emergency incidents available in an easy to use API, using a common format, but Chicago is one major city that does–providing an example of one city that is ahead of the curve when it comes to the smart city journey.
To get started, we signed up for an API key within the Chicago 311 developer portal, and we took the API path for Chicago 311 requests:
This same setup will work for any of the cities that support Open311 including San Francisco, Washington DC, Boston, and others. We just wanted to show what is possible with Chicago. Eventually we’ll create real time streaming versions of all the available 311 APIs, and add them to an real time streaming API gallery we are building. If you would like to see a real time streaming version of 311 in your city, but aren’t sure where to start, feel free to reach out, and we’ll see what we can do to help.
You can find the demo for this project over at Github, or get at the scripts behind it on the Github repository. It is a pretty basic example of a listing page, but it gets the point across what you can do when streaming 511 traffic data.