Queries the activation status and the RAM roles of an Alibaba Cloud service.
Operation description
Description
This topic describes how to query the activation status and the RAM roles of an Alibaba Cloud service. In this example, the Elastic High Performance Computing (E-HPC) service that is deployed in the China (Hangzhou) region is queried.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
ros:GetServiceProvisions | list |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID. You can call the DescribeRegions operation to query the most recent region list. | cn-hangzhou |
TemplateBody | string | No | The structure that contains the template body. The template body must be 1 to 524,288 bytes in length. If the length of the template body exceeds the upper limit, we recommend that you add parameters to the HTTP POST request body to prevent request failures caused by excessively long URLs. You must and can specify only one of the following parameters: TemplateBody, TemplateURL, TemplateId, and TemplateScratchId. | {"ROSTemplateFormatVersion": "2015-09-01","Resources": {"ApiGateway": {"Type": "ALIYUN::ApiGateway::Group","Properties": { "GroupName": "ros_example" }},"FC": {"Type": "ALIYUN::FC::Service","Properties": {"ServiceName": "ros_example"}}}} |
TemplateURL | string | No | The URL of the file that contains the template body. The URL must point to a template that is located on an HTTP or HTTPS web server or in an Object Storage Service (OSS) bucket, such as oss://ros/template/demo or oss://ros/template/demo?RegionId=cn-hangzhou. The template body must be 1 to 524,288 bytes in length. If you do not specify the region ID of the OSS bucket, the value of RegionId is used. You must and can specify only one of the following parameters: TemplateBody, TemplateURL, TemplateId, and Services. | oss://ros-template/demo |
TemplateId | string | No | The template ID. This parameter applies to shared and private templates. You must and can specify only one of the following parameters: TemplateBody, TemplateURL, TemplateId, and Services. | 5ecd1e10-b0e9-4389-a565-e4c15efc**** |
TemplateVersion | string | No | The version of the template. If you do not specify this parameter, the latest version is used. This parameter takes effect only when TemplateId is specified. | v1 |
Parameters | array<object> | No | The parameters. | |
object | No | |||
ParameterKey | string | Yes | The name of the parameter. If you do not specify the name and value of a parameter, Resource Orchestration Service (ROS) uses the default name and value that are specified in the template. Note
The Parameters parameter is optional. If you specify Parameters, you must specify ParameterKey.
| Amount |
ParameterValue | string | Yes | The value of the parameter. Note
The Parameters parameter is optional. If you specify Parameters, you must specify ParameterValue.
| 12 |
Services | array<object> | No | The services. | |
object | No | |||
ServiceName | string | Yes | The name of the service or feature. Valid values:
| EHPC |
For more information about common request parameters, see Common parameters.
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "A9938C04-26AD-5EFA-B394-EA7866842DFF",
"ServiceProvisions": [
{
"ServiceName": "EHPC",
"Status": "Enabled",
"StatusReason": "No permission.",
"AutoEnableService": false,
"EnableURL": "https://common-buy.aliyun.com/?commodityCode=nas",
"RoleProvision": {
"AuthorizationURL": "https://ehpc.console.aliyun.com/",
"Roles": [
{
"RoleName": "AliyunServiceRoleForEHPC",
"Created": true,
"Function": "Default",
"ApiForCreation": {
"ApiProductId": "rds",
"ApiName": "CreateServiceLinkedRole",
"ApiType": "Open",
"Parameters": {
"ServiceLinkedRole": "AliyunServiceRoleForRdsPgsqlOnEcs",
"RegionId": "${RegionId}"
}
}
}
]
},
"DependentServiceNames": [
"NAS"
]
}
]
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-01-12 | The internal configuration of the API is changed, but the call is not affected | View Change Details |
2022-10-28 | API Description Update. The response structure of the API has changed | View Change Details |
2021-11-12 | The response structure of the API has changed | View Change Details |