DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

Cover image for  MY LEARNINGS: API 101 & POSTMAN
Dhanush Raj R  J
Dhanush Raj R J

Posted on

MY LEARNINGS: API 101 & POSTMAN

This was the first time I attended a session on APIs and Postman. The session was mind boggling😍😍. I came to know what is an API, its advantages, common APIs, about Postman, send data, receive data, different Datatypes, status codes etc.

                        API
Enter fullscreen mode Exit fullscreen mode

API(Application Programming Interface), which is a software intermediary that allows two applications to talk to each other
i.e Basically APIs act as a Facilitator.
Its advantages are:-

  • It reduce the work load of software developers.

  • API is also used to improve the features.

Image description
API allow developers to access data from a service(like Google, Facebook etc) without any knowledge of how the code base has been implemented.

                       POSTMAN
Enter fullscreen mode Exit fullscreen mode

Postman is an API platform for building and using APIs. Here I familiarized with postman UI.
Request and Response are the important things in Postman.
Different types of request that we use are:

  • Get Request - To retrieve the information
  • Post Request - To sent the information
  • Pull Request - To update the information
  • Delete Request - To delete the information

REQUEST contain three parts:

  1. Parameters
  2. Authorization
  3. Headers

RESPONSE contain three parts:

  1. Status Code
  2. Headers
  3. Accessing Body data

Different types of status codes are:

  • 200 OK - means we got the data.
  • 201 Created - means data is created
  • 404 Bad Request - means their is some error.

Then we forked a workspace to my workspace and familiarized postman. On that workspace I worked on Get request, Pull request, Delete request etc. There we added new Jokes, updated the existing
ones, deleted some. For Post request we used JSON body for posting new jokes. There is a documentation on postman through which we can get a better understanding.

There are many datatypes in postman, of which we mainly use JSON. The format of JSON file is:
{
"id": "1",
"author": "Dhanush Raj R J",
"joke": "Bugs are updated features",
"source": "iali.dev"
}
The 'id' is very crucial for Put request. Some APIs are public, some are private. The private ones requires Authentication in order to protect the privacy. If we select a particular part of the link we can set it as a variable.

The session was really helpful and I learned many things what is an API, about Postman, Request, Response etc.
The session was handled beautifully by Adam Oomen Jacob. He made sure that we understood every bits and pieces. I thank Tinkerhub MEC and Postman for organising a wonderful session.

Top comments (0)

Let's Get Wacky


Use any Linode offering to create something unique or silly in the DEV x Linode Hackathon 2022 and win the Wacky Wildcard category

β†’ Join the Hackathon <-