List roles associated with team

I am looking for a way I can get a list of the roles associated with a team.
I can get a list of members but not a list of the roles associated with their environments, etc?

$repository = new-object Octopus.Client.OctopusRepository $endpoint
$team=$repository.Teams.FindByName(‘testgroup’)

Is there a way to get the effective permissions that are being granted via that team?

Hi,

The resource you are looking for is a ScopedUserRoleResource.

You can get these by doing some like

$repository = new-object Octopus.Client.OctopusRepository $endpoint
$team=$repository.Teams.FindByName(‘testgroup’)
$teamRoles = $repository.Teams.GetScopedUserRoles($team)

I hope that helps!

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