• Product Updates
  • May 02, 2021

Slazzer Launches API v2.0!!!

Slazzer Auto Background Removal API v2.0

The Slazzer team is very excited to bring you our API Version 2, named API v2.0!

This update will predominately give you faster processing speeds and increased performance with new parameters.

It is now live on our site, check it out -> https://www.slazzer.com/api

Some highlights of the slazzer auto background removal API v2.0:

✔️ Significantly faster processing time.

✔️ Output will now be binary image data. No more url links.

We also updated some of our API parameters, take a look:

source_image_file

Upload any of the following image types: PNG, JPG, JPEG

source_image_url

Upload a url link of any of the following image types: PNG, JPG, JPEG

source_image_base64

Upload a compressed base64 format of any of the following image types: PNG, JPG, JPEG

bg_image_file

Use a PNG, JPG. JPEG background image to get a binary output in PNG, JPG, JPEG format.

bg_image_url

Use a url background image to get a binary output in PNG, JPG, JPEG format.

bg_image_base64

Use a base64 format background image to get a binary output in PNG, JPG, JPEG format.

bg_color_code

Get a binary output image with a solid background color. Indicate HEX color code in the following format (e.g. #72E4B3, #B3D472). Make sure to add the ‘#’ before color code.

format

Here you can choose whether you want the output image in PNG or JPG format. Default value will be “PNG”.

crop

Isolate the subject and eliminate all the extra pixels around it.

crop_margin

Modify all the margins around the subject (top, bottom, right and left).

This parameter only works when the ‘crop’ parameter is also applied (crop=True). Default value of this parameter is 0px. it supports input value in the following ways:

Ex. 10px,20px,18px,24px – create 10px margin left, 20px margin top, 18px margin right and 24px margin in bottom.

crop_margin parameter supports max 500px or max 50% of the subject size.

scale

This parameter scales the subject in the output image. Can be in any range between 10% or 100% depending on the image dimensions. Default position parameter value is ‘center’, unless any other position parameter value is given.

position

This parameter positions the subject as you want. Only works when the ‘scale’ parameter is also selected. Default value is ‘center’. Can be a single value between 0% to 100% (horizontal and vertical) or two values between 0% to 100% separated by comma (eg: 10%,18%) both horizontal and vertical.

preview

Put the value as ‘True” to get a preview image at 0.25 megapixels (eg value: 400×600 pixels). The default value is ‘False’.

channel

This parameter by default will give you a binary output image as a JPG with the RGBA color scheme (red, green, blue). When the value “alpha” is added (red, green, blue, alpha), it will return the image as a PNG image with a mask.

roi

This parameter lets you extract the region of interest for a particular image, only the contents of the selected region will be considered as a foreground and everything else will be considered as a background and will be completely removed.

200px,320px,400px,230px – top-left,bottom-right coordinates.

10%,15%,25%,30% – top-left,bottom-right with respect to the image size.

We are very excited about this update and we hope you enjoy it!

There are more to come in the next few weeks..Stay tuned…?

?Note: Our previous API Version 1.0 url – https://slazzer.com/api/v1/remove_image_background is currently deprecated and it will be completely removed by 31st May 2021. Please make sure to update to our latest API Version 2.0 to get continued service.

Have a great day! Team Slazzer!!!

Back to All blog posts

Comments (1)

READ MORE