All Products
Search
Document Center

AI Guardrails:Image Moderation Enhanced Edition 2.0: AIGC and forgery detection

Last Updated:Jun 29, 2026

Image Moderation 2.0 of Alibaba Cloud Content Moderation provides an image detection service for scenarios involving AI-generated content (AIGC) and forgeries. This service lets you determine if an image is generated by AIGC. This topic describes the AIGC and forgery detection features of the Image Moderation service.

1. Use case

Alibaba Cloud Content Moderation provides the following dedicated detection services tailored to AIGC moderation and AI-powered forgery detection:

  • AI-generated content detection:

    • AIGC image detection: As AIGC technology evolves, its generated images become harder to distinguish from user-generated content (UGC). Many platforms must determine if an image is AI-generated. To address this, Alibaba Cloud Content Moderation offers AI-generated image detection. This feature analyzes images for synthesis artifacts to determine if they contain suspected generated or synthetic content.

2. Service description

The AIGC and forgery detection capabilities of Image Moderation 2.0 support the following services:

Scenario

Service

Detection content

Scenario

AI-generated content detection

Service name: AIGC image detection

Service: aigcDetector_global

Detection object: Images.

Detection content: Detects whether an image is likely to have been generated or synthesized by AI.

This service determines if an image is generated by AIGC. Use this service when you need to identify the source of an image.

Service name: AI-Generated Image Detection Ultimate Edition

Service: aigcDetector_ultra_global

Detection object: Images.

Detection content: Detects whether an image is likely to have been generated or synthesized by AI, is a suspected composite image (including synthetic faces), or contains suspected AI local editing.

Determines if an image is forged. Use this service to detect image forgery, especially to check for potential AI local editing.

3. Billing

The AIGC and forgery detection service of Image Moderation 2.0 supports the pay-as-you-go billing methods.

Pay-as-you-go

After you activate the Image Moderation V2.0 service, the default billing method is pay-as-you-go. You are billed daily based on your actual usage. If you do not call the service, you are not charged.

Moderation type

Supported business scenarios (services)

Unit price

general image moderation (image_standard)

  • AIGC image detection (aigcDetector_global)

USD 0.60 per 1,000 calls

Note

Each call to the AIGC-Generated Image Identification service is counted as one call. You are charged based on the actual number of calls. For example, if you call the AIGC-Generated Image Identification service 100 times, you are charged USD 0.06.

advanced image forgery moderation (image_identify_standard_cn)

  • AI-Generated Image Detection Ultimate Edition: aigcDetector_ultra_global

USD 0.60 per 1,000 calls

Note

You are charged for each call to the aigc image detection (Ultimate Edition) service. For example, if you call the aigc image detection (Ultimate Edition) service 100 times, you are charged USD 0.06.

Note

Bills for Content Moderation 2.0 in pay-as-you-go mode are generated every 24 hours. In the billing details, moderationType corresponds to the moderation type field. For more information, see Bill Details.

4. Integration

Step 1: Activate the service

Go to the service activation page to activate the Image Moderation 2.0 service.

After you activate the Image Moderation 2.0 service, the default billing method is pay-as-you-go. Fees are settled daily based on your actual usage. You are not charged if you do not call the service. After you call the API, the system automatically generates bills based on your usage. For more information, see Billing details.

Step 2: Grant permissions to a RAM user

Before you call API operations or use SDKs, you must grant permissions to a RAM user. You must create an AccessKey pair for your Alibaba Cloud account or the RAM user. When you call API operations, you must use the AccessKey pair to complete identity verification. To obtain an AccessKey pair, see Obtain an AccessKey pair.

  1. Log on to the RAM console using your Alibaba Cloud account or as a RAM administrator.

  2. Create a RAM user. For more information, see Create a RAM user.

  3. Grant the AliyunYundunGreenWebFullAccess system policy to the RAM user. For more information, see Grant permissions to a RAM user. After you complete these configurations, you can call the Content Moderation API as the RAM user.

Step 3: Install and integrate an SDK

For more information, see Image Moderation 2.0 SDKs and usage guide. The following table lists the supported regions.

Region

Public endpoint

VPC endpoint

