Reputation: 73
I have a lot of subscriptions and users. I basically need to export the administrators list that is made when you select all Subscriptions and go to "Manage Administrators". Azure Powershell doesn't seem to have this capability. Is there some way to do this through an API or something? If so I am not very familiar with that.
Thanks
Upvotes: 3
Views: 5647
Reputation: 73
The .Net Wrapper over List Subscription User Accounts
would definitely work if using the API.
However, without having to write your own wrapper, I found you can do this:
In PowerShell, in Azure Resource Manager Mode, execute the Get-AzureRmRoleAssignment
cmdlet. Co-admins in the class Azure Service Management stack are listed as an Owner in the new Azure Resource Manager stack.
This blog post is also helpful, the author made a script that can help solve this: http://www.dushyantgill.com/blog/2015/02/08/keep-a-tab-on-access-settings-of-your-azure-subscriptions/
Upvotes: 1
Reputation: 41
Execute the following in PowerShell:
Get-AzureRmRoleAssignment -IncludeClassicAdministrators | Where-Object RoleDefinitionName -like "*administrator*" | fl
Upvotes: 4
Reputation: 136306
You could possibly write your own .Net wrapper over List Subscription User Accounts
. This operation will tell you about the users in your subscription. I was hoping to find a function is Azure Management Library
but could not find so.
Upvotes: 1