plain-wire-55288
05/18/2022, 11:53 AM/sessions/whoami
route. The client request forwards 2 cookies in the request which are
• csrf_token_xxxxxxx
• ory_session_xxxxxx
when I send a request with these cookies to the whoami api route, the request returns an unauthorized error.high-optician-2097
plain-wire-55288
05/18/2022, 11:56 AMhigh-optician-2097
high-optician-2097
console.log('got headers:',req.headers)
plain-wire-55288
05/18/2022, 11:57 AM{
csrf_token_1f220dfd3a110f2ff4cf98b9463fac75b8bb48b2dd16dae2893d56f4a44exxxxxxxxxxx',
ory_session_beautifulchebyshevlr0kekd1p3: 'MTY1Mjg3MTI2OXxUcEhCTk1jQWhwZDJHd2xoalpUSGwxa1dIUHJXTkpjOFhoZmtNSWU3ek9mZEt2YVNMUkd6eEpSWkxqdzZENxxxxxxxxxxxxxxxx'
}
high-optician-2097
.toSession()
call you’re making?high-optician-2097
plain-wire-55288
05/18/2022, 11:58 AMplain-wire-55288
05/18/2022, 11:58 AMhigh-optician-2097
plain-wire-55288
05/18/2022, 11:59 AM"0.0.1-alpha.169
plain-wire-55288
05/18/2022, 11:59 AMhigh-optician-2097
high-optician-2097
high-optician-2097
whoami
HTTP call you#re making?plain-wire-55288
05/18/2022, 12:00 PMconst test = await fetch(`${process.env.ORY_SDK_URL!}/sessions/whoami`, {
headers: {
"X-Session-Token": cookie,
}
})
high-optician-2097
plain-wire-55288
05/18/2022, 12:01 PMhigh-optician-2097
cookie
?plain-wire-55288
05/18/2022, 12:01 PMhigh-optician-2097
const test = await fetch(`${process.env.ORY_SDK_URL!}/sessions/whoami`, {
headers: {
"Cookie": "ory_session_xxx=....; ory_csrf_xxx=....",
}
})
plain-wire-55288
05/18/2022, 12:02 PMhigh-optician-2097
plain-wire-55288
05/18/2022, 12:08 PMplain-wire-55288
05/18/2022, 12:08 PMplain-wire-55288
05/18/2022, 12:08 PMdamp-sunset-69236
05/18/2022, 12:10 PMhigh-optician-2097
high-optician-2097
high-optician-2097
broad-processor-55988
05/18/2022, 1:09 PMbroad-processor-55988
05/18/2022, 1:09 PMhigh-optician-2097
broad-processor-55988
05/19/2022, 10:34 AM