
# 查询云服务器规格详情列表（废弃） - NovaListFlavorsDetails
#### 功能介绍
查询云服务器规格信息列表。
当前API已废弃，请使用[查询规格详情和规格扩展信息列表 - ListFlavors](https://support.huaweicloud.com/api-ecs/zh-cn_topic_0020212656.html)。
#### 调试
您可以在[API Explorer](https://apiexplorer.developer.huaweicloud.com/apiexplorer/doc?product=ECS&api=NovaListFlavorsDetails)中调试该接口。
#### URI
GET /v2.1/{project_id}/flavors/detail
参数说明请参见[表1]。
 表1路径参数 
| 参数         | 是否必选 | 描述                                                                                                                      |
|:---|:---|:---|
| project_id | 是    | 项目ID。 获取方法请参见[获取项目ID](https://support.huaweicloud.com/api-ecs/ecs_01_0016.html)。 |
   
![](https://support.huaweicloud.com/api-ecs/public_sys-resources/note_3.0-zh-cn.png)
支持分页查询，请参见[分页查询](https://support.huaweicloud.com/api-ecs/zh-cn_topic_0020805967.html#ZH-CN_TOPIC_0020805967__section1098071718385)。
表2查询参数 
| 参数       | 是否必选 | 参数类型   | 描述                                                                    |
|:---|:---|:---|:---|
| minDisk  | 否    | String | 最小的硬盘规格，单位GiB，大于等于此规格的都可以查询到。                                         |
| minRam   | 否    | String | 最小的内存规格，单位MiB，大于等于此规格的都可以查询到。                                         |
| sort_key | 否    | String | 排序字段，默认值为：flavorid。可以指定的其他key为name/ memory_mb/vcpus/root_gb/flavorid。 |
| sort_dir | 否    | String | 升序/降序排序，默认值为：asc。可以指定的参数为asc/desc。                                    |
   
#### 请求消息
无
#### 响应消息
响应参数如[表3]所示。
 表3响应参数 
| 参数            | 参数类型             | 描述                                                                                                  |
|:---|:---|:---|
| flavors       | Array of objects | 云服务器规格列表，详情请参见[表4]。                                      |
| flavors_links | Array of objects | 分页查询时，查询下一页数据链接 , 详情请参见[表5 flavors_links字段数据结构说明]。 |
   
 表4flavors数据结构说明 
| 参数                         | 参数类型             | 描述                                                                                                                                                                                                                                                                                                                                               |
|:---|:---|:---|
| id                         | String           | 云服务器规格ID。                                                                                                                                                                                                                                                                                                                                        |
| name                       | String           | 云服务器规格名称。                                                                                                                                                                                                                                                                                                                                        |
| vcpus                      | Integer          | 云服务器规格对应的CPU核数。                                                                                                                                                                                                                                                                                                                                  |
| ram                        | Integer          | 云服务器规格对应的内存大小，单位为MiB。                                                                                                                                                                                                                                                                                                                            |
| disk                       | Integer          | 云服务器规格对应要求系统盘大小。 当前未使用该参数，缺省值为0。                                                                                                                                                                                                                                                                          |
| swap                       | String           | 云服务器规格对应要求的交换分区大小。 当前未使用该参数，缺省值为""。                                                                                                                                                                                                                                                                  |
| OS-FLV-EXT-DATA:ephemeral  | Integer          | 扩展属性，临时盘大小。 当前未使用该参数，缺省值为0。                                                                                                                                                                                                                                                                            |
| OS-FLV-DISABLED:disabled   | Boolean          | 扩展属性，该云服务器规格是否禁用。 当前未使用该参数，缺省值为false。                                                                                                                                                                                                                                                               |
| rxtx_factor                | Float            | 云服务器可使用网络带宽与网络硬件带宽的比例。 当前未使用该参数，缺省值为1.0。                                                                                                                                                                                                                                                            |
| os-flavor-access:is_public | Boolean          | 扩展属性，flavor是否给所有租户使用。 - true：表示给所有租户使用。  - false：表示给指定租户使用。   缺省值为true。 |
| links                      | Array of objects | 规格相关快捷链接地址，详情请参见[表5]。                                                                                                                                                                                                                                                                           |
   
 表5links字段数据结构说明 
| 参数   | 参数类型   | 描述        |
|:---|:---|:---|
| rel  | String | 快捷链接标记名称。 |
| href | String | 对应快捷链接。   |
   
#### 请求示例
查询云服务器规格信息列表。
```
GET https://{endpoint}/v2.1/743b4c0428d94531b9f2add666642e6b/flavors/detail
```
#### 响应示例
```
{
    "flavors": [
        {
            "name": "c3.2xlarge.2",
            "links": [
                {
                    "href": "https://compute.region.example.com/v2.1/743b4c0428d94531b9f2add666642e6b/flavors/c3.2xlarge.2",
                    "rel": "self"
                },
                {
                    "href": "https://compute.region.example.com/743b4c0428d94531b9f2add666642e6b/flavors/c3.2xlarge.2",
                    "rel": "bookmark"
                }
            ],
            "ram": 16384,
            "OS-FLV-DISABLED:disabled": false,
            "vcpus": 8,
            "swap": "",
            "os-flavor-access:is_public": true,
            "rxtx_factor": 1,
            "OS-FLV-EXT-DATA:ephemeral": 0,
            "disk": 0,
            "id": "c3.2xlarge.2"
        },
        {
            "name": "c3.2xlarge.4",
            "links": [
                {
                    "href": "https://compute.region.example.com/v2.1/743b4c0428d94531b9f2add666642e6b/flavors/c3.2xlarge.4",
                    "rel": "self"
                },
                {
                    "href": "https://compute.region.example.com/743b4c0428d94531b9f2add666642e6b/flavors/c3.2xlarge.4",
                    "rel": "bookmark"
                }
            ],
            "ram": 32768,
            "OS-FLV-DISABLED:disabled": false,
            "vcpus": 8,
            "swap": "",
            "os-flavor-access:is_public": true,
            "rxtx_factor": 1,
            "OS-FLV-EXT-DATA:ephemeral": 0,
            "disk": 0,
            "id": "c3.2xlarge.4"
        }
    ]
}
```
#### 返回值
请参考[通用请求返回值](https://support.huaweicloud.com/api-ecs/ecs_07_0001.html)。
