ibi-group / datatools-server

Server for IBI's GTFS data management platform.
MIT License
49 stars 51 forks source link

Unable to fetch users from Auth0 management API #523

Open aguiraf opened 1 year ago

aguiraf commented 1 year ago

Hi guys, thanks to issue #487, following @wkulesza instructions, we managed to get the authentication working again; unfortunately, the listing of users within the Administration section no longer seems to be functioning. The server log shows this message:

ERROR  c.c.d.manager.auth.Auth0Users(Auth0Users.java:186) Could not get Auth0 API token {"error":"unauthorized_client","error_description":"Grant type 'client_credentials' not allowed for the client.","error_uri":"https://auth0.com/docs/clients/client-grant-types"}

In fact, by setting the "Token Endpoint Authentication Method" to "none" on Auth0, the grant type "Client credentials" (Advanced settings) is automatically disabled, which is however used by the Auth0Users.java class to obtain the token to use the Auth0 Management API in order to get the list of users. Any hint? thanks

miles-grant-ibigroup commented 1 year ago

We've run into this issue ourselves! If you look at the auth0 docs that are linked in the error messages we've used those instructions to configure our auth0 domain to work with datatools.