From 6ba228e2cd37f885e0136ff8d2d98b8442987d2f Mon Sep 17 00:00:00 2001 From: "jeremy.zhang" Date: Thu, 21 Jun 2018 23:34:16 +0800 Subject: [PATCH] Add v3 api-ref for force delete snapshot This patch is to add v3 api-ref for force delete a snapshot. Change-Id: I44d16a9fa9065b5e92b18c487b45e7076ec03b0e --- .../snapshot-force-delete-request.json | 3 ++ .../v3/volumes-v3-snapshots-actions.inc | 33 +++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 api-ref/source/v3/samples/snapshot-force-delete-request.json diff --git a/api-ref/source/v3/samples/snapshot-force-delete-request.json b/api-ref/source/v3/samples/snapshot-force-delete-request.json new file mode 100644 index 00000000000..5c56464d919 --- /dev/null +++ b/api-ref/source/v3/samples/snapshot-force-delete-request.json @@ -0,0 +1,3 @@ +{ + "os-force_delete": {} +} diff --git a/api-ref/source/v3/volumes-v3-snapshots-actions.inc b/api-ref/source/v3/volumes-v3-snapshots-actions.inc index 6835b67e9ad..4ba975ab7ce 100644 --- a/api-ref/source/v3/volumes-v3-snapshots-actions.inc +++ b/api-ref/source/v3/volumes-v3-snapshots-actions.inc @@ -71,3 +71,36 @@ Request Example .. literalinclude:: ./samples/snapshot-status-update-request.json :language: javascript + + +Force delete a snapshot +~~~~~~~~~~~~~~~~~~~~~~~ + +.. rest_method:: POST /v3/{project_id}/snapshots/{snapshot_id}/action + +Attempts to force delete a snapshot, regardless of state. Specify the +``os-force_delete`` action in the request body. + +Response codes +-------------- + +.. rest_status_code:: success ../status.yaml + + - 202 + + +Request +------- + +.. rest_parameters:: parameters.yaml + + - project_id: project_id_path + - snapshot_id: snapshot_id_path + - os-force_delete: os-force_delete + + +Request Example +--------------- + +.. literalinclude:: ./samples/snapshot-force-delete-request.json + :language: javascript