VMware Cloud Director API - Task

VMware Cloud Director API - Task

TaskType

Element:
Task
Type:
TaskType
Namespace:
http://www.vmware.com/vcloud/v1.5
Description:
Represents an asynchronous operation in vCloud Director.
Since:
0.9
Schema:
task.xsd
Media type(s):
application/vnd.vmware.vcloud.task+json
application/vnd.vmware.vcloud.task+xml
Extends:
EntityType
XML Representation:
<Task xmlns="http://www.vmware.com/vcloud/v1.5" href="xs:anyURI" type="xs:string" id="xs:string" operationKey="xs:string"
        name="xs:string" status="xs:string" operation="xs:string" operationName="xs:string"
        serviceNamespace="xs:string" startTime="xs:dateTime" endTime="xs:dateTime" expiryTime="xs:dateTime"
        cancelRequested="xs:boolean">
    <Link href="xs:anyURI" id="xs:string" type="xs:string" name="xs:string"
            rel="xs:string" model="xs:string"/>
    <Description> xs:string </Description>
    <Tasks>
        <Task> TaskType </Task>
    </Tasks>
    <Owner href="xs:anyURI" id="xs:string" type="xs:string" name="xs:string"/>
    <Error stackTrace="xs:string" message="xs:string" majorErrorCode="xs:int" minorErrorCode="xs:string"
            vendorSpecificErrorCode="xs:string">
        <TenantError message="xs:string" majorErrorCode="xs:int" minorErrorCode="xs:string" vendorSpecificErrorCode="xs:string"/>
    </Error>
    <User href="xs:anyURI" id="xs:string" type="xs:string" name="xs:string"/>
    <Organization href="xs:anyURI" id="xs:string" type="xs:string" name="xs:string"/>
    <Progress> xs:int </Progress>
    <Params> ... </Params>
    <Details> xs:string </Details>
    <VcTaskList>
        <VcTask name="xs:string" moref="xs:string" status="xs:string" description="xs:string"
                errorMessage="xs:string" objectName="xs:string" objectType="xs:string" objectMoref="xs:string"
                virtualCenterID="xs:string" startTime="xs:dateTime" endTime="xs:dateTime"/>
    </VcTaskList>
    <Result>
        <ResultContent> ... </ResultContent>
        <ResultReference href="xs:anyURI" id="xs:string" type="xs:string" name="xs:string"/>
    </Result>
</Task>

Attributes

Attribute Type Required Modifiable Since Deprecated Description
href anyURI No always 0.9 The URI of the entity.
type string No always 0.9 The MIME type of the entity.
id string No none 0.9 The entity identifier, expressed in URN format. The value of this attribute uniquely identifies the entity, persists for the life of the entity, and is never reused.
operationKey string No create 5.1 Optional unique identifier to support idempotent semantics for create and delete operations.
name string Yes always 0.9 The name of the entity.
status string Yes none 0.9 The execution status of the task. One of:
queued (The task has been queued for execution)
preRunning (The task is awaiting preprocessing or administrative action.)
running (The task is running.)
success (The task completed with a status of success.)
error (The task encountered an error while running.)
aborted (The task was aborted by an administrative action.)
operation string No always 0.9 A message describing the operation that is tracked by this task.
operationName string No none 0.9 The short name of the operation that is tracked by this task.
serviceNamespace string No create 5.1 Identifier of the service that created the task. It must not start with com.vmware.vcloud and the length must be between 1 and 128 symbols.
startTime dateTime No none 0.9 The date and time the system started executing the task. May not be present if the task has not been executed yet.
endTime dateTime No none 0.9 The date and time that processing of the task was completed. May not be present if the task is still being executed.
expiryTime dateTime No none 0.9 The date and time at which the task resource will be destroyed and no longer available for retrieval. May not be present if the task has not been executed or is still being executed.
cancelRequested boolean No none 5.1 Whether user has requested this processing to be canceled.

Elements

Element Type Required Modifiable Since Deprecated Description
Description string No always 0.9 Optional description.
Details string No always 5.1 Detailed message about the task. Also contained by the Owner entity when task status is preRunning.
Error ErrorType No always 0.9 Represents error information from a failed task.
Link LinkType No none 0.9 A reference to an entity or operation associated with this object.
Organization ReferenceType No none 1.5 The organization to which the User belongs.
Owner ReferenceType No create 0.9 Reference to the owner of the task. This is typically the object that the task is creating or updating.
Params anyType No none 1.5 The parameters with which this task was started.
Progress int No none 1.5 Read-only indicator of task progress as an approximate percentage between 0 and 100. Not available for all tasks.
Result ResultType No always 13.0 An optional element that can be used to hold the result of a task.
Tasks TasksInProgressType No none 0.9 A list of queued, running, or recently completed tasks associated with this entity.
User ReferenceType No create 1.5 The user who started the task.
VCloudExtension VCloudExtensionType No always 0.9 An optional extension element that can contain an arbitrary number of elements and attributes. Not related to extension services.
VcTaskList VcTaskListType No none 33.0 List of Virtual Center tasks related to this vCD task.

