Book Image

Hands-On RESTful API Design Patterns and Best Practices

By : Anupama Murali, Harihara Subramanian J, Pethuru Raj
Book Image

Hands-On RESTful API Design Patterns and Best Practices

By: Anupama Murali, Harihara Subramanian J, Pethuru Raj

Overview of this book

This book deals with the Representational State Transfer (REST) paradigm, which is an architectural style that allows networked devices to communicate with each other over the internet. With the help of this book, you’ll explore the concepts of service-oriented architecture (SOA), event-driven architecture (EDA), and resource-oriented architecture (ROA). This book covers why there is an insistence for high-quality APIs toward enterprise integration. It also covers how to optimize and explore endpoints for microservices with API gateways and touches upon integrated platforms and Hubs for RESTful APIs. You’ll also understand how application delivery and deployments can be simplified and streamlined in the REST world. The book will help you dig deeper into the distinct contributions of RESTful services for IoT analytics and applications. Besides detailing the API design and development aspects, this book will assist you in designing and developing production-ready, testable, sustainable, and enterprise-grade APIs. By the end of the book, you’ll be empowered with all that you need to create highly flexible APIs for next-generation RESTful services and applications.
Table of Contents (13 chapters)

RESTful API design rules

Now that we understand the roles and responsibilities of an API designer, the API design best practices, and the API design core principles, we can cover one more essential API design aspect called the rules of APIs. The best practices and design principles are guidelines that API designers try to incorporate in their API design. However, the rules of API need to be amended in the API design to make our APIs RESTful. So, this section is dedicated to RESTful API rules such as the following:

  • Use of Uniform Resource Identifiers
  • URI authority
  • Resource modelling
  • Resource archetypes
  • URI path
  • URI query
  • Metadata design rules (HTTP headers and returning error codes) and representations
  • Client concerns (versioning, security, and hypermedia processing)

We're confident that having a clear understanding of these rules will move us closer to design and begin...