Virtual Machine
Create virtual machines
Creates one or more virtual machines with the specified custom configuration and features provided in the request body. For more information about the virtual machine features offered by Hyperstack, see Custom VM features.
post/core/virtual-machines
Request
- Base URL: https://infrahub-api.nexgencloud.com/v1
- URL: https://infrahub-api.nexgencloud.com/v1/core/virtual-machines
- Auth: API key in header api_key
Request body
Example request
{
"security_rules": [
{
"protocol": "any"
}
]
}Response
Virtual machine(s) created successfully.
Example response
{
"status": true,
"message": "VM is scheduled for creation.",
"instances": [
{
"id": 1402,
"name": "example-vm",
"status": "CREATING",
"environment": {
"id": 9876,
"name": "example-environment",
"org_id": 7613,
"region": "NORWAY-1",
"features": {
"green_status": "GREEN"
}
},
"image": {
"name": "Ubuntu Server 24.04 LTS (Noble Numbat)"
},
"flavor": {
"id": 8429,
"name": "n1-cpu-small",
"cpu": 4,
"ram": 4,
"disk": 100
},
"os": "Ubuntu Server 24.04 LTS (Noble Numbat)",
"keypair": {
"name": "example-keypair"
},
"volume_attachments": [
{
"volume": {
"id": 1402,
"name": "example-volume",
"description": "example",
"volume_type": "Cloud-SSD",
"size": 10
},
"status": "ATTACHING",
"device": "/dev/disk/by-id/virtio-a66fd1a8-e198-4eb4-a",
"created_at": "2026-05-06T16:04:09Z"
}
],
"security_rules": [
{
"id": 1129,
"direction": "egress",
"protocol": "any",
"port_range_min": 1,
"port_range_max": 65535,
"ethertype": "IPv4",
"remote_ip_prefix": "0.0.0.0/0",
"status": "SUCCESS",
"created_at": "2026-05-06T15:18:42Z"
}
],
"power_state": "NOSTATE",
"vm_state": "building",
"fixed_ip": "192.0.2.91",
"floating_ip": "203.0.113.205",
"floating_ip_status": "NO FLOATING IP",
"port_randomization_status": "NO_FLOATING_IP",
"port_randomization": true,
"created_at": "2026-05-06T16:04:09Z"
}
]
}Changes
No recorded changes to this operation across all 1 revision of this API.