Can Cookies be sent with newman requests?


We run a collection in postman and set a cookie for each request. When I export the collection and run with newman I am seeing errors that suggests this isn’t happening when run using newman. I can’t find anything in the collection json either that would suggest the cookies we have in postman are exported for use by newman.

Is it possible to run our collection with our cookie in newman as we do in postman?



Hi @ben

I see that you’ve raised this as a ticket internally and the suggested workaround has helped :slight_smile:

Posting the same to help the ones looking for the solution:

There isn’t a way to export cookies from the app as of now. The workaround is to add cookie header (like Cookie: <name>=<value>) manually in the request and then export the collection


you can also use the below script in the pre-request script tab and then export the collection.

key: ‘Cookie’,
value: ‘=’