VMware Cloud Director API - POST-SuspendVApp
POST /vApp/{id}/power/action/suspend
- Operation:
- POST /vApp/{id}/power/action/suspend
- Description:
-
Suspend a vApp or VM.
If used on a vApp, suspends all VMs in the vApp. If used on a VM, suspends the VM. This operation is available only for a vApp or VM that is powered on.
- Since:
- 0.9
- Input parameters
-
- Consume media type(s):
- None
- Input type:
- None
- Output parameters
-
TaskType
This operation is asynchronous and returns a task that you can monitor to track the progress of the request.
- Produce media type(s):
-
application/vnd.vmware.vcloud.task+xml
application/vnd.vmware.vcloud.task+json
- Output type:
- TaskType
- Examples
-
- Request
-
HTTP 1.1
POST /api/vApp/vapp-6943025b-dd0d-4b3b-bf7a-e23135a253a7/power/action/suspend
Headers:
x-vcloud-authorization: iFZF7U6Ycko1r9Q5xwoP/d7L6MkGvdyv9U9Td9fI8I8=
Body:
- Response
-
HTTP/1.1 202 Accepted
Headers:
Content-Length: 1316
Content-Type: application/vnd.vmware.vcloud.task+xml; version=5.5
Location: https://vcloud.example.com/api/task/c3deb787-4509-4f90-a05c-de8d258c16ac
Vary: Accept-Encoding
Body:
<?xml version="1.0" encoding="UTF-8"?>
<Task
xmlns="http://www.vmware.com/vcloud/v1.5"
status="running"
startTime="2013-03-29T11:18:18.692+02:00"
serviceNamespace="com.vmware.vcloud"
operationName="vappSuspend"
operation="Suspending Virtual Application vApp Name(6943025b-dd0d-4b3b-bf7a-e23135a253a7)"
expiryTime="2013-06-27T11:18:18.692+03:00"
cancelRequested="false"
name="task"
id="urn:vcloud:task:c3deb787-4509-4f90-a05c-de8d258c16ac"
type="application/vnd.vmware.vcloud.task+xml"
href="https://vcloud.example.com/api/task/c3deb787-4509-4f90-a05c-de8d258c16ac"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.vmware.com/vcloud/v1.5 http://vcloud.example.com/api/v1.5/schema/master.xsd">
<Link
rel="task:cancel"
href="https://vcloud.example.com/api/task/c3deb787-4509-4f90-a05c-de8d258c16ac/action/cancel"/>
<Owner
type="application/vnd.vmware.vcloud.vApp+xml"
name="vApp Name"
href="https://vcloud.example.com/api/vApp/vapp-6943025b-dd0d-4b3b-bf7a-e23135a253a7"/>
<User
type="application/vnd.vmware.admin.user+xml"
name="system"
href="https://vcloud.example.com/api/admin/user/8fa42d37-5eda-43ed-ad8a-f005c625a96c"/>
<Organization
type="application/vnd.vmware.vcloud.org+xml"
name="Default"
href="https://vcloud.example.com/api/org/b5d81989-f274-4e55-9005-b53b48a158d1"/>
<Details/>
</Task>