v33

latestOpenAPI 3.1.0raw.githubusercontent.com2026-04-175267122.5 KB

Get instance resource utilization stats

Returns real-time resource utilization statistics for a running VM instance. Metrics are collected from /proc/<pid>/stat and /proc/<pid>/statm for CPU and memory, and from TAP interface statistics for network I/O.

get/instances/{id}/stats

Path parameters

idstring required

Instance ID or name

Response

Instance utilization statistics

instance_idstring required

Instance identifier

instance_namestring required

Instance name

cpu_secondsnumber double required

Total CPU time consumed by the VM hypervisor process in seconds

memory_rss_bytesinteger required

Resident Set Size - actual physical memory used by the VM in bytes

memory_vms_bytesinteger required

Virtual Memory Size - total virtual memory allocated in bytes

network_rx_bytesinteger required

Total network bytes received by the VM (from TAP interface)

network_tx_bytesinteger required

Total network bytes transmitted by the VM (from TAP interface)

allocated_vcpusinteger required

Number of vCPUs allocated to the VM

allocated_memory_bytesinteger required

Total memory allocated to the VM (Size + HotplugSize) in bytes

memory_utilization_rationumber double nullable

Memory utilization ratio (RSS / allocated memory). Only present when allocated_memory_bytes > 0.

Example response

{
  "instance_id": "qilviffnqzck2jrim1x6s2b1",
  "instance_name": "my-web-server",
  "cpu_seconds": 29.94,
  "memory_rss_bytes": 443338752,
  "memory_vms_bytes": 4330745856,
  "network_rx_bytes": 12345678,
  "network_tx_bytes": 87654321,
  "allocated_vcpus": 2,
  "allocated_memory_bytes": 4294967296,
  "memory_utilization_ratio": 0.103
}