Creates a tag rule based on which instances of cloud services can be automatically added to an application group.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
ContactGroupList.N | RepeatList | Yes | Default alert group |
The alert group for receiving alert notifications. |
RegionId | String | Yes | cn-hangzhou |
The ID of the region. Note You can call the DescribeRegions operation to query the most recent region list.
|
TagKey | String | Yes | tagKey1 |
The key of the tag. |
EnableSubscribeEvent | Boolean | No | true |
Specifies whether to enable event subscription. Valid values:
|
EnableInstallAgent | Boolean | No | true |
Specifies whether to automatically install the CloudMonitor agent on ECS instances that are automatically added to the application group. Default value: false. Valid values:
|
MatchExpressFilterRelation | String | No | and |
The logical operator used between conditional expressions. Valid values:
Note
|
MatchExpress.N.TagValueMatchFunction | String | No | contains |
The method used to match the value of the tag. Valid values: Valid values:
Set the value of N to 1. Note Alibaba Cloud will support multiple conditional expressions in the future.
|
MatchExpress.N.TagValue | String | No | Tag value |
The value of the tag. Set the value of N to 1. Note This parameter and the
MatchExpress.N.TagValueMatchFunction parameter must be used in pairs.
|
TemplateIdList.N | RepeatList | No | 12345 |
The ID of the alert template. Note When CloudMonitor creates the application group, CloudMonitor generates alert rules
for the application group based on the specified alert template.
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
Code | String | 200 |
The HTTP status code. Note The status code 200 indicates that the call was successful.
|
Message | String | OK |
The error message. |
Success | Boolean | true |
Indicates whether the call was successful. |
RequestId | String | 84AC6F0B-7945-466A-AA44-99BB5A561F86 |
The ID of the request. |
Examples
Sample requests
http(s)://[Endpoint]/? Action=CreateDynamicTagGroup
&ContactGroupList.1=Default alert group
&RegionId=cn-hangzhou
&TagKey=tagKey1
&<Common request parameters>
Sample success responses
XML
format
<Code>200</Code>
<RequestId>84AC6F0B-7945-466A-AA44-99BB5A561F86</RequestId>
<Success>true</Success>
JSON
format
{
"Code":"200",
"RequestId":"84AC6F0B-7945-466A-AA44-99BB5A561F86",
"Success":true
}
Error codes
For a list of error codes, visit the API Error Center.