In this Azure PowerShell article, we will discuss the syntax and usage of the Get-AzRoleDefinition Azure PowerShell cmdlet. Along with that, we will also discuss the implementation with examples.
Table of Contents
Get-AzRoleDefinition
Get-AzRoleDefinition is an excellent Azure PowerShell cmdlet that can help you to retrieve the list of Azure RBAC roles that are available that you can assign.
Syntax
Below is the syntax of the Get-AzRoleDefinition Azure PowerShell cmdlet.
Get-AzRoleDefinition
Get-AzRoleDefinition [[-Name] <String>]
Let’s discuss some implementation examples of the Get-AzRoleDefinition PowerShell command.
Example-1:
Get-AzRoleDefinition
After executing the above PowerShell command, I got the lists of Azure RBAC roles that are available.
You can see the output here

Example-2:
You can also execute the below Azure PowerShell command to get the specified role definition i.e Automation Job Operator.
Get-AzRoleDefinition -Name "Automation Job Operator"
After executing the above PowerShell command I got the below output.
PS C:\WINDOWS\system32> Get-AzRoleDefinition -Name "Automation Job Operator"
Name : Automation Job Operator
Id : 4fe576fe-1146-4730-92eb-48519fa6bf9f
IsCustom : False
Description : Create and Manage Jobs using Automation Runbooks.
Actions : {Microsoft.Authorization/*/read, Microsoft.Automation/automationAcc
ounts/hybridRunbookWorkerGroups/read,
Microsoft.Automation/automationAccounts/jobs/read,
Microsoft.Automation/automationAccounts/jobs/resume/action...}
NotActions : {}
DataActions : {}
NotDataActions : {}
AssignableScopes : {/}
You can see the output here as below

Get-AzRoleDefinition – Video Tutorial
You may also like following the below articles
Wrapping Up
In this Azure article, we have discussed the syntax and usage of the Get-AzRoleDefinition Azure PowerShell cmdlet with examples. Thanks for reading this article !!!

I am Rajkishore, and I have over 14 years of experience in Microsoft Azure and AWS, with good experience in Azure Functions, Storage, Virtual Machine, Logic Apps, PowerShell Commands, CLI Commands, Machine Learning, AI, Azure Cognitive Services, DevOps, etc. Not only that, I do have good real-time experience in designing and developing cloud-native data integrations on Azure or AWS, etc. I hope you will learn from these practical Azure tutorials. Read more.