Cosmic Admin API Reference
createVolume
Creates a disk volume from a disk offering. This disk volume must still be attached to a virtual machine to make use of it.
Request parameters
Parameter Name | Description | Required |
account | the account associated with the disk volume. Must be used with the domainId parameter. | false |
customid | an optional field, in case you want to set a custom id to the resource. Allowed to Root Admins only | false |
diskcontroller | the disk controller to use. Either 'IDE', 'VIRTIO' or 'SCSI' | false |
diskofferingid | the ID of the disk offering. Either diskOfferingId or snapshotId must be passed in. | false |
displayvolume | an optional field, whether to display the volume to the end user or not. | false |
domainid | the domain ID associated with the disk offering. If used with the account parameter returns the disk volume associated with the account for the specified domain. | false |
format | the disk format to use. Either 'QCOW2' or 'RAW' | false |
maxiops | max iops | false |
miniops | min iops | false |
name | the name of the disk volume | false |
projectid | the project associated with the volume. Mutually exclusive with account parameter | false |
size | Arbitrary volume size | false |
snapshotid | the snapshot ID for the disk volume. Either diskOfferingId or snapshotId must be passed in. | false |
virtualmachineid | the ID of the virtual machine; to be used with snapshot Id, VM to which the volume gets attached after creation | false |
zoneid | the ID of the availability zone | false |
Response Tags
Response Name | Description |
id | ID of the disk volume |
account | the account associated with the disk volume |
attached | the date the volume was attached to a VM instance |
chaininfo | the chain info of the volume |
created | the date the disk volume was created |
destroyed | the boolean state of whether the volume is destroyed or not |
deviceid | the ID of the device on user vm the volume is attahed to. This tag is not returned when the volume is detached. |
diskBytesReadRate | bytes read rate of the disk volume |
diskBytesWriteRate | bytes write rate of the disk volume |
diskcontroller | disk controller this volume is on |
diskIopsRatePerGb | io requests per GB |
diskIopsReadRate | io requests read rate of the disk volume |
diskIopsTotalRate | io requests total rate of the disk volume |
diskIopsWriteRate | io requests write rate of the disk volume |
diskofferingdisplaytext | the display text of the disk offering |
diskofferingid | ID of the disk offering |
diskofferingname | name of the disk offering |
displayvolume | an optional field whether to the display the volume to the end user or not. |
domain | the domain associated with the disk volume |
domainid | the ID of the domain associated with the disk volume |
format | format of the disk |
hypervisor | Hypervisor the volume belongs to |
isextractable | true if the volume is extractable, false otherwise |
isodisplaytext | an alternate display text of the ISO attached to the virtual machine |
isoid | the ID of the ISO attached to the virtual machine |
isoname | the name of the ISO attached to the virtual machine |
maxiops | max iops of the disk volume |
miniops | min iops of the disk volume |
name | name of the disk volume |
path | the path of the volume |
project | the project name of the vpn |
projectid | the project id of the vpn |
provisioningtype | provisioning type used to create volumes. |
serviceofferingdisplaytext | the display text of the service offering for root disk |
serviceofferingid | ID of the service offering for root disk |
serviceofferingname | name of the service offering for root disk |
size | size of the disk volume |
snapshotid | ID of the snapshot from which this volume was created |
state | the state of the disk volume |
status | the status of the volume |
storage | name of the primary storage hosting the disk volume |
storageid | id of the primary storage hosting the disk volume; returned to admin user only |
storagetype | shared or local storage |
templatedisplaytext | an alternate display text of the template for the virtual machine |
templateid | the ID of the template for the virtual machine. A -1 is returned if the virtual machine was created from an ISO file. |
templatename | the name of the template for the virtual machine |
type | type of the disk volume (ROOT or DATADISK) |
virtualmachineid | id of the virtual machine |
vmdisplayname | display name of the virtual machine |
vmname | name of the virtual machine |
vmstate | state of the virtual machine |
zoneid | ID of the availability zone |
zonename | name of the availability zone |
tags(*) | the list of resource tags associated with volume |
account | the account associated with the tag |
customer | customer associated with the tag |
domain | the domain associated with the tag |
domainid | the ID of the domain associated with the tag |
key | tag key name |
project | the project name where tag belongs to |
projectid | the project id the tag belongs to |
resourceid | id of the resource |
resourcetype | resource type |
value | tag value |
jobid | the ID of the latest async job acting on this object |
jobstatus | the current status of the latest async job acting on this object |