Skip to main content
POST
/
v1
/
outpaint
Outpaint
curl --request POST \
  --url https://api.developer.pixelcut.ai/v1/outpaint \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --data '
{
  "image_url": "https://cdn3.pixelcut.app/product.jpg",
  "left": 0,
  "top": 0,
  "right": 0,
  "bottom": 0,
  "creativity": 0,
  "output_format": "jpeg"
}
'
{
  "result_url": "https://assets.pixelcut.app/public/result/a16646be-91c8-4e3a-b359.jpg"
}

Authorizations

X-API-KEY
string
header
required

All API requests require a valid api key. Include your token as a HTTP request header in the following format: X-API-Key: skXXXXXXXXXXXXXXXX. You can obtain an api key by signing up for developer access in your Pixelcut account.

Headers

Accept
string

Acceptable response media type(s). application/json, image/*. Default is application/json.

Body

image_url
string<url>
required

URL of the image to be processed.

Example:

"https://cdn3.pixelcut.app/product.jpg"

left
integer<int32>
default:0

Number of pixels to extend the image in this direction (0-2000).

Required range: 0 <= x <= 2000
top
integer<int32>
default:0

Number of pixels to extend the image in this direction (0-2000).

Required range: 0 <= x <= 2000
right
integer<int32>
default:0

Number of pixels to extend the image in this direction (0-2000).

Required range: 0 <= x <= 2000
bottom
integer<int32>
default:0

Number of pixels to extend the image in this direction (0-2000).

Required range: 0 <= x <= 2000
creativity
number<float>
default:0

Controls the creativity of the generated content. Higher values produce more creative but potentially less coherent results. 0 means maximum coherence, 1 means maximum creativity.

Required range: 0 <= x <= 1
output_format
enum<string>
default:jpeg

The format of the output image. Default is jpeg.

Available options:
jpeg,
png

Response

Success

result_url
string

A URL to access the resultant image which is valid for 1 hour. File format will be jpeg.

Example:

"https://assets.pixelcut.app/public/result/a16646be-91c8-4e3a-b359.jpg"