Skip to content

Retrieve Oauth2 access token of the current user from Kratos #1511

Answered by Benehiko
thomasboni asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @thomasboni,

This seems related to this discussion #1264 and this issue #397.

Kratos does not store the access token from the OIDC provider and only has the claims available which you can then map using jssonet shown in our docs. You can see in the Kratos code base here and here only the claims are extracted and mapped.

Currently it is not possible to retrieve the access token from Kratos and would require you to re-initialise a login request to the OIDC provider on your own service to use the token.

I hope this answers your question :)

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@thomasboni
Comment options

Answer selected by thomasboni
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants