API Notes
kirin_custom_elements only supports image-based subject creation and does not support reference_type, element_image_list, element_video_list, or element_voice_id
Authentication
authorization string required
All APIs require authentication via Bearer Token.
Get API Key:
Visit API Key Management Page to get your API Key.
Usage:
Add to request header:
Authorization: Bearer YOUR_API_KEY
Parameters
model string required
Model ID for the request
Value: kirin_custom_elements
element_name string required
Subject name
Range: Up to 20 characters
element_description string required
Subject description
Range: Up to 100 characters
element_frontal_image string required
Frontal reference image used to define the main appearance of the subject. Supports an image URL or Base64-encoded image content.
Supported formats: .jpg, .jpeg, .png
Range: File size must not exceed 10MB; width and height must be at least 300px; aspect ratio must be between 1:2.5 and 2.5:1
element_refer_list array required
Additional reference image list used to define other angles or close-up details of the subject. Must include 1 to 3 images, and each image should differ from element_frontal_image.
image_url
stringrequiredReference image URL or Base64-encoded image content.
Supported formats:
.jpg,.jpeg,.png
Range: File size must not exceed10MB; width and height must be at least300px; aspect ratio must be between1:2.5and2.5:1
tag_list array
Configure tags for the subject. One subject can have multiple tags.
| tag_id | Name |
|---|---|
| o_101 | Trending Meme |
| o_102 | Character |
| o_103 | Animal |
| o_104 | Prop |
| o_105 | Clothing |
| o_106 | Scene |
| o_107 | Effect |
| o_108 | Other |
tag_id
stringrequiredTag ID.
Options:
o_101,o_102,o_103,o_104,o_105,o_106,o_107,o_108
callback_url string
Callback URL
external_task_id string
Custom task ID. Does not override the system-generated task ID but can be used to query the task.
Note: Must be unique per user.
Polling
Since result generation takes time, you need to poll the task status after creating the task.
The initial response only returns information such as the task ID and initial status. The final result must be obtained by polling the task status endpoint using the task ID.
See the examples on the right for polling requests and responses.
Response Format
output array
Generation results. Only present when status is completed.
content
arrayList of generated content
text
stringSubject information JSON string containing the following fields:
element_id: Subject ID
element_name: Subject name
element_description: Subject description
element_frontal_image: Frontal reference image
element_refer_list: Additional reference image list
element_refer_list[].image_url: Reference image URL
tag_list: Tag list
tag_list[].id: Tag ID
tag_list[].name: Tag name
tag_list[].description: Tag description
owned_by: Owner user ID
final_unit_deduction: Final billing deductiontype
stringResource type, this API returns
texturl
stringURL (empty for this API)