How to list all users of G-Suite without client secret but with admin user consent?

Skip to first unread message

Chiranjib Karn

Nov 27, 2017, 9:22:19 AM11/27/17
to google-api-java-client
My SaaS web application is in Grails 3, which has requirement to fetch user list of clients from their G-Suite account.
I am using following java libraries: 
"google-api-client", "google-oauth-client-jetty", "google-oauth-client" and "google-api-services-admin-directory".
I have managed to get the list of users using google SDK with "" scope from a given G-Suite account, which is the expected behavior. 
But for that I have to use "client_secret", which is not feasible to obtain from all of my clients as it involves manual work. Is there any way around to get list of users without client_secret but need admin user consent?

Matthew Whisenhunt

Nov 27, 2017, 12:11:51 PM11/27/17
to google-api-java-client
It sounds like this is what you are looking for.
Reply all
Reply to author
0 new messages