# Using data variables in URL path fails in Newman but works in Postman

**URL:** <https://community.postman.com/t/using-data-variables-in-url-path-fails-in-newman-but-works-in-postman/24195>\
**Category:** Help Hub\
**Tags:** newman-project, variables, collections\
**Created:** [May 28, 2021, 1:27am UTC](https://community.postman.com/t/using-data-variables-in-url-path-fails-in-newman-but-works-in-postman/24195 "2021-05-28T01:27:49Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rarunrk](https://avatars.discourse-cdn.com/v4/letter/r/2bfe46/32.png) [@rarunrk](https://community.postman.com/u/rarunrk)\
**Post date:** [May 28, 2021, 1:27am UTC](https://community.postman.com/t/using-data-variables-in-url-path-fails-in-newman-but-works-in-postman/24195/1 "2021-05-28T01:27:49Z")

</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 have used the data variable in the URL path. It works in Postman but however it doesn’t work in Newman. It gives a Bad Request Error.

[http://xxx.xxx.xxx.xxx:9999/transaction/{{Transaction\_Id\_Status\_Finish\_Ok}}?full=true&finishStatus=finishedError](http://xxx.xxx.xxx.xxx:9999/transaction/%7B%7BTransaction_Id_Status_Finish_Ok%7D%7D?full=true&finishStatus=finishedError)

It cannot replace the place holder with the value from test\_data.csv {{Transaction\_Id\_Status\_Finish\_Ok}}

Please help step by step on how to use data variable in request path (not as a request param)

But in postman: It complains the same "Like variable cannot be resolved, but when I run it as a collection in postman, it all works fine

Command to run Newman:

docker run --volume ~:/etc/newman -t postman/newman\_alpine33 run test\_transaction.json -e transaction\_environment.json -d test\_data.csv

test\_data.csv:

Transaction\_Id,﻿Transaction\_Id\_Status\_Finish,Transaction\_Id\_Status\_Finish\_Ok,Transaction\_Id\_Status\_Finish\_Error,Transaction\_Id\_Parent,Transaction\_Id\_Children,Transaction\_Id\_history,Expected\_User\_Name  
339306893,339306579,339306579,339306701,339306703,339306702,339306702,TEST-PERF

_Details (like screenshots)_:

![image](https://us1.discourse-cdn.com/getpostman/optimized/2X/d/df5f436e5dcb54fb16ef7251ce8dfae2807e2300_2_690x52.png)

_How I found the problem_:

_I’ve already tried_:
