Ideogram AI Ideogram V4.5 Edit API Documentation
Playground
Try it on WaveSpeedAI!Ideogram V4.5 Image Edit transforms images with written instructions, reference images, masks, and precision controls, supporting targeted edits, visual refinements, composition changes, and professional creative workflows. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing.
Features
Ideogram V4.5 Edit modifies an existing image using natural-language instructions, with optional reference images and mask-based control. Use it to change objects, colors, materials, text, layouts, and other visual elements while keeping the source image as the foundation.
Choose between regular editing and high-precision editing depending on how strongly unchanged areas need to be preserved.
Why Choose This?
-
Prompt-based image editing
Modify an existing image with natural-language instructions. -
Targeted visual changes
Change objects, colors, materials, text, styling, and other image elements. -
Reference-image guidance
Add supporting images to guide appearance, products, subjects, or visual direction. -
Mask-based editing
Restrict changes to specific regions while preserving the rest of the image. -
High-precision mode
Useedit_precision=highwhen preserving unaffected image regions is especially important. -
Four quality tiers
Choosevery_low,low,medium, orhighdepending on cost and output requirements.
Parameters
| Parameter | Required | Description |
|---|---|---|
| image | Yes | Public URL of the source image to edit. |
| prompt | Yes | Text instructions describing the desired edit. Supports 1–10000 characters. |
| reference_images | No | Optional reference image URLs. Supports up to 4 images without a mask, or up to 3 when mask_url is provided. |
| mask_url | No | Mask matching the source image dimensions. Black regions may be edited; white regions are preserved. The mask must contain both editable and preserved areas. |
| aspect_ratio | No | Optional output aspect ratio: 1:1, 4:3, 3:4, 16:9, or 9:16. Leave empty to follow the source image. |
| edit_precision | No | Editing precision: regular or high. Default: regular. |
| quality | No | Generation quality: very_low, low, medium, or high. Default: medium. |
Editing Rules
- Leave
aspect_ratioempty when usingedit_precision=high. - When using
mask_url, leaveaspect_ratioempty. - A masked edit supports up to
3reference images. - A regular edit without a mask supports up to
4reference images. - If
aspect_ratiois omitted, the output follows the source image geometry; large inputs may be downscaled. - Custom aspect ratios are available only for regular edits without a mask.
imageis always the source image being edited;reference_imagesonly provide additional guidance.
How to Use
- Upload the source image — Provide the image you want to modify.
- Write the edit instruction — Describe what should change and what should remain unchanged.
- Add reference images optional — Supply supporting images when appearance or style guidance is useful.
- Add a mask optional — Restrict editing to specific regions when precise localization is needed.
- Choose edit precision — Use
regularfor standard editing orhighwhen preservation of unaffected details matters more. - Choose quality — Select
very_low,low,medium, orhigh. - Submit — Generate and retrieve the edited image.
Pricing
Pricing is based only on the selected quality tier.
| Quality | Price per Image |
|---|---|
| Very Low | $0.008 |
| Low | $0.03 |
| Medium | $0.06 |
| High | $0.22 |
The default medium quality edit costs $0.06 per image.
edit_precision, aspect_ratio, mask_url, and the number of reference_images do not add separate charges.
Best Use Cases
- Product variations — Change product colors, materials, finishes, or visual styling.
- Advertising edits — Revise layouts, graphics, text, and campaign imagery.
- Selective corrections — Modify a specific area while preserving the rest of the source image.
- Interior styling — Change furniture, materials, colors, or decorative elements.
- Typography edits — Revise text or designed visual elements inside an existing image.
- Reference-guided editing — Use supporting images to guide products, subjects, or style changes.
Pro Tips
- State the requested change directly instead of redescribing the entire source image.
- Mention what should remain unchanged when preservation matters.
- Use
edit_precision=highwhen unaffected regions need stronger preservation. - Use a mask when the edit should be limited to a specific part of the image.
- Keep reference images closely related to the requested change.
- Use
very_loworlowquality for rapid iteration before moving to higher-quality output. - Check text, small details, and masked boundaries before publishing the final result.
Notes
imageandpromptare required.edit_precisiondefaults toregular.qualitydefaults tomedium.- Mask polarity is black for editing and white for preservation.
- A mask must match the source image dimensions and contain both editable and preserved regions.
- High precision is designed to reduce unintended changes but does not guarantee perfectly unchanged pixels.
- Up to
4reference images are supported without a mask. - Up to
3reference images are supported when a mask is used.
Related Models
- Ideogram V4.5 — Generate images from text with typography, composition, and prompt control.
- Ideogram V4.5 Edit — Edit existing images with prompts, references, masks, and precision control.
Authentication
For authentication details, please refer to the Authentication Guide.
API Endpoints
Submit Task & Query Result
set -euo pipefail
export WAVESPEED_API_KEY="your-api-key"
REQUEST_BODY=$(cat <<'JSON'
{
"image": "https://interactive-examples.mdn.mozilla.net/media/cc0-images/painted-hand-298-332.jpg",
"prompt": "A cinematic ocean wave at sunrise, highly detailed",
"aspect_ratio": "1:1",
"edit_precision": "regular",
"quality": "medium"
}
JSON
)
# 1. Submit the prediction.
SUBMIT_RESPONSE=$(curl --silent --show-error --fail-with-body \
-X POST "https://api.wavespeed.ai/api/v3/ideogram-ai/ideogram-v4.5/edit" \
-H "Authorization: Bearer ${WAVESPEED_API_KEY}" \
-H "Content-Type: application/json" \
-d "${REQUEST_BODY}")
TASK=$(printf '%s' "${SUBMIT_RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
PREDICTION_ID=$(printf '%s' "${TASK}" | jq -r '.id // empty')
if [ -z "${PREDICTION_ID}" ]; then
printf 'Submission response did not contain a prediction id
' >&2
exit 1
fi
RESULT_URL="https://api.wavespeed.ai/api/v3/predictions/${PREDICTION_ID}/result"
# 2. Poll until the prediction finishes.
while true; do
RESPONSE=$(curl --silent --show-error --fail-with-body \
"${RESULT_URL}" \
-H "Authorization: Bearer ${WAVESPEED_API_KEY}")
RESULT=$(printf '%s' "${RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
STATUS=$(printf '%s' "${RESULT}" | jq -r '.status // empty')
case "${STATUS}" in
completed) printf '%s\n' "${RESULT}" | jq '.outputs'; break ;;
failed|cancelled|timeout|deleted) printf '%s\n' "${RESULT}" | jq . >&2; exit 1 ;;
*) sleep 2 ;;
esac
doneParameters
Task Submission Parameters
Request Parameters
| Parameter | Type | Required | Default | Range | Description |
|---|---|---|---|---|---|
| image | string | Yes | - | Source image to edit. Supply a publicly accessible image URL. | |
| prompt | string | Yes | - | Describe the changes to make to the source image. | |
| reference_images | array<string> | No | - | 0 ~ 4 items | Optional guidance images. Up to four without a mask, or three when mask_url is supplied. |
| mask_url | string | No | - | - | Upload a mask image or provide its URL. Use the same dimensions as the source. Black pixels mark the edit area and white pixels preserve the image. Include both black and white regions. |
| aspect_ratio | string | No | - | 1:1, 4:3, 3:4, 16:9, 9:16 | Optional output aspect ratio. Leave empty to follow the source image geometry, with downscaling if needed. Select a ratio only for regular edits without a mask. |
| edit_precision | string | No | regular | regular, high | Regular applies prompt-based edits. High restores unchanged pixels. Leave aspect_ratio empty when using high precision. |
| quality | string | No | medium | very_low, low, medium, high | Editing quality and price tier. |
Response Parameters
| Parameter | Type | Description |
|---|---|---|
| code | integer | HTTP status code (e.g., 200 for success) |
| message | string | Status message (e.g., “success”) |
| data.id | string | Unique identifier for the prediction, Task Id |
| data.model | string | Model ID used for the prediction |
| data.outputs | array | Output values, usually URL strings; some models return text strings or structured result objects (empty when status is not completed) |
| data.urls | object | Object containing related API endpoints |
| data.status | string | Task status. completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses. |
| data.created_at | string | ISO timestamp of when the request was created (e.g., “2023-04-01T12:34:56.789Z”) |
| data.error | string | Error message (empty if no error occurred) |
| data.timings | object | Object containing timing details |
| data.timings.inference | integer | Inference time in milliseconds |
Result Request Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| id | string | Yes | - | Task ID |
Result Response Parameters
| Parameter | Type | Description |
|---|---|---|
| code | integer | HTTP status code (e.g., 200 for success) |
| message | string | Status message (e.g., “success”) |
| data | object | The prediction data object containing all details |
| data.id | string | Unique identifier for the prediction |
| data.model | string | Model ID used for the prediction |
| data.outputs | array<string | object> | Array of generated outputs (empty when status is not completed). Items are usually URL strings, but may be text strings or structured result objects, depending on the model. |
| data.urls | object | Object containing related API endpoints |
| data.status | string | Status: completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses |
| data.created_at | string | ISO timestamp of when the request was created |
| data.error | string | Error message (empty if no error occurred) |
| data.timings | object | Object containing timing details |
| data.timings.inference | integer | Inference time in milliseconds |