GET https://ark.cn-beijing.volces.com/api/v3/sandbox_instances/{id}/metrics
查询单个独立沙箱实例的资源采样时间序列,可按时间范围过滤。返回按采样时间排列的 CPU、内存和磁盘指标。
鉴权#
本接口支持鉴权方式如下,详情请参见 Base URL 及鉴权。
- API Key 鉴权,请在 API Key 管理 页面,获取长效 API Key。
请求参数#
Path 参数#
id string 必选 | 实例 ID
沙箱实例 ID,如 sbi- 开头。
Query 参数#
在 URL Query String 中传入。
end integer | 结束时间
结束时间,Unix 时间戳,单位为秒。
最小值:0
start integer | 起始时间
起始时间,Unix 时间戳,单位为秒。
最小值:0
响应参数#
data object[] | 指标采样
指标采样数组,按采样时间排列。没有可用样本时为空数组。
cpu_count number | CPU 核数
data.cpu_count
cpu_used_pct number | CPU 使用率
data.cpu_used_pct
CPU 使用率百分比。
disk_total number | 总磁盘
data.disk_total
总磁盘空间,单位字节。
disk_used number | 已用磁盘
data.disk_used
已用磁盘空间,单位字节。
mem_total number | 总内存
data.mem_total
总内存,单位字节。
mem_used number | 已用内存
data.mem_used
已用内存,单位字节。
mem_cache number | 缓存内存
data.mem_cache
缓存内存,单位字节。
timestamp string | 采样时间
data.timestamp
采样时间,ISO 8601 格式。
timestamp_unix number | 采样时间戳
data.timestamp_unix
采样时间,Unix 时间戳(秒)。