# Cannot run newman on jenkins \[newman :command not found\]

**URL:** <https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128>\
**Category:** Help Hub\
**Created:** [July 23, 2018, 7:35pm UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128 "2018-07-23T19:35:48Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![teddy.uzoh](https://avatars.discourse-cdn.com/v4/letter/t/6de8d8/32.png) [@teddy.uzoh](https://community.postman.com/u/teddy.uzoh)\
**Post date:** [July 23, 2018, 7:35pm UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/1 "2018-07-23T19:35:48Z")

</div>

> **Archived topic — this may be out of date.**  
> Newman has been replaced by the **[Postman CLI](https://learning.postman.com/docs/postman-cli/postman-cli-overview/)**, Postman’s official, signed command-line tool. It runs collections as Newman did, and also lints API specs, runs mocks and monitors, and syncs local files with Postman from your terminal, CI/CD pipeline or coding agent.  
> Working with an AI coding agent? The [Postman plugin](https://github.com/postmanlabs/postman-plugin) lets agents in Claude Code, Cursor, Codex and others design, mock, test and ship APIs with Postman.  
> For current help, see the [Postman docs](https://learning.postman.com/docs/), try the free [Postman tools](https://www.postman.com/tools) (no account needed), or join us on [Discord](https://discord.gg/58aNNsRBGR).

Hi all,

Please, I am running into an issue running Newman in Jenkins. I am able to execute my API test on Linux box itself but not on Jenkins. I am getting this error when I try to execute via shell **newman: command not found.** I also set my environment variables on Jenkins using PATH = **/usr/local/bin:$PATH newman -v**

Image attached:

- the test I ran successfully on the box itself
- Environment variable setup on Jenkins
- Console output from Jenkins  
 ![image](https://us1.discourse-cdn.com/getpostman/original/3X/7/7/7742e9c30b1c9e2702d2d66aa8856ec9b1566795.png)

I really appreciate your help

Thanks

---

<div class="post-metadata">

**Author:** ![jignesh.kalaria](https://avatars.discourse-cdn.com/v4/letter/j/b5a626/32.png) [@jignesh.kalaria](https://community.postman.com/u/jignesh.kalaria)\
**Post date:** [August 30, 2018, 8:13am UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/2 "2018-08-30T08:13:25Z")

</div>

Hi,

Append newman local system foder path before you set configration

e,g,

C:/Users/jkalaria/AppData/Roaming/npm/newman is my local system path than enter run and than your collcetions detail

so “Local newman system path” run “Collection detail”

---

<div class="post-metadata">

**Author:** ![pandu.biet](https://avatars.discourse-cdn.com/v4/letter/p/ec9cab/32.png) [@pandu.biet](https://community.postman.com/u/pandu.biet)\
**Post date:** [September 9, 2019, 6:41am UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/3 "2019-09-09T06:41:09Z")

</div>

Hi Team,

I am also getting same error but my Jenkin is in AWS EC2(Linux) , Please help me to resolve this.

In AWS CLI, I have installed node js and newman and could able to run newman commands but when i run same command from Jenkin UI which is present in same AWS EC2, I am getting below error

_[Collection\_run] $ /bin/sh -xe /tmp/jenkins7542658729538318661.sh_  
_+ newman -version_  
_/tmp/jenkins7542658729538318661.sh: line 2: newman: command not found_  
_Build step ‘Execute shell’ marked build as failure_  
_Finished: FAILURE_

Please solve this

![image](https://us1.discourse-cdn.com/getpostman/original/3X/0/1/0194767b037a8584862488fb10fa471a1c7ea223.png)

In AWS CLI , i am getting response properly

 ![image](https://us1.discourse-cdn.com/getpostman/original/3X/0/c/0c07a859398e942c5f5fccdc8f13f45a54e05ce4.png)

---

<div class="post-metadata">

**Author:** ![krishnagrandhi5](https://avatars.discourse-cdn.com/v4/letter/k/df788c/32.png) [@krishnagrandhi5](https://community.postman.com/u/krishnagrandhi5)\
**Post date:** [December 1, 2019, 8:14am UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/4 "2019-12-01T08:14:21Z")

</div>

worked perfectly after giving the full newman path before the collection run command

---

<div class="post-metadata">

**Author:** ![jhpdk1974](https://avatars.discourse-cdn.com/v4/letter/j/ecc23a/32.png) [@jhpdk1974](https://community.postman.com/u/jhpdk1974)\
**Post date:** [February 29, 2020, 2:35pm UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/5 "2020-02-29T14:35:03Z")

</div>

Worked for me also - Thank you

---

<div class="post-metadata">

**Author:** ![nghianv377](https://avatars.discourse-cdn.com/v4/letter/n/0ea827/32.png) [@nghianv377](https://community.postman.com/u/nghianv377)\
**Post date:** [June 4, 2020, 9:00am UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/6 "2020-06-04T09:00:58Z")

</div>

Thank you very much. It fine after add full path by your advice

---

<div class="post-metadata">

**Author:** ![freddan1980](https://avatars.discourse-cdn.com/v4/letter/f/4da419/32.png) [@freddan1980](https://community.postman.com/u/freddan1980)\
**Post date:** [June 30, 2020, 6:17pm UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/7 "2020-06-30T18:17:39Z")

</div>

Can someone give me the exact Shell command for MAC to fire it off correctly , my builds keeps failing

cd /Users/johanlindstrom/Development/Postman/  
cd /Users/johanlindstrom/node\_modules/newman

newman run Collection 1.postman\_collection.json

---

<div class="post-metadata">

**Author:** ![aaggar1](https://avatars.discourse-cdn.com/v4/letter/a/3e96dc/32.png) [@aaggar1](https://community.postman.com/u/aaggar1)\
**Post date:** [March 30, 2021, 3:08pm UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/8 "2021-03-30T15:08:37Z")

</div>

I am using Linux container. when I try giving folder path “newman” run XXX.

- cd /usr/local/bin/node-v12.3.1-linux-x64/lib/node\_modules/newman/bin
- newman run SCTSTSanityTest.postman\_collection.json -e StarGate.postman\_environment.json -r htmlextra --reporter-htmlextra-export reports/Newman\_Test\_Execution\_Report.html --insecure

/tmp/jenkins153481404085324858.sh: 9: /tmp/jenkins153481404085324858.sh: newman: not found

---

<div class="post-metadata">

**Author:** ![material-astronomer9](https://avatars.discourse-cdn.com/v4/letter/m/b4bc9f/32.png) [@material-astronomer9](https://community.postman.com/u/material-astronomer9)\
**Post date:** [May 23, 2024, 6:10pm UTC](https://community.postman.com/t/cannot-run-newman-on-jenkins-newman-command-not-found/2128/10 "2024-05-23T18:10:48Z")

</div>

I am also getting this error, i’m using a aws ec2 as agent but even when add full path it’s not working

 ![image](https://us1.discourse-cdn.com/getpostman/original/3X/3/5/3517cb2d16a1237426becb35ed8a647f3b00cef3.png)