Operations

CRUD Operation Description Since Deprecated
create POST /admin/catalog/{id}/metadata Merge the metadata provided in the request with existing metadata. 1.5
create POST /admin/edgeGateway/{id}/action/configureServices Update edgeGateway configuration. 5.1 33.0
create POST /admin/edgeGateway/{id}/action/configureSyslogServerSettings Configure Syslog server settings for the org vdc edge gateway 5.11
create POST /admin/edgeGateway/{id}/action/convertToAdvancedGateway Mark a gateway as an advanced gateway. 27.0 9.7
create POST /admin/edgeGateway/{id}/action/disableDistributedRouting Disable distributed routing for a gateway 29.0
create POST /admin/edgeGateway/{id}/action/enableDistributedRouting Enable distributed routing for a gateway 29.0
create POST /admin/edgeGateway/{id}/action/modifyFormFactor Modify edgeGateway form factor. 11.0
create POST /admin/edgeGateway/{id}/action/reapplyServices Reapply services on an edgeGateway. 5.1 32.0
create POST /admin/edgeGateway/{id}/action/redeploy Redeploy edgeGateway. 5.1
create POST /admin/edgeGateway/{id}/action/syncSyslogServerSettings Synchronize syslog server settings on an edgeGateway. 5.1
create POST /admin/edgeGateway/{id}/action/upgradeConfig Upgrades the edge gateway appliance size. 5.1
create POST /admin/edgeGateway/{id}/metadata Sets all the metadata for the specified gateway. 35.0
create POST /admin/extension/action/migrateTenant Initiate relocation of all entities for a given org (tenant). 29.0
create POST /admin/extension/networkPool/{id}/action/repair Repair a network pool. 32.0 35.0
create POST /admin/extension/networkPool/{id}/action/sync Sync a network pool. 32.0 35.0
create POST /admin/extension/providervdc/{id}/action/merge Merge provider vDCs. 5.1
create POST /admin/extension/providervdc/{id}/action/updateResourcePools Add or remove provider vDC resource pools. 1.5
create POST /admin/extension/providervdc/{id}/storageProfiles Update storage classes of a provider vDC. 5.1
create POST /admin/extension/resourcePool/{id}/action/migrateVms Migrate one or more virtual machines to a different resource pool. 5.1
create POST /admin/extension/resourcePool/{rpId}/rules Create VM Affinity Rules within this resource pool.
create POST /admin/extension/resourcePool/{rpId}/vmGroups Create VM group within this resource pool.
create POST /admin/extension/rule/{ruleId}/action/disable Disables the specified VM Host affinity rule.
create POST /admin/extension/rule/{ruleId}/action/enable Enables the specified VM Host affinity rule.
create POST /admin/extension/rule/{ruleId}/action/makeMandatory Make specified VM Host affinity rule mandatory.
create POST /admin/extension/rule/{ruleId}/action/makeOptional Make the specified VM Host affinity optional.
create POST /admin/extension/strandedItem/{id}/action/forceDelete Removes stranded item and its children 5.1
create POST /admin/extension/vimServer/{id}/action/forcevimserverreconnect Force vCloud Director to reconnect to a registered vCenter server. 1.0
create POST /admin/extension/vimServer/{id}/action/refresh Refresh vCenter server. 5.1
create POST /admin/extension/vimServer/{id}/action/refreshStorageProfiles Refresh Storage Classes data from a registered vCenter server. 5.1
create POST /admin/extension/vimServer/{id}/action/unregister Unregister a vCenter server. 1.0 34.0
create POST /admin/extension/vimServer/{id}/importVmIntoExistingVApp Import a virtual machine from vCenter into an existing vCloud Director vApp. 1.5
create POST /admin/extension/vmGroup/name/{groupName}/action/addVms Adds virtual machines to the specified VM group.
create POST /admin/extension/vmGroup/name/{groupName}/action/removeVms Removes virtual machines from the specified VM group.
create POST /admin/network/{id}/action/convertToDistributedInterface Convert org vdc network to a distributed interface

This operation is valid for internal org vdc routed networks that are subinterfaces or internal.

29.0 35.0
create POST /admin/network/{id}/action/convertToInternalInterface Convert org vdc network to an interface

This operation is valid for internal org vdc routed networks that are subinterfaces

27.0 35.0
create POST /admin/network/{id}/action/convertToSubInterface Convert org vdc network to an sub interface

This operation is valid for internal org vdc routed networks

