Kling Image O3 Text To Image
Usage-based pricing
ae_kling_image_o3_text_to_image
Create images or related image series from text prompts, with optional character or object reference images.
Usage-based pricing
Pricing
| Condition | Charge |
|---|---|
| image resolution is 1K | 33.6 AE credits per image, based on the number of images actually generated and delivered. |
| image resolution is 2K | 33.6 AE credits per image, based on the number of images actually generated and delivered. |
| image resolution is 4K | 67.2 AE credits per image, based on the number of images actually generated and delivered. |
| image resolution not supplied | 33.6 AE credits per image, based on the number of images actually generated and delivered. |
Charges are based on the images actually generated and delivered; the requested image count does not determine the number delivered.
Parameters
Optional parameters use the platform defaults when omitted.
| Parameter | Type | Required | Description | Default |
|---|---|---|---|---|
request_body | object | Yes | No parameter description. | — |
request_body.prompt | string | Yes | Text prompt for image generation. Max 2500 characters. | — |
request_body.elements | array | unknown | No | Optional: Elements (characters/objects) for face control. Reference in prompt as @Element1, @Element2, etc. | — |
request_body.elements[].frontal_image_url | string | unknown | No | The frontal image of the element (main view). Optional. | — |
request_body.elements[].reference_image_urls | array | unknown | No | Additional reference images from different angles. 0-3 images supported. Optional. | — |
request_body.sync_mode | boolean | No | If `True`, the media will be returned as a data URI. | false |
request_body.num_images | integer | No | Number of images to generate (1-9). Only used when result_type is 'single'. | 1 |
request_body.resolution | enum (1K | 2K | 4K) | No | Image generation resolution. 1K: standard, 2K: high-res, 4K: ultra high-res. | 1K |
request_body.result_type | enum (single | series) | No | Result type. 'single' for one image, 'series' for a series of related images. | single |
request_body.aspect_ratio | enum (16:9 | 9:16 | 1:1 | 4:3 | 3:4 | 3:2 | 2:3 | 21:9) | No | Aspect ratio of generated images. | 16:9 |
request_body.output_format | enum (jpeg | png | webp) | No | The format of the generated image. | png |
request_body.series_amount | integer | unknown | No | Number of images in series (2-9). Only used when result_type is 'series'. | — |
Invocation example
Copy the request and explore its response example.
POST
/agent-api/v1/tool/executeX-Api-KeySubmit first, then query with the returned task_id until the task completes.
Request coderequest.sh
curl --request POST \
--url 'https://agentearth.ai/agent-api/v1/tool/execute?tool_name=ae_kling_image_o3_text_to_image' \
--header "X-Api-Key: $AGENTEARTH_API_KEY" \
--header 'Content-Type: application/json' \
--data-raw '{
"params": {
"request_body": {
"aspect_ratio": "16:9",
"num_images": 1,
"output_format": "png",
"prompt": "Wide 16:9 authentic retro pixel-art fighting-game scene. An azure-blue humanoid combat mech on the left fires a bright cyan chest cannon at a crimson-red humanoid combat mech on the right, with visible impact sparks and one coherent action moment. Side-view duel on a dark futuristic city rooftop, large amber setting sun, dark purple night sky, crisp square pixels and faithful blocky mech silhouettes. Leave a quiet uncluttered area in the upper-left sky for a title to be added later. No text, letters, numbers, logos, HUD, health bars, buttons, watermark, border, commercial badges, unrelated characters, or extra weapons.",
"resolution": "2K",
"result_type": "single",
"sync_mode": false
}
}
}'Response exampleresponse.json
{
"description": "task accepted; poll the result via query_tool with this task_id",
"query_tool": "ae_get_result",
"status": "created",
"task_id": "4036f7a4-4642-441e-8cf9-1bc226f66d32"
}


