REST-API

REST is an architectural style for distributed hypermedia systems that stands for Representational State Transfer. It was first presented in Roy Fielding’s famous dissertation in 2000.

It is a client/server networked hypermedia application architectural style. RESTful web services are online services that use the REST architecture. These services are designed to perform best on the web and include features such as a consistent user experience.

Resources are data and functionality that are accessed using URIs. To represent a resource, REST uses multiple representations such as text, JSON, and XML. It’s also made to work with stateless communication protocols like HTTP. PUT, DELETE, POST, and OPTIONS are a few of the most regularly utilized techniques. Not only is it stateless, but it also has other crucial benefits such as being simpler than SOAP, being able to see faults or mistakes while working, and being lightweight, maintainable, and scalable.

REST API: Best Practices, Concepts, Structure, and Benefits | AltexSoft

Guiding Principles of REST

REST has its own set of guidelines and limits. If a service interface is to be called RESTful, these principles must be followed. RESTful architecture has six guiding concepts.

These principles are:

  1. Uniform Interface
  2. Client-Server
  3. Stateless
  4. Cacheable
  5. Layered System
  6. Code on Demand

The Architecture of the REST-API

Architecture of the REST-API
  • HTTP GET, POST, PUT, or DELETE requests are transmitted from the client to the server in the form of a web URL.
  • After that, the server sends back a response in the form of a resource, which can be HTML, XML, Image, or JSON.
  • In a REST-based architecture, there are five methods in HTTP that are often utilized. These are the commands for creating, reading, updating, and deleting.
  1. POST –To create new subordinate resources
  2. GET –To retrieve resource representation
  3. PUT-To update an existing resource
  4. PATCH-To make a partial update
  5. DELETE- To delete the resources

Advantages of REST-API

  • client and server are independent
  • By serializing data in XML or JSON format, it adds flexibility to formats.
  • Scalable
  • transparency and dependability
  • Because of its simplicity, the REST API is simple to grasp and learn.

Difference between REST and SOAP

Difference between REST and SOAP
Difference between REST and SOAP

I hope you found this useful. I would like to hear from you so feel free to drop a comment or connect with me via LinkedIn or Portfolio.

--

--

--

Blogger | Web Developer | Undergraduate 🎓

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Materialized Views in Amazon Redshift.

Death by Code — When Developers Lose the Fight Against Complexity

What is Product Ownership?

Business Critical Services Safe Live Testing

Capturing Linux EC2 Memory using AWS SSM, IAM, and S3 (PoC)

Welcome to Great Expectations, FileDataAsset!

A Quick Glance On Blocking Queue In Java!

Opyn Upgrades to 0x v4

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Pramud Nadula

Pramud Nadula

Blogger | Web Developer | Undergraduate 🎓

More from Medium

SOC128 — Malicious File Upload Attempt

Opan’s ESP32 Project Archive 8: ESP32 Web Server

Node.js Rest CRUD API with MySQL Part 2

Ansible Playbook — Configuration Using Variable File / Name