Updated on 2024-08-09 GMT+08:00

Querying the Image of a Cloud Phone

Function

This API is used to query available cloud phone images by project ID.

URI

GET /v1/{project_id}/cloud-phone/phone-images

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Specifies the project ID.

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

image_type

No

String

Specifies the image type. The value can be public (public images), private (private images), share (shared images), or all (all images).

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Specifies the user token. It can be obtained by calling an Identity and Access Management (IAM) API. The value of X-Subject-Token in the response header is the user token.

Response Parameters

Status code: 200

Table 4 Response body parameters

Parameter

Type

Description

request_id

String

Specifies the unique request ID.

phone_images

Array of PhoneImage objects

Specifies images of cloud phones.

Table 5 PhoneImage

Parameter

Type

Description

image_name

String

Specifies the cloud phone image name. The value can contain a maximum of 128 bytes.

os_type

String

Specifies the image OS type, which can contain a maximum of 16 bytes.

is_public

Integer

Image type

  • 1: public image

  • 2: private image

os_name

String

Specifies the cloud phone OS, which can contain a maximum of 36 bytes.

image_label

String

Specifies the cloud phone specifications to which the image applies.

  • cloud_phone: applicable to physical.rx1.xlarge cloud phone servers

  • cloud_phone_1620: applicable to cloud phone servers of the physical.kg1.4xlarge.cp type

  • cloud_game: cloud mobile game servers of the physical.rx1.xlarge.cg type

  • cloud_game_1620: applicable to cloud mobile game servers of the physical.kg1.4xlarge.cg type

  • qemu_phone: applicable to qemu cloud phones on physical.rx1.xlarge cloud phones

image_id

String

Specifies the unique identifier of the cloud phone image. The value can contain a maximum of 32 bytes.

is_support_encrypt

Boolean

Specifies whether the current image supports file-level encryption.

Example Requests

Querying the image of a cloud phone

GET https://{CPH Endpoint}/v1/{project_id}/cloud-phone/phone-images

Example Responses

Status code: 200

OK

{
  "phone_images" : [ {
    "image_name" : "AOSP",
    "os_type" : "aosp",
    "is_public" : 1,
    "os_name" : "AOSP7.1.1",
    "image_label" : "cloud_game",
    "image_id" : "20032420200401a60b0003a99684b8ea"
  }, {
    "image_name" : "AOSP",
    "os_type" : "aosp",
    "is_public" : 1,
    "os_name" : "AOSP7.1.1",
    "image_label" : "cloud_phone",
    "image_id" : "20032120200330a20b000eae5b8c01e6"
  }, {
    "image_name" : "AOSP",
    "os_type" : "aosp",
    "is_public" : 1,
    "os_name" : "AOSP7.0.0",
    "image_label" : "qemu_phone",
    "image_id" : "be4d231e44d2a4ccf612660a473fe1e3"
  } ],
  "request_id" : "5aac6ab146ba76e5b12a3d00a03a9869"
}

Status Codes

Status Code

Description

200

OK

Error Codes

See Error Codes.