API Documentation
  • Introduction
  • API Reference
  • 🔐Authentication
  • Core APIs
    • Perfect Redesign
    • Beautiful Redesign
    • Creative Redesign
    • Sketch to Render
    • Virtual staging
    • Precision
    • Fill Spaces
    • Decor Staging
    • Furniture Removal
    • Colors & Textures
    • Furniture Finder
    • Full HD
    • Text to design
    • Furniture Creator
    • Design Advisor
    • Sky Colors
    • Design Transfer
    • Floor Editor
    • Paint Visualizer
    • Material Swap
    • Room Composer
    • Design Critique
    • Create Mask Image
    • Download Generated Images
    • Smart Home AI
  • DESIGN SCOPE
    • Interiors
      • Design Styles for Interiors
      • Room Types
      • Colors in Interior Design
      • Explore Material Options for Interior Designs
    • Exteriors
      • Design Styles for Exteriors
      • Copy of Design Styles for Exteriors
      • House angles
      • Exterior Colors
      • Material Options for Exterior Designs
    • Gardens
      • Design Styles for Gardens
      • Garden Types
      • Explore Color Options for Garden Designs
      • Material Options for Garden Designs
  • Data
    • User Details
    • Design Scope
  • Others
    • What is Masked Image?
Powered by GitBook
On this page

Was this helpful?

  1. Core APIs

Paint Visualizer

PreviousFloor EditorNextMaterial Swap

Last updated 4 months ago

Was this helpful?

The paint_visualizer endpoint allows you to transform the look and feel of your interiors and exteriors with our Paint Visualizer tool. This feature enables you to effortlessly change the paint color of any wall, whether interior or exterior, using either our preset options or colors you upload.

You can select areas to paint using Automated Selection or Manual Selection. Choose colors from our Presets OR use the color picker OR upload an image with your sample color. For the best results, ensure your selection is as accurate as possible.

ENDPOINT

POST /paint_visualizer

An API URL would be like https://homedesigns.ai/api/v2/paint_visualizer

The paint_visualizer endpoint lets you easily change the paint color of any wall using preset options or custom colors.

An API request must be in the form-data format.

Request

Parameters & Data Type
Value
Description

image

file[ .jpg, .jpeg, .png] / base64 Image string

-

The image to be processed by the API. The image dimensions must be 512x512 pixels or greater for optimal results. (Required Parameter)

masked_image file[ .jpg, .jpeg, .png] / base64 Image string

-

The image to be processed by the API. The image dimensions must be 512x512 pixels or greater for optimal results. to generate a mask image (Required Parameter)

no_design

integer

Min - 1, Max - 4

Specifies the number of design variations you want the API to generate. The minimum is 1 and the maximum is 4. (Required Parameter)

color_image

file[ .jpg, .jpeg, .png] / base64 Image string

Color Image should be as per your choice

The image to be processed by the API.

(Required if rgb_color is not available).

rgb_color RGB Color string code with ',' comma seperated value. Example: '183,42,42'

RGB color should be as per RGB color code

An rgb_color value is specified with: rgb( RED , GREEN , BLUE ). Each parameter defines the intensity of the color as an integer between 0 and 255. For example, rgb(0,0,255) is rendered as blue, because the blue parameter is set to its highest value (255) and the others are set to 0. to choose the color code.

(Required if color_image is not available)

Parameters & Errors

image

Error Messages
Reason

Image field required

Image not provided

Invalid image size. The image width and height must be 512x512 or greater than 512x512 pixels.

Image Size Not Proper.

Invalid image format. Only PNG, JPEG and JPG images are allowed.

Image Format not valid.

masked_image

Error Messages
Reason

masked_image field required

masked_image not provided

Invalid image size. The image width and height must be 512x512 or greater than 512x512 pixels.

masked_image Size must be greater than 512x512.

Invalid image format. Only PNG, JPEG and JPG images are allowed.

masked_image Format not valid.

no_design

Error Messages
Reason

no_design field required

no_design not provided

no_design value is not a valid enumeration member; permitted: 1, 2, 3, 4

no_design not provided properly

color_image

Error Messages
Reason

The color_image is required when rgb_color is not provided.

whether the color_image or rgb_color field is required to get the results.

The color image field must be an image.

color_image value is not an image.

The color image field must be a file of type: jpeg, png, jpg

The image format is not supported for the color_image.

rgb_color

Error Messages
Reason

The rgb_color is required when color_image is not provided.

whether the rgb_color or color_image field is required to get the results.

The rgb_color field format is invalid. Example: '183,42,42'

rgb_color value is not in proper format.


//Output should be in list of array depends on no of designs as shown below:

{
    "input_image": "https://storage.googleapis.com/generativeartbucket/UserGenerations/cristian/input-9a87be38-4cbf-4a6f-9e8c-434c0a8f73ef-2024-05-30-11-08-30.png",
    "output_images": [
            "https://storage.googleapis.com/generativeartbucket/UserGenerations/cristian/output-9a87be38-4cbf-4a6f-9e8c-434c0a8f73ef-1.png",
            "https://storage.googleapis.com/generativeartbucket/UserGenerations/cristian/output-9a87be38-4cbf-4a6f-9e8c-434c0a8f73ef-2.png",
            "https://storage.googleapis.com/generativeartbucket/UserGenerations/cristian/output-9a87be38-4cbf-4a6f-9e8c-434c0a8f73ef-2.png"
    ]
}


Click Here
Video Tutorial.
Click Here
Page cover image