Delete volume¶
Overview¶
Deletes a specified volume.
Classification¶
- Delete
API Operation Object¶
- os-volumes
Synchronous / Asynchronous¶
- -
Request¶
HTTP Request Method¶
- DELETE
HTTP Request Path¶
{api_endpoint}/v2/{tenant_id}/os-volumes/{volume_id}
Response¶
Sample API Request and Response¶
Sample API Request¶
Request URI¶
https://example.com/v2/{tenant_id}/os-volumes/{volume_id}
Request Header¶
Accept-Encoding: gzip, deflate, compress (optional)
Accept: application/json
X-Auth-Token: ajk3adjiown02
Content-Type: application/json
Request Body¶
- none
Sample API Response¶
Response Header¶
HTTP/1.1 202 Accepted
<response_code>: see "HTTP Responses" section
<message>: message based on the response code
- skip auto insert field such as "X-Compute-Request-Id" and "Content-Length", "Date"
Response Body¶
- none
Execution Example¶
HTTP Request¶
DELETE /v2/ad355aa6ed3e4cf5ae0fa0df652bc291/os-volumes/6a268a2b-becc-4a52-ac1c-f49b32ae7a46 HTTP/1.1
User-Agent: curl/7.35.0
Host: 192.168.56.250:8774
X-Auth-Token: ebbd28fada8b4d23be04d60b912d8144
Content-type: application/json
Accept: application/json
HTTP Response¶
HTTP/1.1 202 Accepted
Content-Type: text/html; charset=UTF-8
Content-Length: 0
X-Compute-Request-Id: req-a04b3dbb-a320-4a09-8530-5e5763f1c3e3
Date: Thu, 15 Oct 2015 05:41:01 GMT
Error Execution Example¶
HTTP Request¶
DELETE /v2/ad355aa6ed3e4cf5ae0fa0df652bc291/os-volumes/6a268a2b-becc-4a52-ac1c-f49b32ae7a46 HTTP/1.1
User-Agent: curl/7.35.0
Host: 192.168.56.250:8774
X-Auth-Token: ebbd28fada8b4d23be04d60b912d8144
Content-type: application/json
Accept: application/json
HTTP Response¶
HTTP/1.1 400 Bad Request
Content-Length: 157
Content-Type: application/json; charset=UTF-8
X-Compute-Request-Id: req-fcf70f08-37c4-4b9a-8041-878b241de1bc
Date: Thu, 15 Oct 2015 05:39:44 GMT
{"badRequest": {"message": "Invalid input received: Invalid volume: Volume status must be available or error, but current status is: creating", "code": 400}}