Domain name for API request: vod.intl.tencentcloudapi.com.
Call this API to create a subject for a specified model.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: CreateAigcCustomElement. |
| Version | Yes | String | Common Params. The value used for this API: 2018-07-17. |
| Region | No | String | Common Params. This parameter is not required. |
| ElementName | Yes | String | Subject name. It cannot exceed 20 characters. |
| ElementDescription | Yes | String | Subject description. Up to 100 characters. |
| ElementFrontalImage | Yes | String | Front reference image of the subject. Supports passing an image URL (ensure it is accessible). Image format: .jpg, .jpeg, and .png are supported. The image file size must not exceed 10 MB. The image width and height must not be less than 300 px. The image aspect ratio must be between 1:2.5 and 2.5:1. |
| ElementReferList.N | Yes | Array of ElementReferInfo | Other reference lists of the subject. You can upload multiple reference images of the subject from different angles to define its appearance. Upload at least 1 reference image and up to 3 reference images. |
| Parameter Name | Type | Description |
|---|---|---|
| ElementId | String | Principal ID. You need to record the returned principal ID. |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
POST / HTTP/1.1
Host: vod.intl.tencentcloudapi.com
Content-Type:application/json
X-TC-Action: CreateAigcCustomElement
<Common request parameters>
{
"ElementName": "my_element",
"ElementDescription": "Principal",
"ElementFrontalImage": "https://****.vod-qcloud.com/6cd2c44bvodcq1500039**/179cafb25145403**1/ClcdjoxE6jcA.png",
"ElementReferList": [
{
"ImageUrl": "https://****.vod-qcloud.com/6cd2c44bvodcq1500039**/179cafb25145403**1/feefsfrefer.png"
}
]
}
{
"Response": {
"RequestId": "1047d0dc-6dc8-4898-a7f3-03726a822b0e",
"ElementId": "53459345344333"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| InternalError | Internal error. |
| InvalidParameterValue | Parameter value error. |
文档反馈