Introducing REST, HTTP, and SOAP
REST and SOAP are two different approaches to implementing an API design and HTTP is the data transfer protocol that supports REST APIs. In this section, we shall learn a bit more about them.
While we’re mainly going to focus on the creation of a REST API, it’s equally essential to know the difference between REST and SOAP APIs so that you can decide wisely what type of API suits your organization’s requirements.
REST
REST stands for Representational State Transfer. It represents a modern architectural style for designing an API.
The features of a REST API are:
- A REST API accommodates stateless client-server architectural models, and the data is transferred over the HTTP/HTTPS protocol.
- It supports several data types such as XML, JSON, plain text, and HTML, which makes it easily consumable. JSON is the most widely used data type as it’s a human-readable language.
- It is lightweight and compatible...