Skip to main content
Glama
BerkantACUN

redis-guard-mcp

by BerkantACUN

redis_scan_keys

Scan Redis keys matching a glob pattern without blocking the server. Pass the returned cursor back to continue pagination until 0 indicates done.

Instructions

One SCAN page of keys matching a glob pattern. Never blocks the server the way KEYS can on a large keyspace — pass the returned cursor back in as cursor to continue; 0 means done.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cursorNo
patternNo*

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description must disclose behavior, and it does: it guarantees non-blocking (unlike KEYS) and details the cursor-based pagination contract. It does not describe the exact return format (e.g., an array of keys plus a cursor) or any error conditions, but those are partially inferable from the pagination instructions. This is sufficient coverage for a straightforward read-only operation.

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

Conciseness5/5

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

The description is two concise sentences, front-loaded with the core purpose and then the critical safety caveat and pagination detail. Every phrase adds value, and there is no filler or redundant restating of the tool name. It is exemplary in structure and economy.

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 tool with no output schema and no annotations, this description is quite complete: it covers purpose, safety (non-blocking), and the cursor mechanics needed to iterate. It does not mention the return shape (list of keys + cursor) or possible edge cases like empty results, but those are minor omissions for a scanning tool. The essential information for correct invocation is present.

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?

Given the schema has 0% description coverage, the description fully compensates by explaining both parameters: 'pattern' as a glob pattern and 'cursor' with its significance (returned cursor, 0 means done). It also implies defaults indirectly (starter cursor of 0). This leaves no ambiguity for an agent about how to supply the parameters.

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 description clearly states the tool fetches one SCAN page of keys matching a glob pattern, with a specific verb and resource. It implies the tool is for top-level keys rather than hash or set fields, but it does not explicitly differentiate from sibling commands like redis_hscan or redis_sscan. The purpose is unambiguous and the reference to KEYS helps distinguish it from an unsafe alternative.

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 explicitly advises using this tool instead of KEYS to avoid blocking the server, providing a clear when-not-to-use directive. It also explains how to paginate by passing the returned cursor back and that 0 indicates completion. However, it does not state when to prefer this over other SCAN variants like hscan or sscan, which is a minor gap given the sibling list.

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