Submits a content moderation job.
Operation description
The job that you submit by calling this operation is run in asynchronous mode. The job is added to an ApsaraVideo Media Processing (MPS) queue to be scheduled and run. You can call the QueryMediaCensorJobDetail operation or configure an asynchronous notification to obtain the job results.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
ice:SubmitMediaCensorJob | create | *All Resources * |
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
TemplateId | string | No | The template ID. If this parameter is not specified, the default template is used for moderation. | S00000001-100060 |
CoverImages | string | No | The Object Storage Service (OSS) objects that are used as the thumbnails. Specify the thumbnails in a JSON array. A maximum of five thumbnails are supported. Note
If this parameter is specified, the system checks the thumbnails specified by this parameter instead of the thumbnails of the input file specified by Media.
| [{"Bucket":"example-bucket-****","Location":"oss-cn-shanghai","Object":"example-****.jpeg","RoleArn":"acs:ram::1997018457688683:role/AliyunICEDefaultRole"}] |
Title | string | No | The video title, which can be up to 64 bytes in length. Note
If this parameter is specified, the system checks the title specified by this parameter instead of the title of the input file specified by Media.
| Hello World |
Description | string | No | The video description, which can be up to 128 bytes in length. Note
If this parameter is specified, the system checks the description specified by this parameter instead of the description of the input file specified by Media.
| example description |
Barrages | string | No | The live comments of the video. Note
If this parameter is specified, the system checks the live comments specified by this parameter instead of the live comments of the input file specified by Media.
| hello world |
Output | string | Yes | The output snapshots. The moderation job generates output snapshots and the result JSON file in the path corresponding to the input file.
| oss://sashimi-cn-shanghai/censor/snapshot-{Count}.jpg |
UserData | string | No | The user-defined data, which can be up to 128 bytes in length. | UserDatatestid-001-**** |
NotifyUrl | string | No | The callback URL. Simple Message Queue (SMQ, formerly MNS) and HTTP callbacks are supported. | mns://125340688170****.oss-cn-shanghai.aliyuncs.com/queues/example-pipeline |
Input | object | No | The information about the file to be moderated. | |
Type | string | No | The type of the input file. Valid values: OSS: OSS object. Media: media asset. | Media |
Media | string | No | The input file. The file can be an OSS object or a media asset. You can specify the path of an OSS object in one of the following formats: 1. oss://bucket/object 2. http(s)://bucket.oss-[regionId].aliyuncs.com/object In the preceding paths, bucket indicates an OSS bucket that resides in the same region as the current project, and object indicates the path of the object in the bucket. | 1b1b9cd148034739af413150fded**** |
ScheduleConfig | object | No | The scheduling configurations. | |
PipelineId | string | No | The ID of the ApsaraVideo Media Processing (MPS) queue to which the job is submitted. | 5246b8d12a62433ab77845074039**** |
Priority | integer | No | The job priority. A larger value indicates a higher priority. Valid values: 1 to 10. | 6 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "25818875-5F78-4A13-BEF6-D7393642CA58",
"JobId": "88c6ca184c0e47098a5b665e2****"
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2022-07-19 | Add Operation | View Change Details |