# Remove Image Background

> Remove Image Background is a paid API for AI agents from api.agentwonderland.com, paid per call via x402, $0.1/call, status unknown (last checked 2026-09-15).

Removes the background from an image provided as a URL or base64 data, returning a PNG or WebP with a transparent, white, or custom-colored background.

## Facts

- Endpoint: POST https://api.agentwonderland.com/x402/endpoints/remove-image-background
- Price: $0.1/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/remove-image-background-46ca9fda
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_mikdWM5H5lgypKJn8Q5vX

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability remove-image-background-46ca9fda -d '<json body>'
```

Example prompt: Can you remove the background from this product photo — https://example.com/shoe.jpg — and give me a transparent PNG back?

## When to prefer this

Choose this endpoint when you need a fast, pay-per-call background removal on a single image passed by URL or base64, with control over the output format (PNG or WebP) and background fill color. It is ideal for agent workflows processing product photos, headshots, or logos without requiring a subscription to a dedicated image editing SaaS.

## Known failure modes

- Invalid or inaccessible image URL returns an error
- Malformed base64 data causes a decoding failure
- Unsupported image format may result in processing error
- Subject detection failure on images with complex or edge-blending backgrounds
- Network timeout if the source URL is slow to respond
- Invalid hex color code for bgColor may fall back to default or return an error

## How this service works

Remove Image Background: Remove the background from any image. Pass a URL or base64 data.

## Output

Returns a processed image file (PNG or WebP) with the background removed and replaced by the specified color (transparent by default, white, or a hex color code). The agent receives the image binary or a URL/base64 of the resulting image ready for use in design, e-commerce, or publishing workflows.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "image": {
   "type": "string",
   "title": "Image",
   "description": "Image URL or base64-encoded image data",
   "json_schema_extra": {
    "example": "https://example.com/photo.jpg"
   }
  },
  "bgColor": {
   "type": "string",
   "title": "Bgcolor",
   "default": "transparent",
   "description": "Background color: transparent, white, or hex code"
  },
  "outputFormat": {
   "type": "string",
   "title": "Outputformat",
   "default": "png",
   "description": "Output format: png or webp"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/remove-image-background-46ca9fda/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.agentwonderland.com](https://www.zero.xyz/host/api.agentwonderland.com/llms.txt)
