Using POSTMAN , everything is fine :
I pass the same headers,params,... to superagent as following :
const superagent = require(\'superagent\');
const
The difference is that you are probably making a call to another domain than where your js app is running. This is called CORS. When you do that, combined with Authentication, the server needs to return CORS headers, saying:
access-control-allow-credentials: true
access-control-allow-origin: your-app-domain.here
Two pitfalls: