# Newman implimentation with pre-request-script and tests

**URL:** <https://community.postman.com/t/newman-implimentation-with-pre-request-script-and-tests/34433>\
**Category:** Help Hub\
**Tags:** newman-project, tests\
**Created:** [April 12, 2022, 11:37am UTC](https://community.postman.com/t/newman-implimentation-with-pre-request-script-and-tests/34433 "2022-04-12T11:37:14Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![navigation-administ6](https://avatars.discourse-cdn.com/v4/letter/n/c5a1d2/32.png) [@navigation-administ6](https://community.postman.com/u/navigation-administ6)\
**Post date:** [April 12, 2022, 11:37am UTC](https://community.postman.com/t/newman-implimentation-with-pre-request-script-and-tests/34433/1 "2022-04-12T11:37:14Z")

</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).

**Your question may already have an answer on the community forum. Please search for related topics, and then read through the [guidelines](https://community.postman.com/t/about-the-just-getting-started-category/37) before creating a new topic.**

> Here’s an outline with best practices for making your inquiry.

_My question_:  
I am new in postman.I am trying to implement newman with postman.  
my question is, can I write pre-request-script and tests script in newman to check any conditon?

_Details (like screenshots)_:

_How I found the problem_:

_I’ve already tried_:

---

<div class="post-metadata">

**Author:** ![w4dd325](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/w4dd325/32/12436_2.png) [@w4dd325](https://community.postman.com/u/w4dd325)\
**Post date:** [April 12, 2022, 5:45pm UTC](https://community.postman.com/t/newman-implimentation-with-pre-request-script-and-tests/34433/2 "2022-04-12T17:45:21Z")

</div>

Hi @navigation-administ6

Newman runs Postman collections in the command line.

So the pre-req and test scripts would be written in Postman.  
Then you would use Newman to run that collection via the command line.

> **[Running collections on the command line with Newman | Postman Learning Center](https://learning.postman.com/docs/running-collections/using-newman-cli/command-line-integration-with-newman/)**
>
> Running collections on the command line with Newman: documentation for Postman, the collaboration platform for API development. Create better APIs—faster.
