Skip to main content
Glama

Remove Image Background

remove_image_background
Destructive

Remove or replace an image background with transparency, a solid color, or a custom image to isolate subjects or prepare product photos.

Instructions

This tool will remove or replace the background of an image, returning a transparent, solid-color, or custom-image background. It spends 1 credit. It takes the following arguments: - media_file or image_url (one required): The image to process, either an uploaded file or a public URL. - output_transparent (bool, optional): Make the background transparent. Defaults to true unless a color or image background is given. - background_color (str, optional): Hex color to fill the background with. - background_image_url (str, optional): Public URL of an image to use as the new background.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "remove_image_background"
  }
}

Input Schema

NameRequiredDescriptionDefault
image_urlNoPublic URL of the image to process. Use this or media_file.
media_fileNoBase64-encoded image or image data URI. Use this or image_url.
background_colorNoHex color (e.g. '#00ff00') to fill the background with instead of transparency.
output_transparentNoIf true, the removed background becomes transparent. Defaults to true unless background_color or background_image_url is given.
background_image_urlNoPublic URL of an image to use as the new background. Takes precedence over background_color.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The credit cost ('spends 1 credit') is genuinely useful context the annotations do not carry. However, destructiveHint=true is never explained — the description does not say whether the source image is overwritten or a new asset is produced — and there is no mention of auth, rate limits, or whether a job handle is returned.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose and cost sentences are well front-loaded, but the remaining text is a bulleted re-listing of a fully documented schema, which is largely redundant. Half the description is schema echo rather than new information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description should clarify what actually comes back — an image file, a URL, or an async job id (relevant since get_job_status is a sibling). It describes the conceptual result but not the return form, leaving a real gap for a credit-spending, annotated-destructive operation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, and every parameter in the description (including defaults and precedence rules) is already stated in the schema. Baseline 3 applies: the description restates rather than adds meaning, contributing nothing like format limitations or size constraints.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence gives a specific verb (remove/replace) plus resource (image background) and enumerates the three output modes. The word 'image' implicitly separates it from the video-background sibling, but no sibling is named explicitly, so it lands just short of the top mark.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied through parameter documentation ('one required', defaults). There is no statement about when to prefer this over remove_video_background, when a credit check should precede it, or whether the operation is synchronous versus needing get_job_status, so the routing decision is left to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.