Skip to main content
Glama

Agent Data Tools: Company, compliance and checks

PII detection and redaction: emails, phones, cards, IBANs

text_pii
Read-only

Find personal data in a text and get it back redacted: emails, phone numbers, card numbers (Luhn-checked), IBANs (mod-97), US SSNs, IP and crypto wallet addresses, each with its position, plus the text with every hit replaced by a label such as [EMAIL]. Hits are shown masked. Up to 20,000 characters; names and street addresses are not detected. Use before logging, storing or sending text to a model. Example: text=Contact Anna at anna.berg@example.com or +46 70 123 45 67; card 4111 1111 1111 1111.. Price $0.01/call via x402 USDC or a card key (/credits), first 10 free; failed calls free. Reads or computes only and changes nothing; each call is charged, so repeats are not free.

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": "text_pii"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesThe text to scan (up to 20,000 characters)
typesNoOptional comma-separated types to look for: email, iban, credit_card, us_ssn, crypto_address, ip_address, phone (default all)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnly and non-destructive, and the description adds substantial context they do not carry: hits are returned masked, validation methods (Luhn, mod-97) are disclosed, the 20,000-character limit is stated, and billing is spelled out ($0.01/call via x402 USDC or credits, first 10 free, failed calls free). The note that repeats are not free is consistent with idempotentHint=false and usefully warns the agent before retrying.

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 with the core action and entity list, then limits, exclusions, example, and cost in descending priority. Dense but every clause carries information; the pricing/payment-method clause is the one spot that could be trimmed without losing agent-relevant meaning.

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?

Covers everything needed to call it correctly: input constraint, unsupported entity types, output shape (positions plus labelled text, masked hits), validation rigor, and cost model. No output schema exists, yet the description adequately explains what comes back, so nothing material is missing.

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 100%, so the baseline is 3, but the worked example ('text=Contact Anna at anna.berg@example.com or +46 70 123 45 67; card 4111 1111 1111 1111') demonstrates the expected input shape and reinforces the Luhn-checked card behavior. The `types` filter is left to the schema, which already enumerates its values, so this is additive without being redundant.

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?

States a concrete verb and resource ('Find personal data in a text and get it back redacted') and immediately enumerates the exact entity classes covered (emails, phones, Luhn-checked cards, mod-97 IBANs, SSNs, IPs, wallet addresses). It also names what it produces (positions plus labelled replacement text), which distinguishes it from extraction or summarization siblings.

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?

Gives a clear triggering context: 'Use before logging, storing or sending text to a model.' It also bounds the tool with explicit negative guidance ('names and street addresses are not detected') and a size ceiling of 20,000 characters. It stops short of naming a sibling alternative for cases outside its coverage, so it is strong but not fully routing.

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