Remediations - List Deployments At Management Group
Gets all deployments for a remediation at management group scope.
POST https://management.azure.com/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.PolicyInsights/remediations/{remediationName}/listDeployments?api-version=2021-10-01
POST https://management.azure.com/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.PolicyInsights/remediations/{remediationName}/listDeployments?$top={$top}&api-version=2021-10-01
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
management
|
path | True |
string |
Management group ID. |
management
|
path | True |
The namespace for Microsoft Management RP; only "Microsoft.Management" is allowed. |
|
remediation
|
path | True |
string |
The name of the remediation. |
api-version
|
query | True |
string |
Client Api Version. |
$top
|
query |
integer int32 |
Maximum number of records to return. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
The retrieved remediation deployments. |
|
Other Status Codes |
Error response describing why the operation failed. |
Security
azure_auth
Azure Active Directory OAuth2 Flow
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
Name | Description |
---|---|
user_impersonation | impersonate your user account |
Examples
List deployments for a remediation at management group scope
Sample request
POST https://management.azure.com/providers/Microsoft.Management/managementGroups/financeMg/providers/Microsoft.PolicyInsights/remediations/myRemediation/listDeployments?api-version=2021-10-01
Sample response
{
"value": [
{
"remediatedResourceId": "/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1",
"deploymentId": "/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.resources/deployments/a088e8fd-8600-4126-8d74-fc7ead0e9ae4",
"status": "Succeeded",
"resourceLocation": "eastus",
"createdOn": "2018-09-13T21:51:09.075918Z",
"lastUpdatedOn": "2018-09-13T21:52:09.8919106Z"
},
{
"remediatedResourceId": "/subscriptions/c1164d71-0942-499f-bc2f-b6b7b0bae493/resourcegroups/myResourceGroup2/providers/microsoft.storage/storageaccounts/stor1",
"deploymentId": "/subscriptions/c1164d71-0942-499f-bc2f-b6b7b0bae493/resourcegroups/myResourceGroup2/providers/microsoft.resources/deployments/6b8898c0-18a2-449e-987a-8d4d4f634f56",
"status": "Succeeded",
"resourceLocation": "westus",
"createdOn": "2018-09-13T21:51:09.075918Z",
"lastUpdatedOn": "2018-09-13T21:52:09.8761679Z"
}
]
}
Definitions
Name | Description |
---|---|
Error |
Error definition. |
Error |
Error response. |
Management |
The namespace for Microsoft Management RP; only "Microsoft.Management" is allowed. |
Remediation |
Details of a single deployment created by the remediation. |
Remediation |
List of deployments for a remediation. |
Typed |
Scenario specific error details. |
ErrorDefinition
Error definition.
Name | Type | Description |
---|---|---|
additionalInfo |
Additional scenario specific error details. |
|
code |
string |
Service specific error code which serves as the substatus for the HTTP error code. |
details |
Internal error details. |
|
message |
string |
Description of the error. |
target |
string |
The target of the error. |
ErrorResponse
Error response.
Name | Type | Description |
---|---|---|
error |
The error details. |
ManagementGroupsNamespaceType
The namespace for Microsoft Management RP; only "Microsoft.Management" is allowed.
Name | Type | Description |
---|---|---|
Microsoft.Management |
string |
RemediationDeployment
Details of a single deployment created by the remediation.
Name | Type | Description |
---|---|---|
createdOn |
string |
The time at which the remediation was created. |
deploymentId |
string |
Resource ID of the template deployment that will remediate the resource. |
error |
Error encountered while remediated the resource. |
|
lastUpdatedOn |
string |
The time at which the remediation deployment was last updated. |
remediatedResourceId |
string |
Resource ID of the resource that is being remediated by the deployment. |
resourceLocation |
string |
Location of the resource that is being remediated. |
status |
string |
Status of the remediation deployment. |
RemediationDeploymentsListResult
List of deployments for a remediation.
Name | Type | Description |
---|---|---|
nextLink |
string |
The URL to get the next set of results. |
value |
Array of deployments for the remediation. |
TypedErrorInfo
Scenario specific error details.
Name | Type | Description |
---|---|---|
info |
|
The scenario specific error details. |
type |
string |
The type of included error details. |