diff --git a/api-ref/source/v3/parameters.yaml b/api-ref/source/v3/parameters.yaml index 902060ceb9c..a1b664e7977 100644 --- a/api-ref/source/v3/parameters.yaml +++ b/api-ref/source/v3/parameters.yaml @@ -13,6 +13,12 @@ admin_project_id: in: path required: false type: string +all_tenants: + description: | + Shows details for all projects. + in: path + required: false + type: string backup_id: description: | The UUID for a backup. @@ -1610,6 +1616,18 @@ total_capacity: in: body required: true type: string +total_count: + description: | + Total number of volumes. + in: body + required: true + type: integer +total_size: + description: | + Total size of volumes in GB. + in: body + required: true + type: integer totalBackupGigabytesUsed: description: | The total number of backups gibibytes (GiB) used. @@ -1699,6 +1717,12 @@ volume: in: body required: true type: object +volume-summary: + description: | + Dictionary of ``volume-summary`` objects. + in: body + required: true + type: object volume_1: description: | A ``volume`` object. diff --git a/api-ref/source/v3/samples/volumes-list-summary-response.json b/api-ref/source/v3/samples/volumes-list-summary-response.json new file mode 100644 index 00000000000..53a78f7da27 --- /dev/null +++ b/api-ref/source/v3/samples/volumes-list-summary-response.json @@ -0,0 +1,6 @@ +{ + "volume-summary": { + "total_size": 4, + "total_count": 4 + } +} \ No newline at end of file diff --git a/api-ref/source/v3/volumes-v3-volumes.inc b/api-ref/source/v3/volumes-v3-volumes.inc index 3782efa9743..592f65e0dee 100644 --- a/api-ref/source/v3/volumes-v3-volumes.inc +++ b/api-ref/source/v3/volumes-v3-volumes.inc @@ -574,3 +574,41 @@ Response Example .. literalinclude:: ./samples/volume-metadata-update-response.json :language: javascript + + + +Get volumes summary +=================== + +.. rest_method:: GET /v3/{project_id}/volumes/summary + +Display volumes summary with total number of volumes and total size in GB + + +Normal response codes: 200 +Error response codes: + + +Request +------- + +.. rest_parameters:: parameters.yaml + + - project_id: project_id_path + - all_tenants: all_tenants + +Response Parameters +------------------- + +.. rest_parameters:: parameters.yaml + + - volume-summary: volume-summary + - total_size: total_size + - total_count: total_count + + +Response Example +---------------- + +.. literalinclude:: ./samples/volumes-list-summary-response.json + :language: javascript