Obtaining the Resource Flavor List
Function
This API is used to obtain the resource flavor list.
Debugging
You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.
URI
GET /v1/{project_id}/dev-servers/resource-flavors
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Definition: Project ID. For details, see Obtaining a Project ID and Name. Constraints: The value can contain 1 to 64 characters. Letters, digits, and hyphens (-) are allowed. Range: N/A Default Value: N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
server_type |
No |
String |
Definition: Service type. Constraints: N/A Range
Default Value: N/A |
|
arch |
No |
String |
Definition: CPU architecture of the flavor. Constraints: N/A Range
Default Value: N/A |
|
charging_mode |
No |
String |
Definition: CPU architecture of the flavor. Constraints: N/A Range
Default Value: N/A |
Request Parameters
None
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
current |
Integer |
Definition: Current page number. Constraints: N/A Default Value: N/A |
|
data |
Array of ServerResourceFlavorInstanceResponse objects |
DevServer flavor list. |
|
pages |
Integer |
Definition: Total number of pages. Constraints: N/A Default Value: N/A |
|
size |
Integer |
Definition: Number of records on each page. Constraints: N/A Default Value: N/A |
|
total |
Long |
Definition: Total number of records. Constraints: N/A Default Value: N/A |
|
Parameter |
Type |
Description |
|---|---|---|
|
flavor |
String |
IaaS flavor name. |
|
specification |
String |
Flavor specifications. |
|
arch |
String |
Cloud server architecture. |
|
server_type |
String |
Cloud server type. |
|
sku_code |
String |
Flavor billing code. |
|
charging_mode |
String |
Billing mode. |
|
roce_num |
Integer |
NIC quantity. |
|
count |
Integer |
Supernode instance nodes. |
|
status |
String |
Server specifications status. |
|
server_flavors |
Array of ServerFlavorInfo objects |
Available flavors for supernode scaling. |
|
flavor_type |
String |
Compute PU type. |
|
availability_zones |
Array of AvailabilityZoneResponse objects |
AZ and on-sale status. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
AZ ID. |
|
is_sold_out |
Boolean |
Flavor on-sale status. |
Status code: 400
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Range: N/A |
|
error_msg |
String |
Definition: Error message. Range: N/A |
Status code: 401
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Range: N/A |
|
error_msg |
String |
Definition: Error message. Range: N/A |
Status code: 403
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Range: N/A |
|
error_msg |
String |
Definition: Error message. Range: N/A |
Status code: 500
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Range: N/A |
|
error_msg |
String |
Definition: Error message. Range: N/A |
Example Requests
GET https://{endpoint}/v1/{project_id}/dev-servers/resource-flavors
Example Responses
Status code: 200
Accepted
{
"current" : 1,
"data" : [ {
"arch" : "ARM",
"availability_zones" : [ {
"id" : "cn-north-7c",
"is_sold_out" : false
}, {
"id" : "cn-north-7b",
"is_sold_out" : false
}, {
"id" : "cn-north-7a",
"is_sold_out" : false
} ],
"charging_mode" : "COMMON",
"count" : 1,
"flavor" : "modelarts.bm.npu.arm.8snt9b3.d.physical",
"flavor_type" : "ASCEND_SNT9B",
"roce_num" : 8,
"server_flavors" : [ {
"name" : "kat2e.48xlarge.8.376t.physical"
}, {
"name" : "kat2e.48xlarge.8.400t.physical"
} ],
"server_type" : "ECS",
"sku_code" : "modelarts.vm.cpu.2u.d",
"specification" : "8*Snt9b3|8*64GB|192vcpus|768GiB"
} ],
"pages" : 1,
"size" : 1,
"total" : 1
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Accepted |
|
400 |
Bad Request |
|
401 |
Unauthorized |
|
403 |
Forbidden |
|
500 |
Server Internal Error |
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