Skip to main content
Glama

Upscale or remove background

var2_modify_image

Remove background (cut out subject, transparent) OR upscale (2K/4K/8K, "sharper", "enhance", "isolate the ") an existing IMAGE — even when it is a www.var2.ai/image/ link. type ∈ upscale | remove-bg (no other type exists). IMAGE ONLY — judge by media type, not "edit"/"extend": track/song edits → var2_create_audio; video edits → var2_create_video / var2_join_videos. image_url: storage URL, var2 share link, or any https URL. Models: topaz-upscale (upscale_factor 2–6, default 2; credits scale with output megapixels), recraft-upscale (≤2048px), remove-background. Stylistic edits → var2_create_image type=image-to-image.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "image_url": "<image_url>"
    },
    "name": "var2_modify_image"
  }
}

Input Schema

NameRequiredDescriptionDefault
typeNoDefault upscale.
modelNoDefault topaz-upscale.
image_urlYesStorage URL, var2 share link (www.var2.ai/image/<id> — auto-resolved), or any public https URL.
webhook_urlNoOptional. https:// URL var2 POSTs a signed delivery to when the asset is ready (or fails). Signature header: X-VAR2-Signature: t=<unix>, v1=<hex(hmac_sha256(webhook_secret, t + "." + body))>. Retried with exponential backoff (8 attempts over ~4 days).
upscale_factorNotopaz-upscale only. Default 2. Output = image × factor per side (max 100 MP); credits are charged per started 8 MP of output.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / upscale_factor
      Added value: +{
      +  "description": "topaz-upscale only. Default 2. Output = image × factor per side (max 100 MP); credits are charged per started 8 MP of output.",
      +  "enum": [
      +    2,
      +    3,
      +    4,
      +    5,
      +    6
      +  ],
      +  "type": "integer"
      +}
  2. First observed

TDQS

A4.5/5.0
Behavior4/5

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

Annotations only declare it is a non-readOnly, non-destructive, open-world call. The description adds real behavioral context beyond them: credits scale with output megapixels and are charged per started 8 MP, model-specific caps (recraft-upscale ≤2048px, topaz-upscale factor 2–6), and that share links are auto-resolved. It does not state that the call is asynchronous or how to fetch the result, which is the remaining gap.

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

Conciseness4/5

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

Front-loaded with the two operations and the IMAGE-only constraint before routing and model detail. It is dense shorthand with heavy parenthetical stacking, which slightly hurts scanability, but no clause is filler.

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

Completeness4/5

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

For a 5-parameter generation tool with no output schema, it covers routing, accepted URL forms, model constraints, cost behavior, and webhook delivery. The main omission is that it never says the job is async or points to var2_get_image_result for polling.

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

Parameters4/5

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

Schema coverage is already 100%, so the baseline is 3. The description still adds meaning: model choice tradeoffs (topaz with a factor range and MP-based credit cost vs. recraft's 2048px ceiling) and the guarantee that no other type value exists, which prevents enum guessing.

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

Purpose5/5

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

States a specific pair of operations (background removal / upscaling) on a specific resource (an existing IMAGE), including the accepted URL forms. It explicitly rules out the sibling interpretations an agent might otherwise pick (audio/video edits, stylistic edits) by name.

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

Usage Guidelines5/5

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

Gives explicit routing rules: 'type ∈ upscale | remove-bg (no other type exists)', and directs track/song edits to var2_create_audio, video edits to var2_create_video / var2_join_videos, and stylistic edits to var2_create_image type=image-to-image. Both when-to-use and when-not-to-use are spelled out.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources