Okta API for getting users and their groups

I know that there is an api for getting all users of a given group (/api/v1/groups/{groupId}/users) but is there a way to modify what data comes back from this call? I would like for this call to also return all of the groups that each user is in.

The only way that I currently see is to do the above groups/users call and then to loop through the results calling “/api/v1/users/{userId}” for each user. I can image this becoming time consuming if there are many users and/or many groups being returned.

Is there a better way for me to get this data that I am just not seeing?

Hi @McHolty

There is no option to list the membership of the users on this particular endpoint. You can see all the available query parameters for it here.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.