How to get and use the ID Token / Access Token in a Shiny Server + auth0 setting?

Hello,
I am developing a Shiny Server app with auth0, but am confused about how to find out who my logged user is.
My first goal is to get the users ID or shomething, I figure later on with the Management API I can obtain more information about the user.

I understand in theory that:

The ID Token and/or Access Token is passed through the Rules pipeline, then sent to the app.
Auth0 Rules

Could somebody explain how this exactly works with a Shiny server and how can I access it in my server functions?
Is this information stored in some object I can directly access from the server side, like the session object maybe?

Thanks for the help!

Hi! I am also following the same question. I wish to create app but I am stuck at getting the access token for the ID.

1 Like

Update: I found a solution one can just re-use, from Curso-R,
here: GitHub - curso-r/auth0: Authentication in shinyapps using Auth0 service

See the related part:

When you are connected, it is possible to access user information inside the session$userData$login_info object. This object must be acessed in a reactive environment.

Thanks a lot for sharing it with the rest of community!

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.