Supported services

Singapore

https://green-cip.ap-southeast-1.aliyuncs.com

https://green-cip-vpc.ap-southeast-1.aliyuncs.com

aigcDetector_global

US (Virginia)

green-cip.us-east-1.aliyuncs.com

green-cip-vpc.us-east-1.aliyuncs.com

US (Silicon Valley)

green-cip.us-west-1.aliyuncs.com

None

London

green-cip.eu-west-1.aliyuncs.com

None

Step 4: Adjust image moderation rules (Optional)

In the Content Moderation console, you can adjust the detection rules for the image moderation service. You can toggle detection scopes, copy a service, configure custom image libraries and vocabularies, and query detection records and usage. For more information, see the Console Operation Guide.

5. API

Usage notes

You can call this API to create an image moderation task. For more information about how to construct an HTTP request, see the Access Guide. You can also use a pre-constructed HTTP request. For more information, see the Access Guide.

  • API operation: ImageModeration

  • Billing information: This is a paid operation. You are billed only for requests that return an HTTP status code of 200. Requests that return other error codes are not billed. For more information about billing methods, see the Billing overview.

  • Image requirements:

    • The following image formats are supported: PNG, JPG, JPEG, BMP, WEBP, TIFF, SVG, HEIC (the longest side must be less than 8,192 pixels), GIF (only the first frame is processed), and ICO (only the last image is processed).

    • The image size cannot exceed 20 MB. The height or width cannot exceed 16,384 pixels, and the total number of pixels cannot exceed 250 million. We recommend that you use images with a resolution of at least 200 × 200 pixels to ensure the effectiveness of the detection algorithm.

    • The image download time is limited to 3 seconds. If the download takes longer than 3 seconds, a timeout error is returned.

QPS limits

The queries per second (QPS) limit for this API operation is 100 for each user. However, for the aigcDetector_ultra_global services, the limit is 20 QPS. API calls that exceed these limits will be throttled, which can impact your business. Pace your API calls accordingly. If you have a high workload or need to scale up urgently, contact your business manager to request a higher QPS limit.

Debug

Before you start, you can use Alibaba Cloud OpenAPI Explorer to test the or Image Moderation 2.0 API online. You can also view sample code and SDK dependencies to understand how to use the API and its parameters.

Important

The online debugging feature calls the Content Moderation API operation using the currently logged-on account. Therefore, the calls are included in your billable usage.

Request parameters

For information about the common parameters required in a request, see the Access Guide.

The request body is a JSON struct that contains the following fields:

Name

Type

Required

Example

Description

Service

String

Yes

aigcDetectorFull

The detection service. Valid values:

  • aigcDetector_global: AIGC image detection

ServiceParameters

JSONString

Yes

A set of parameters for the content moderation object, provided as a JSON string. For a description of each string, see Table 1. ServiceParameters.

Table 1. ServiceParameters

Name

Type

Required

Example

Description

imageUrl

String

Yes. Image Moderation 2.0 supports three methods for uploading images:

  • Submit the URL of an image for detection by passing imageUrl.

  • Use OSS authorization for detection. You must pass ossBucketName, ossObjectName, and ossRegionId.

  • Submit a local image file for image moderation. This method does not occupy your OSS storage space. The image file is stored for only 30 minutes. SDKs are integrated with the feature of uploading local images. For more information about the sample code, see Image Moderation Enhanced Edition 2.0 SDKs and usage guide.

https://img.alicdn.com/tfs/TB1U4r9AeH2gK0jSZJnXXaT1FXa-2880-480.png

The URL of the object to detect. Make sure the URL is accessible over the public network and is no more than 2,048 characters long.

Note The URL cannot contain Chinese characters. Make sure you submit only one URL per request.

ossBucketName

String

bucket_01

The name of the authorized OSS bucket.

Note

To use an internal OSS URL for an image, you must first use your root account to go to the Cloud Resource Access Authorization page and grant the AliyunCIPScanOSSRole role.

ossObjectName

String

2022023/04/24/test.jpg

The name of the file in the authorized OSS bucket.

ossRegionId

String

cn-beijing

The region where the OSS bucket is located.

dataId

String

