# Update Request URLs in Bulk in Postman collection

**URL:** <https://community.postman.com/t/update-request-urls-in-bulk-in-postman-collection/31832>\
**Category:** Help Hub\
**Tags:** collections\
**Created:** [January 24, 2022, 9:04am UTC](https://community.postman.com/t/update-request-urls-in-bulk-in-postman-collection/31832 "2022-01-24T09:04:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![praveendvd](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/praveendvd/32/6796_2.png) [@praveendvd](https://community.postman.com/u/praveendvd)\
**Post date:** [January 24, 2022, 9:04am UTC](https://community.postman.com/t/update-request-urls-in-bulk-in-postman-collection/31832/1 "2022-01-24T09:04:44Z")

</div>

all Postman lovers,

Here you go , I have created command line utility that allows you to update URLs in bulk in Postman collection file .

Now you dont have to worry about replacing request URLs across all your collections when the project structure changes . You just have to run

npx postman-collection-url-updater -c “collection.json” -r “[https://localhost:23456/api/v1/{{path}](https://localhost:23456/api/v1/%7B%7Bpath%7D)}” -w “{{baseURL}}/{{path}}” -s “new\_collection.json”

In the above example all the urls will have the [https://localhost:23456/api/v1/{{path}](https://localhost:23456/api/v1/%7B%7Bpath%7D)} part get replaced with {{baseURL}}/{{path}} . ❤

> **[postman-collection-url-updater](https://www.npmjs.com/package/postman-collection-url-updater)**
>
> Postman collection url updater is a command line utility project that can update urls across multiple postman requests in your postman collection. It allows to update postman request urls in bulk inside the postman collection. it also support...

Please do try it out and let me know your thoughts and comments 🙌🙌

---

<div class="post-metadata">

**Author:** ![praveendvd](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/praveendvd/32/6796_2.png) [@praveendvd](https://community.postman.com/u/praveendvd)\
**Post date:** [February 4, 2022, 10:06am UTC](https://community.postman.com/t/update-request-urls-in-bulk-in-postman-collection/31832/2 "2022-02-04T10:06:40Z")

</div>

🎉🎉🎉😍 **#500** + **#Downloads** so far :  
[postman-collection-url-updater - npm](https://www.npmjs.com/package/postman-collection-url-updater)

Hi Linkedin Family and all Postman lovers

postman-collection-url-updater **#v3** is out ❤❤

I have added one more utility **#postman** - **#collection** - **#aggregator** to the project , now you can consoilidate/move multiple collections into single collection. 😍

just install the package and run the below command

npm i -g postman-collection-url-updater

postman-collection-aggregator -l “./collection1.json” “./collection2.json” -n “new\_collection”

This will create a new collection called “new\_collection” with sub collection 1 and 2 as sub folders , all variables will be added to the new\_collection

postman-collection-aggregator -d “./collectionDirectory” -n “new\_collection”

you can also simply pass the directory containing all the collections instead of individual files

It was a rollercoaster ride of learning:

1. Creating a nodejs cmd utility

2. Writing Github action, to run in linux, windows, and Mac

3. Creating automatic npm publish and writing Github pages

4. Writing Jest unit and system test

5. Learning Jest coverage test and Mocks

Will write an article soon with all the information

**#sdet**  **#testautomationengineer**  **#article**  **#postmanapi**  **#postman**  **#nodejsdeveloper**  **#qaengineer**  **#medium**  **#javascriptdeveloper**  **#js**

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/system/32/29796_2.png) [@system](https://community.postman.com/u/system)\
**Post date:** [December 12, 2024, 2:46pm UTC](https://community.postman.com/t/update-request-urls-in-bulk-in-postman-collection/31832/4 "2024-12-12T14:46:55Z")

</div>

Closed on December 12, 2024, 2:46pm UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
