stable-image/inpaint
https://api.stability.ai
https://api.stability.ai
https://api.stability.ai
https://api.stability.ai
POST
/v2alpha/generation/stable-image/inpaint
v2alpha/generation
Search-and-Replace Mode
adjustments to images. The service will automatically mask the most appropriate object based on the contents
of the
search_prompt
, and replace it with a generated result based on the prompt
.mode
parameter to search
and provide a short description of what tosearch-and-replace in the
search_prompt
parameter.Mask Mode
individual pixels. Design professionals can provide a
mask
for the section of the image to be replaced,and use standard image prompting to describe the full image as it should appear after the editing.
The resulting image will incorporate all of the elements described in the
prompt
.mode
parameter to mask
and either pass in an image
with an alpha channelor provide an explicit mask image to the
mask
parameter. If both are present the mask
parameter willtake precedence.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.stability.ai/v2alpha/generation/stable-image/inpaint' \
--header 'authorization;'
Response Response Example
200 - Example 1
{}
Request
Header Params
authorization
string
required
content-type
string
required
accept
string
optional
Body Params multipart/form-data
object {0}