← DotTrim

DotTrim API & MCP

Clean up AI pixel art from your code or from your AI coding agent. Free, no account.

Two tools
ToolWhat it doesUse it for
cleanFinds the dot grid and gives every dot one solid color. Keeps the background.Scenes, backgrounds, tiles
spriteRemoves the background and restores clean pixels. Transparent PNG with a dark outline by default.Characters, items, props

Results come back as PNG with one dot = one pixel.

MCP server (Claude Code, Cursor, …)

Install

Needs Node.js 18 or newer. Then ask your agent things like “Clean up assets/raw/knight.png as a 32-dot sprite and save it at 4× scale.”

Claude Code

claude mcp add dottrim -- npx -y dottrim-mcp

Cursor, Claude Desktop, Windsurf, … (MCP config JSON)

{
  "mcpServers": {
    "dottrim": {
      "command": "npx",
      "args": ["-y", "dottrim-mcp"]
    }
  }
}

Tools: dottrim_clean (input_path, output_path, dot_size, colors, scale) and dottrim_sprite (input_path, output_path, size, outline, colors, scale). PNG and JPEG input. MIT license. Source: github.com/Woooont/dottrim-mcp · npm

HTTP API

Request
POST https://www.odwo.kr/dottrim/api/clear?<options>
Content-Type: image/png

<PNG bytes>

Send the raw PNG file as the body (not a form). Up to 4096 px on the long side.

OptionToolValuesMeaning
mode=dotcleanUse the clean tool. Leave it out for sprite.
pxclean1–64Size of one dot in the input, in pixels. Default: automatic.
sizesprite16, 24, 32, 48, 64Shrink so the longer side is this many dots. Default: keep.
outlinesprite0No dark outline. Default: outline on.
kboth8, 16, 32Palette size. Default: automatic.
Response
{
  "png": "<base64 PNG, one dot = one pixel>",
  "width": 41, "height": 42,
  "repeat": false,
  "me": { "left": 49, "daily": 50 }
}
StatusMeaning
200Done. repeat: true means the same image was sent before and was not counted.
400image: not a readable PNG · size: too large
429daily: daily limit reached
503busy: try again in a moment
Example
curl -s -X POST -H "Content-Type: image/png" --data-binary @knight.png \
  "https://www.odwo.kr/dottrim/api/clear?size=32" \
  | python3 -c "import json,sys,base64; open('knight_clean.png','wb').write(base64.b64decode(json.load(sys.stdin)['png']))"

Limits and privacy

  1. 50 new images per day per IP address. Sending the same image again with other options is free.
  2. Please don’t send images faster than one at a time per user; the server processes them in a queue.
  3. Uploaded images are not stored. If an automatic quality check flags a result, that image and result are kept for 3 days to find the cause. Privacy policy (Korean).