Removes the background from an image and optionally adds AI-generated shadows, crops to the subject, and applies margins. When AI shadows are requested, an additional 3 credits will be consumed.
Input Image Limits:
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.
Acceptable response media type(s). application/json or image/*. Default is application/json.
URL of the image to be processed.
"https://cdn3.pixelcut.app/product.jpg"
The format of the resultant image. Currently, only png is supported.
png Enable and configure AI-generated shadow. When enabled, +3 credits are consumed. Pass true for automatic shadow estimation or provide a light source for custom control.
When true, crops the image to the region of interest (the detected subject).
(Beta) General margin applied to all sides when crop is enabled. Only applies if crop is true. When specified as a string with '%' (0-49%), it represents a percentage of the image dimensions. When specified as a string with 'px', it represents pixels (>=0px).
"100px"
(Beta) Directional margin override that applies when crop is enabled. Only applies if crop is true. When specified, this overrides the general margin parameter for this specific side. When specified as a string with '%' (0-49%), it represents a percentage of the image dimensions. When specified as a string with 'px', it represents pixels (>=0px).
"50px"
(Beta) Directional margin override that applies when crop is enabled. Only applies if crop is true. When specified, this overrides the general margin parameter for this specific side. When specified as a string with '%' (0-49%), it represents a percentage of the image dimensions. When specified as a string with 'px', it represents pixels (>=0px).
"50px"
(Beta) Directional margin override that applies when crop is enabled. Only applies if crop is true. When specified, this overrides the general margin parameter for this specific side. When specified as a string with '%' (0-49%), it represents a percentage of the image dimensions. When specified as a string with 'px', it represents pixels (>=0px).
"50px"
(Beta) Directional margin override that applies when crop is enabled. Only applies if crop is true. When specified, this overrides the general margin parameter for this specific side. When specified as a string with '%' (0-49%), it represents a percentage of the image dimensions. When specified as a string with 'px', it represents pixels (>=0px).
"50px"
Success
A URL to access the resultant image which is valid for 1 hour. File format will be png.
"https://assets.pixelcut.app/public/result/a16646be-91c8-4e3a-b359.png"