# Stability AI Background Removal via Locus x402

> Stability AI Background Removal via Locus x402 is a paid API for AI agents from stability-ai.x402.paywithlocus.com, paid per call via x402, $0.057/call, status unknown (last checked 2026-09-13).

Removes the background from a source image using Stability AI, returning a clean foreground cutout in PNG or WebP format.

## Facts

- Endpoint: POST https://stability-ai.x402.paywithlocus.com/stability-ai/remove-background
- Price: $0.057/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/stability-ai-background-removal-via-locus-x402-1acbbbc7
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_pElIXlYGXxNtqp4inoGuX

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 stability-ai-background-removal-via-locus-x402-1acbbbc7 -d '<json body>'
```

Example prompt: Can you remove the background from this product photo and give me a clean PNG cutout with a transparent background?

## When to prefer this

Choose this endpoint when you need automated, AI-powered background removal from images with minimal setup, especially in workflows that require micropayment-based access via x402/USDC. It is ideal for processing product images, headshots, or marketing assets at $0.057 per call without requiring an API key subscription to Stability AI directly. Prefer this over manual editing tools when building agent-driven pipelines for e-commerce, content creation, or asset preparation.

## Known failure modes

- Invalid or unsupported image format causes processing failure
- Image URL is inaccessible or malformed, returning an error
- Output format value other than 'png' or 'webp' is rejected
- Payment authorization fails due to insufficient USDC balance
- Image contains no clear foreground subject making segmentation ambiguous
- Large image files may time out or fail during processing

## How this service works

Generative AI platform for images, 3D models, and audio — text-to-image, editing, upscaling, and more.

## Output

Returns a JSON response containing a data object with the processed image (background removed, foreground isolated), the output format (PNG or WebP), and payment metadata including settled USDC amount and a request ID with a status URL for tracking.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "image": {
   "type": "string"
  },
  "output_format": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": {},
  "payment": {
   "scheme": "exact",
   "settledUsdc": "0.001000",
   "authorizedMaxUsdc": "0.001000"
  },
  "request": {
   "id": "00000000-0000-4000-8000-000000000000",
   "statusUrl": "/requests/00000000-0000-4000-8000-000000000000"
  },
  "success": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/stability-ai-background-removal-via-locus-x402-1acbbbc7/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from stability-ai.x402.paywithlocus.com](https://www.zero.xyz/host/stability-ai.x402.paywithlocus.com/llms.txt)
