Ideogram AI Ideogram V4.5 Edit API Documentation

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
    Use edit_precision=high when preserving unaffected image regions is especially important.

  • Four quality tiers
    Choose very_low, low, medium, or high depending on cost and output requirements.


Parameters

ParameterRequiredDescription
imageYesPublic URL of the source image to edit.
promptYesText instructions describing the desired edit. Supports 1–10000 characters.
reference_imagesNoOptional reference image URLs. Supports up to 4 images without a mask, or up to 3 when mask_url is provided.
mask_urlNoMask matching the source image dimensions. Black regions may be edited; white regions are preserved. The mask must contain both editable and preserved areas.
sizeNoOptional output dimensions in width*height format, e.g. 2048*2048. Leave empty to follow the source image.
edit_precisionNoEditing precision: regular or high. Default: regular.
qualityNoGeneration quality: very_low, low, medium, or high. Default: medium.

How to Use

  1. Upload the source image — Provide the image you want to modify.
  2. Write the edit instruction — Describe what should change and what should remain unchanged.
  3. Add reference images optional — Supply supporting images when appearance or style guidance is useful.
  4. Add a mask optional — Restrict editing to specific regions when precise localization is needed.
  5. Choose edit precision — Use regular for standard editing or high when preservation of unaffected details matters more.
  6. Choose quality — Select very_low, low, medium, or high.
  7. Submit — Generate and retrieve the edited image.

Pricing

Pricing is based only on the selected quality tier.

QualityPrice 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, size, 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=high when 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_low or low quality for rapid iteration before moving to higher-quality output.
  • Check text, small details, and masked boundaries before publishing the final result.

Notes

  • Custom sizes are supported only for regular edits without a mask. Dimensions must be at least 256px and multiples of 32, with a maximum of 4,194,304 pixels and an aspect ratio no greater than 6:1.
  • Leave size empty to follow the source image.
  • For high-precision or masked edits, leave size unset.
  • Masks must match the source image dimensions and contain both black areas to edit and white areas to preserve.
  • Up to 4 reference images are supported, or 3 when using a mask. Only the source image is edited.
  • Large input images may be downscaled.

  • 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",
  "resolution": "1k",
  "edit_precision": "regular",
  "quality": "medium"
}
JSON
)

# 1. Submit the prediction once. Never retry this request automatically:
# a retry after an unclear failure can create a second, billed task.
CHECK='The task may already exist. Check History or the predictions list before submitting again.'
if ! SUBMIT_RESPONSE=$(curl --silent --show-error --fail-with-body \
  --connect-timeout 10 --max-time 60 \
  -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}"); then
  printf 'Submit failed. %s\n' "${CHECK}" >&2
  exit 1
fi

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. %s\n' "${CHECK}" >&2
  exit 1
fi
RESULT_URL="https://api.wavespeed.ai/api/v3/predictions/${PREDICTION_ID}/result"

# 2. Poll until the prediction reaches a final status.
BODY_FILE=$(mktemp)
trap 'rm -f "${BODY_FILE}"' EXIT
while true; do
  # Transient errors (429, 5xx) are retried, honoring Retry-After.
  HTTP_CODE=$(curl --silent --show-error --fail-with-body \
    --connect-timeout 10 --max-time 60 --retry 5 --retry-delay 2 \
    --output "${BODY_FILE}" --write-out '%{http_code}' \
    "${RESULT_URL}" \
    -H "Authorization: Bearer ${WAVESPEED_API_KEY}" || true)
  case "${HTTP_CODE}" in
    2??) ;;
    000|429|5??)  # dropped connection or temporary error: keep polling
      printf 'Task %s: HTTP %s, polling again in 10s\n' "${PREDICTION_ID}" "${HTTP_CODE}" >&2
      sleep 10; continue ;;
    *) printf 'Task %s: HTTP %s\n' "${PREDICTION_ID}" "${HTTP_CODE}" >&2
      cat "${BODY_FILE}" >&2; exit 1 ;;
  esac
  RESULT=$(jq 'if type == "object" and has("data") then .data else . end' "${BODY_FILE}")
  STATUS=$(printf '%s' "${RESULT}" | jq -r '.status // empty')

  case "${STATUS}" in
    completed) printf '%s\n' "${RESULT}" | jq '.outputs'; break ;;
    failed|cancelled|timeout|deleted)
      printf 'Task %s ended with status %s\n' "${PREDICTION_ID}" "${STATUS}" >&2
      printf '%s\n' "${RESULT}" | jq . >&2; exit 1 ;;
    *) sleep 2 ;;
  esac
done

Retry temporary errors only while polling, never the submit request. Errors, retries and timeouts

Parameters

Task Submission Parameters

Request Parameters

ParameterTypeRequiredDefaultRangeDescription
imagestringYes1 ~ unlimited charactersSource image to edit. Supply a publicly accessible image URL.
promptstringYes1 ~ 10000 charactersDescribe the changes to make to the source image.
reference_imagesarray<string>No-0 ~ 4 items · each item: 1 ~ unlimited charactersOptional guidance images. Up to four without a mask, or three when mask_url is supplied.
mask_urlstringNo-1 ~ unlimited charactersUpload 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_ratiostringNo-1:1, 4:3, 3:4, 3:2, 2:3, 16:9, 9:16The aspect ratio of the generated image. If not specified, it is determined automatically from the input image.
resolutionstringNo1k1k, 2kOutput size tier. Does not change the price. Ignored when mask_url is set or edit_precision is high, which keep the source image's size.
edit_precisionstringNoregularregular, highRegular applies prompt-based edits. High restores unchanged pixels and keeps the source image's size.
qualitystringNomediumvery_low, low, medium, highEditing quality and price tier.

Conditional constraints

  • Not allowed: reference_images has at least 4 items and mask_url is provided.

Every model also accepts the global request options enable_sync_mode and enable_base64_output; see their pages for details.

Response Parameters

ParameterTypeDescription
codeintegerHTTP status code (e.g., 200 for success)
messagestringStatus message (e.g., “success”)
data.idstringUnique identifier for the prediction, Task Id
data.modelstringModel ID used for the prediction
data.outputsarrayOutput values, usually URL strings; some models return text strings or structured result objects (empty when status is not completed)
data.urlsobjectObject containing related API endpoints
data.statusstringTask status. completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses.
data.created_atstringISO timestamp of when the request was created (e.g., “2023-04-01T12:34:56.789Z”)
data.errorstringError message (empty if no error occurred)
data.timingsobjectObject containing timing details
data.timings.inferenceintegerInference time in milliseconds

Result Request Parameters

ParameterTypeRequiredDefaultDescription
idstringYes-Task ID

Result Response Parameters

ParameterTypeDescription
codeintegerHTTP status code (e.g., 200 for success)
messagestringStatus message (e.g., “success”)
dataobjectThe prediction data object containing all details
data.idstringUnique identifier for the prediction
data.modelstringModel ID used for the prediction
data.outputsarray<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.urlsobjectObject containing related API endpoints
data.statusstringStatus: completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses
data.created_atstringISO timestamp of when the request was created
data.errorstringError message (empty if no error occurred)
data.timingsobjectObject containing timing details
data.timings.inferenceintegerInference time in milliseconds
© 2026 WaveSpeedAI. All rights reserved.