All Products
Search
Document Center

AliyunServiceRoleForApiGatewayMonitoring service-linked role

Last Updated: Sep 26, 2021

This topic describes the scenarios of the AliyunServiceRoleForApiGatewayMonitoring service-linked role and how to delete the role.

Background information

The AliyunServiceRoleForApiGatewayMonitoring service-linked role is a RAM role that is provided to facilitate you to apply the same alert settings to all API operations in an API group.

Scenarios

API Gateway assumes the AliyunServiceRoleForApiGatewayMonitoring service-linked role to gain access to your CloudMonitor resources. After the mapping between an API group and an application group in CloudMonitor is established, the API operations in the API group automatically become instances in the mapping application group in CloudMonitor. This way, you can manage the alert settings for multiple API operations in the same API group at a time.

Description of the AliyunServiceRoleForApiGatewayMonitoring service-linked role

Role name: AliyunServiceRoleForApiGatewayMonitoring Policy attached to the role: AliyunServiceRolePolicyForApiGatewayMonitoring Permission description:

{
  "Version": "1",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": [
        "cms:CreateMonitorGroup",
        "cms:CreateMonitorGroupInstances",
        "cms:DescribeMonitorGroups",
        "cms:DeleteMonitorGroup",
        "cms:DeleteMonitorGroupInstances"
      ],
      "Resource": "acs:cms:*:*:*"
    }
  ]
}

Delete the AliyunServiceRoleForApiGatewayMonitoring service-linked role

Before you delete the AliyunServiceRoleForApiGatewayMonitoring service-linked role, you must delete the application group that depends on the service-linked role in CloudMonitor. To delete the AliyunServiceRoleForApiGatewayMonitoring service-linked role, perform the following steps:

  1. Log on to the CloudMonitor console.

  2. In the left-side navigation pane, click Application Groups.

  3. Find and delete the APIGATEWAY_${region}_$(groupId) application group in CloudMonitor. In the name, ${region} indicates the region where the API group that maps the application group resides, and $(groupId) indicates the ID of the API group. For example, the name of the application group is APIGATEWAY_ap-southeast-1_d17e78c9d436436c89a7e8c42a329a4d.

  4. Log on to the RAM console. In the left-side navigation pane, click RAM Roles. Find the AliyunServiceRoleForApiGatewayMonitoring role and click Delete in the Actions column.

For more information, see the "Delete a service-linked role" section of the Service-linked roles topic.