• Elastic Volume Service

evs
  1. Help Center
  2. Elastic Volume Service
  3. API Reference
  4. OpenStack Cinder API v2
  5. EVS Disk
  6. Querying Details of Tenant Quotas

Querying Details of Tenant Quotas

Function

This API is used to query the details of tenant quotas.

URI

  • URI format

    GET /v2/{project_id}/os-quota-sets/{project_id}?usage=True

  • Parameter description

    Parameter

    Mandatory

    Description

    project_id

    Yes

    Specifies the project ID.

Request

None

Response

  • Parameter description

    Parameter

    Type

    Description

    quota_set

    map

    Specifies the queried quotas.

    volumes

    map<string, int>

    Specifies the number of EVS disks. This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    snapshots

    map<string, int>

    Specifies the number of snapshots. This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    gigabytes

    map<string, int>

    Specifies the total size (GB) of EVS disks and snapshots allowed by the quota. This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    volumes_TYPE

    map<string, int>

    Specifies the number of EVS disks reserved for a specified volume type. This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    snapshots_TYPE

    map<string, int>

    Specifies the number of snapshots reserved for a specified volume type. This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    gigabytes_TYPE

    map<string, int>

    Specifies the size (GB) reserved for a specified volume type. This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    id

    string

    Specifies the tenant ID.

    backups

    map<string, int>

    Specifies the number of backups. This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    backup_gigabytes

    map<string, int>

    Specifies the backup size (GB). This parameter is made up of key-value pairs which include reserved, limit, and in_use.

    message

    string

    Specifies the returned error message when an error occurs.

    code

    string

    Specifies the returned error code when an error occurs. For details about the code, see the following returned values.

    NOTE:

    If the limit value returned in the response is -1, no quota limit has been established.

  • Example response
    {
        "quota_set": {
            "gigabytes_SAS": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 21
            }, 
            "volumes_SATA": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 8
            }, 
            "gigabytes": {
                "reserved": 0, 
                "limit": 42790, 
                "in_use": 2792
            }, 
            "backup_gigabytes": {
                "reserved": 0, 
                "limit": 5120, 
                "in_use": 51
            }, 
            "snapshots_SAS": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 0
            }, 
            "volumes_SSD": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 28
            }, 
            "snapshots": {
                "reserved": 0, 
                "limit": 10, 
                "in_use": 6
            }, 
            "id": "cd631140887d4b6e9c786b67a6dd4c02", 
            "volumes_SAS": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 2
            }, 
            "snapshots_SSD": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 0
            }, 
            "volumes": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 108
            }, 
            "gigabytes_SATA": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 168
            }, 
            "backups": {
                "reserved": 0, 
                "limit": 100, 
                "in_use": 10
            }, 
            "gigabytes_SSD": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 1085
            }, 
            "snapshots_SATA": {
                "reserved": 0, 
                "limit": -1, 
                "in_use": 0
            }
        }
    }

    or

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

    In the preceding example, error indicates a general error, for example, badrequest or itemNotFound. An example is provided as follows:

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

Returned Values

  • Normal

    200

Error Codes

For details, see Error Codes.