Maszyny wirtualne

Resize a VM

POST
/cloud/project/{project_uuid}/vm/{vmid}/upgrade/

Changes CPU, RAM, OS disk, CPU class, and public/private networking on an existing VM. After the VM is created or CPU, RAM, or CPU class is increased, you can lower those resources 24 hours later. CPU or RAM downgrade is allowed only while the VM is stopped. OS disk size cannot shrink. You cannot switch between attached WAN modes (ipv4 / ipv6 / dual); disable WAN first.

Authorization

bearerAuth
AuthorizationBearer <token>

API key created in the portal (Settings → API Keys). Send as Authorization: Bearer <key>.

In: header

Path Parameters

project_uuid*string

Project UUID.

vmid*integer

VM identifier (VMID).

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Resize CPU, RAM, disk, CPU class, and networking on an existing VM.

Response Body

application/json

curl -X POST "https://example.com/cloud/project/string/vm/0/upgrade/" \  -H "Content-Type: application/json" \  -d '{    "cores": 2,    "ram_gb": 1,    "os_disk_gb": 10,    "wan_mode": "off"  }'
{  "message": "string"}