Hi, I'm trying to use a jwt from the user's sessio...
# support-questions-legacy
d
Hi, I'm trying to use a jwt from the user's session in NextJS SSR. So far in
getServerSideProps
I get the user's session, then get a jwt using
session.getAccessToken()
. Is this token supposed to be usable for requests to my other backend ? I have called
JWT.init()
, and add a
Bearer [accessToken]
header but my requests still end up unauthorized
r
Hey. You could use this token for the other backend. Yea.
You don’t need to do JWT.init
For the other backend, when you try and verify the token, what are the debug logs output? (You may need to enable debug log mode)
d
The debug logs don't show any error, because it was already working 😅 Sorry about that, I was trying to use an admin route with a non-admin account
r
rigth ok
6 Views