| Description | : Retrieve alert rule definitions in a subscription. |
| Reference | : Link ¶ |
⚶ Changes
{
"#id": "MetricAlerts_ListBySubscription",
"$responses": {
"200": {
"$properties": {
"value": {
"$properties": {
"properties": [
{
"#name": "scopes",
"Description": {
"new": "the list of resource id's that this metric alert is scoped to. You cannot change the scope of a metric rule based on logs.",
"old": "the list of resource id's that this metric alert is scoped to."
}
}
]
}
}
}
}
}
}
⚼ Request
GET:
/subscriptions/{subscriptionId}/providers/Microsoft.Insights/metricAlerts
{
subscriptionId:
string
,
api-version:
string
,
}
⚐ Response (200)
{
value:
}
[
]
,
{
,
properties:
}
{
,
description:
string
,
severity:
integer
,
enabled:
boolean
,
scopes:
[
,
string
,
]
evaluationFrequency:
string
,
windowSize:
string
,
targetResourceType:
string
,
targetResourceRegion:
string
,
criteria:
{
,
odata.type:
enum
,
}
autoMitigate:
boolean
,
actions:
[
]
,
{
,
actionGroupId:
string
,
webHookProperties:
object
,
}
lastUpdatedTime:
string
,
isMigrated:
boolean
,
}
⚐ Response (default)
{
error:
}
{
,
code:
string
,
message:
string
,
target:
string
,
details:
[
]
,
{
,
code:
string
,
message:
string
,
target:
string
,
additionalInfo:
}
[
]
,
{
,
type:
string
,
info:
object
,
}
additionalInfo:
}
[
]
,
{
,
type:
string
,
info:
object
,
}