This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Viewing docs for Azure Native v3.21.0
published on Tuesday, Jul 14, 2026 by Pulumi
published on Tuesday, Jul 14, 2026 by Pulumi
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Viewing docs for Azure Native v3.21.0
published on Tuesday, Jul 14, 2026 by Pulumi
published on Tuesday, Jul 14, 2026 by Pulumi
Get a specific governance rule for the requested scope by ruleId
Uses Azure REST API version 2022-01-01-preview.
Using getGovernanceRule
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getGovernanceRule(args: GetGovernanceRuleArgs, opts?: InvokeOptions): Promise<GetGovernanceRuleResult>
function getGovernanceRuleOutput(args: GetGovernanceRuleOutputArgs, opts?: InvokeOptions): Output<GetGovernanceRuleResult>def get_governance_rule(rule_id: Optional[str] = None,
scope: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetGovernanceRuleResult
def get_governance_rule_output(rule_id: pulumi.Input[Optional[str]] = None,
scope: pulumi.Input[Optional[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetGovernanceRuleResult]func LookupGovernanceRule(ctx *Context, args *LookupGovernanceRuleArgs, opts ...InvokeOption) (*LookupGovernanceRuleResult, error)
func LookupGovernanceRuleOutput(ctx *Context, args *LookupGovernanceRuleOutputArgs, opts ...InvokeOption) LookupGovernanceRuleResultOutput> Note: This function is named LookupGovernanceRule in the Go SDK.
public static class GetGovernanceRule
{
public static Task<GetGovernanceRuleResult> InvokeAsync(GetGovernanceRuleArgs args, InvokeOptions? opts = null)
public static Output<GetGovernanceRuleResult> Invoke(GetGovernanceRuleInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetGovernanceRuleResult> getGovernanceRule(GetGovernanceRuleArgs args, InvokeOptions options)
public static Output<GetGovernanceRuleResult> getGovernanceRule(GetGovernanceRuleArgs args, InvokeOptions options)
fn::invoke:
function: azure-native:security:getGovernanceRule
arguments:
# arguments dictionarydata "azure-native_security_getgovernancerule" "name" {
# arguments
}The following arguments are supported:
getGovernanceRule Result
The following output properties are available:
- Azure
Api stringVersion - The Azure API version of the resource.
- Condition
Sets List<object> - The governance rule conditionSets - see examples
- Display
Name string - Display name of the governance rule
- Id string
- Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
- Name string
- The name of the resource
- Owner
Source Pulumi.Azure Native. Security. Outputs. Governance Rule Owner Source Response - The owner source for the governance rule - e.g. Manually by user@contoso.com - see example
- Rule
Priority int - The governance rule priority, priority to the lower number. Rules with the same priority on the same scope will not be allowed
- Rule
Type string - The rule type of the governance rule, defines the source of the rule e.g. Integrated
- Source
Resource stringType - The governance rule source, what the rule affects, e.g. Assessments
- System
Data Pulumi.Azure Native. Security. Outputs. System Data Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Tenant
Id string - The tenantId (GUID)
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Description string
- Description of the governance rule
- Excluded
Scopes List<string> - Excluded scopes, filter out the descendants of the scope (on management scopes)
- Governance
Email Pulumi.Notification Azure Native. Security. Outputs. Governance Rule Email Notification Response - The email notifications settings for the governance rule, states whether to disable notifications for mangers and owners
- Include
Member boolScopes - Defines whether the rule is management scope rule (master connector as a single scope or management scope)
- Is
Disabled bool - Defines whether the rule is active/inactive
- Is
Grace boolPeriod - Defines whether there is a grace period on the governance rule
- Metadata
Pulumi.
Azure Native. Security. Outputs. Governance Rule Metadata Response - The governance rule metadata
- Remediation
Timeframe string - Governance rule remediation timeframe - this is the time that will affect on the grace-period duration e.g. 7.00:00:00 - means 7 days
- Azure
Api stringVersion - The Azure API version of the resource.
- Condition
Sets []interface{} - The governance rule conditionSets - see examples
- Display
Name string - Display name of the governance rule
- Id string
- Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
- Name string
- The name of the resource
- Owner
Source GovernanceRule Owner Source Response - The owner source for the governance rule - e.g. Manually by user@contoso.com - see example
- Rule
Priority int - The governance rule priority, priority to the lower number. Rules with the same priority on the same scope will not be allowed
- Rule
Type string - The rule type of the governance rule, defines the source of the rule e.g. Integrated
- Source
Resource stringType - The governance rule source, what the rule affects, e.g. Assessments
- System
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Tenant
Id string - The tenantId (GUID)
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Description string
- Description of the governance rule
- Excluded
Scopes []string - Excluded scopes, filter out the descendants of the scope (on management scopes)
- Governance
Email GovernanceNotification Rule Email Notification Response - The email notifications settings for the governance rule, states whether to disable notifications for mangers and owners
- Include
Member boolScopes - Defines whether the rule is management scope rule (master connector as a single scope or management scope)
- Is
Disabled bool - Defines whether the rule is active/inactive
- Is
Grace boolPeriod - Defines whether there is a grace period on the governance rule
- Metadata
Governance
Rule Metadata Response - The governance rule metadata
- Remediation
Timeframe string - Governance rule remediation timeframe - this is the time that will affect on the grace-period duration e.g. 7.00:00:00 - means 7 days
- azure_
api_ stringversion - The Azure API version of the resource.
- condition_
sets list(any) - The governance rule conditionSets - see examples
- display_
name string - Display name of the governance rule
- id string
- Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
- name string
- The name of the resource
- owner_
source object - The owner source for the governance rule - e.g. Manually by user@contoso.com - see example
- rule_
priority number - The governance rule priority, priority to the lower number. Rules with the same priority on the same scope will not be allowed
- rule_
type string - The rule type of the governance rule, defines the source of the rule e.g. Integrated
- source_
resource_ stringtype - The governance rule source, what the rule affects, e.g. Assessments
- system_
data object - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- tenant_
id string - The tenantId (GUID)
- type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- description string
- Description of the governance rule
- excluded_
scopes list(string) - Excluded scopes, filter out the descendants of the scope (on management scopes)
- governance_
email_ objectnotification - The email notifications settings for the governance rule, states whether to disable notifications for mangers and owners
- include_
member_ boolscopes - Defines whether the rule is management scope rule (master connector as a single scope or management scope)
- is_
disabled bool - Defines whether the rule is active/inactive
- is_
grace_ boolperiod - Defines whether there is a grace period on the governance rule
- metadata object
- The governance rule metadata
- remediation_
timeframe string - Governance rule remediation timeframe - this is the time that will affect on the grace-period duration e.g. 7.00:00:00 - means 7 days
- azure
Api StringVersion - The Azure API version of the resource.
- condition
Sets List<Object> - The governance rule conditionSets - see examples
- display
Name String - Display name of the governance rule
- id String
- Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
- name String
- The name of the resource
- owner
Source GovernanceRule Owner Source Response - The owner source for the governance rule - e.g. Manually by user@contoso.com - see example
- rule
Priority Integer - The governance rule priority, priority to the lower number. Rules with the same priority on the same scope will not be allowed
- rule
Type String - The rule type of the governance rule, defines the source of the rule e.g. Integrated
- source
Resource StringType - The governance rule source, what the rule affects, e.g. Assessments
- system
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- tenant
Id String - The tenantId (GUID)
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- description String
- Description of the governance rule
- excluded
Scopes List<String> - Excluded scopes, filter out the descendants of the scope (on management scopes)
- governance
Email GovernanceNotification Rule Email Notification Response - The email notifications settings for the governance rule, states whether to disable notifications for mangers and owners
- include
Member BooleanScopes - Defines whether the rule is management scope rule (master connector as a single scope or management scope)
- is
Disabled Boolean - Defines whether the rule is active/inactive
- is
Grace BooleanPeriod - Defines whether there is a grace period on the governance rule
- metadata
Governance
Rule Metadata Response - The governance rule metadata
- remediation
Timeframe String - Governance rule remediation timeframe - this is the time that will affect on the grace-period duration e.g. 7.00:00:00 - means 7 days
- azure
Api stringVersion - The Azure API version of the resource.
- condition
Sets any[] - The governance rule conditionSets - see examples
- display
Name string - Display name of the governance rule
- id string
- Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
- name string
- The name of the resource
- owner
Source GovernanceRule Owner Source Response - The owner source for the governance rule - e.g. Manually by user@contoso.com - see example
- rule
Priority number - The governance rule priority, priority to the lower number. Rules with the same priority on the same scope will not be allowed
- rule
Type string - The rule type of the governance rule, defines the source of the rule e.g. Integrated
- source
Resource stringType - The governance rule source, what the rule affects, e.g. Assessments
- system
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- tenant
Id string - The tenantId (GUID)
- type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- description string
- Description of the governance rule
- excluded
Scopes string[] - Excluded scopes, filter out the descendants of the scope (on management scopes)
- governance
Email GovernanceNotification Rule Email Notification Response - The email notifications settings for the governance rule, states whether to disable notifications for mangers and owners
- include
Member booleanScopes - Defines whether the rule is management scope rule (master connector as a single scope or management scope)
- is
Disabled boolean - Defines whether the rule is active/inactive
- is
Grace booleanPeriod - Defines whether there is a grace period on the governance rule
- metadata
Governance
Rule Metadata Response - The governance rule metadata
- remediation
Timeframe string - Governance rule remediation timeframe - this is the time that will affect on the grace-period duration e.g. 7.00:00:00 - means 7 days
- azure_
api_ strversion - The Azure API version of the resource.
- condition_
sets Sequence[Any] - The governance rule conditionSets - see examples
- display_
name str - Display name of the governance rule
- id str
- Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
- name str
- The name of the resource
- owner_
source GovernanceRule Owner Source Response - The owner source for the governance rule - e.g. Manually by user@contoso.com - see example
- rule_
priority int - The governance rule priority, priority to the lower number. Rules with the same priority on the same scope will not be allowed
- rule_
type str - The rule type of the governance rule, defines the source of the rule e.g. Integrated
- source_
resource_ strtype - The governance rule source, what the rule affects, e.g. Assessments
- system_
data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- tenant_
id str - The tenantId (GUID)
- type str
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- description str
- Description of the governance rule
- excluded_
scopes Sequence[str] - Excluded scopes, filter out the descendants of the scope (on management scopes)
- governance_
email_ Governancenotification Rule Email Notification Response - The email notifications settings for the governance rule, states whether to disable notifications for mangers and owners
- include_
member_ boolscopes - Defines whether the rule is management scope rule (master connector as a single scope or management scope)
- is_
disabled bool - Defines whether the rule is active/inactive
- is_
grace_ boolperiod - Defines whether there is a grace period on the governance rule
- metadata
Governance
Rule Metadata Response - The governance rule metadata
- remediation_
timeframe str - Governance rule remediation timeframe - this is the time that will affect on the grace-period duration e.g. 7.00:00:00 - means 7 days
- azure
Api StringVersion - The Azure API version of the resource.
- condition
Sets List<Any> - The governance rule conditionSets - see examples
- display
Name String - Display name of the governance rule
- id String
- Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
- name String
- The name of the resource
- owner
Source Property Map - The owner source for the governance rule - e.g. Manually by user@contoso.com - see example
- rule
Priority Number - The governance rule priority, priority to the lower number. Rules with the same priority on the same scope will not be allowed
- rule
Type String - The rule type of the governance rule, defines the source of the rule e.g. Integrated
- source
Resource StringType - The governance rule source, what the rule affects, e.g. Assessments
- system
Data Property Map - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- tenant
Id String - The tenantId (GUID)
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- description String
- Description of the governance rule
- excluded
Scopes List<String> - Excluded scopes, filter out the descendants of the scope (on management scopes)
- governance
Email Property MapNotification - The email notifications settings for the governance rule, states whether to disable notifications for mangers and owners
- include
Member BooleanScopes - Defines whether the rule is management scope rule (master connector as a single scope or management scope)
- is
Disabled Boolean - Defines whether the rule is active/inactive
- is
Grace BooleanPeriod - Defines whether there is a grace period on the governance rule
- metadata Property Map
- The governance rule metadata
- remediation
Timeframe String - Governance rule remediation timeframe - this is the time that will affect on the grace-period duration e.g. 7.00:00:00 - means 7 days
Supporting Types
GovernanceRuleEmailNotificationResponse
- Disable
Manager boolEmail Notification - Defines whether manager email notifications are disabled
- Disable
Owner boolEmail Notification - Defines whether owner email notifications are disabled
- Disable
Manager boolEmail Notification - Defines whether manager email notifications are disabled
- Disable
Owner boolEmail Notification - Defines whether owner email notifications are disabled
- disable_
manager_ boolemail_ notification - Defines whether manager email notifications are disabled
- disable_
owner_ boolemail_ notification - Defines whether owner email notifications are disabled
- disable
Manager BooleanEmail Notification - Defines whether manager email notifications are disabled
- disable
Owner BooleanEmail Notification - Defines whether owner email notifications are disabled
- disable
Manager booleanEmail Notification - Defines whether manager email notifications are disabled
- disable
Owner booleanEmail Notification - Defines whether owner email notifications are disabled
- disable_
manager_ boolemail_ notification - Defines whether manager email notifications are disabled
- disable_
owner_ boolemail_ notification - Defines whether owner email notifications are disabled
- disable
Manager BooleanEmail Notification - Defines whether manager email notifications are disabled
- disable
Owner BooleanEmail Notification - Defines whether owner email notifications are disabled
GovernanceRuleMetadataResponse
- created_
by string - Governance rule Created by object id (GUID)
- created_
on string - Governance rule creation date
- updated_
by string - Governance rule last updated by object id (GUID)
- updated_
on string - Governance rule last update date
- created_
by str - Governance rule Created by object id (GUID)
- created_
on str - Governance rule creation date
- updated_
by str - Governance rule last updated by object id (GUID)
- updated_
on str - Governance rule last update date
GovernanceRuleOwnerSourceResponse
SystemDataResponse
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- created_
at string - The timestamp of resource creation (UTC).
- created_
by string - The identity that created the resource.
- created_
by_ stringtype - The type of identity that created the resource.
- last_
modified_ stringat - The timestamp of resource last modification (UTC)
- last_
modified_ stringby - The identity that last modified the resource.
- last_
modified_ stringby_ type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
- created
At string - The timestamp of resource creation (UTC).
- created
By string - The identity that created the resource.
- created
By stringType - The type of identity that created the resource.
- last
Modified stringAt - The timestamp of resource last modification (UTC)
- last
Modified stringBy - The identity that last modified the resource.
- last
Modified stringBy Type - The type of identity that last modified the resource.
- created_
at str - The timestamp of resource creation (UTC).
- created_
by str - The identity that created the resource.
- created_
by_ strtype - The type of identity that created the resource.
- last_
modified_ strat - The timestamp of resource last modification (UTC)
- last_
modified_ strby - The identity that last modified the resource.
- last_
modified_ strby_ type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Viewing docs for Azure Native v3.21.0
published on Tuesday, Jul 14, 2026 by Pulumi
published on Tuesday, Jul 14, 2026 by Pulumi