Product SiteDocumentation Site

14.6.7.  Export Action

The export action exports a virtual machine to an export storage domain. A destination storage domain must be specified with a storage_domain reference. By default, the export action will not overwrite any existing virtual machine of the same name in the destination domain. An API user changes this behaviour by setting the overwrite parameter to true. Finally, if snapshots of the virtual machine should not be included in the exported virtual machine, the discard_snapshots parameter may be set to true.
Example 14.16. Action to export a virtual machine to an export storage domain
POST /rhevm-api/vms/5114bb3e-a4e6-44b2-b783-b3eea7d84720/export HTTP/1.1
Content-type: application/xml

<action>
    <storage_domain>
        <name>export1</name>
    </storage_domain>
    <overwrite>true<overwrite/>
    <discard_snapshots>true<discard_snapshots/>
</action>