Skip to navigation

Get cloud VM metrics

Returns current resource-usage metrics for a cloud VM. Requires scope: vm.read.

# Example request with curl (set IBEE_API_TOKEN to a platform API token and WORKSPACE_ID to the workspace first).
# VM_ID: Virtual machine ID
curl "https://api.ibee.ai/v1/compute/cloud-vms/$VM_ID/metrics?workspace_id=$WORKSPACE_ID" \
-H "Authorization: Bearer $IBEE_API_TOKEN"

Authentication

AuthorizationBearer

IBEE platform API token. Production tokens start with ibee_prod_key_; development tokens start with ibee_dev_key_. Use a token only with its matching gateway environment.

Path parameters

vm_idstringRequired
Virtual machine ID.

Query parameters

workspace_idstringRequiredformat: "^[1-9][0-9]*$">=1 character

The positive numeric workspace ID to scope this request to. Zero, negative, and non-numeric values are rejected.

Response

VM metrics returned successfully.
vm_idstring
ID of the VM.
vm_typeenum
  • cloud
  • gpu
Allowed values:
power_statestring

Power state observed on the host when the sample was taken: running, stopped, paused, suspended, blocked, crashed or unknown.

monitoring_statusenum
  • active: a recent sample exists.
  • stale: the last sample is older than the freshness threshold.
  • unavailable: no sample has been collected.
Allowed values:
month_rx_bytesintegerDefaults to 0
Bytes received so far in the current calendar month.
month_tx_bytesintegerDefaults to 0
Bytes transmitted so far in the current calendar month.
last_collected_atdatetime or nullOptional

When the sample was collected (ISO 8601).

cpu_percentdouble or nullOptional

CPU utilisation, 0-100.

memory_used_bytesinteger or nullOptional
Memory in use, in bytes.
memory_used_percentdouble or nullOptional

Memory in use as a percentage of the VM’s memory, 0-100.

storage_used_bytesinteger or nullOptional
Disk space in use, in bytes.
storage_total_bytesinteger or nullOptional
Disk capacity visible to the guest, in bytes.
storage_used_percentdouble or nullOptional

Disk space in use as a percentage of storage_total_bytes, 0-100.

storage_provisioned_bytesinteger or nullOptional
Disk capacity provisioned for the VM, in bytes.
disk_read_bpsdouble or nullOptional
Disk read throughput in bytes per second.
disk_write_bpsdouble or nullOptional
Disk write throughput in bytes per second.
disk_read_iopsdouble or nullOptional
Disk read operations per second.
disk_write_iopsdouble or nullOptional
Disk write operations per second.
net_rx_bpsdouble or nullOptional
Network receive rate in bytes per second.
net_tx_bpsdouble or nullOptional
Network transmit rate in bytes per second.

Errors

401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
413
Content Too Large Error
422
Unprocessable Entity Error
429
Too Many Requests Error
500
Internal Server Error
502
Bad Gateway Error
503
Service Unavailable Error
504
Gateway Timeout Error