API testing using Postman | Learn API testing | Part 2

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] hi guys welcome to the channel so as a part of this video i'm going to talk about introduction to postman in this video i'm going to talk each and everything about postman like how postman actually works from where you should download it and then finally for any api tester who is new in this field how to actually use postman application and how to perform api testing this video will be my first video on postman where i will be teaching how to perform apa testing on postman tool so let's get started to download the postman app you just need to go to google and just type postman the moment i postman you will see download the app just click on download the app button and just click on download since my laptop is 64-bit i'm gonna download it and this is a exe file so guys if you have seen my this playlist so this playlist is for each and everyone who want to learn epa testing so i have already uploaded my two videos on that this video is going to be my third video in coming days i will be talking more deeper and deeper into apa testing and i will be talking about deeper into how to perform api testing using postman tool and guys i'm giving a guarantee that i'm going to talk about those things which i'm sure that you guys would have never seen that i'm gonna talk something different that you guys will love and i'm sure that even though you're using postnatal from maybe five years or seven years or so what i'm gonna teach today you will find it different from your own knowledge so let's get started so as you can see that is already downloaded i will just go to the downloads and i will try to install it i will wait until this gets installed completely so now finally your postman is installing a system so if you already have a google account on your postman you can sign in with that or else you can create an account for this postman since i'm teaching you for the first time what you can do is keep signing in and take me straight to the app you need not sign into the application because you are learning it the first time and just go to the straight to the app guys here if you see this is my user interface of my postman application this is how your postman application looks like this is the gui what i'm going to do is i'm going to close this and i'm going to teach each and everything to you step by step so if you see this new button create new if i click on this it will only ask you what you want to create so i'm going to teach you guys to create and request so let's create and request and then a request name i can give anything i wanted and because description in case you have you can give it and any request you create should be there inside a collection so you have to give a collection name so i'm gonna give my collection name is mkp and save to mkt that means the request that i'm creating this manish should get saved inside my collection mkt so i'm just saving it and if i just comment collection now my mkt collection is created and in that i have created a request the name of that request is manish and it isn't get call if you see this particular thing from guys this is my request builder starting from here to here from here to here in between this area that is called my request builder whatever the request i will be having i will be adding in this block this is called as request builder whatever request that developer will create or any request or any api that developer has worked on i will be adding in this particular area from here to here this is my request builder and all the calls will be of different http methods when i say http methods don't worry about what do you mean by http method now because i will be uploading a separate video on http methods where you will be learning each and every http methods in detail for now we just understand that this particular thing is called as http methods so let's suppose that the api which developer is giving to me now is a get request is a get request and that is the reason i have selected get and as you remember in this video i said you guys that if you remember this topic now i said you guys that whenever developer write a logic whenever he'd uh perform or he write a logic for any particular thing he will give a url that url you need to add it here and then there's there are headers so if if i have to give an example like what what actually is headers so as i said you guys that to use different companies api or to use your own apis you need a credential to access those api credentials are nothing but you need an authorization to use that particular api and to use those api you need an api key so you need to add that api key here that means you need to add something like my api key and then you need to add the api key value so this will vary from company to company so that is the use of headers there are many other things also that you will be learning in maybe future classes guys always remember whenever you are having a get call you are not having a body in that whenever you are having a post call or put call or patch call that time you will be having body and what exactly is this http methods that is put post uh that is get post put patch delete head options all this column do not have to worry about it i'm gonna upload a single video for that from where you guys learn this perfectly now don't break your head just remember that on my get call there will not be any party because in get call what i do is i will just try to capture the data i just try to get the data from my server so i do not sign anything my body do not worry about it i'm going to upload a separate video on my http methods so now you don't have to worry so this is my http methods which i need to select based on the request that developer has built it and here i will be entering my url in case i have different kind of parameters i have to add it here and then i need to click on send button the moment i click on send button i will get the response here this is my response so i will get the response here when you are sending a request you can also click on send button directly and get the response or else you can click on this button and you can send and download the request and there is a save button here which will save your request in this postman in your local system so so this is how you create a collection and then in that you create a multiple request remember guys in a particular collection there can be multiple requests you just understand in this way like you have a test suit and then in that you will be having multiple test cases right so your test suit here in is like your collection so inside a collection there can be multiple possibilities of your request so if you see here you will see multiple options here that is share collection you can share your collection with your peers your colleagues and you can rename the collection you can edit anything you want it here and uh you can you can make make a duplicate of this particular collection you can export this collection in your local system you can delete this collection so this is an option you will get it when you click on the options of your particular request you will see that open a new tab or else rename it edit it duplicate it or delete it if you duplicate let's say your one more request will get created and now you just have to rename it let's say my next request is abhishek name is abhishek and now my whatever the new request that i've created is not a get call but it's a postcard so i will write it as post you remember guys this get is still here even though i've started post it will not save until and unless you click on save button here now you see that when i clicked on save button here this request got automatically changed from get to post so this is how you create multiple collections and in that you create multiple requests now guys uh if you see this is my file option in which i can create a new tab of my postman application new postman window i can open new runner window i can open i can import some collection that i have received from my peers if you come to setting here it has a lot of settings in it that you can see you can change your theme of your postman from black to white based on your need like how you want it like you you guys are having a lot of shortcuts here which you will be required when you will be working on postman for apa testing rigorously because this will save your time and this shortcuts are very much necessary guys believe me this is download new new man from npn so this is required when you want to run your collection automation with a single click from command line itself so this is required i will tell each and every points that i'm talking maybe in my future video but in detail since this is my introduction video i'm gonna talk each and everything which is required to you so do not have to worry anything in case you have any certificate you have you can add it here in case you want your request to go from some other ip address and you need a proxy you can add it here what is the use office i will be talking about this in my future video do not have to worry you can check for the updates if your postman is not up to date since i am up to date it is showing that you are up to date and post my latest version is installed if you just click on this enable automatically download major updates it will download i am disabling it for now if you see about postman this will give you everything you need about postman like uh this is postman for window and what is the version it has each and everything like if you want to report an issue if you want to read the documentation of postman and in case you want to go to the website you want to tweet them something so it is all about this setting if you see edit option you have this basic edit option that will be having in each and every application uh this is all basic option nothing more in it if you see console show postman console so this will help you to see all the logs so lost in the sense suppose uh your personal console is there and you have some request and you are sending that particular request now when you are sending a request it is not 100 true that you will get a response you will get a positive response there are chances that you may not get a response and you may get some error so your postman console will show you what an error logs you are getting so this is very much required and after that if you see here this is same as what i told you so need not worry about it so this is also same as that option which i showed you this is also console so when you send a request anything and click on send button and that time you will get the console so you will get what url you have entered and what response you are getting and it will also show in case you are not getting a positive response that means if you are getting some error it will show all the logs that will be required to send to the developer so this is very much required so for now i will just close it and then you can find and replace that means if you have a lot of collection in your postman and you want to search something so that time you can search it example i'm searching manish so it is showing me there is one collection right it is showing me there is one collection and there is a request called as manish so this is option to find out which collection you want to find out which particular request you want to find out so this is required when you are having a lot of collection in your particular postman application guys if you see this height sidebar so this is your sidebar this particular thing is a sidebar this thing on my screen left side whatever you see is my sidebar if i click on this hide sidebar that sidebar will get hidden if you if you want to show you can show it so now guys if you see my request is on the upper side and my response is on the lower side can you see this my request is on the upper side and my response is on the lower side if i want my request to be on the left side and my response on the right side that time i need to click on this button if you see here my request is here and my response is here so this is the beauty of it there are a lot of options here uh keyboard shortcuts which i just showed you guys which you will be required when you are doing api testing thoroughly and you can also see here my workspaces since i'm not logged in if i just log in here you guys will see that all my collections will be shown here all my requests will be shown here so this is about workspace and then invite guys see if i'm logged in with my account and i want those particular collections or that particular request to be used by someone else also in my team so that time what i will do is i will invite that particular user to use my workspace so this is the use of this let's show you guys by signing into the postman so i'm just signing in so this is my one more account which is my personal account so from where i have logged into my postman application and now if you see if i just press on this button so guys once i logged into my account i got all the car all the collection that was that was there in my account and all the requests that was there in my account if i see workspace now you can see that i have a workspace that is my workspace and i can rename it i can invite to workspace that is i i can invite to other people on my workspace that means i can write an email id and once they log into their postman they will get all the collection that i'm having with the help of this is that and i can create a new workspace if needed i can invite other people to use my workspace using this and guys if you see this this is sync your api request across devices guys see when you are using your postman application with same mail id on let's say on your personal device also and on your office laptop also and you want everything all your requested response to be in sync when i say sync i mean that may be chances are there that today i have worked on my personal laptop and i have worked on more apis i have worked on more api testing and those apis are not there now in my office laptop they are not sync with each other so that time to make my request and response to be sync on postman application i need to press this button once i click the sync button all the request and response that i have received in this particular local system same request and response will save across all the devices so that uses this button so this is something cook is based what is the use of it i will be teaching you in my future videos learning now is not important option of setting which i have already shown you guys in my this topic so this is same as that this is notification if in case postman send any notification to us it will be shown here and then if you want to do it something about postman you can click on this button this heart button and you can just tweet them so this is our managing account so this is my personal mail id uh since i've logged into this account so that is the reason it is showing me if in case i want to add a new account i can just click on this plus and just i can log into another account also so this is environment now what it is i will be teaching briefly about this environment topic in my future video this is one of the most important topic that every epa tester should know i know most of the epiderm do not know this but i will make sure to teach you guys maybe in my future video do not have to worry now this environmental quick look like i will teach in my future videos so whatever the environment you will add same that view you can have a look into that so environment is nothing but see guys you can add it like uh my uh qa environment like your testing environment your production environment your beta environment all those environment you can add it here so that is the use if you see this import button so this is an option to import a collection to your this postman application so you can import a file using using any folder that is there in your system or you can import it with any link that you have and you can just import a collection this runner this runner is used as i told uh if you have any automation you have collection and you have written some test scripts and you want to run them in a single click you will get the response so i will teach all the automation of api just with postman application in my future videos do not have to worry and now this plus option if if you see uh it will add another tab or else it will add another postman window so very simple guys if you see here if you click on this history you can see that all the requests that i have sent from my local system have got saved into my history so that is the use of it other than this we have an option of this boot camp if you see see this boot camp is nothing but this will only teach you from starting how to use in postman so see explore zero percent completed so if you resume this this will only teach you how you can create a collection how you can create and create a request how you can send the request how you can receive the requests each and everything you want to teach you so boot camp is nothing but that will teach you how you can use your postman application to do apa testing now i i'm taking an example of any request i'm showing you an example like this is my dummy request that i have taken and i'm sending the request see guys i'm getting some response so this is the response i have got now so this was my request if you see so this was my request actually and this is a response i have got so this is my response so response can be viewed by either in pretty way pretty view something which you will be able to view it like very easy way like so what you're reading is a pretty view like anyone who is reading is able to understand what they have written raw is something which will be written in a raw format it is not pretty i mean if you will be finding difficulty to read this right so this is that preview is something how actually it looks that is preview so it has different type of response so generally we see in pd view to see the response in a very understandable format and then if you see here this is my 200 okay so this is my status code response status code if you see this is my status quo 200 200 means i sent the request and i actually got the response so this is i sent the request and i got the response that's why i got 200 status code now why i got 200 status code only and what exactly is 200 status code and what actually is http status quotes i will be uploading a separate video on that maybe after immediately after this video for your understanding do not have to worry about it if you see here this is the time taken to send the request and to get the response so i got a response in 992 millisecond that means i got a response in 0.9 seconds less than one second i got a response and this is the size of my response body you can see that it is 7 10 byte this is how you send the request and you get the response and guys uh when when you are adding any headers when you are adding any headers suppose these are all headers i added right adding a header has two ways either you can just write something here and you can write some value this is one way of writing header or else you can go to the bulk edit you can go to the bulk edit and you can write multiple headers you wanted and add multiple headers you wanted all will be saved there you see here you can add multiple headers you wanted and all will be saved here so the use of bulk added to add more headers if you want to add in a single click you can add it here now i will tell you guys what is the use of this params so is nothing but if you want to add some parameter to your request guys if you see i'm adding a parameter let's say name as mkt if you see here whenever i'm adding some name right whenever i'm adding some parameter right so my url was earlier it was still here when i added a parameter it added a question mark and added my name equals to mkt so whenever you are adding any parameter it will only add a question mark and after that it will add a parameter now if you want to add and more parameters also you can just add and and after that you can add it like if you see here i added age it only added and and now you can enter your age whatever the age will be right so what i'm trying to say here is whenever you're adding a parameter to your request any parameter for the first request you have to enter question mark and then your particular key and then your value so your name this name is called as key if you see here and your mkt is nothing but your value so this is how you add parameters so this was your request builder right now you can go to the code section of it and when developer expect you that what actually request you have sent sometime they asked what is the curl of it so in that time you need to send this particular call you need to just click on this code and you can see here you have selected the curl so there are multiple ways of saving the particular request you can save your request by either this go native or http one so you can save it as curl also there are multiple ways of saving a particular request you can just click on this copy and now you can send him wherever you want it send him you via mail or anywhere you want and then after that you have this new button right i told you how to create and request it has a lot of things you can create a collection you can create an environment what are all these things i will be teaching in separate videos these topics are very big so you know how to create a request right you know how to create a collection you you just need to know all these two things as of now do not break your head go to the templates guys i have seen many testers who are like learning api testing for the first time they find it difficult to get the apis to just to practice like how to practice the api so for them this is a place where they can go and test with the and play with the apis so guys if you see here it has lot of apis so these all apis are public apis which you can use it you can use it and you can learn it i mean for learning purpose these are all apas are there you can learn automation from here itself whatever api you need you just type it here you just enter maps i'm just showing you see you you've got some some apis related to maps if you read this you got some eps related to maps uh let's say i want to need ap for some basic knowledge i will just into basic and click on from all i will click on basic apis and i'll just click on enter so if you see here introduction intro to writing test with example run in postman this api uh introduction to writing test i have got it from there itself if you see this basic to test syntax i mean these and all apis are free you can just these are all apis are there for your learning purpose see as i told you guys when you are adding a particular parameters there will be a question mark so you can you can learn it from here they have added a lot of headers they have added automation scripts as well to make sure whether the that particular test case is pass or fail that result you will get it here test result name of the first test pass name of the second test pass how to add it do not have to worry i will teach you each and everything so if you check body i got the result and i got this status as 200 okay okay means you got the positive response you sent the request and you got the response server have given the response to you and this is what you have got you have got it in 1.1 seconds and the size of my body is a response body is 859 bytes so this is apis which are public and these are public's api means you can use it for your learning purpose or in case you want to use those apis you can use it so they have also have api network in that if you see there are multiple companies who have added their apis for others to learn it see twitter have added upon api and a lot of companies have added their apis so these are not public you can use it for any purpose you want it for your learning purpose anything you can just take it just click on it and you will get it i'm sure that these are all things no one will tell you and i'm sure that you guys are hearing this for the very first time uh in case you know you knew already very much well in code and always remember whenever you're using postman your internet connectivity is required always to send the request to the server you are actually playing with apis you are actually playing with your logic how you can expect your web server your application server to receive what are you doing in an application so this is this will send the request to the web server because it need and connection internet connectivity is required yes it requires so i guess this is all about postman i have added a playlist make sure that you watch it from starting i've added more more videos on that playlist please do watch it so this is all about from this video if you think this video was useful please give a big thumbs up this video subscribe to my channel software testing by mkt and please share this video with your friends which video about postman i should i should upload next put out in the comment section i will be clearing all your doubts thank you guys
Info
Channel: SoftwaretestingbyMKT
Views: 59,619
Rating: 4.9232154 out of 5
Keywords: api testing, postman, api, api testing with postman, learn postman tool for api testing, postman tutorial, postman tool for rest api testing, api testing using postman, postman api testing, Postman Api Testing, what is postman, postman api, how to test api with postman, how to use postman, rest api, postman post request, what is api testing, What is API, post request using postman, postman tutorials for beginners, postman beginner tutorial, how to test API, softwaretestingbymkt
Id: p4Og5Iuox6A
Channel Id: undefined
Length: 28min 15sec (1695 seconds)
Published: Thu Aug 06 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.