Credentials provider doesn't provide jwt account, jwt profile, session user #9043
Unanswered
zZHorizonZz
asked this question in
Help
Replies: 1 comment
-
Any update ? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Since my issue got closed I can't provide a reproducer. I'm posting it here.
Provider type
Credentials
Environment
System:
OS: Windows 10 10.0.23575
CPU: (8) x64 11th Gen Intel(R) Core(TM) i5-1135G7 @ 2.40GHz
Memory: 3.87 GB / 31.63 GB
Binaries:
Node: 16.18.0 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.19 - ~\AppData\Roaming\npm\yarn.CMD
npm: 9.4.2 - C:\Program Files\nodejs\npm.CMD
pnpm: 8.6.2 - ~\AppData\Local\pnpm\pnpm.EXE
Browsers:
Edge: Spartan (44.23575.1001.0), Chromium (119.0.2151.44)
Internet Explorer: 11.0.23575.1001
npmPackages:
next: ^13.5.4 => 13.5.4
next-auth: ^4.24.4 => 4.24.4
react: ^18.2.0 => 18.2.0
npx envinfo --npmPackages "@auth/*" returns nothing
Reproduction URL
This issue can't be reproduced that easilly see decribe section bellow.
Describe the issue
The problem here is that we are trying to use credentials for our in-house provider, but even though login is successful, the refresh token seems like it's working as well and checking if a session is valid for example via useSession works when we are trying to access account or profile in jwt or user (which we don't need it's just it doesn't return anything as well) all are returning undefined for profile in jwt and user in session callbacks it doesn't matter but problem here is that account is undefined so we are not able to retrieve access token.
Code used:
Also token response looks something like this:
How to reproduce
This issue can't be reproduced easily see describe section above.
Expected behavior
At least the account should be probably returned so that accessToken can be accessed.
Beta Was this translation helpful? Give feedback.
All reactions