Easily remove unwanted objects, defects, people, or text from your pictures in just seconds.
Bearer authentication format, for example: Bearer {{API Key}}.
Request Body
Optional extra parameters for the request. The returned image type. Default is png.
Enum: png, webp, jpeg
Dedicated Endpoints settings, which only take effect for users who have already subscribed to the Dedicated Endpoints Documentation . Set to true to schedule this task to use your Dedicated Endpoints’s dedicated resources. Default is false.
The base64-encoded original image, with a maximum resolution of 16 megapixels and a maximum file size of 30 MB.
The base64-encoded mask image, with a maximum resolution of 16 megapixels and a maximum file size of 30 MB.
Response
The Base64-encoded content of the returned image.
The returned image type.
Enum: png
, webp
, jpeg
Example
Cleanup allows you to easily remove unwanted objects, defects, people, or text from your pictures in just seconds.
Try it in the playground .
Request:
curl --location --request POST 'https://api.novita.ai/v3/cleanup' \
--header 'Authorization: Bearer {{API Key}}' \
--header 'Content-Type: application/json' \
--data-raw '{
"image_file":"{{Base64 encoded image}}",
"mask_file":"{{Base64 encoded image}}"
}'
Response:
{
"image_file" : "{{Base64 encoded image}}" ,
"image_type" : "png"
}
HTTP status codes in the 2xx range indicate that the request has been successfully accepted. A code of 400 means there is an error with the request parameters, while status codes in the 5xx range indicate internal server errors.
You can retrieve the image URL in the image_file
field of the response in base64 format.
Response:
{
"image_file" : "{{Base64 encoded image}}" ,
"image_type" : "png"
}