VPS: Virtual machine
Setup purchased virtual machine
Setup newly purchased virtual machine with initial state.
Use this endpoint to configure and initialize purchased VPS instances.
post/api/vps/v1/virtual-machines/{virtualMachineId}/setup
Path parameters
virtualMachineIdinteger required
Example:1268054
Virtual Machine ID
Request body
Example request
{
"template_id": 1130,
"data_center_id": 19,
"post_install_script_id": 6324,
"password": "oMeNRustosIO",
"hostname": "my.server.tld",
"enable_backups": true,
"ns1": "4.3.2.1",
"ns2": "1.2.3.4",
"public_key": {
"name": "my-key",
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC2X..."
}
}Response
Success response
Example response
{
"id": 17923,
"subscription_id": "Azz353Uhl1xC54pR0",
"data_center_id": 521,
"plan": "KVM 4",
"hostname": "srv17923.hstgr.cloud",
"state": "running",
"actions_lock": "unlocked",
"cpus": 4,
"memory": 8192,
"disk": 51200,
"bandwidth": 1073741824,
"ns1": "1.1.1.1",
"ns2": "8.8.8.8",
"ipv4": [
{
"id": 52347,
"address": "213.331.273.15",
"ptr": "something.domain.tld"
}
],
"ipv6": [
{
"id": 52347,
"address": "213.331.273.15",
"ptr": "something.domain.tld"
}
],
"template": {
"id": 6523,
"name": "Ubuntu 20.04 LTS",
"description": "Ubuntu 20.04 LTS",
"documentation": "https://docs.ubuntu.com"
},
"created_at": "2024-09-05T07:25:36.00000Z"
}