PolicyInsightsExtensions.SummarizePolicyStatesAsync Method

Definition

Overloads

SummarizePolicyStatesAsync(ArmClient, ResourceIdentifier, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Summarizes policy states for the resource.

  • Request Path: /{resourceId}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForResource
SummarizePolicyStatesAsync(SubscriptionResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Summarizes policy states for the resources under the subscription.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForSubscription
SummarizePolicyStatesAsync(SubscriptionPolicySetDefinitionResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Summarizes policy states for the subscription level policy set definition.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForPolicySetDefinition
SummarizePolicyStatesAsync(ManagementGroupResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Summarizes policy states for the resources under the management group.

  • Request Path: /providers/{managementGroupsNamespace}/managementGroups/{managementGroupName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForManagementGroup
SummarizePolicyStatesAsync(ResourceGroupResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Summarizes policy states for the resources under the resource group.

  • Request Path: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForResourceGroup
SummarizePolicyStatesAsync(PolicyAssignmentResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Summarizes policy states for the subscription level or resource group level policy assignment.

  • Request Path: /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForResourceGroupLevelPolicyAssignment
SummarizePolicyStatesAsync(SubscriptionPolicyDefinitionResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Summarizes policy states for the subscription level policy definition.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForPolicyDefinition

SummarizePolicyStatesAsync(ArmClient, ResourceIdentifier, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Summarizes policy states for the resource.

  • Request Path: /{resourceId}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForResource
public static Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary> SummarizePolicyStatesAsync (this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier scope, Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType policyStateSummaryType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member SummarizePolicyStatesAsync : Azure.ResourceManager.ArmClient * Azure.Core.ResourceIdentifier * Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary>
<Extension()>
Public Function SummarizePolicyStatesAsync (client As ArmClient, scope As ResourceIdentifier, policyStateSummaryType As PolicyStateSummaryType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of PolicySummary)

Parameters

client
ArmClient

The ArmClient instance the method will execute against.

scope
ResourceIdentifier

The scope that the resource will apply against.

policyStateSummaryType
PolicyStateSummaryType

The virtual resource under PolicyStates resource type for summarize action. In a given time range, 'latest' represents the latest policy state(s) and is the only allowed value.

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

client is null.

Applies to

SummarizePolicyStatesAsync(SubscriptionResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Summarizes policy states for the resources under the subscription.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForSubscription
public static Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary> SummarizePolicyStatesAsync (this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType policyStateSummaryType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member SummarizePolicyStatesAsync : Azure.ResourceManager.Resources.SubscriptionResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary>
<Extension()>
Public Function SummarizePolicyStatesAsync (subscriptionResource As SubscriptionResource, policyStateSummaryType As PolicyStateSummaryType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of PolicySummary)

Parameters

subscriptionResource
SubscriptionResource

The SubscriptionResource instance the method will execute against.

policyStateSummaryType
PolicyStateSummaryType

The virtual resource under PolicyStates resource type for summarize action. In a given time range, 'latest' represents the latest policy state(s) and is the only allowed value.

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

An async collection of PolicySummary that may take multiple service requests to iterate over.

Exceptions

subscriptionResource is null.

Applies to

SummarizePolicyStatesAsync(SubscriptionPolicySetDefinitionResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Summarizes policy states for the subscription level policy set definition.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForPolicySetDefinition
public static Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary> SummarizePolicyStatesAsync (this Azure.ResourceManager.Resources.SubscriptionPolicySetDefinitionResource subscriptionPolicySetDefinitionResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType policyStateSummaryType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member SummarizePolicyStatesAsync : Azure.ResourceManager.Resources.SubscriptionPolicySetDefinitionResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary>
<Extension()>
Public Function SummarizePolicyStatesAsync (subscriptionPolicySetDefinitionResource As SubscriptionPolicySetDefinitionResource, policyStateSummaryType As PolicyStateSummaryType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of PolicySummary)

Parameters

subscriptionPolicySetDefinitionResource
SubscriptionPolicySetDefinitionResource

The SubscriptionPolicySetDefinitionResource instance the method will execute against.

policyStateSummaryType
PolicyStateSummaryType

The virtual resource under PolicyStates resource type for summarize action. In a given time range, 'latest' represents the latest policy state(s) and is the only allowed value.

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

An async collection of PolicySummary that may take multiple service requests to iterate over.

Applies to

SummarizePolicyStatesAsync(ManagementGroupResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Summarizes policy states for the resources under the management group.

  • Request Path: /providers/{managementGroupsNamespace}/managementGroups/{managementGroupName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForManagementGroup
public static Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary> SummarizePolicyStatesAsync (this Azure.ResourceManager.ManagementGroups.ManagementGroupResource managementGroupResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType policyStateSummaryType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member SummarizePolicyStatesAsync : Azure.ResourceManager.ManagementGroups.ManagementGroupResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary>
<Extension()>
Public Function SummarizePolicyStatesAsync (managementGroupResource As ManagementGroupResource, policyStateSummaryType As PolicyStateSummaryType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of PolicySummary)

Parameters

managementGroupResource
ManagementGroupResource

The ManagementGroupResource instance the method will execute against.

policyStateSummaryType
PolicyStateSummaryType

The virtual resource under PolicyStates resource type for summarize action. In a given time range, 'latest' represents the latest policy state(s) and is the only allowed value.

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

An async collection of PolicySummary that may take multiple service requests to iterate over.

Exceptions

managementGroupResource is null.

Applies to

SummarizePolicyStatesAsync(ResourceGroupResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Summarizes policy states for the resources under the resource group.

  • Request Path: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForResourceGroup
public static Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary> SummarizePolicyStatesAsync (this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType policyStateSummaryType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member SummarizePolicyStatesAsync : Azure.ResourceManager.Resources.ResourceGroupResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary>
<Extension()>
Public Function SummarizePolicyStatesAsync (resourceGroupResource As ResourceGroupResource, policyStateSummaryType As PolicyStateSummaryType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of PolicySummary)

Parameters

resourceGroupResource
ResourceGroupResource

The ResourceGroupResource instance the method will execute against.

policyStateSummaryType
PolicyStateSummaryType

The virtual resource under PolicyStates resource type for summarize action. In a given time range, 'latest' represents the latest policy state(s) and is the only allowed value.

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

An async collection of PolicySummary that may take multiple service requests to iterate over.

Exceptions

resourceGroupResource is null.

Applies to

SummarizePolicyStatesAsync(PolicyAssignmentResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Summarizes policy states for the subscription level or resource group level policy assignment.

  • Request Path: /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForResourceGroupLevelPolicyAssignment
public static Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary> SummarizePolicyStatesAsync (this Azure.ResourceManager.Resources.PolicyAssignmentResource policyAssignmentResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType policyStateSummaryType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member SummarizePolicyStatesAsync : Azure.ResourceManager.Resources.PolicyAssignmentResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary>
<Extension()>
Public Function SummarizePolicyStatesAsync (policyAssignmentResource As PolicyAssignmentResource, policyStateSummaryType As PolicyStateSummaryType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of PolicySummary)

Parameters

policyAssignmentResource
PolicyAssignmentResource

The PolicyAssignmentResource instance the method will execute against.

policyStateSummaryType
PolicyStateSummaryType

The virtual resource under PolicyStates resource type for summarize action. In a given time range, 'latest' represents the latest policy state(s) and is the only allowed value.

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

An async collection of PolicySummary that may take multiple service requests to iterate over.

Applies to

SummarizePolicyStatesAsync(SubscriptionPolicyDefinitionResource, PolicyStateSummaryType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Summarizes policy states for the subscription level policy definition.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/providers/Microsoft.PolicyInsights/policyStates/{policyStatesSummaryResource}/summarize
  • Operation Id: PolicyStates_SummarizeForPolicyDefinition
public static Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary> SummarizePolicyStatesAsync (this Azure.ResourceManager.Resources.SubscriptionPolicyDefinitionResource subscriptionPolicyDefinitionResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType policyStateSummaryType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member SummarizePolicyStatesAsync : Azure.ResourceManager.Resources.SubscriptionPolicyDefinitionResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateSummaryType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.PolicyInsights.Models.PolicySummary>
<Extension()>
Public Function SummarizePolicyStatesAsync (subscriptionPolicyDefinitionResource As SubscriptionPolicyDefinitionResource, policyStateSummaryType As PolicyStateSummaryType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of PolicySummary)

Parameters

subscriptionPolicyDefinitionResource
SubscriptionPolicyDefinitionResource

The SubscriptionPolicyDefinitionResource instance the method will execute against.

policyStateSummaryType
PolicyStateSummaryType

The virtual resource under PolicyStates resource type for summarize action. In a given time range, 'latest' represents the latest policy state(s) and is the only allowed value.

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

An async collection of PolicySummary that may take multiple service requests to iterate over.

Applies to