Skip to main content
Glama

list-backup-files

Read-only

List backup files in a directory and preview which files a retention rule would remove, with filters for database, backup type, and time range.

Instructions

dbabrain common.cli list-backup-files: Which backup files a directory holds, or which a retention rule would remove. Request fields (pass them as request):

  • db_type (required): The engine the files belong to.

  • host: The host holding them.

  • target: SQL Server: the instance that lists its own backup folder - {host, port, username, password}.

  • path (required): The directory.

  • database_name: One database.

  • kinds: full | diff | log.

  • latest: Only the newest per database and kind.

  • after: Newer than this instant.

  • before: Older than this instant.

  • mode: prune: how obsolescence is judged.

  • cleanup_retention: prune: how long files are kept.

  • delete: prune: true is REFUSED since 0.38.0 - the command answers the plan and deletes nothing.

  • timeout_seconds: How long to wait.

  • wal_segments: PostgreSQL (0.35.0, 1.250): answer every segment name under wal/ on the log row - what a restore's WAL continuity is read from. Off by default: a cluster archives thousands.

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": "list-backup-files"
  }
}

Input Schema

NameRequiredDescriptionDefault
requestNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/5.0
Behavior4/5

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

Beyond the readOnlyHint/destructiveHint annotations, the description makes the strongest possible non-destructive claim: 'delete: prune: true is REFUSED since 0.38.0 - the command answers the plan and deletes nothing.' It also flags a version gate (0.35.0, 1.250) and explains that wal_segments is off by default because a cluster archives thousands of segments. It does not discuss auth requirements or result size, but the safety profile is well amplified.

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 purpose sentence followed by a scannable field list, with no repetition across entries. The 'dbabrain common.cli `list-backup-files`' prefix is redundant with the tool name, and a few entries (wal_segments) are longer than needed, but nearly every line carries decision-relevant information.

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

Completeness5/5

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

The tool has an output schema, so return values need no prose, and the annotations cover the safety profile. What remains — the full request contract, defaults, version gates, and the refusal of delete — is all present, which is strong coverage for a wrapper whose schema documents nothing.

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 0% — the single `request` property is an untyped object — so the description must carry the entire field contract, and it does: it enumerates twelve fields, marks db_type and path required, gives the kinds values (full | diff | log), spells out the target object shape, and groups the prune-only fields. Remaining gaps are the allowed db_type values and the timestamp format for after/before.

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 line names the resource (backup files) and both scopes: enumerating what a directory holds, and previewing what a retention rule would remove. The 'retention rule would remove' half implicitly separates it from prune-backup-files, but no sibling is named, so the differentiation is inferred rather than stated.

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 context is present but indirect: 'mode: prune' and 'cleanup_retention: prune' mark the fields only relevant to the retention-plan path, and 'delete ... true is REFUSED' signals that actual deletion lives elsewhere. There is no explicit 'use this when / use prune-backup-files instead' sentence, so the agent must infer the routing.

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

Deploy Server

Other Tools