Creates an environment instance.
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 |
---|---|---|---|---|
arms:CreateEnvironment | create |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID. | cn-hangzhou |
AliyunLang | string | No | The language. Default value: zh. Valid values:
| zh |
EnvironmentName | string | Yes | The name of the environment. | env1 |
EnvironmentType | string | Yes | The type of the environment. Valid values:
| CS |
EnvironmentSubType | string | Yes | The subtype of the environment. Valid values:
| ECS, ACK, etc. |
BindResourceId | string | Yes | The ID of the resource bound to the environment, such as the container ID or VPC ID. For a Cloud environment, specify the region ID. | c6e9dec475dca4a50a188411d8cbxxx |
ManagedType | string | No | Specifies whether agents or exporters are managed. Valid values:
| none |
FeePackage | string | No | The payable resource plan.
| CS_Basic |
PrometheusInstanceId | string | No | The ID of the Prometheus instance. If no Prometheus instance is created, call the InitEnvironment operation. | c6e9dec475dca4a50a188411d8cbxxx |
GrafanaWorkspaceId | string | No | The ID of the Grafana workspace associated with the environment. If this parameter is left empty, the default shared Grafana workspace is used. | grafana-rnglkcdrntlhk0**** |
ResourceGroupId | string | No | The ID of the resource group. | rg-acfmxyexli2**** |
Tags | array<object> | No | The tags of the instance. You can specify this parameter to manage tags for the instance. | |
object | No | The list of tags. | ||
Key | string | No | The tag key. | TestKey |
Value | string | No | The tag value. | TestValue |
InitEnvironment | boolean | No | Specifies whether to initialize the environment. | false |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "16AF921B-8187-489F-9913-43C808B4****",
"Code": 200,
"Data": "env-xxxxx",
"Message": "message"
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-06-17 | The request parameters of the API has changed | View Change Details |
2024-05-28 | The request parameters of the API has changed | View Change Details |
2024-05-08 | The internal configuration of the API is changed, but the call is not affected | View Change Details |
2024-03-19 | The request parameters of the API has changed | View Change Details |
2024-02-23 | The request parameters of the API has changed | View Change Details |
2024-01-09 | The request parameters of the API has changed | View Change Details |
2023-11-03 | The internal configuration of the API is changed, but the call is not affected | View Change Details |