Tamás Polgár
Tamás Polgár

Reputation: 2272

Postman not sending session cookie

It's not entirely clear for me whether Postman is supposed to send cookies received in previous requests (including the session cookie) back in later requests to the same URL or not.

Could please someone confirm that in this manner it's supposed to work like a browser or not. Should I have to manually specify cookies before a request?

I am testing a Node.js/Express backend with it. Express reports that req.cookies is undefined.

Upvotes: 2

Views: 1509

Answers (2)

We need to use the cookie-parser middleware to read cookies in express.

   var cookies = require("cookie-parser");
   app.use(cookies());

Upvotes: 0

klubi
klubi

Reputation: 1523

YES.

Postman will use cookies from previous requests if following ones are made to same domain.

Upvotes: 2

Related Questions