No

img123****

The data ID of the detection object.

The ID can contain uppercase letters, lowercase letters, digits, underscores (_), hyphens (-), and periods (.). It can be up to 64 characters long and can be used to uniquely identify your business data.

referer

String

No

www.aliyun.com

The referer request header, used for scenarios such as hotlink protection. The length cannot exceed 256 characters.

infoType

String

Yes

aigcData

The type of auxiliary information to be returned. Valid values:

  • customImage: information about matches in the custom image library.

  • aigcData: information about the AIGC implicit watermark.

To specify multiple types, provide a comma-separated list, such as customImage,aigcData.

Response parameters

Name

Type

Example

Description

RequestId

String

70ED13B0-BC22-576D-9CCF-1CC12FEAC477

The ID of the current request. This is a unique identifier generated by Alibaba Cloud for the request and can be used for troubleshooting.

Data

Object

The result of image moderation. For more information, see Table 2. Data.

Code

Integer

200

The returned HTTP status code. For more information, see Response codes.

Msg

String

OK

The response message for the current request.

Table 2. Data

Name

Type

Example

Description

Result

Array

The parameter results of image moderation, such as risk labels and confidence scores. For more information, see Table 3. result.

RiskLevel

String

high

The risk level, which is returned based on the configured high and low risk scores. Valid values:

  • high: high risk

  • medium: medium risk

  • low: low risk

  • none: no risk detected

Note

It is recommended to handle high-risk content directly. Medium-risk content should be manually reviewed. Low-risk content should be handled only when high recall is required. Otherwise, treat it the same as content with no detected risk. You can configure risk scores in the Content Moderation console.

DataId

String

img123******

The data ID of the detection object.

Note

If you passed a dataId in the request parameters, the same dataId is returned here.

Ext

Object

Additional information for the image. For more information, see Ext.

Table 3. result

Name

Type

Example

Description

Label

String

tm_auto

The label returned after image content detection. Multiple labels and scores may be returned for a single image. For supported labels, see:

Confidence

Float

81.22

The confidence score ranges from 0 to 100 and is accurate to two decimal places. Some labels do not have a confidence score. For more information, see Descriptions of risk labels.

Description

String

Fireworks and pyrotechnics

A description of the Label field.

Important

This field explains the Label field and is subject to change. It is recommended to handle results based on the Label field, not this field.

Table 4: Ext

Parameter

Type

Value

Description

CustomImage

JSONArray

If a match is found in a custom library, this parameter returns that library's details. For more information, see CustomImage.

AigcData

Object

Returns AIGC implicit marker detection results for the image. For more information, see AigcData.

Table 5. CustomImage

Parameter

Type

Example value

Description

LibId

String

lib0001

The unique ID of the matched custom image library.

LibName

String

Custom Image Library A

The name of the matched custom image library.

ImageId

String

20240307

The unique ID of the matched custom image.

Table 6: AigcData

Parameter

Type

Value

Description

AIGC

Object

"AIGC": {"Label": "1",

"ContentPropagator": "",

"ReservedCode1": "0424***",

"ProduceID": "0307***",

"ReservedCode2": "",

"PropagateID": "",

"ContentProducer": "0728***"}

The AIGC implicit watermark information in the image conforms to the standard AIGC metadata fields. For more information, see Implicit Watermark Metadata Information.

Implicit identification metadata

Parameter

Example value

Description

Label

1

Indicates whether the content is AI-generated or synthesized:

  • 1: The content is AI-generated or synthesized.

  • 2: (For propagation platforms only) The content may be AI-generated or synthesized.

  • 3: (For propagation platforms only) The content is suspected of being AI-generated or synthesized.

ContentProducer

001191******M000100Y43

The code or name of the service provider that identifies the content producer.

  • Required fields

    • Digits 1-2: The identification format definition code, which specifies the encoding rule version. For codes created based on this guide, this value is 00.

    • Digit 3: The entity type. 1 indicates an organization, and 2 indicates an individual.

    • Digit 4: For an organization, 1 indicates that a Unified Social Credit Code is used.

    • Digits 5-22: The Unified Social Credit Code for the organization.

  • Extension fields

    • Digit 23: 1 for a generation and synthesis service, 2 for content propagation.

    • Digits 24-27: A unique service/model ID.

