Hey, did everyone are they sure?
And welcome to another video.
In this video, we're going to talk about something that I kind of rushed through it, and some of you
probably already know it, but I expect that you know nothing and that's where we are going to start.
In case you didn't noticed, I wrote a get here.
So what is this get and what it's going to do?
Let's go ahead and talk more about this one.
Now, whenever you make a Web request, there are types of Web requests that you make.
Usually we really don't see or talk much about it because it's kind of obvious for us.
But as a developer, that becomes a little bit more to us.
Whenever you make a request to ask something from the Google, Google looks into the database and give
it to you.
That kind of request is known for the browser to make in most of the cases, but whenever you actually
write in your email and password and you send it to Google and that validates it, that's a different
kind of request because you are sending some data for the database itself and you're trying to just
kind of put that data permanently, not in the case of log in, but definitely at the case of registration.
So these kinds of things are made up of different web requests.
Now, there are not too many of them for you to remember, but we call them as web request and they
play a very important role at the time of building the web application, whether it's just rest API
or something else, they are really important and good news is there are majorly four of them that we
are going to talk, everybody talks, but there are a little bit more and I'll explain more of them.
Simply putting get post, put and delete and no, there is no color code associated with them.
Usually delete is marked as red, but there is no color code associated with them.
I just put it because I felt these are good ones.
Let's talk about them one by one and they are really simple get is for requesting the information.
Let's just say you are onto a shopping website, you are searching for a term and it gives you a result
back.
These are all get operations and when you slide at just your pricing or maybe your filter by request
or filter by rating, these all are get requests because you are not putting any information onto the
database, you are just asking for it.
And for all these kinds of asking information, we just go for request information and get type of request.
In the case of post, it is usually add to database.
Now what happens in this case, whenever there is information that you are sending something that probably
is going to just add it onto the database itself, then definitely 100% it's supposed to request.
Now, if a sensitive information is also traveling something like your password or something, it is
recommended that web developers use a post request because in the post the data doesn't travel like
in the URL or some place, which is really not that much safe.
So in the case, whenever there is a database involved and you want to put some information or to store
that permanently, then for such persistence information post request is being used.
Another one is put whenever there is a database information which is already there, but you want to
update it.
That's where the put request comes in.
For example, you want to change your username, you want to change your name, you want to change your
photos.
There is already something in the database and that's where the put request comes in.
And finally, last but not the least, the delete request, which obviously is type of request delete
and you delete something from the database.
Now as a user, nobody cares about what kind of request they are sending as a web developer.
Yes, we do care a lot about it now.
Definitely not.
These are the only ones, but these are the majorly being used in every single tech giant major of majority
of them.
But there is a link here to read more, and this is the official MD documentation that you can click
from this web link and I'll give you all the presentation and everything.
Don't do worry.
So what you can see is majority.
These kinds of requests are there.
So there is a get request.
Yes, of course there is a head request, but we don't use it that much.
Yes, in the course we will be using it.
But you don't have to worry too much on that.
You automatically get that.
You don't have to worry.
Then there is a post put and delete that we talked about, but there is a connect, there is option
trace and patch and all of that.
You don't have to worry.
Majority of the time you won't be seeing much of the people using it until unless you are building extremely
complex application.
And by the time you'll be having information about all four of them, it would be easier for you to
understand the rest of them.
Okay.
So now that you are all done and you know the reason why I wrote a get here, because all of this is
asking information.
None of them is adding information on the database.
We don't have a database yet, but this is all that you should know about the request.
Read a little bit more on the documentation.
Even if you don't understand it.
Just glimpsing through over it is always a good idea.
Let's go ahead and catch up in the next video.