Inspiration

We wanted to create a REST API and this weeks theme of tidying up and helping the environment inspired us to create an API that would help the enivironment

What it does

/objects Returns an array containing all objects Use query parameters page and pageSize to optimise the output.

/objects/bicycle Returns the information about bicycle

/objects/bicycle/common_components Return the information of common components of a bicycle Other requests that can be made include:

  • object_name returns object name
  • waste_type what type of waste the object is
  • recycle the best way to get rid of it

How we built it

We used datastax astra to store the data and express.js for the application. Depending on the route the data is fetched from the database and returned to the user in a json format.

Challenges we ran into

Initially we planned to deploy to Firebase and we did prepare the firebase project but ran into trouble with billing on firebase which delayed us. We ended up deploying to a Linode Ubuntu instance. It was a great learning experience for us.

Accomplishments that we're proud of

We delivered a working API that can be used in applications by anyone around the world.

What we learned

  • How a REST api works
  • Route management in express.js.
  • How to deploy an express app to Firebase(Even though we ran into troubles with billing, we tested it using firebase serve)
  • How to deploy an express app to Linode

What's next for TidyAPI

We would love to work on a twitter bot that uses this api and whenever a user tweets an image mentioning the bot the bot return with a list of objects detected in the image and how to recycle them.

Built With

Share this project:

Updates