Job List Query
Function
This API queries a batch of image moderation jobs. You can specify the job status to filter the jobs.
Prerequisites
Before using Text Moderation, you need to apply for the service and complete authentication. For details, see Getting Started with Moderation (Image).
URI
URI format
GET /v1.0/moderation/image/batch/jobs?status={status_type}
Request Message
Table 1 describes the request parameters.
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| status | No | String | Indicates the job status. Possible values are as follows:
|
Response Message
Table 2 describes the response parameters.
| Parameter | Type | Description |
|---|---|---|
| result | Array | Indicates the calling result when the API is successfully called. This parameter is not included when the API fails to be called. |
| job_id | String | Indicates the job ID. |
| status | String | Indicates the job status. Possible values are as follows:
|
| create_time | String | Indicates the time when a job is created. For example, 2018-01-02T15:03:04Z. |
| update_time | DateTime | Indicates the time when a job is updated. For example, 2018-01-02T15:03:04Z. |
| error_code | String | Indicates the error code of a failed API call. For details, see Error Codes. This parameter is not included when the API is successfully called. |
| error_msg | String | Indicates the error message of a failed API call. This parameter is not included when the API is successfully called. |
Examples
- Example request
GET https://moderation.cn-north-1.myhuaweicloud.com/v1.0/moderation/image/batch/jobs?status=finish Request Header: Content-Type:application/json X-Auth-Token: MIINRwYJKoZIhvcNAQcCoIINODCCDTQCAQExDTALBglghkgBZQMEAgEwgguVBgkqhkiG...
- Example successful response
{ "result": [ { "job_id": "53ba32e2-c96a-4d0a-a1df-6ddc75f40aed", "status": "finish", "create_time": "2018-11-22T06:17:09Z", "update_time": "2018-11-22T06:17:16Z" } ] } - Example failed response
{ "error_code": "AIS.0005", "error_msg": "The service does not exist." }
- Abnormal
Return Value
Description
400
- The request cannot be understood by the server due to malformed syntax. The client should not repeat the request without modifications.
- The request parameter is incorrect.
401
The request requires user authentication.
403
No operation permission.
404
The server has not found anything matching the Request-URI.
500
The server encountered an unexpected condition which prevented it from fulfilling the request.
Last Article: Result Query
Next Article: Moderation Feedback
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.