I'm attempting to get all the users for a particular orgUnitPath. I've set up the org unit for Engineering but currently left it empty (to test that).
Using Go I have the following:
func ListMembers(adm *admin.Service, customerId, orgUnitPath string) ([]*admin.User, error) {
adm *admin.Service
return adm.Users.List().Customer(customerId).Fields(googleapi.Field("orgUnitPath=" + orgUnitPath)).Do()
}
A call with my customerId and '/Engineering' gives me the following response:
googleapi: Error 400: Invalid field selection orgUnitPath=/Engineering, invalidParameter
I also tried adding .Projection("full")
but get the same error.
I feel like I'm missing something pretty basic here. Any ideas?