MakePhotos Docs
API Reference

POST /remove-bg

Remove image background — MakePhotos API reference.

POST /api/v1/remove-bg

Remove the background from a Cloudinary-hosted image.

Request

curl -X POST "https://makephotos.ai/api/v1/remove-bg?key=mk_live_..." \
  -H "Content-Type: application/json" \
  -d '{
    "image_url": "https://res.cloudinary.com/.../product.jpg"
  }'

Body parameters

ParameterTypeRequiredDescription
image_urlstringYesCloudinary URL of the input image

The image must be hosted on Cloudinary (res.cloudinary.com). Upload images first using the upload endpoint.

Response

{
  "result_url": "https://res.cloudinary.com/.../e_background_removal/product.jpg",
  "credits_used": 10,
  "credits_remaining": {
    "monthly": 40,
    "topup": 10,
    "total": 50
  }
}
FieldTypeDescription
result_urlstringURL with background removal transformation applied
credits_usednumberAlways 10
credits_remainingobjectUpdated credit balances

Errors

StatusCodeDescription
400invalid_paramsMissing image_url or not a Cloudinary URL
401invalid_api_keyInvalid or missing API key
402insufficient_creditsLess than 10 credits available
403no_active_subscriptionNo active subscription

Credit cost

Background removal costs a flat 10 credits per image, regardless of image size or resolution.

On this page