Apache CloudStack 4.16.0.0 Root Admin API Reference

registerTemplate

Registers an existing template into the CloudStack cloud.

Request parameters

Parameter NameDescriptionRequired
displaytextthe display text of the template. This is usually used for display purposes.true
formatthe format for the template. Possible values include QCOW2, RAW, VHD and OVA.true
hypervisorthe target hypervisor for the templatetrue
namethe name of the templatetrue
urlthe URL of where the template is hosted. Possible URL include http:// and https://true
accountan optional accountName. Must be used with domainId.false
bits32 or 64 bits support. 64 by defaultfalse
checksumthe checksum value of this template. The parameter containing the checksum will be considered a MD5sum if it is not prefixed and just a plain ascii/utf8 representation of a hexadecimal string. If it is required to use another algorithm the hexadecimal string is to be prefixed with a string of the form, "{<algorithm>}", not including the double quotes. In this <algorithm> is the exact string representing the java supported algorithm, i.e. MD5 or SHA-256. Note that java does not contain an algorithm called SHA256 or one called sha-256, only SHA-256.false
deployasis(VMware only) true if VM deployments should preserve all the configurations defined for this templatefalse
detailsTemplate details in key/value pairs using format details[i].keyname=keyvalue. Example: details[0].hypervisortoolsversion=xenserver61false
directdownloadtrue if template should bypass Secondary Storage and be downloaded to Primary Storage on deploymentfalse
domainidan optional domainId. If the account parameter is used, domainId must also be used.false
isdynamicallyscalabletrue if template contains XS/VMWare tools inorder to support dynamic scaling of VM cpu/memoryfalse
isextractabletrue if the template or its derivatives are extractable; default is falsefalse
isfeaturedtrue if this template is a featured template, false otherwisefalse
ispublictrue if the template is available to all accounts; default is truefalse
isroutingtrue if the template type is routing i.e., if template is used to deploy routerfalse
ostypeidthe ID of the OS Type that best represents the OS of this template. Not applicable with VMware, as we honour what is defined in the templatefalse
passwordenabledtrue if the template supports the password reset feature; default is falsefalse
projectidRegister template for the projectfalse
requireshvmtrue if this template requires HVMfalse
sshkeyenabledtrue if the template supports the sshkey upload feature; default is falsefalse
templatetagthe tag for this template.false
zoneidthe ID of the zone the template is to be hosted onfalse
zoneidsA list of zone ids where the template will be hosted. Use this parameter if the template needs to be registered to multiple zones in one go. Use zoneid if the template needs to be registered to only one zone.Passing only -1 to this will cause the template to be registered as a cross zone template and will be copied to all zones. false

Response Tags

Response NameDescription
idthe template ID
accountthe account name to which the template belongs
accountidthe account id to which the template belongs
bitsthe processor bit size
bootabletrue if the ISO is bootable, false otherwise
checksumchecksum of the template
childtemplatesif root disk template, then ids of the datas disk templates this template owns
createdthe date this template was created
crossZonestrue if the template is managed across all Zones, false otherwise
deployasisVMware only: true if template is deployed without orchestrating disks and networks but "as-is" defined in the template.
deployasisdetailsVMware only: additional key/value details tied with deploy-as-is template
detailsadditional key/value details tied with template
directdownloadKVM Only: true if template is directly downloaded to Primary Storage bypassing Secondary Storage
displaytextthe template display text
domainthe name of the domain to which the template belongs
domainidthe ID of the domain to which the template belongs
downloaddetailsLists the download progress of a template across all secondary storages
formatthe format of the template.
hostidthe ID of the secondary storage host for the template
hostnamethe name of the secondary storage host for the template
hypervisorthe hypervisor on which the template runs
iconBase64 string representation of the resource icon
isdynamicallyscalabletrue if template contains XS/VMWare tools inorder to support dynamic scaling of VM cpu/memory
isextractabletrue if the template is extractable, false otherwise
isfeaturedtrue if this template is a featured template, false otherwise
ispublictrue if this template is a public template, false otherwise
isreadytrue if the template is ready to be deployed from, false otherwise.
namethe template name
ostypeidthe ID of the OS type for this template.
ostypenamethe name of the OS type for this template.
parenttemplateidif Datadisk template, then id of the root disk template this template belongs to
passwordenabledtrue if the reset password feature is enabled, false otherwise
physicalsizethe physical size of the template
projectthe project name of the template
projectidthe project id of the template
removedthe date this template was removed
requireshvmtrue if template requires HVM enabled, false otherwise
sizethe size of the template
sourcetemplateidthe template ID of the parent template if present
sshkeyenabledtrue if template is sshkey enabled, false otherwise
statusthe status of the template
templatetagthe tag of this template
templatetypethe type of the template
urlthe URL which the template/iso is registered from
zoneidthe ID of the zone for this template
zonenamethe name of the zone for this template
jobidthe ID of the latest async job acting on this object
jobstatusthe current status of the latest async job acting on this object