There are three main characteristics of HTTP Request Methods:

1. Safe
2. Idempotent
3. Cacheable

Let's talk about them in this thread. πŸ§΅πŸ‘‡πŸ»
πŸ”Έ Safe

We can call an HTTP request method safe if it doesn't affect the server's state.
The safe methods request the server to send data without performing any modification to the original data. Hence safe methods accomplish read-only operations.
Even though they are read-only operations, they sometimes cause a change in server state; the server can update its statistics.

One thing to note here is that the safe methods never request the server to change its state.
πŸ”Έ Idempotent

Idempotent methods have no side effects on the server. We can call them in a row, and they guarantee that they will not affect the server state (except for keeping statistics).

GET, HEAD, OPTIONS, PUT, DELETE, and TRACE methods are idempotent.
All safe methods are idempotent, but not all idempotent methods are safe.

To be an idempotent method, only the state of the server matters, not the code returned by it. Hence DELETE method is idempotent but not safe.
⚠️ Another thing to note here is that the client-side ensures the validation of idempotence. The bad codebase can shatter the idempotent constraint.
πŸ”Έ Cacheable

As the term suggests, we can call HTTP response methods cacheable if it is possible to cache the response for later use.

However, there are some constraints: πŸ‘‡πŸ»
Constraints for an HTTP response to be cached:

1. Method should be cacheable. Only GET and HEAD methods are cacheable.

2. PUT and PATCH can be cached if the `Content-Location` header is set.
3. Only a few status codes are cacheable: 200, 203, 204, 206, 300, 301, 404, 405, 410, 414, and 501.

4. Headers like `Cache-Control` can be used to prevent caching.
With that being said, that's pretty much it for this thread.

Visit RapidAPI Hub (RapidAPI.com/hub?utm_source…) and build a strong understanding of APIs by playing around with over 35K excellent APIs.

β€’ β€’ β€’

Missing some Tweet in this thread? You can try to force a refresh
γ€€

Keep Current with RapidAPI

RapidAPI Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @Rapid_API

16 Sep
Here are ten widely used HTTP headers:

πŸ”Ή Accept
πŸ”Ή Accept-Encoding
πŸ”Ή Authorization
πŸ”Ή Accept-Language
πŸ”Ή Content-Type
πŸ”Ή Content-Location
πŸ”Ή Content-Encoding
πŸ”Ή Content-Length
πŸ”Ή Content-Language
πŸ”Ή Cache-Control

Let's talk about them in a bit more detail πŸ§΅πŸ‘‡πŸ» Introduction to HTTP headers
Client and server can pass the extra bit of information with the request and response using HTTP headers.

HTTP headers are not case-sensitive.
The HTTP headers are divided into four categories:

1️⃣ Request headers: Client to Server

2️⃣ Response headers: Server to Client

3️⃣ Representation headers: Information about the body of the resource

4️⃣ Payload headers: Information about the payload data
Read 13 tweets
16 Sep
Check out these five amazing Text Analysis APIs. πŸ†Ž

Feel free to use them in your next application.

πŸ§΅πŸ‘‡πŸ»
1️⃣ Sentiment Analysis

- Enter a string to check the positive or negative tone.

πŸ”— RapidAPI.com/twinword/api/s…

πŸ’° Freemium
πŸ“ˆ Popularity: 9.6/10
πŸ•› Latency: 342ms
βœ… Service Level: 100%
2️⃣ Text-Processing

- This API provides sentiment analysis, stemming and lemmatization, part-of-speech tagging and chunking, phrase extraction, and named entity recognition.

πŸ”— RapidAPI.com/japerk/api/tex…

πŸ’° Freemium
πŸ“ˆ Popularity: 9.6/10
πŸ•› Latency: 438ms
βœ… Service Level: 100%
Read 6 tweets
14 Sep
A complete introduction to API Testing. πŸ§ͺ

API testing is performed to test whether a particular API meets some pre-defined parameters or not.

Let's talk more about API Testing πŸ§΅πŸ‘‡πŸ» A complete introduction to API Testing
API testing includes testing APIs in isolation to ascertain if they meet the functionality, reliability, latency, performance, security, and other essential parameters.
API testing commonly includes testing APIs with JSON or XML payload sent over HTTP, HTTPS, JMS, and MQ. These are widely used data formats and networking/messaging protocols.
Read 15 tweets
13 Sep
Project-based learning is the way to go.

We bring you the top 5 sports APIs to build some of the best full-stack applications.

πŸ§΅πŸ‘‡πŸ»
1️⃣ API-BASKETBALL

- Over 190 Basketball Leagues & Cups with Livescore, Odds, Bookmakers, Statistics.

πŸ”— RapidAPI.com/api-sports/api…

πŸ“ˆ Popularity: 9.7 / 10
πŸ•§ Latency: 420ms
βœ… Service Level: 100%
2️⃣ API-FOOTBALL

- You will get access to over 870 football leagues and cups. You can get a live score as well if you use this API.

πŸ”— RapidAPI.com/api-sports/api…

πŸ“ˆ Popularity: 10 / 10
πŸ•§ Latency: 268ms
βœ… Service Level: 100%
Read 7 tweets
10 Sep
Publish/Subscribe Pattern Based APIs

Let's try to know more about Pub/Sub design pattern and learn some facts about it.

πŸ§΅πŸ‘‡πŸ» Publish/Subscribe Pattern Based APIs
Publish/Subscribe (Pub/Sub) is an asynchronous messaging style used in serverless and microservices architectures.

With this model, messages are not sent to a specific subscriber but are instead categorized to be available to all subscribers of the category.
πŸ“Œ How Pub/Sub Pattern Based APIs Work

The main characteristic of Pub/Sub APIs is the existence of publishers and subscribers, as the name implies. Publishers categorize messages and those that are subscribed to a specified category receive that message.
Read 10 tweets
8 Sep
There are 9 HTTP request methods:

πŸ”Ή GET
πŸ”Ή PUT
πŸ”Ή POST
πŸ”Ή HEAD
πŸ”Ή TRACE
πŸ”Ή PATCH
πŸ”Ή DELETE
πŸ”Ή OPTIONS
πŸ”Ή CONNECT

Let's talk about them in a bit more detail πŸ§΅πŸ‘‡πŸ»
HTTP request methods are the actions initiated from the client-side to perform certain actions.

These HTTP request methods are sometimes called nouns or referred to as HTTP verbs.
πŸ“Œ GET

The GET method is the most common of all these request methods. It is used to get the desired resources from the server.

The GET methods don't affect the state of the server.
Read 13 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!

:(