ImaginePro
HomeDocs
HomeDocs
  1. API Documentation
  • Introduction
  • System Design
  • Get Started
  • My Account
    • Credits
    • Generation Modes
  • API Documentation
    • Generate Image
      POST
    • Get Progress
      GET
    • Upscale
      POST
    • Variation
      POST
    • Zoom
      POST
    • Pan
      POST
    • Reroll
      POST
    • Make Square
      POST
    • Cancel Job
      POST
    • Inpainting
      POST
    • Image to Text (describe)
      POST
    • Image to Image
      POST
    • Face Swap
      POST
    • Blend
      POST
    • History
      GET
    • Generate Image Boost
      POST
    • Button Boost
      POST
    • Prompt Check
      POST
    • Account Info
      GET
    • Generate Image - Flux Model
      POST
    • Remove Background
      POST
  • FLUX API Documentation
    • Generate Image
      POST
    • Upscale Image
      POST
  • DIY Plan Endpoints
    • Queue Management
      • Count jobs in queue
      • Reboot the queue
      • Pause the queue
      • Resume the queue
    • Get Linked Discord Token Details
    • Toggle Linked Discord Token
    • Get Message Trace
    • Get Ban Words List
    • Update Ban Words List
    • Get Linked Account List
    • Get Linked Account queue status
    • Excute MJ commad
  • Guide
    • FAQ
    • Troubleshoot
  • HowTos
    • How to get Discord token, server and channel ID
    • How to use ImaginePro web app
    • How to make ImaginePro API request in Postman
    • How to use Midjourney V6
    • How to link your own Discord account
    • How to debug the ImaginePro web app
  • Web App
    • Credits
  1. API Documentation

Inpainting

POST
https://api.imaginepro.ai/api/v1/nova/button
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
messageId
string 
required
The unique identify from your previous upscale request.
button
enum<string> 
required
The button action.
Allowed value:
Vary (Region)
Default:
Vary (Region)
Example:
Vary (Region)
mask
string 
required
The mask is a base64 encoded string of the region you want to inpaint.
prompt
string 
optional
You can optionally pass prompt in your command - which can be used useful for the inpainting area.
ref
string 
optional
The reference metadata which will return as part of the webhook.
webhookOverride
string 
optional
The webhook URL which the response will send to, the payload of this webhook is same as our Message endpoint.
Example
{
  "messageId": "e57fb09d-25f0-49f7-8f0f-2e902ffe9fdd",
  "mask": "UklGRiQAAABXRUJQVlA4WAoAAAAQABAJAAABKAAATAwAAABAAEAAAAAAABIAAAAAQAAAEgAAA...",
  "prompt": "A little cat running on the grass",
  "button": "Vary (Region)"
}

Request 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 '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)"
}'

Responses

🟢200Success
application/json
Body
success
boolean 
required
The status of the request.
messageId
string 
required
The messageId of the request, which will be used for querying the progress, sending subsequential actions later, etc.
createdAt
string 
required
The timestamp of the job creation.
error
string 
optional
The error message, if any
Example
{
    "success": true,
    "messageId": "d15c1541-229a-442b-9873-d3494dede12a",
    "createdAt": "2023-08-01T14:03:01.817Z"
}
Previous
Cancel Job
Next
Image to Text (describe)
Built with