uichemy_edit_image_masked
Edit part of a picture with AI and put the result in its slot — the Image panel's Generative Fill (fill: paint something new into the area, described by prompt), Magic Eraser (erase: remove what is in the area) and Expand (expand: extend the picture outward). Runs the SAME code as the editor and costs the same UiChemy credits (refunded down to what the model actually used); it needs the plan the editor's smart editing needs. The area is region — a rectangle in fractions of the picture (0-1, from the top-left) — or maskUrl, a PNG the size of the picture that is transparent where it should change. The result is a NEW file; the original stays in storage. Same write as uichemy_crop_image.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| op | Yes | ||
| url | No | The picture to edit. Defaults to what is in the slot now. | |
| slot | Yes | The image slot to edit and put the result in. | |
| prompt | No | What should appear in the area. Required for `fill`. | |
| region | No | ||
| maskUrl | No | ||
| projectId | Yes | ||
| expandPercent | No | How far `expand` extends each edge. Default 25. |