Cosmic Domain Admin API Reference

deployVirtualMachine

Creates and automatically starts a virtual machine based on a service offering, disk offering, and template.

Request parameters

Parameter NameDescriptionRequired
serviceofferingidthe ID of the service offering for the virtual machinetrue
templateidthe ID of the template for the virtual machinetrue
zoneidavailability zone for the virtual machinetrue
accountan optional account for the virtual machine. Must be used with domainId.false
affinitygroupidscomma separated list of affinity groups id that are going to be applied to the virtual machine. Mutually exclusive with affinitygroupnames parameterfalse
affinitygroupnamescomma separated list of affinity groups names that are going to be applied to the virtual machine.Mutually exclusive with affinitygroupids parameterfalse
bootmenutimeoutTimeout (in ms) to for the boot menufalse
bootorderComma seperated list from which device to boot from first, can one of 'hd','cdrom','network'false
customidan optional field, in case you want to set a custom id to the resource. Allowed to Root Admins onlyfalse
deploymentplannerDeployment planner to use for vm allocation. Available to ROOT admin onlyfalse
detailsused to specify the custom parameters.false
diskcontrollerthe disk controller to use. Either 'IDE', 'VIRTIO' or 'SCSI'false
diskofferingidthe ID of the disk offering for the virtual machine. If the template is of ISO format, the diskOfferingId is for the root disk volume. Otherwise this parameter is used to indicate the offering for the data disk volume. If the templateId parameter passed is from a Template object, the diskOfferingId refers to a DATA Disk Volume created. If the templateId parameter passed is from an ISO object, the diskOfferingId refers to a ROOT Disk Volume created.false
displaynamean optional user generated name for the virtual machinefalse
displayvman optional field, whether to the display the vm to the end user or not.false
domainidan optional domainId for the virtual machine. If the account parameter is used, domainId must also be used.false
groupan optional group for the virtual machinefalse
hostiddestination Host ID to deploy the VM to - parameter available for root admin onlyfalse
hypervisorthe hypervisor on which to deploy the virtual machine. The parameter is required and respected only when hypervisor info is not set on the ISO/Template passed to the callfalse
ip6addressthe ipv6 address for default vm's networkfalse
ipaddressthe ip address for default vm's networkfalse
iptonetworklistip to network mapping. Can't be specified with networkIds parameter. Example: iptonetworklist[0].ip=10.10.10.11&iptonetworklist[0].ipv6=fc00:1234:5678::abcd&iptonetworklist[0].networkid=uuid - requests to use ip 10.10.10.11 in network id=uuidfalse
keyboardan optional keyboard device type for the virtual machine. valid value can be one of de,de-ch,es,fi,fr,fr-be,fr-ch,is,it,jp,nl-be,no,pt,uk,usfalse
keypairname of the ssh key pair used to login to the virtual machinefalse
macaddressthe MAC-Address for default vm's networkfalse
maintenancepolicyeither 'LiveMigrate' or 'ShutdownAndStart' when performing hypervisor maintenancefalse
manufacturerstringManufacturer String to put in hardware info, defaults to 'Mission Critical Cloud'false
namehost name for the virtual machinefalse
networkidslist of network ids used by virtual machine. Can't be specified with ipToNetworkList parameterfalse
optimiseforOptimise for 'Windows' or 'Generic'false
projectidDeploy vm for the projectfalse
rootdisksizeOptional field to resize root disk on deploy. Value is in GB. Only applies to template-based deployments. Analogous to details[0].rootdisksize, which takes precedence over this parameter if both are providedfalse
sizethe arbitrary size for the DATADISK volume. Mutually exclusive with diskOfferingIdfalse
startvmtrue if start vm after creating; defaulted to true if not specifiedfalse
userdataan optional binary data that can be sent to the virtual machine upon a successful deployment. This binary data must be base64 encoded before adding it to the request. Using HTTP GET (via querystring), you can send up to 2KB of data after base64 encoding. Using HTTP POST(via POST body), you can send up to 32K of data after base64 encoding.false

Response Tags

