Skip to content

Example for VM export via REST API #1

Open
@ddemlow

Description

@ddemlow

This example worked for me using REST API Docs "try it" for export of a specific virdomain UUID

curl -X POST "https://10.205.15.70/rest/v1/VirDomain/dc691643-4b44-4929-b3d7-484d2f72ffe3/export" -H "accept: application/json" -H "Content-Type: application/json" -d "{\"target\":{\"pathURI\":\"smb://administrator:[email protected]/exports/export-example\",\"definitionFileName\":\"export-example.xml\",\"compress\":true}}"

the json body used which specifies the smb path and credentials used to store the exported VM. Note that for import to work - the folder /export-example here must match the definition file name base - export-example.xml. Generally this would be the VM name for both if the export was triggered from the HC3 UI but that is not required.

 { 
	 "target": { 
		 "pathURI": "smb://administrator:[email protected]/exports/export-example", 
		 "definitionFileName": "export-example.xml", 
		 "compress": true
		 				 }
 }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions