问题
I'm trying to retrieve the 'customerId' value for a Non-Admin user on a Google Apps Enterprise.
As a non-admin there are a lot of APIs I won't have access to. Is there any way for me to retrieve the 'customerId' for my account?
回答1:
The customerId is identical for all users in the Google Apps instance (including users in other secondary domains).
If you're working with a single Google Apps instance, the customerId is static and thus once discovering it from an admin account, you can hard code it.
In order to retrieve the customerId via the users.get() API call, the authenticated user needs to at the very least be a delegated admin with read-only access to users via the API privileges.
来源:https://stackoverflow.com/questions/21316835/how-can-i-retrieve-the-customerid-from-a-using-google-api-calls-from-a-nonadmin