About Kling Image 4.0
Native 2K, 4K or 8K stills with readable lettering, plus edits from up to ten references.
Call it with the model name kling/image-4.0/edit on POST /jobs/createTask, from $0.066.
Introduction
Rework an image with a defined change
Bring existing pictures to this endpoint when a source subject or visual treatment matters to the next design. Kling Image 4.0 image editing takes a prompt plus one to ten reference images. The instruction explains the role of each reference, the requested change, and the details that should remain recognisable.
Our rose edit changed the reference into a hand-painted vintage advertisement on an amber background. The rose stayed recognisable, and the result also added unwanted lettering. Review the subject and the complete design together before choosing an image for delivery.
Prepare the references and controls
Check source formats and upload order before writing numbered citations. Keep each reference beside its intended role while preparing the request, so the image numbers and instructions match.
Parameter table
Both the prompt and the reference collection are required. Output count, resolution, and aspect ratio are optional controls with the defaults shown here.
| Parameter | Accepted input | Default | How to use it |
|---|---|---|---|
prompt | Required string, 1 to 21,000 characters | None | Cite references and separate the change from preservation requirements. |
image_urls | Required array of 1 to 10 images | None | Supply JPG or PNG files in the order cited by the prompt. |
num_outputs | Integer from 1 to 9 | 1 | Ask for independent edited results. |
aspect_ratio | auto, 16:9, 9:16, 1:1, 4:3, 3:4, 3:2, 2:3, 21:9 | auto | Fix the output shape or let the prompt and references guide it. |
Each reference can be up to 30 MB, must measure at least 300 px on each side, and must have a ratio between 2:5 and 5:2. These requirements concern input images. Select the desired output frame separately rather than assuming the source dimensions define it.
Write an instruction that assigns responsibility
Make the role of each source clear before describing the finish. For example, ask for the ceramic object from @image_1 and the colour palette from @image_2. Follow those roles with the intended background and treatment, keeping the details to preserve distinct from the changes you want.
Match citations to input order
Use @image_1 for the image placed at the beginning of the reference array, @image_2 for the next, and continue in order. Pair each citation with its role: subject, palette, or visual treatment. If the requested change conflicts with a source detail, say which part you intend to change so the design direction is clear.
Describe preservation in concrete terms
Name visible features that matter, such as the handle shape of a jug, the outline of a flower, or the markings on a product. Then specify the change: a painted surface treatment, a different background colour, or a new arrangement. Inspect the returned image against the original; a preservation instruction does not replace that comparison.
Control copy even when changing style
A phrase such as "vintage advertisement" describes a design genre but leaves room for the model to invent wording. State the exact text to include, or request no lettering when none is needed. Add "no other words" for a strict copy boundary and check the result. Our rose edit shows why lettering deserves attention even when the intended change is visual style.
Observed result: rose on an amber ground
The amber-rose-vintage-ad run used a reference image, the 2k tier, a 2:3 ratio, and one requested output. It returned one 1664 x 2496 PNG. The rose stayed recognisable and was repainted against an amber background, matching the requested hand-painted direction.
The words that appeared without a request
The same output included ROSE and NATURAL ESSENCE. Neither phrase appeared in the instruction. Treat this as a defect to review before delivering an advertisement, even though the reference subject survived the restyling. Review every visible word against your requested copy, including small lines around the main subject.
Choose the workflow for the deliverable
Keep image editing for work where the input supplies a subject or visual direction. For a revision, identify the detail that needs attention and describe that change alongside the features you want to keep. Compare each new result with the source images before selecting it.
Kling says its series workflow plans related images, while its long-image workflow makes a complete product-detail or webpage visual. Pick Kling Image 4.0 Set (kling/image-4.0-set) when you need a coordinated collection, or Kling Image 4.0 Long (kling/image-4.0-long) when the deliverable is that kind of long page. One to nine independent edits here should not be treated as a coordinated series. For comparison with another model, use the same sources and change request, then inspect subject preservation, background changes, and any added text together.
Request parameters
| Parameter | Required | Description |
|---|---|---|
aspect_ratio | No | The shape of the frame: wide, square or tall. auto · 16:9 · 9:16 · 1:1 · 4:3 · 3:4 · 3:2 · 2:3 · 21:9 · Default: auto |
image_urls | Yes | Photos to edit or combine. Say in the prompt what each one adds. |
num_outputs | No | How many results to make in one go. ≥ 1 · ≤ 9 · Default: 1 |
prompt | Yes | Describe what you want to make. |
resolution | No | Choose an available output size. 2k · 4k · 8k · Default: 2k |
Pricing
Prices are in USD and charged to your PopNow balance. When a task is accepted, we reserve the maximum quoted amount from your API balance. On completion, we charge for actual usage, never more than the hold, and release the remainder. If the task fails, the hold is released.
| Option | USD per image |
|---|---|
| resolution 2K | $0.063 |
| resolution 4K | $0.094 |
| resolution 8K | $0.157 |
Send the same request body to POST /jobs/quote to see the estimated and maximum USD charge before running. A quote does not run the task or charge your balance.
API quick start
Call the Kling Image 4.0 API in three steps
- Create an API key. Sign in to PopNow and create a key in the API console. Keys start with sk-popnow-. API calls are billed in USD from your PopNow balance.
- Send the request. POST /jobs/createTask with model kling/image-4.0/edit and an input object that follows the parameter table. The response returns a task ID straight away.
- Get the result. Poll GET /jobs/recordInfo with the task ID, or pass a callBackUrl and we post the result to it. Download the output links when the task succeeds.
# 1. Create the task. Keep the Idempotency-Key if you retry after a network error.
export IDEMPOTENCY_KEY="$(uuidgen)"
curl -X POST https://api.popnow.ai/api/v1/jobs/createTask \
-H "Authorization: Bearer $POPNOW_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $IDEMPOTENCY_KEY" \
-d '{
"model": "kling/image-4.0/edit",
"input": {
"prompt": "A ceramic teapot on a linen cloth, soft window light, muted palette",
"image_urls": [
"https://media.popnow.ai/influencer/examples/marco.webp"
],
"num_outputs": 1,
"resolution": "2k",
"aspect_ratio": "auto"
}
}'
# 2. Copy data.taskId from the response, then poll until state is succeeded, failed, canceled or expired.
TASK_ID="TASK_ID_FROM_RESPONSE"
curl "https://api.popnow.ai/api/v1/jobs/recordInfo?taskId=$TASK_ID" \
-H "Authorization: Bearer $POPNOW_API_KEY"Replace the prompt and any links with your own. The API tab has the response, polling and callback reference.
Kling Image 4.0 API questions
How much does the Kling Image 4.0 API cost?
Kling Image 4.0 starts at $0.066 per image with Edit Image, its lowest-priced task. Prices by option: 2K $0.063 per image, 4K $0.094 per image, 8K $0.157 per image. API usage is charged in USD to your PopNow balance. When a task is accepted, we reserve the maximum quoted amount from your API balance. On completion, we charge for actual usage, never more than the hold, and release the remainder. If the task fails, the hold is released.
What are the limits of the Kling Image 4.0 · Edit Image API?
Resolutions: 2K · 4K · 8K; Aspect ratios: auto · 16:9 · 9:16 · 1:1 · 4:3 · 3:4 +3; Outputs per call: 1–9; Reference images: 10; Prompt length (characters): 21,000. Requests outside these limits are rejected before anything is charged.
More about Kling Image 4.0
- Endpoints
- Kling Image 4.0 · Create Image