GO CLI application, how to retrieve usedID

I have followed the examples on how to use a checkJwt to control access to given API paths. However, I need to retrieve also user data (like the user ID). How can I do it?
Thanks.

To get the user information you can call the [GET /userinfo] (Authentication API Explorer) endpoint. Given the Auth0 Access Token obtained during login, this endpoint returns a user’s profile. This endpoint will work only if openid was granted as a scope for the access_token.

Just as additional information about Go, you can also see more information about authenticating and getting the user profile in a webapp [here] (Auth0 Go SDK Quickstarts: Login) and [here] (auth0-golang-web-app/01-Login at master · auth0-samples/auth0-golang-web-app · GitHub).

Thanks.
What I have is not a web too, but what auth0 calls non interactive app (for me it is just a CLI server) implementing the API. I believe the get call will work!

So I tried, but I get some gibberish response and no idea what to do with it.
Do I need to define a struct and use JSON.UNMARSHALL on the repose body, or what else?
Thanks for any help.
Also, the scope opened is for clients. Here it is the API app that needs to retrieve the data. Basically an android client does the login, then it sends the token with some data to an API which needs to retrieve the userID and store the data the client sent.

TO add the android client had scope openID

Hey there!

Sorry for such huge delay in response! We’re doing our best in providing you with best developer support experience out there, but sometimes our bandwidth is not enough comparing to the number of incoming questions.

Wanted to reach out to know if you still require further assistance?