REST In Simple Terms
DEBAKANTA JENA
Product Owner@Avaya , Cloud Communications & Work-stream Collaboration,Digital workplace infrastructure,Proficiency(Agile,Devops,Cloud ,cloud transformation, UCaaS, CCaaS, Cloud-Go Hybrid, Public)
What is REST ??
REpresentational State Transfer (REST) is an architectural style that defines a set of constraints to be used for creating web services. REST API is a way of accessing web services in a simple and flexible way without having any processing.
What is the difference between APIs and REST APIs?
The main difference between an API and a REST API is the way they communicate with each other.?
An API can communicate using any protocol, data format and architecture that suits your needs. On the other hand, a REST API is based on a set of architectural principles that define how it should be designed and function.
A REST API follows a set of architectural principles that are based on the web and uses the same standards, such as HTTP and URIs.?
Why REST ??
REST technology is generally preferred to the more robust Simple Object Access Protocol (SOAP) technology because REST uses less bandwidth, simple and flexible making it more suitable for internet usage. It’s used to fetch or give some information from a web service. All communication done via REST API uses only HTTP request.
How REST Works
A request is sent from client to server in the form of a web URL as HTTP GET or POST or PUT or DELETE request.
After that, a response comes back from the server in the form of a resource which can be anything like HTML, XML, Image, or JSON.
Any REST request includes four essential parts: an HTTP method, an endpoint, headers, and a body.
HTTP method describes what is to be done with a resource.There are four basic methods
There are other methods which are less frequently used like OPTIONS and HEAD. PATCH: It is used to modify capabilities.The PATCH request only needs to contain the changes to the resource, not the complete resource.
领英推荐
An endpoint contains a Uniform Resource Identifier (URI) indicating where and how to find the resource on the Internet. The most common type of URI is a Unique Resource Location (URL), serving as a complete web address.
Headers store information relevant to both the client and server. Mainly, headers provide authentication data — such as an API key, the name or IP address of the computer where the server is installed, and the information about the response format.
A body is used to convey additional information to the server. For instance, it may be a piece of data you want to add or replace.
What is Code On Demand (CoD) ?
Instead of sending back JSON representations, the server may return a piece of executable code on the client’s demand. The CoD practice gives the client more control over the features and allows for extended functionality.
Benefits of using REST APIs
Here are a few advantages that REST APIs
Disadvantages of a REST API?
INNOVATIVE TECHNOLOGIES: Technical Writing / Regulatory Compliance / Process Mapping and Flows / Gernerative AI
3 个月Very well done.