Skip to content
Harshita edited this page Oct 31, 2015 · 8 revisions

Welcome to the Bin Watch wiki!

This is project #3 of GHCI Hackathon 2015.

DB admin url : http://binwatch-ghci.rhcloud.com/rockmongo/

List of API

Please go through the API reference for complete list of API.

XSS

We have handled user inputs to prevent [XSS attack](https://www.owasp.org/index.php/Cross-site_Scripting_(XSS)_.

Simulation

To simulate few actions and demonstrate them we have added few API end points.

Adding a bin

We have created an API which can simulate creation of a bin at a given latitude and longitude

 curl -H "Content-Type: application/json" -X POST -d  '{"key":"AIzaSyATUDNMyqUpSjLyBDlO3WWTQQH4FtgjyTU"}' http://binwatch-ghci.rhcloud.com/add/bin/:latitude/:latitude

Adding sensor data to a bin id

We have created an API which can simulate addition of the sensor data for a bin.

 curl -H "Content-Type: application/json" -X POST -d  '{"key":"AIzaSyATUDNMyqUpSjLyBDlO3WWTQQH4FtgjyTU"}' http://binwatch-ghci.rhcloud.com/add/bin/:binID/a

ctivity

Predicting fill time

We have created an API which will follow the algorithmic calculation to store estimated fill time of a bin. We plan to set up a cron job in future which will do this calculation for all the bins every night.

 curl -H "Content-Type: application/json" -X POST -d '{"key":"AIzaSyATUDNMyqUpSjLyBDlO3WWTQQH4FtgjyTU"}' http://binwatch-ghci.rhcloud.com/bin/predict/:binID

List of Areas where the bins are placed currently :

  • Koramangala, Bengaluru, Karnataka, India
  • Majestic, Bengaluru, Karnataka, India
  • Hoodi, Bengaluru, Karnataka, India