0

I am using superagent to POST login data to my external endpoint (at a different origin). This external endpoint returns a JWT, as well as a set-header cookie with the JWT inside it as well. I use this cookie to render pages server-side if a user is already logged in.

However, when I check

request.end((err, res) => { console.log(res) } 

I do not see any set-header cookie. What am I doing wrong? If it helps, I am using this boilerplate's ApiClient.js.

1 Answer 1

0

That's because set-cookie is one of the two forbidden response header names.

Sign up to request clarification or add additional context in comments.

2 Comments

Any idea why? Seems very strange.
The link that @Knu posted contains an explanation.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.