orgUnitPath when I get a list of users

29 views
Skip to first unread message

TempleSnr

unread,
Feb 15, 2024, 12:17:30 PMFeb 15
to Google Apps Script Community
please would someone be able to put me out of my misery!!?

What's wrong with this line?
var users = AdminDirectory.Users.list({customer: 'A14x81kfv', orgUnitPath: '/Top Org/HR'}).users;
var users = AdminDirectory.Users.list({customer: 'A14x81kfv',viewtype: "admin_view", orgUnitPath: '/Top Org/HR'}).users;

It retrieves all users in all OUs. The OU definitely exists.

I checked out Search For Users and tried all kinds of variations but nothing's working.

thank you in advance
Reply all
Reply to author
Forward
0 new messages