After a successful upscale (U1, U2, U3, U4). You have the option to use the Vary (Region) button to redraw a section of your image; also known as Inpainting.You can use this tool to generate the mask and retrieve its base64 encoded string.If you are making mask by yourself, please make sure it uses background in black, and white color for selected zone.
Request
Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Body Params application/json
Example
{"messageId":"e57fb09d-25f0-49f7-8f0f-2e902ffe9fdd","mask":"UklGRiQAAABXRUJQVlA4WAoAAAAQABAJAAABKAAATAwAAABAAEAAAAAAABIAAAAAQAAAEgAAA...","prompt":"A little cat running on the grass","button":"Vary (Region)"}
Request Code Samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl--location--request POST 'https://api.imaginepro.ai/api/v1/nova/button' \
--header'Authorization: Bearer <token>' \
--header'Content-Type: application/json' \
--data-raw'{
"messageId": "e57fb09d-25f0-49f7-8f0f-2e902ffe9fdd",
"mask": "UklGRiQAAABXRUJQVlA4WAoAAAAQABAJAAABKAAATAwAAABAAEAAAAAAABIAAAAAQAAAEgAAA...",
"prompt": "A little cat running on the grass",
"button": "Vary (Region)"
}'