A Whole Look Into REST
A refresher.
REST stands for Representational State Transfer and was a term coined by Roy Fielding in 2000, whilst writing his dissertation. In it, he laid out some constraints that should be in place whenever two systems communicate. REST is, in essence, a set of rules that define what the server is and what it does.
There are 6 constraints which make a web service RESTful:
There are 6 constraints which make a web service RESTful:
- Uniform Interface: ensures that servers and clients can communicate by defining the interface between them; this also ensures that architecture can be disassembled easily on both sides. This is the constraint that deals with the HTTP verbs; (ie. GET, POST, PUT/PATCH, DELETE).
- Client-Server: client sends a request to the server, server sends a request back to the client.
- Stateless: Servers treat each request as new. They do not store previous HTTP request data. Therefore, each request sent must carry all of its pertinent data. That way, it doesn’t matter which server the request travels to.
- Cacheable: Improves performance by allowing clients to access data that doesn’t change very often.
- Layered System: This allows for different actions to carpool. From the client, there could be an API being deployed and authentication requests in the same ride!
- Code on Demand: This allows us to return executable code when necessary.

Thanks for stopping by 🙃️, BYE!