I have not done a book review in a while, so here goes. I read Fernando Doglio's book REST API Development with Node.js: Manage and Understand the Full Capabilities of Successful REST Development 2nd Edition.
The book is devided in two major parts. The first part familiarizes the reader to the REST paradigm, how to design RESTful APIs and Node.js in general. I really liked the approach Fernando takes explaining the basic concepts of a REST API. The paradigm is explained concise enough to be applicaple, without too many theoretical details. Same goes with the basic concepts of HTTP, which is used as the transport protocol for the REST API throughout the book.
The Node.js section is a bit too short on my opinion, if the reader is not familiar with Node.js already. Then again, the book lifts the important concepts of asyncronous programming and async I/O, so the reader can prep on those, if necessary. Fernando also presents couple of library choices in Node ecosystem, which could be used to develop REST APIs.
The second part of the book walks you through the full process of developing an REST API, with some focus on the design also. There are dedicated chapters for:
- API Design
- Development in Node.js
- Basics in testing
- Documentation with Swagger
- Deployment basics (on bare metal Linux box)
One paragraph especially warmed my heart:
... an API is an application programming interface, with the key word being interface. When thinking about designing an API that will be used by developers other than yourself, there is a key aspect that needs to be taken into consideration: the Developer eXperience (DX).
This is something which should always be on focus when designing your API and its documentation. As a API developer, your customer is the developer. Try and make his/her life as easy as possible with well-designed API, and clear and practical documentation.
Overall, the second part of the book has quite a lot of information to grasp, if the reader is new to API development in Node environment. The section revolves around one example API, which I liked. The example API is small enough, but has enough endpoints and methods to give a realistic picture what a real life API might look like.
Only major gripe I have, is the unavailability of the actual project code, e.g. as a GitHub repository. I hate reading code from black and white book pages. The code would be so much easier to read and grasp from a text editor's window on your iPad or computer.
Other than that, I think Fernando's book will give a good intro to RESTful API design and development in Node.js environment, with a practical example, especially if you are new to these concepts.
Full disclosure: I received a free copy of the book for reviewing.