Skip to main content
Glama

screenshot_gc

Reclaim disk space from cached screenshots by applying retention policies. Default dry run lists candidates; pass dryRun and confirm flags to delete. Scope by tag or include orphan files.

Instructions

Reclaim disk space from cached screenshots by retention policy. By DEFAULT this is a dry run: it returns the captures that WOULD be deleted (candidates) plus a count/size of leftover orphan files, and deletes nothing. To actually delete, pass BOTH dryRun:false AND confirm:true. Retention caps (all optional): maxCount (keep newest N), maxTotalBytes (keep newest under a byte budget), maxAgeMs (delete older than). When you pass none, the cache's env defaults apply (newest 200 / 256 MiB). Scope to a single tag with tag (other tags are never touched); includeOrphans (default true) also reclaims leftover on-disk files with no index entry. The newest capture is always kept by the count/byte caps. Only ever touches files inside the screenshot cache — never any other path.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagNoLimit deletion to captures under this tag (case-insensitive). Other tags are never touched.
dryRunNoDefault true: only LIST what would be deleted, delete nothing. Set false (with confirm:true) to actually delete.
confirmNoSafety gate: deletion happens ONLY when dryRun:false AND confirm:true. Otherwise the call is forced to a dry run.
includeNoOptional response-shape opt-in. `['envelope']` returns the self-documenting envelope (`_version` / `data` / `as_of` / `confidence`). `['raw']` forces raw shape (overrides DESKTOP_TOUCH_ENVELOPE=1 server default). Default behaviour is raw shape (compat with existing clients).
maxAgeMsNoDelete captures older than this many milliseconds (opt-in; can clear even the newest).
maxCountNoKeep only the newest N captures; delete the rest. The single newest is always kept.
maxTotalBytesNoKeep the newest captures under this total byte budget; delete older ones beyond it. The newest is always kept.
includeOrphansNoDefault true: also reclaim leftover on-disk image files that are not tracked in the cache index (e.g. files left behind by a crash).
Behavior5/5

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

No annotations are provided, so the description fully discloses behavior: default dry run, safety gate, retention caps (maxCount, maxTotalBytes, maxAgeMs), orphan handling, and that only the screenshot cache is touched. It also explains that the newest capture is always kept.

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?

The description is a single dense paragraph but well-organized: starts with purpose, then default behavior, then parameters. It is concise and front-loaded, though slightly packed. Every sentence adds value.

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?

Given no output schema, the description partially covers return values (candidates, count/size of orphans). However, it does not detail the exact structure of the response, which may leave the agent uncertain about what to expect from the tool.

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

Parameters5/5

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

With 100% schema coverage, the description still adds value beyond the schema: explains defaults, default behavior (dry run), retention policy nuances, and that `includeOrphans` is true by default. This enriches the agent's understanding.

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?

The description states a specific verb and resource: 'Reclaim disk space from cached screenshots by retention policy.' This clearly distinguishes it from sibling tools like `screenshot` (which captures screenshots) and `screenshot_query` (which queries captures).

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

Usage Guidelines4/5

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

The description explains default dry-run behavior and the safety gate for actual deletion (both `dryRun:false` and `confirm:true`). It covers retention caps and scope. However, it does not explicitly state when not to use this tool or offer direct alternatives, but the context is clear for a cleanup tool.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/wangkang1133/desktop-touch-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server