POSTMAN with Jenkins

POSTMAN requests and tests can be run in different ways. One of the ways is to run tests directly from the POSTMAN interface by writing scripts and there are other ways is to run the test using frameworks such as Newman and Jenkins.

In our previous article, we have seen how to run a collection from the command line using Newman and npm. Now let us see how to run the POSTMAN test using Jenkins.

What is Jenkins?

Jenkins is a continuous integration tool written in Java and is an open-source tool. It can be used as a continuous integration server to performs a chain of different actions leading to an integration process.

This is a server-based application and requires a web server like Apache or Tomcat. The popularity of Jenkins lies in the fact that all the faults and errors can be detected at the early stages of software development. Jenkins achieves this by letting you continuously test your build project and find the error in the early stages of development.

Why Companies are Using Jenkins?

Some of the reasons are below:

  • Software companies can accelerate their software development process as Jenkins helps us to build automated tests at a very good rate.
  • Not only at the software final development phase, but Jenkins can also be used at all the phases of the software development life cycle.
  • Even in the stages like documentation also Jenkins can helpful.
Advantages of using Jenkins

There are different advantages of using Jenkins, some are stated below:

  • As Jenkins is an open-source, therefore there are different inputs that are taken from the public through various public meetings to make the project and the strategies better.
  • Due to the high and frequent engagement of people, every month the Jenkins team is able to make a stable release.
  • There are more than 350 Plugins that can be directly accessed from the Jenkins Database.
  • Jenkins supports cloud-based architecture which makes it possible to deploy Jenkins in cloud-based platforms.
Disadvantages of Using Jenkins

There are disadvantages of using Jenkins, though it is powerful and of the most widely tool. Some of them are:

  • The installation is process is a bit harder and thus developers find it difficult to get started with it. Those who are working with it for the first time, have issues even configuring it after installation.
  • Despite the fact that it is a continuous integration tool, the continuous integration fails suddenly when even a minor change is carried out in the settings, etc.
  • The interface used by Jenkins looks obsolete, but it is not really known why the interface developers are not taking measures to upgrade it.
What is meant by Continous Integration?

When a particular task is completed by a developer working in the software development phase, then he/she can commit the code when completed. Now, when there are many developers working on the same project, they may need to commit multiple times in a given time. And also the commit time for all the developers may be different.

Now, when someone completes his piece of work, then he makes a code commit. After the commit, the build starts, then the test is started and then the deployment starts. So basically we can see that it goes like this: code commit->build->test->deploy.

This process keeps on rotating for all the individual developers until the project is completed. This process is called continuous integration.

The continuous integration process includes hosting, monitoring, compiling, testing code, etc. And so tools necessary are:

  • Continuous Integration Servers such as Jenkins, TeamCity, etc.
  • Source Control Tool such as CVS, GIT, etc.
  • Build Tools such as Make, ANT, Maven, etc.
  • Automation Testing Framework such as Selenium, Appium, UTF, etc.
Jenkins Plugins

Jenkins will allow you only to use some set of a limited set of features. If Jenkins has to be integrated with other tools then there are plugins that need to be installed. Suppose, if you want to integrate your Jenkins with GIT then the GIT plugins have to be installed.

Postman Interview Questions

Installing Jenkins and Getting Started

To run a test from Jenkins, we see the two following things:

  • How to set up a job in Jenkins.
  • How to run POSTMAN from Jenkins.

Before you start using Jenkins, the Jenkins software must be installed in your system.

Download Jenkins: Visit the official page of Jenkins:


Now, click and download the .war file. (for windows users).

Once the file gets downloaded, just create any folder on the desktop(optional) and move the jenkins.war file into that folder.

I have named my folder jenkins (you may use any name.). Now open the command prompt and change the path to the same jenkins folder directory.

Now, type the following command: java -jar jenkins.war.

Now, you should see that the jenkins set-up has started in the command prompt itself.

The above way may not work every time while installing Jenkins. The other way to install Jenkins is by directly using the Jenkins Installer where you will be asked whether you want to download and install necessary plugins at the same time as installing the software.

visit the link: and hit the download button as shown in the below interface.

The Jenkins file which you will download will be a .rar file and you have to extract it.

Now, you will get the actual file, which you can start installing directly into your system.

Once you click Install, you will be asked to proceed to the installation by clicking Next.

After clicking the Next button, the installation process for Jenkins will start. Sometimes, it may ask for selecting additional plugins and sometimes it may install the required plugins by default.

Once Jenkins gets installed, you will see this interface after setting a username and a password. Jenkins will open in any of your chosen browsers and by default, it will load in the address: localhost:8080. Just make sure that port 8080 is not used by any other applications or thread in your Operating system.

Postman Interview Questions

Running Test with Jenkins

To run a test using Jenkins, the collection which you want to run has to be exported into a local directory of the system. Let us choose a collection and export it.

Go to POSTMAN and select the collection you want to export. Click into the three dots(...) sign beside the collection name and you will find an option to export the collection.

Once you select the export option, you will get some options on which files you want to export. There will a POSTMAN recommended one. You should choose that.

After selecting the radio button Collection v2.1 (which is the recommended one), click the Export button.

You may choose any directory, I have chosen the folder collection, which I have created inside the C drive. And save the file with any file name. But the extension should be .json.

Once you save the file in the folder or directory, you are done with exporting. Now, go to your browser and load Jenkins. By default, your Jenkins should load into the PORT 8080, so type localhost:8080 into the URL bar and hit enter.

Now, once the page is loaded into your browser, you should see the page as below:

In the above image, you can see the welcome message from Jenkins, and below that there is an option for creating new jobs. Click to create new jobs to get started.

Now, enter any name of your choice. I shall name it as: testjob.

Then click on the Ok button which is on the same page to save the job.

Once you click the Ok button, the job will be instantly saved and you will see the job configuration page.

As you scroll down the page you will be navigated to the Build option.

In the case you are using windows, select the Execute Windows batch command. In the case you are using Mac, select the Execute shell command.


Now, inside the while textarea, you can write the same Newman command, which you wrote in case of running the POSTMAN test in the command line, using Newman.

The steps to run the test would be:

  • Command for navigating to the root directory, C drive in my case. So, I shall use: Cd/.
  • Command for navigating to the folder where I have my .json file exported. In my case, it is a collection folder inside the C drive. So, I shall use: cd collection.
  • Command for running the JSON file- text.json. So, I shall use the Newman command: newman run text.json.
cd collection
newman run text.json


Now, click on Apply and then click Save. As you Apply and Save you will be automatically navigated into a page, where you will get the option to build your test.

Click on Build Now to build the test. It may take a few seconds to build the project and once complete you will be able to see it along with the date and time of creation.

Now, click on the built project (#2 in this case)to see different options such as console output, etc.

You may click the Console Output option to see the output.

Postman Data Cascading

0 results
Comment / Suggestion Section
Point our Mistakes and Post Your Suggestions