<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: khairozzaman</title>
    <description>The latest articles on DEV Community by khairozzaman (@khairozaman).</description>
    <link>https://dev.to/khairozaman</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4166549%2F622a3f89-6b07-463b-914d-5d7782cebc8a.png</url>
      <title>DEV Community: khairozzaman</title>
      <link>https://dev.to/khairozaman</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/khairozaman"/>
    <language>en</language>
    <item>
      <title>🌐 REST API — More Than Just GET, POST, PUT &amp; DELETE</title>
      <dc:creator>khairozzaman</dc:creator>
      <pubDate>Tue, 06 Oct 2026 13:35:58 +0000</pubDate>
      <link>https://dev.to/khairozaman/rest-api-more-than-just-get-post-put-delete-321d</link>
      <guid>https://dev.to/khairozaman/rest-api-more-than-just-get-post-put-delete-321d</guid>
      <description>&lt;p&gt;As a backend developer, we hear about REST APIs almost every day.&lt;/p&gt;

&lt;p&gt;But what exactly is REST?&lt;/p&gt;

&lt;p&gt;What is an API?&lt;br&gt;
And what is the philosophy behind REST API design?&lt;br&gt;
Today, I’m trying to understand these concepts step by step. &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;What is REST?
REST stands for:
Representational State Transfer.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;REST is not a programming language, framework, or protocol.&lt;br&gt;
It is an architectural style  for designing networked applications.&lt;/p&gt;

&lt;p&gt;In simple terms, we can think of REST as:&lt;/p&gt;

&lt;p&gt;An architectural approach to organizing data and information as resources, representing them in a meaningful way, and transferring those representations through a uniform interface.&lt;/p&gt;

&lt;p&gt;For example, imagine we have a User stored in a database:&lt;br&gt;
User&lt;br&gt;
id: 10&lt;br&gt;
name: Rahim&lt;br&gt;
email: &lt;a href="mailto:rahim@example.com"&gt;rahim@example.com&lt;/a&gt;&lt;br&gt;
An API can provide a representation of that resource to the client:&lt;br&gt;
json&lt;br&gt;
{&lt;br&gt;
  "id": 10,&lt;br&gt;
  "name": "Rahim",&lt;br&gt;
  "email": "&lt;a href="mailto:rahim@example.com"&gt;rahim@example.com&lt;/a&gt;"&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;The actual database object is not being sent directly. Instead, a representation of the resource is transferred to the client.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;What is an API?
API stands for:
Application Programming Interface.
Simply put, an API provides a way for different software systems to communicate with each other.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A typical flow looks like:&lt;br&gt;
Client → API → Server&lt;/p&gt;

&lt;p&gt;For example, when a frontend needs user data, it sends a request through the API.&lt;br&gt;
The backend processes the request and returns a response.&lt;br&gt;
Frontend → Request → Backend&lt;br&gt;
Frontend ← Response ← Backend&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;What is a REST API?
When an API is designed according to REST principles, we commonly call it a REST API.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For example, if we have a users resource:&lt;br&gt;
http&lt;br&gt;
GET    /users&lt;br&gt;
POST   /users&lt;br&gt;
GET    /users/10&lt;br&gt;
PATCH  /users/10&lt;br&gt;
DELETE /users/10&lt;br&gt;
Notice something important:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;The URL represents the resource.&lt;/li&gt;
&lt;li&gt;The HTTP method represents the intended operation.
For example:
/users → Resource
GET    → Retrieve
POST   → Create
PATCH  → Update
DELETE → Delete
Instead of designing endpoints around actions:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;/getUsers&lt;br&gt;
/createUser&lt;br&gt;
/deleteUser&lt;/p&gt;

&lt;p&gt;REST encourages us to think in terms of resources.&lt;/p&gt;

&lt;h1&gt;
  
  
  The Philosophy Behind REST
&lt;/h1&gt;

&lt;p&gt;REST is not simply about using GET, POST, PUT, PATCH, and DELETE.&lt;br&gt;
The real idea is to follow a set of architectural principles when designing APIs.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Resource-Oriented Design&lt;br&gt;
Think about what the resource is, rather than what action you want to perform.&lt;br&gt;
The URL identifies the resource, while the HTTP method describes the interaction.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Statelessness
Each request should contain the information necessary for the server to process it.
The server should not depend on previous requests to understand the current request.
For example:&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Authorization: Bearer &lt;/p&gt;

&lt;p&gt;The authentication information is included with the request, so the server does not need to rely on the state of a previous request.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Client–Server Separation
The client and server should have separate responsibilities.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Client → User Interface&lt;br&gt;
Server → Data + Business Logic&lt;br&gt;
This separation allows both sides to evolve independently.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Uniform Interface
REST promotes a consistent and predictable way of interacting with resources.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For example:&lt;br&gt;
GET /users/10&lt;/p&gt;

&lt;p&gt;From the endpoint and method, we can understand that we are retrieving the user resource with ID 10`.&lt;/p&gt;

&lt;p&gt;A uniform interface makes an API easier to understand, consume, and maintain.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Representation
The server provides a representation of a resource.
For example:
json
{
"id": 10,
"name": "Rahim",
"email": "&lt;a href="mailto:rahim@example.com"&gt;rahim@example.com&lt;/a&gt;"
}&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;JSON is commonly used for representations, but REST itself is not limited to JSON.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Cacheability&lt;br&gt;
Some responses can be cached when appropriate.&lt;br&gt;
Caching can reduce unnecessary requests and improve application performance.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Layered System
The client does not necessarily communicate directly with the main backend server.&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;There can be multiple layers between them:&lt;br&gt;
Client&lt;br&gt;
   ↓&lt;br&gt;
Load Balancer&lt;br&gt;
   ↓&lt;br&gt;
API Gateway&lt;br&gt;
   ↓&lt;br&gt;
Backend&lt;br&gt;
   ↓&lt;br&gt;
Database&lt;br&gt;
The client doesn't need to know how these internal layers are implemented.&lt;/p&gt;

&lt;h1&gt;
  
  
  The Key Idea
&lt;/h1&gt;

&lt;p&gt;REST is not about memorizing HTTP methods.&lt;br&gt;
It is a way of thinking about API design.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F52jqlxm73p2pofx3jpds.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F52jqlxm73p2pofx3jpds.png" alt=" " width="630" height="354"&gt;&lt;/a&gt;&lt;br&gt;
Think in resources, represent those resources clearly, use a uniform interface, keep communication stateless, and separate the client from the server.&lt;/p&gt;

&lt;p&gt;Understanding this philosophy helps us move beyond simply building APIs to actually designing APIs.&lt;/p&gt;

&lt;p&gt;I’m continuing to explore these concepts and apply them in my journey as a Go Backend Engineer. &lt;/p&gt;

&lt;h1&gt;
  
  
  GoLang #Golang #BackendDevelopment #RESTAPI #API #SoftwareEngineering #WebDevelopment #BackendEngineer #LearningInPublic
&lt;/h1&gt;

</description>
      <category>restapi</category>
      <category>api</category>
      <category>backend</category>
      <category>backenddevelopment</category>
    </item>
  </channel>
</rss>