Response NameDescription
idthe ID of the virtual machine
accountthe account associated with the virtual machine
bootmenutimeoutTimeout of the boot menu (in ms)
bootorderBoot order priority
cpunumberthe number of cpu this virtual machine is running with
cpuusedthe amount of the vm's CPU currently used
createdthe date when this virtual machine was created
detailsVm details in key/value pairs.
diskioreadthe read (io) of disk on the vm
diskiowritethe write (io) of disk on the vm
diskkbsreadthe read (bytes) of disk on the vm
diskkbswritethe write (bytes) of disk on the vm
diskofferingidthe ID of the disk offering of the virtual machine
diskofferingnamethe name of the disk offering of the virtual machine
displaynameuser generated name. The name of the virtual machine is returned if no displayname exists.
displayvman optional field whether to the display the vm to the end user or not.
domainthe name of the domain in which the virtual machine exists
domainidthe ID of the domain in which the virtual machine exists
forvirtualnetworkthe virtual network for the service offering
groupthe group name of the virtual machine
groupidthe group ID of the virtual machine
guestosidOs type ID of the virtual machine
haenabletrue if high-availability is enabled, false otherwise
hostidthe ID of the host for the virtual machine
hostnamethe name of the host for the virtual machine
hypervisorthe hypervisor on which the template runs
instancenameinstance name of the user vm; this parameter is returned to the ROOT admin only
isdynamicallyscalabletrue if vm contains XS tools inorder to support dynamic scaling of VM cpu/memory.
isodisplaytextan alternate display text of the ISO attached to the virtual machine
isoidthe ID of the ISO attached to the virtual machine
isonamethe name of the ISO attached to the virtual machine
keypairssh key-pair
laststartdateTimestamp of last start of VM
laststartversionWhat Cosmic version did the VM start with
maintenancepolicyMaintenance Policy of the VM
manufacturerstringManufacturer String to put in hardware info, defaults to 'Mission Critical Cloud'
memorythe memory allocated for the virtual machine
namethe name of the virtual machine
networkkbsreadthe incoming network traffic on the vm
networkkbswritethe outgoing network traffic on the host
optimiseforOptimise for 'Windows' or 'Generic'
ostypeidOS type id of the vm
passwordthe password (if exists) of the virtual machine
passwordenabledtrue if the password rest feature is enabled, false otherwise
projectthe project name of the vm
projectidthe project id of the vm
publicippublic IP address id associated with vm via Static nat rule
publicipidpublic IP address id associated with vm via Static nat rule
restartrequiredtrue if VM needs to a stop/start to receive updated VM specs on the hypervisor
rootdevicecontrollercontroller type of the root volume
rootdeviceiddevice ID of the root volume
rootdevicetypedevice type of the root volume
serviceofferingidthe ID of the service offering of the virtual machine
serviceofferingnamethe name of the service offering of the virtual machine
servicestateState of the Service from LB rule
statethe state of the virtual machine
templatedisplaytext an alternate display text of the template for the virtual machine
templateidthe ID of the template for the virtual machine. A -1 is returned if the virtual machine was created from an ISO file.
templatenamethe name of the template for the virtual machine
useridthe user's ID who deployed the virtual machine
usernamethe user's name who deployed the virtual machine
vgputhe vgpu type used by the virtual machine
zoneidthe ID of the availablility zone for the virtual machine
zonenamethe name of the availability zone for the virtual machine
affinitygroup(*)list of affinity groups associated with the virtual machine
idthe ID of the affinity group
accountthe account owning the affinity group
descriptionthe description of the affinity group
domainthe domain name of the affinity group
domainidthe domain ID of the affinity group
namethe name of the affinity group
projectthe project name of the affinity group
projectidthe project ID of the affinity group
typethe type of the affinity group
virtualmachineIdsvirtual machine IDs associated with this affinity group
nic(*)the list of nics associated with vm
idthe ID of the nic
broadcasturithe broadcast uri of the nic
gatewaythe gateway of the nic
ip6addressthe IPv6 address of network
ip6cidrthe cidr of IPv6 network
ip6gatewaythe gateway of IPv6 network
ipaddressthe ip address of the nic
isdefaulttrue if nic is default, false otherwise
isolationurithe isolation uri of the nic
macaddresstrue if nic is default, false otherwise
mirroripaddressthe mirror ip address for the nic
mirrorkeythe mirror key for the nic
netmaskthe netmask of the nic
networkidthe ID of the corresponding network
networknamethe name of the corresponding network
secondaryipthe Secondary ipv4 addr of nic
traffictypethe traffic type of the nic
typethe type of the nic
virtualmachineidId of the vm to which the nic belongs
tags(*)the list of resource tags associated with vm
accountthe account associated with the tag
customercustomer associated with the tag
domainthe domain associated with the tag
domainidthe ID of the domain associated with the tag
keytag key name
projectthe project name where tag belongs to
projectidthe project id the tag belongs to
resourceidid of the resource
resourcetyperesource type
valuetag value
jobidthe ID of the latest async job acting on this object
jobstatusthe current status of the latest async job acting on this object