> For the complete documentation index, see [llms.txt](https://docs.console.zenlayer.com/api-reference/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.console.zenlayer.com/api-reference/compute/vm/image/describeimages.md).

# DescribeImages

## 1. API Description

This API (DescribeImages) is used to query the details of images.

## 2. Input Parameters

The following request parameter list only provides API request parameters.

| Parameter Name | Required | Type                                                                          | Description                                                                                            |
| -------------- | -------- | ----------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------ |
| zoneId         | Yes      | String                                                                        | <p>Zone ID.</p><p>Call DescribeZones and find zoneId in the response.</p>                              |
| imageIds       | No       | Array of String                                                               | <p>ID list of images.</p><p>Call DescribeImages and find imageId in the response.</p>                  |
| imageName      | No       | String                                                                        | Image name.                                                                                            |
| category       | No       | [ImageCategory](/api-reference/compute/vm/datastructure.md#imagecategory)     | <p>Image category.</p><p>Available values:CentOSWindowsUbuntuDebian</p>                                |
| imageType      | No       | [ImageSourceType](/api-reference/compute/vm/datastructure.md#imagesourcetype) | Image type.PUBLIC\_IMAGE: the default images.CUSTOM\_IMAGE: the newly created images by yourself.      |
| osType         | No       | [ImageType](/api-reference/compute/vm/datastructure.md#imagetype)             | <p>Operating system type.</p><p>Available values:WindowsLinux</p>                                      |
| imageStatus    | No       | [ImageStatus](/api-reference/compute/vm/datastructure.md#imagestatus)         | Image status.CREATING: creating.AVAILABLE: able to use.UNAVAILABLE: unable to use.                     |
| pageNum        | No       | Integer                                                                       | <p>Number of pages returned.</p><p>Default value: 1.</p><p>Default value: 1</p>                        |
| pageSize       | No       | Integer                                                                       | <p>Number of items in the current page result.</p><p>Default value: 20;</p><p>Maximum value: 1000.</p> |

## 3. Output Parameters

| Parameter Name | Type                                                                       | Description                                                                                                           |
| -------------- | -------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- |
| requestId      | String                                                                     | <p>The unique request ID, which is returned for each request.</p><p>RequestId is required for locating a problem.</p> |
| totalCount     | Integer                                                                    | Number of images meeting the filtering conditions.                                                                    |
| dataSet        | Array of [ImageInfo](/api-reference/compute/vm/datastructure.md#imageinfo) | Information on an image.                                                                                              |

## 4. Code Example

{% tabs %}
{% tab title="Example" %}
**Query all available images with no parameter.**

```json
POST /api/v2/vm HTTP/1.1
Host: console.zenlayer.com
Content-Type: application/json
X-ZC-Action: DescribeImages
<Common Request Params>

Request:
{
  "zoneId": "FRA-A",
  "osType": "linux",
  "pageSize": 3
}

Response:
{
  "requestId": "T6818FFFC-B917-4E46-8BEC-D8BBD8FA2AA5",
  "response": {
    "requestId": "T6818FFFC-B917-4E46-8BEC-D8BBD8FA2AA5",
    "dataSet": [
      {
        "imageVersion": "18.04",
        "imageId": "img-EVhEsCuXhCN0urZ7Vt77oOr6K",
        "imageName": "Ubuntu Server 18.04 LTS x86 64-bit",
        "imageDescription": null,
        "osType": "linux",
        "imageSize": "30",
        "imageStatus": "AVAILABLE",
        "category": "Ubuntu",
        "imageType": "PUBLIC_IMAGE"
      },
      {
        "imageVersion": "11.5",
        "imageId": "img-MJHkbWzEl9anNobblDtpRTDPB",
        "imageName": "Debian 11.5 Amd x86 64-bit",
        "imageDescription": null,
        "osType": "linux",
        "imageSize": "30",
        "imageStatus": "AVAILABLE",
        "category": "Debian",
        "imageType": "PUBLIC_IMAGE"
      },
      {
        "imageVersion": "7.4",
        "imageId": "img-3ELi56cECstEUqmcQzqIGdiuB",
        "imageName": "CentOS 7.4.1708 x86 64-bit",
        "imageDescription": null,
        "osType": "linux",
        "imageSize": "30",
        "imageStatus": "AVAILABLE",
        "category": "CentOS",
        "imageType": "PUBLIC_IMAGE"
      }
    ],
    "totalCount": 7
  }
}
```

{% endtab %}
{% endtabs %}

## 5. Developer Resources

Zenlayer Cloud API 2.0 integrates [SDKs](/api-reference/api-introduction/toolkit/api-sdk.md)，to make it easier for you to call APIs. More programming languages will be supported.

## 6. Error Codes

The following only lists the error codes related to the API business logic. For other error codes, see [Common Error Codes](/api-reference/api-introduction/instruction/commonerrorcode.md).

| HTTP Status Code | Error Code | Description |
| ---------------- | ---------- | ----------- |
