Obtaining the Environment List
Function
Obtain the environment list.
URI
GET /v1/{project_id}/cae/environments
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Project ID. See Obtaining a Project ID. |
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
X-Auth-Token |
Yes |
String |
User token.
|
|
X-Enterprise-Project-ID |
No |
String |
Enterprise project ID.
NOTE:
For details about how to obtain enterprise project IDs and enterprise project features, see Enterprise Management User Guide.
|
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
api_version |
String |
API version. Fixed value: v1. |
|
kind |
String |
API type. Fixed value: Environment. |
|
items |
Array of EnvironmentItem objects |
Environment list. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
Environment ID. |
|
name |
String |
Environment name. |
|
job_id |
String |
Job ID. |
|
status |
String |
Environment status.
|
|
annotations |
Map<String,String> |
Additional attributes of the environment.
|
|
created_at |
String |
Creation time. |
|
updated_at |
String |
Update time. |
Example Requests
Obtain the environment list.
GET https://{endpoint}/v1/{project_id}/cae/environments
Example Responses
Status code: 200
OK
{
"api_version" : "v1",
"kind" : "Environment",
"items" : [ {
"id" : "5d3d1e90-2f5d-4ef1-958b-3fc1ed0b0898",
"name" : "test",
"version" : "1.2.0",
"job_id" : "15cbf4ff-e6a8-4504-a5e0-574b9c21493a",
"status" : "finish",
"annotations" : {
"cluster_id" : "2177808d-a78e-11ed-be73-0255ac100b0a",
"enterprise_project_id" : "0",
"env_category" : "v2",
"group_name" : "xxx",
"inbound_eip_addr" : "100.xx.xx.xxx",
"namespace" : "79c4xxxf5f3a4xxxda92601xxx64b1e8c-test",
"public_elb_id" : "da9e107e-bd25-412f-9546-563ed11ae34c",
"type" : "exclusive",
"vpc_id" : "09902850-9454-4715-9764-018f0c3701fd",
"subnet_id" : "b8ed83e8-da73-440e-95ca-0f16a328c987",
"egress_subnet_id" : "b8ed83e8-da73-440e-95ca-0f16a328c987",
"elb_id" : "fffdb681-4b5b-4e17-8aad-ee128ab187c7",
"runtime_platform" : "cce-share"
},
"created_at" : "2023-02-08T08:49:34.000737Z",
"updated_at" : "2023-02-08T08:49:34.000737Z"
} ]
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
OK |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot