How it works...

Our RESTful API application will be running locally on port 1337. When running the test code, it will connect to it and make several requests using different HTTP methods to create a user, retrieve a user, update a user, and delete a user. All the operations will be logged in the Terminal.

If you prefer to test it yourself, you can replace all the code inside the test function, and use the r function to make custom requests. For instance, to create a new user called Smith:

r(`/users/Smith`, 'post') 
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.19.244.187