查询云手机规格列表 - ListCloudPhoneModels
功能介绍
查询或统计云手机的规格列表。
调试
您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。
授权信息
账号具备所有API的调用权限,如果使用账号下的IAM用户调用当前API,该IAM用户需具备调用API所需的权限,具体权限要求请参见权限和授权项。
URI
GET /v1/{project_id}/cloud-phone/phone-models
|
参数 |
是否必选 |
参数类型 |
描述 |
|---|---|---|---|
|
project_id |
是 |
String |
项目id。 |
|
参数 |
是否必选 |
参数类型 |
描述 |
|---|---|---|---|
|
status |
否 |
Integer |
规格状态
不传该参数表示查询所有状态的规格。 |
|
offset |
否 |
Integer |
偏移量为一个大于等于0整数,表示查询该偏移量后面的所有的资源数,默认值为0。 |
|
limit |
否 |
Integer |
每页返回的资源个数。取值范围:1~100(默认值为100),一般设置为10、20、50。 |
请求参数
|
参数 |
是否必选 |
参数类型 |
描述 |
|---|---|---|---|
|
X-Auth-Token |
是 |
String |
用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 |
响应参数
状态码:200
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
request_id |
String |
请求的唯一标识ID。 |
|
phone_models |
Array of PhoneModel objects |
云手机的规格信息。 |
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
server_model_name |
String |
云手机服务器的规格名称,不超过64个字节。 |
|
phone_model_name |
String |
云手机的规格名称,不超过64个字节。 |
|
status |
Integer |
规格状态。
已下线的规格不可用来购买云手机服务器 |
|
cpu |
Integer |
CPU核数。 |
|
memory |
Integer |
内存大小,单位:MB。 |
|
disk |
Integer |
系统存储大小,单位:GiB。 |
|
resolution |
String |
分辨率,不超过16个字节。 |
|
extend_spec |
String |
扩展描述,不超过512个字节。 |
|
spec_code |
String |
规格名称,不超过64个字节。 |
|
phone_capacity |
Integer |
当前云手机规格包含的云手机个数。 |
|
image_label |
String |
镜像类型,只支持如下类型:
|
|
product_type |
Integer |
产品类型。
|
|
phone_model_version |
Integer |
规格版本:
|
|
dpi |
Integer |
每英寸点数。 |
|
fps |
String |
渲染帧率。 |
|
volume_mode |
Integer |
手机物理磁盘是否独立。
|
|
render_fps |
Integer |
渲染帧率。 |
|
stream_fps |
Integer |
出流帧率。 |
请求示例
查询手机规格列表
GET https://{CPH Endpoint}/v1/{project_id}/cloud-phone/phone-models
响应示例
状态码:200
OK
{
"phone_models" : [ {
"server_model_name" : "physical.rx1.xlarge",
"phone_model_name" : "rx1.cp.c60.d32.e1v1.qemu",
"status" : 1,
"cpu" : 2,
"memory" : 3072,
"disk" : 32,
"resolution" : "540x960",
"render_fps" : 60,
"stream_fps" : 60,
"extend_spec" : "{\"eip_count\": 1, \"vip_count\":1, \"emulator_type\":0, \"bms_image_id\":\"72460777-7fcb-4cae-8bb5-62d93be86bd7\",\"core_bind_strategy\":\"lxc_qemu_common_hosted_c60\", \"sd_disk\": 1}",
"spec_code" : "rx1.cp.c60.d32.e1v1.qemu",
"phone_capacity" : 60,
"image_label" : "qemu_phone",
"product_type" : 0
}, {
"server_model_name" : "physical.rx1.xlarge",
"phone_model_name" : "rx1.cp.c60.d10.e1v1",
"status" : 1,
"cpu" : 2,
"memory" : 3584,
"disk" : 10,
"resolution" : "720x1280",
"render_fps" : 60,
"stream_fps" : 60,
"extend_spec" : "{\"eip_count\": 1, \"vip_count\":1, \"emulator_type\":1,\"thinpool_size_g\":70, \"sharepool_size_g\":650,\"max_share_disk_size_g\":50,\"encode_server_spec\": {\"cpu\": 2,\"memory\": 14448,\"disk\": 10,\"image_id\":\"coderserver_v2.5\", \"port_num\":0},\"core_bind_strategy\":\"common_hosted_c60\"}",
"spec_code" : "rx1.cp.c60.d10.e1v1",
"phone_capacity" : 60,
"image_label" : "cloud_phone",
"product_type" : 0
} ],
"request_id" : "e0dd77cb688743468599487ca2a1c738"
}
状态码
|
状态码 |
描述 |
|---|---|
|
200 |
OK |
错误码
请参见错误码。