For details, see the Cybersecurity Standard Practice Guide.

ProduceID

123456

The content production ID. A unique identifier that the production platform uses to trace synthesized content.

ReserveCode1

d41d8cd98f00b204e9800998ecf8427e

A reserved field.

This field can store information that the generation and synthesis service provider uses to protect security and ensure the integrity of the content and the implicit identification. A hash mechanism based on ContentProducer and ProduceID can securely store and verify key information.

ContentPropagator

001191******M000100Y43

The name, ID, or code of the propagation platform. For services that provide AI-generated or synthesized content, this value can be the same as ContentProducer.

PropagatorID

123456

The content propagation ID. A unique ID that the propagation platform assigns to propagated synthetic content.

ReserveCode2

d41d8cd98f00b204e9800998ecf8427e

A reserved field.

This field can store information that the content propagation service provider uses to protect security and ensure the integrity of the content and the implicit identification. A hash mechanism based on ContentPropagator and PropagatorID can securely store and verify key information.

Examples

Sample request

{
    "Service": "aigcDetector_global",
    "ServiceParameters": {
        "imageUrl": "https://img.alicdn.com/tfs/TB1U4r9AeH2gK0jSZJnXXaT1FXa-2880-480.png",
        "dataId": "img123****"
    }
}

Sample responses

{
    "Msg": "OK",
    "Code": 200,
    "Data": {
        "DataId": "img123****",
        "Result": [
            {
                "Label": "aigc",
                "Confidence": 81.88,
                "Description": "Suspected to be generated by AIGC"
            }
        ]
    },
    "RequestId": "ABCD1234-1234-1234-1234-1234XYZ"
}
  • When the system finds a match in a custom image library, the following is an example of the response:

Note

The sample requests and responses in this topic are formatted for readability. Actual responses are not formatted with line breaks or indentation.

Risk label descriptions

The following table lists the risk labels, their corresponding confidence scores, and their definitions. You can enable or disable each risk label in the Content Moderation console. For some risk labels, you can also configure more specific detection scopes. For more information, see the Console User Guide.

Note

We recommend that you store the risk labels and confidence scores returned by the system for a certain period. This data can be used as a reference for future content governance. You can set priorities for manual review or annotation and implement tiered content governance measures based on the risk labels.

Table 4.Supported Labels for AIGC-Generated Image Identification (aigcDetector_global)

Label (label)

Confidence score range (confidence)

Meaning

aigc

0 to 100. A higher score indicates a higher confidence level.

The image is suspected to be generated by AIGC.

ugc

0 to 100. A higher score indicates a higher confidence level.

The image is not generated by AIGC.

Note

The ugc label is disabled by default. To enable it, you can configure the settings in the Content Moderation console. If no risk label is detected, the nonLabel label is returned.

Table 9. Labels for AI-generated Image Detection (Ultimate Edition) (aigcDetector_ultra)

Label

Confidence

Description

risk_aigc

0 to 100. A higher score indicates greater confidence.

The image is likely generated by AIGC.

risk_fake

0 to 100. A higher score indicates greater confidence.

The image is likely a synthesized image.

risk_edit

0 to 100. A higher score indicates greater confidence.

The image is likely an AI-edited image.

Code descriptions

The following table describes the meanings of the returned codes. The system charges only for requests that return a code of 200. No fees are charged for other codes.

Code

Description

200

The request is successful.

400

A request parameter is empty.

401

A request parameter is invalid.

402

The length of a request parameter does not meet the requirements. Check and modify the parameter.

403

The number of requests exceeds the QPS limit. Check and adjust the concurrency.

404

An error occurred while downloading the specified image. Check the image or retry.

405

The download of the specified image timed out. This may be because the image is inaccessible. Check the image and retry.

406

The specified image is too large. Check and adjust the image size, then retry.

407

The format of the specified image is not supported. Check and adjust the image format, then retry.

408

The account does not have permission to call this API operation. This may be because the service is not activated, the account has an overdue payment, or the account is not authorized.

500

A system error occurred.