Skip to main content
Glama
BerkantACUN

redis-guard-mcp

by BerkantACUN

redis_hscan

Paginate through a Redis hash's fields using HSCAN with a cursor, returning the next cursor for continued iteration and avoiding blocking on large hashes.

Instructions

One HSCAN page of a hash's fields. Pass the returned cursor back in as cursor to continue; 0 means done. Paginated rather than a single HGETALL, which can block a shared Redis server for as long as a large hash takes to serialize.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyYes
cursorNo

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 carries full behavioral disclosure. It explicitly reveals the paginated nature, cursor mechanics, and the rationale (non-blocking). It does not mention the exact return structure (e.g., alternating field/value pairs) or that it is read-only, but these are partially implied by the operation name. The added pagination contract goes beyond the schema, which only has key and cursor.

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?

Two sentences, no filler. The primary purpose is front-loaded, and the pagination guidance is concise and immediately actionable. Every word earns its place.

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?

For a 2-parameter tool with no output schema and no annotations, the description covers the essential usage pattern (cursor loop) and the reason for pagination. However, it omits the response format (field-value pairs, the structure of each page) and does not state that it only works on hash keys. An agent might need this to correctly parse results, making the description slightly incomplete.

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%, so the description must compensate. It explains the cursor parameter well: 'Pass the returned cursor back in as `cursor` to continue; 0 means done,' adding dynamic semantics that the schema alone does not convey. The key parameter is obvious from the context of a hash operation.

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 clearly states it returns 'One HSCAN page of a hash's fields,' specifying the operation (HSCAN), the resource (hash fields), and the pagination behavior. It distinguishes itself from siblings like redis_hget (single field) and redis_get (whole key) by its focus on paged iteration.

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 the pagination loop ('Pass the returned cursor back in as `cursor` to continue; 0 means done') and gives a concrete reason to choose this over HGETALL ('can block a shared Redis server'). It implies usage for iterating large hashes without blocking, though it does not explicitly name alternative tools like redis_hget for single-field access.

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