27.0 35.0
create POST /admin/network/{id}/action/reset Reset networking services on a network. 1.5
create POST /admin/network/{id}/action/syncSyslogServerSettings Synchronize syslog server settings for a network. 1.5
create POST /admin/network/{id}/metadata Merge the metadata provided in the request with existing metadata. 1.5
create POST /admin/org/{id}/associations/localAssociationData/action/regenerateKeyPair Regenerates an org's key pair for associations
create POST /admin/org/{id}/metadata Merge the metadata provided in the request with existing metadata. 1.5
create POST /admin/org/{id}/settings/vAppLeaseSettings/action/expireVAppsRuntimeLease
create POST /admin/org/{id}/settings/vAppLeaseSettings/action/expireVAppsStorageLease
create POST /admin/org/{id}/settings/vAppTemplateLeaseSettings/action/expireVAppTemplatesStorageLease
create POST /admin/providervdc/{id}/metadata Merge the metadata provided in the request with existing metadata. 1.5
create POST /admin/pvdcStorageProfile/{id}/metadata Merge the metadata provided in the request with existing metadata.
create POST /admin/vdc/{id}/action/registerVApp Create a vApp based on a set of .vmx files and resource mappings 5.5
create POST /admin/vdc/{id}/metadata Merge the metadata provided in the request with existing metadata. 1.5
create POST /admin/vdc/{id}/vdcStorageProfiles Add or remove virtual datacenter storage classes.
create POST /admin/vdcStorageProfile/{id}/metadata Merge the metadata provided in the request with existing metadata.
create POST /catalog/{id}/action/captureVApp Create a vApp template in this catalog from a vApp. 5.5
create POST /catalog/{id}/action/copy Copy a catalog item from one catalog to another. 5.5
create POST /catalog/{id}/action/move Move a catalog item from one catalog to another. 5.5
create POST /catalog/{id}/action/sync Force sync the catalog to the remote subscribed catalog. 5.5
create POST /catalogItem/{id}/action/sync Synchronize a catalog item with its source object. 5.5
create POST /catalogItem/{id}/metadata Merge the metadata provided in the request with existing catalog item metadata. 1.5
create POST /disk/{id}/action/moveDisk Move a disk to a different Org VDC. 36.0
create POST /disk/{id}/metadata Merge the metadata provided in the request with existing metadata. 5.1
create POST /media/{id}/action/enableDownload Enable download for the media 5.5
create POST /media/{id}/metadata Merge the metadata provided in the request with existing metadata. 1.5
create POST /org/{id}/action/instantiate Instantiates a VDC template. 5.7
create POST /site/associations Add a new {@link SiteAssociationType} for this site.
create POST /site/associations/localAssociationData/action/regenerateKeyPair Add a new {@link SiteAssociationType} for this site.
create POST /tasksList/{id} Post an external task to this organization.
create POST /vApp/{id}/action/bootOptions
create POST /vApp/{id}/action/changeReplicationTrackingSettings
create POST /vApp/{id}/action/checkCompliance Check storage profile compliance for the specified VM. 5.1
create POST /vApp/{id}/action/checkComputePolicyCompliance Check VM's compute policy compliance 33.0
create POST /vApp/{id}/action/consolidate Consolidate VM snapshots. 1.5
create POST /vApp/{id}/action/convertStandAloneVmToVApp Convert a stand alone VM into a single VM VApp. 35.0
create POST /vApp/{id}/action/convertToReplicationTrackingVm
create POST /vApp/{id}/action/createSnapshot Creates new snapshot of a virtual machine or of all the virtual machines in a vApp. 5.1
create POST /vApp/{id}/action/deploy Deploy a vApp or VM. 0.9
create POST /vApp/{id}/action/disableNestedHypervisor Hide hardware-assisted CPU virtualization from guest OS. 5.1
create POST /vApp/{id}/action/discardSuspendedState Discard suspended state of a vApp or VM. 0.9
create POST /vApp/{id}/action/editTrustedPlatformModule
create POST /vApp/{id}/action/enableDownload Enable a vApp for download. 5.5
create POST /vApp/{id}/action/enableNestedHypervisor Expose hardware-assisted CPU virtualization to guest OS. 5.1
create POST /vApp/{id}/action/failover Promote a replication tracking VM to a standard VM
create POST /vApp/{id}/action/installVMwareTools Install VMware Tools on a running VM. 1.5
create POST /vApp/{id}/action/reapplyComputePolicy Reapplies existing vdcComputePolicy to a VM 33.0
create POST /vApp/{id}/action/recomposeVApp Recompose a vApp to add or remove VMs. 1.0
create POST /vApp/{id}/action/reconfigureVm Updates Vm name, Description, and any or all of the following sections.
  • VirtualHardwareSection
  • OperatingSystemSection
  • NetworkConnectionSection
  • GuestCustomizationSection
Sections not included in the request body will not be updated.
5.1
create POST /vApp/{id}/action/reloadFromVc Reloads VM state from VC. 5.6
create POST /vApp/{id}/action/removeAllSnapshots Removes all user created snapshots for a vApp or virtual machine. 5.1
create POST /vApp/{id}/action/revertToCurrentSnapshot Reverts