[keycloak-dev] Getting User Details from a Token (Node.js Adapter)

Stian Thorgersen sthorger at redhat.com
Wed Oct 2 08:43:49 EDT 2019


Please use keycloak-user ml for help and questions

On Wed, 2 Oct 2019, 13:47 Evan Shortiss, <eshortis at redhat.com> wrote:

> Hey folks,
>
> Does the Node.js module have documented features for accessing token
> properties?
>
> My particular use case is that I'd like to retrieve the user's username. I
> can access it via
> *req.kauth.grant.access_token.content.preferred_username* but
> it feels like this is an interface that could be changed since it's not
> documented AFAICT.
>
> Is there a recommended approach for doing this? Is there any plan to add
> features such as *req.kauth.getTokenContent()* or similar?
>
> Thanks
>
>
> --
>
> Evan Shortiss
>
> Technical Marketing Manager
>
> Red Hat NA <https://www.redhat.com/>
>
> Los Angeles
>
> evan.shortiss at redhat.com
> M: +1-781-354-2834     IM: evanshortiss
> <https://www.redhat.com/>
> _______________________________________________
> keycloak-dev mailing list
> keycloak-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/keycloak-dev
>


More information about the keycloak-dev mailing list