Skip to main content
Glama

mask_text

Mask sensitive parts of a string, such as emails or card numbers, keeping a configurable number of characters at each end. Pure CPU, instant.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "text": "<text>"
    },
    "name": "mask_text"
  }
}

Input Schema

NameRequiredDescriptionDefault
keepNoCharacters to keep at each end
textYesText to mask

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added
  2. Removed
  3. Changed3 schema fields changed
    • addedInput schema / properties / keep
      Added value: +{
      +  "description": "Characters to keep at each end",
      +  "type": "integer"
      +}
    • addedInput schema / properties / text
      Added value: +{
      +  "description": "Text to mask",
      +  "type": "string"
      +}
    • addedInput schema / required
      Added value: +[
      +  "text"
      +]
  4. Added

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden. It usefully discloses that the operation is 'Pure CPU, instant' — implying no network call, no auth, and deterministic low-latency behavior — but it never says what the masked characters are replaced with, how short strings are handled, or that the transformation is lossy and irreversible.

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 short sentences, front-loaded with the core action and followed by a useful performance note. No filler, no repetition of the tool name, and the key qualifier about kept characters arrives before the trailing detail.

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 two-parameter, annotation-free utility with a fully documented schema and no output schema, the description is close to sufficient: purpose, examples, and cost profile are all present. The one real omission is the shape of the returned value (replacement character and formatting), which an agent would still have to discover by calling it.

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

Parameters3/5

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

Schema coverage is 100%, with both 'keep' and 'text' described in the schema, so the baseline is 3. The description restates 'keep' as 'a configurable number of characters at each end' and adds value by illustrating which text to target (emails, card numbers), but adds no syntax, default, or edge-case meaning beyond the schema.

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 names a specific verb and resource ('Mask sensitive parts of a string') and grounds it with concrete examples (emails, card numbers) plus the governing rule (keep N characters at each end). It is immediately distinguishable from data-generating siblings like hash_text or generate_uuid. It does not explicitly name a sibling alternative, which keeps it just short of a 5.

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?

Use is implied by the examples of sensitive data, so an agent can infer this is the redaction/PII tool. However, there is no explicit when-to-use/when-not guidance and no pointer to related tools such as truncate, text_replace, or hash_text that might be confused with masking.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources