tencent cloud

Cloud Infinite

Querying Smart Compression Status

PDF
フォーカスモード
フォントサイズ
最終更新日: 2025-09-08 17:08:53

Feature Description

This API is used to query the status of the intelligent image compression feature.

Authorization Description

When used by a sub-account, the ci:DescribeImageSlim permission is required. For details, please refer to Cloud Infinite.

Service Activation

To use this feature, you need to enable Cloud Infinite in advance and bind a bucket. For details, see Binding a Bucket.

Use Limits

When using this API, please first confirm the relevant restrictions. For details, see Specifications and Limits.

Request

Request sample

GET /?image-slim HTTP/1.1
Host: <BucketName-APPID>.pic.<Region>.myqcloud.com
Date: <GMT Date>
Authorization: <Auth String>
Note:
Authorization: Auth String. For details, see Request Signature document.

Request header

This request operation only uses common request headers. To learn about common request headers, see Common Request Headers.

Request body

The request does not have a request body.

Response

Response Headers

This response uses only common response headers. To learn about common response headers, see Common Response Headers.

Response Body

<?xml version="1.0" encoding="UTF-8" ?>
<ImageSlim>
<Status>off</Status>
<SlimMode>API</SimMode>
<Suffixs>
<Suffix>jpg</Suffix>
<Suffix>png</Suffix>
</Suffixs>
</ImageSlim>

Parameter Description

Node Name (Keyword)
Parent Node
Description
Status
ImageSlim
State of smart compression, including values:
on: Smart compression is enabled
off: Smart compression is disabled.
SlimMode
ImageSlim
Usage modes of smart compression. There are two kinds:
API: The usage method for enabling smart compression. Once activated, images can be compressed using intelligent compression parameters during image download.
Auto: The automatic usage method for enabling smart compression. Once activated, no parameters are needed, and images in the specified format within the bucket will be automatically compressed by smart compression when accessed.
Suffixs
ImageSlim
Returned when the value of SlimMode contains Auto, indicating the need to automatically perform compression on the image format.
Suffix
Suffixs
Image formats for automatic compression, including values: jpg, png, gif.
The API supports JSON format return. When the request header specifies accept=application/json, the response body is as follows:
{
"ImageSlim":{
"Status":"on",
"SlimMode":"Auto",
"Suffixs":{
"Suffix":[
"jpg"
"png"
]
}
}
}


ヘルプとサポート

この記事はお役に立ちましたか?

フィードバック