CloudStack v2.2.13 - 2.2.14 User API Reference

createTemplate

Creates a template of a virtual machine. The virtual machine must be in a STOPPED state. A template created from this command is automatically designated as a private template visible to the account that created it.

Request parameters

Parameter NameDescriptionRequired
displaytextthe display text of the template. This is usually used for display purposes.true
namethe name of the templatetrue
ostypeidthe ID of the OS Type that best represents the OS of this template.true
bits32 or 64 bitfalse
detailsTemplate details in key/value pairs.false
isfeaturedtrue if this template is a featured template, false otherwisefalse
ispublictrue if this template is a public template, false otherwisefalse
passwordenabledtrue if the template supports the password reset feature; default is falsefalse
requireshvmtrue if the template requres HVM, false otherwisefalse
snapshotidthe ID of the snapshot the template is being created from. Either this parameter, or volumeId has to be passed infalse
templatetagthe tag for this template.false
urlOptional, only for baremetal hypervisor. The directory name where template stored on CIFS serverfalse
virtualmachineidOptional, VM ID. If this presents, it is going to create a baremetal template for VM this ID refers to. This is only for VM whose hypervisor type is BareMetalfalse
volumeidthe ID of the disk volume the template is being created from. Either this parameter, or snapshotId has to be passed infalse

Response Tags

Response NameDescription
idthe ID of the storage pool
clusteridthe ID of the cluster for the storage pool
clusternamethe name of the cluster for the storage pool
createdthe date and time the storage pool was created
disksizeallocatedthe host's currently allocated disk size
disksizetotalthe total disk size of the storage pool
disksizeusedthe host's currently used disk size
ipaddressthe IP address of the storage pool
namethe name of the storage pool
paththe storage pool path
podidthe Pod ID of the storage pool
podnamethe Pod name of the storage pool
statethe state of the storage pool
tagsthe tags for the storage pool
typethe storage pool type
zoneidthe Zone ID of the storage pool
zonenamethe Zone name of the storage pool