Skip to content

cazicruz/HNG-Task2

Repository files navigation

HNG-Task_2

please read the documentation.md file

The API

CREATE Person (POST)

Route : /api
HTTP Method : POST
Description : This method creates a new person. The request body should contain the name of the 'person'

Find Person (GET)

Route : /api
HTTP Method : GET
Description : This method retrieves a person from database either by name if name was given or gets all persons in the database if not given

Modify Person (PUT)

Route : /api
HTTP Method : PUT
Description : This method retrieves a person from database by name then modifies the name

Delete Person (Delete)

Route : /api
HTTP Method : DELETE
Description : This method removes a person from database by name