Skip to main content
Glama
BerkantACUN

redis-guard-mcp

by BerkantACUN

redis_ttl

Check a Redis key's remaining time to live in seconds, where -1 means no expiry and -2 indicates the key does not exist.

Instructions

Seconds until a key expires. -1 = no expiry, -2 = key doesn't exist.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It does explain the return value semantics (-1 for no expiry, -2 for missing key), which is valuable. However, it does not explicitly state that the operation is read-only or non-destructive, nor does it mention any error conditions or permissions. Given the simplicity of a TTL check, this is adequate but not comprehensive.

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 exceptionally concise—two short sentences that immediately convey the core purpose and the critical return-value special cases. There is no filler or redundancy; every word serves a purpose. The main function is front-loaded, and the clarifying value definitions are placed right after. This is a model of efficiency.

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 simple tool with one parameter and no output schema, the description covers the essential behaviors: what it returns and the special sentinel values. It does not discuss error handling, but that is likely covered by the general Redis connection context. The description is nearly complete for its scope, though it could explicitly note that it is a read-only operation.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate for the sparse schema. The description references 'a key' in the first sentence, which implicitly ties to the `key` parameter, but it adds no additional detail about the parameter's format, constraints, or behavior. The schema already specifies the parameter as a string, so the description provides only minimal semantic enhancement.

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's function: it returns the time-to-live in seconds for a key, with explicit meanings for -1 and -2. Though it does not explicitly use a verb like 'returns', the intent is unambiguous. It is distinct from sibling tools like redis_get or redis_type because it focuses specifically on TTL semantics.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus alternatives such as redis_exists or redis_type. There is no mention of situations where TTL checks are preferred, nor any exclusions or prerequisites. The description implies its use for checking expiry but does not give explicit selection criteria.

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