Hunyuan Hy Wu Edit

120.00 credits/megapixel
ae_hy_wu_edit

Edit images using written instructions and up to three reference images, such as changing outfits or combining visual elements.

Image
120.00 credits/megapixel

Pricing

Image editing costs 120.00 credits per megapixel in normal mode and 180 in thinking mode. The actual processing quantity and mode determine the charge.

120.00 credits/megapixel

Parameters

Optional parameters use the platform defaults when omitted.

ParameterTypeRequiredDescriptionDefault
request_bodyobjectYesNo parameter description.—
request_body.seedinteger | unknownNoRandom seed for reproducible results. If None, a random seed is used.—
request_body.promptstringYesThe text prompt describing the desired edit. Supports both English and Chinese. Use specific instructions like 'Replace the clothing on figure 1 with the outfit from figure 2'.—
request_body.sync_modebooleanNoIf True, the media will be returned as a data URI.false
request_body.image_sizeobject | stringNoThe desired size of the generated image. If auto, image size will be determined by the model.auto
request_body.image_size.widthintegerNoThe width of the generated image.512
request_body.image_size.heightintegerNoThe height of the generated image.512
request_body.image_urlsarrayYesURLs of input images for editing. Typically 2 images: the base image and the reference image. Supports up to 3 images.—
request_body.num_imagesintegerNoThe number of images to generate.1
request_body.output_formatenum (jpeg | png)NoThe format of the generated image.png
request_body.enable_thinkingbooleanNoEnable thinking mode. The model reasons about the edit before generating, producing higher quality results at the cost of longer inference time. Disable for faster results on straightforward edits.true
request_body.num_inference_stepsintegerNoNumber of diffusion denoising steps.30
request_body.enable_safety_checkerbooleanNoIf set to true, the safety checker will be enabled.true

Invocation example

Copy the request and explore its response example.

POST/agent-api/v1/tool/executeX-Api-Key

Submit 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_hy_wu_edit' \
  --header "X-Api-Key: $AGENTEARTH_API_KEY" \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "params": {
    "request_body": {
      "enable_thinking": false,
      "image_size": {
        "height": 1418,
        "width": 832
      },
      "image_urls": [
        "https://agentearth.ai/fileserver/file/cc6ed968-1ea9-4a6b-b864-7d702dfe44a3.jpg",
        "https://agentearth.ai/fileserver/file/54fdd3cc-3e04-4e21-b5fd-12f402d1a20b.jpg"
      ],
      "num_images": 1,
      "output_format": "png",
      "prompt": "以第一张图作为底图,保持整张海报的背景、金色圣光、城堡、巨大数字、驴、白绵羊、以及所有文字与整体版式完全不变。只做两处修改:1) 把第一张图中骑驴女生的深色长裤改成黑色丝袜,黑色丝袜包裹住她的双腿,贴合腿部线条,露出腿部曲线;2) 从第二张图提取那个银白色长发、身穿黑金色战甲长袍、披暗红色披风的男子形象,把他添加到第一张图里女生身后的同一头驴背上,两人同骑这一头驴。男子坐在女生正后方,用双臂从后面紧紧环抱女生的腰部,下巴贴近女生肩头,神情冷峻。保持男子银白长发、黑金战甲长袍、暗红披风等形象特征与第二张图一致。"
    }
  }
}'
Response exampleresponse.json
JSONPartial content
{
  "description": "task accepted; poll the result via query_tool with this task_id",
  "query_tool": "ae_get_result",
  "status": "created",
  "task_id": "234f5a02-b734-4d15-ae87-46143952fd47"
}

This example shows part of the response. Copied content is valid JSON.