December 2017
Intermediate to advanced
296 pages
5h 56m
English
To quickly check out the API that we have created, we will be using a Chrome extension named Postman. You can set up the Chrome extension from here: https://chrome.google.com/webstore/detail/postman/fhbjgbiflinjbdggehcddcbncdddomop?hl=en.
Once Postman is set up, we will be testing two API calls to validate the register and login methods.
Open Postman and enter the requested URL as http://localhost:9000/api/v1/users. Next, select the method type as POST. Once that is done, we will set the headers. Add a new header with key as content-type and value as application/json.
Now we will construct the request body/payload. Click on the Body tab, next to Headers, and select Raw request. And update it with the following:
{ "email" ...