# Rengi Forge: Sprite Background Remover

> Rengi Forge: Sprite Background Remover is a paid API for AI agents from rengi.dev, paid per call via x402, $0.05/call, status unknown (last checked 2026-10-22).

Removes the background from a sprite, prop, or character image using either exact color keying for flat backgrounds or AI segmentation for complex ones, returning a clean trimmed PNG with pivot metadata.

## Facts

- Endpoint: POST https://rengi.dev/v1/sprite-tools/remove-bg?utm_source=zero.xyz
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-22
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/rengi-forge-sprite-background-remover-06843637
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_9kv7H8zyvE0QJlzylYmAK

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 rengi-forge-sprite-background-remover-06843637 -d '<json body>'
```

Example prompt: Remove the background from this character sprite — it's on a white background, so use flat keying mode, keep only the main subject, trim it tight, and set the pivot to bottom. Here's the image URL: https://example.com/hero.png

## When to prefer this

Choose this endpoint when you need game-ready sprite cutouts with clean edges, proper pivot metadata, and trim — especially when integrating into a game asset pipeline for Unity, Godot, or similar engines. It excels over generic background-removal APIs because it handles both exact flat-color keying (preserving text and holes) and AI segmentation, and outputs pivot-aware trimmed sprites rather than full-canvas PNGs. Prefer flat mode for solid-color backgrounds for crisp results; use AI mode for photos or complex scenes with one clear main subject.

## Known failure modes

- Image has a multicolor/gradient background but flat mode is selected — result will be incomplete removal
- AI mode struggles with images containing multiple equal-prominence subjects
- Input image exceeds supported size or format constraints
- Invalid base64 encoding causes a parse error
- Image URL is inaccessible or returns a non-image content type
- Subject has very similar color to background causing bleed-through in flat mode

## How this service works

Sprite tools: Cut a sprite, prop or character out of its background: exact keying for one-color backgrounds (text and holes too), AI segmentation for busy ones; clean edges with no halo, trimmed, with a pivot. AI mode handles one main subject, not text on photos. Full schema: https://rengi.dev/v1/sprite-tools/schema

## Output

A background-removed, edge-cleaned PNG with no halo artifacts, optionally trimmed to tight bounds, with a specified pivot point (bottom or center) and configurable padding. AI mode isolates the main subject; flat mode keys out the border color including through text and holes.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "keep": {
   "enum": [
    "auto",
    "main",
    "all"
   ],
   "type": "string",
   "default": "auto",
   "description": "main: only the main subject and what touches it; all: everything that is not background. auto: all for flat backgrounds, main after AI."
  },
  "mode": {
   "enum": [
    "auto",
    "flat",
    "ai"
   ],
   "type": "string",
   "default": "auto",
   "description": "auto: flat key when the border is one color, AI segmentation otherwise."
  },
  "trim": {
   "type": "boolean",
   "default": true
  },
  "image": {
   "type": "string",
   "description": "Base64 PNG, JPEG or WebP."
  },
  "pivot": {
   "enum": [
    "bottom",
    "center"
   ],
   "type": "string",
   "default": "bottom"
  },
  "padding": {
   "type": "integer",
   "default": 2,
   "maximum": 256,
   "minimum": 0
  },
  "imageUrl": {
   "type": "string",
   "format": "uri"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/rengi-forge-sprite-background-remover-06843637/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from rengi.dev](https://www.zero.xyz/host/rengi.dev/llms.txt)
