Pet Shop themed REST API implemented in Node JS
This makes it ideal to implement in apps that follow the MVC architecture in order to be used as the server-side of it
/animal/list (get) - Returns a list with all animals in the database
/animal (post) - Adds a new animal in the database
/animal/:name/:species (put) - Changes two attributes from an animal (the ones given in the url arguments)
/owner/:owner (get) - Returns all animals that may have the inserted argument as an owner
/owner/:owner (delete) - Deletes all animals from an owner from the database
/animal/:name/:species/:age/:owner (delete) - Deletes only the described animal
- An animal is an umbrella term for a pet in this API
- It is an JavaScript object, written directly to "animals.json"
- Composite of the following attributes:
- Name
- Species
- Age
- Owner
- Connect this to a proper database; any relational one would do the trick
- Refactor any possible bottlenecks