Updated on 2024-02-27 GMT+08:00

Querying EVS Disk Types

Function

This API is used to query EVS disk types.

Calling Method

For details, see Calling APIs.

URI

GET /v3/{project_id}/types

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

The project ID.

For details about how to obtain the project ID, see Obtaining a Project ID.

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

No

String

The user token. It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is the user token.

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

volume_types

Array of VolumeType objects

The list of returned disk types.

Table 4 VolumeType

Parameter

Type

Description

id

String

The disk type ID.

name

String

The disk type name.

extra_specs

VolumeTypeExtraSpecs object

The disk type flavor.

description

String

The disk type description.

qos_specs_id

String

The reserved field.

is_public

Boolean

The reserved field.

Table 5 VolumeTypeExtraSpecs

Parameter

Type

Description

RESKEY:availability_zones

String

The list of AZs where the disk type is supported. Elements in the list are separated by commas (,). If this parameter is not specified, the disk type is supported in all AZs.

availability-zone

String

The reserved field.

os-vendor-extended:sold_out_availability_zones

String

The list of AZs where the disk type has been sold out. Elements in the list are separated by commas (,).

volume_backend_name

String

The reserved field.

HW:availability_zone

String

The reserved field.

Status code: 400

Table 6 Response body parameters

Parameter

Type

Description

error

Error object

The error message returned if an error occurs.

Table 7 Error

Parameter

Type

Description

code

String

The error code returned if an error occurs.

For details about error codes and their meanings, see Error Codes.

message

String

The error message returned if an error occurs.

Example Requests

GET https://{endpoint}/v3/{project_id}/types

Example Responses

Status code: 200

OK

{
  "volume_types" : [ {
    "extra_specs" : {
      "volume_backend_name" : "SAS",
      "availability-zone" : "az-dc-1",
      "RESKEY:availability_zones" : "az-dc-1,az-dc-2",
      "os-vendor-extended:sold_out_availability_zones" : "az-dc-2"
    },
    "name" : "SAS",
    "qos_specs_id" : null,
    "id" : "6c81c680-df58-4512-81e7-ecf66d160638",
    "is_public" : true,
    "description" : null
  }, {
    "extra_specs" : {
      "volume_backend_name" : "SATA",
      "availability-zone" : "az-dc-1",
      "RESKEY:availability_zones" : "az-dc-1,az-dc-2",
      "os-vendor-extended:sold_out_availability_zones" : "az-dc-2"
    },
    "name" : "SATA",
    "qos_specs_id" : "585f29d6-7147-42e7-bfb8-ca214f640f6f",
    "is_public" : true,
    "id" : "ea6e3c13-aac5-46e0-b280-745ed272e662",
    "description" : null
  }, {
    "extra_specs" : {
      "volume_backend_name" : "SSD",
      "availability-zone" : "az-dc-1",
      "RESKEY:availability_zones" : "az-dc-1,az-dc-2",
      "os-vendor-extended:sold_out_availability_zones" : "az-dc-2"
    },
    "name" : "SSD",
    "qos_specs_id" : "39b0c29a-308b-4f86-b478-5d3d02a43837",
    "is_public" : true,
    "id" : "6f2dee9e-82f0-4be3-ad89-bae605a3d24f",
    "description" : null
  } ]
}

Status code: 400

Bad Request

{
  "error" : {
    "message" : "XXXX",
    "code" : "XXX"
  }
}

Status Codes

Status Code

Description

200

OK

400

Bad Request

Error Codes

See Error Codes.