Smart Background

The Smart Background service elevates photo customization to new heights by offering an innovative solution for altering the backdrop of images. Unlike the traditional "Change Background" feature accessed via the /removebg endpoint, where users must provide a specific image to serve as the new background, Smart Background harnesses the power of AI to generate a completely new backdrop based on user descriptions.

In contrast, the /removebg endpoint's "Change Background" function requires a predetermined image to replace the original backdrop. While effective for straightforward substitutions, it lacks the flexibility and creative potential provided by "Smart Background," where the possibilities for your photo's new setting are limited only by your imagination. Whether you're looking to transport your subjects to exotic locales, whimsical landscapes, or bespoke scenarios, "Smart Background" offers a tailored, AI-generated solution for every photo.

With Smart Background, users have the unique opportunity to reimagine their photos by simply submitting an image along with a narrative of the desired background. Our advanced AI algorithms then work to seamlessly integrate a bespoke, contextually appropriate scene behind the subject of the photo. This not only allows for unparalleled personalization but also offers a creative freedom unmatched by conventional methods.

Body Params
file

Source image file (binary). (If this parameter is present, the other image source parameters must be empty.)

uri
length between 1 and 2083

Source image URL. (If this parameter is present, the other image source parameters must be empty.)

string
deprecated

Deprecated. Source image ID of an image previously uploaded to Picsart or result image ID from a different API. (If this parameter is present, the other image source parameters must be empty.)

string
required

The prompt.

string
deprecated

The negative prompt (don’t generate this type of images). Don't use the nagitve keywords such as 'no', e.g. don't use 'no distorted faces', use 'distorted faces'.

integer
1 to 10
Defaults to 2

The number of images to generate.

string
enum
Defaults to JPG

Optionally select one of the image formats (JPG is default). Options are as follows:

  • JPG
  • PNG
  • WEBP
Allowed:
string
enum
Defaults to sync

Use this query parameter to establish the processing mode. Acceptable values are sync, async and auto (sync is default):

  • sync: issues a synchronous request, response is given when the result is ready.
  • async: forces an asynchronous request, the response, which is instantaneous, contains a "transaction_id" which is used to poll for the result.
  • REMOVED - auto: the processing mode decision is made by the service, which depends upon the expected processing time.
Allowed:
Responses

Language
Credentials
Header
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json