Call the DescribeImageLib API operation to retrieve a list of custom image libraries.
Usage notes
API operation: DescribeImageLib
You can call this API operation to retrieve a list of custom image libraries.For information about how to construct an HTTP request, see Request structure. You can also use a pre-constructed HTTP request. For more information, see SDK overview.
Billing: This is a free API operation.
QPS limits
You can call this operation up to 10 times per second per account. If the number of calls per second exceeds the limit, throttling is triggered. As a result, your business may be affected. We recommend that you take note of the limit when you call this operation.
Request parameters
| Name | Type | Required | Example | Description |
| ServiceModule | String | Yes | open_api | The name of the service module. Set the value to open_api. |
Returned data
| Name | Type | Example | Description |
| Id | Integer | 1279 | The primary key ID. |
| ModifiedTime | String | 2018-03-19 10:45:44 +0800 | Last modified |
| Name | String | test | The name of the image library. |
| Code | String | 808003055 | The code of the image library. Note This is the code displayed in the console. In API operations, the image library is identified by its primary key ID. |
| ImageCount | String | 191231231230 | The number of images in the image library. |
| Category | String | BLACK | The type of the image library. Valid values:
|
| Source | String | MANUAL | The source of the image library. Valid values:
|
| ServiceModule | String | open_api | The name of the service module. The value open_api indicates an image library used for the content moderation API feature. |
| Scene | String | PORN | The scenario where the image library is used. Valid values:
|
| BizTypes | StringArray | ["bizTypeA", "bizTypeB","bizTypeC"] | The business scenario. For more information, see Create a business scenario. |
| Enable | Boolean | true | Indicates whether the image library is enabled.
|
Examples
Request example:
http(s)://green.cn-shanghai.aliyuncs.com/?
Action=DescribeImageLib&ServiceModule=open_api
&<Common request parameters>
{
"ServiceModule": "open_api"
}Response example:
{
"requestId": "6CF2815C-C8C7-4A01-B52E-FF6E24F53492",
"data": {
"TotalCount": 5,
"ImageLibList": [
{
"Name": "test a",
"Source": "MANUAL",
"ImageCount": 191231231230,
"BizTypes": [
"bizTypeA",
"bizTypeB",
"bizTypeC"
],
"Category": "BLACK",
"ServiceModule": "open_api",
"Scene": "PORN",
"ModifiedTime": "2018-03-19 10:45:44 +0800",
"Id": 1279,
"Code": "808003055",
"Enable": true
},
{
"Name": "aa hello",
"Source": "MANUAL",
"ImageCount": 0,
"BizTypes": [
"bizTypea",
"bizTypeb",
"bizTypec"
],
"Category": "BLACK",
"ServiceModule": "open_api",
"Scene": "PORN",
"ModifiedTime": "2018-03-01 19:20:37 +0800",
"Id": 1222,
"Code": "808003043",
"Enable": true
}
]
},
"code": 200,
"success": true
}该文章对您有帮助吗?