Skip to main content
Glama
Jambozx

OnlineCyberTools MCP (280+ filterable tools)

by Jambozx

text_find_replace

Read-onlyIdempotent

Find and replace text substrings with optional regex patterns, case sensitivity, and replace-all or first-match control.

Instructions

Find and Replace Text with Optional Regex. Find and replace substrings in a block of text, with optional case-insensitive matching, JavaScript regular-expression patterns, and a replace-all-versus-first-match toggle. Use this for literal or regex search-and-replace; use webdev_regex_tester to test a pattern before applying it, or text_text_splitter to break text on a delimiter instead of rewriting it. Returns a new string and never mutates the input. Runs locally on the text you provide: read-only, contacts no external service, and is rate-limited (30 requests/minute for anonymous callers). Returns the rewritten text plus before/after statistics and found/replaced/remaining match counts.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesSource text to search within. Must not be empty (empty returns HTTP 400).
findTextYesSubstring or regex pattern to find. Must not be empty (empty returns HTTP 400). Interpreted as a regular expression when useRegex is true.
replaceTextNoReplacement string substituted for each match. Defaults to empty (which deletes matches).
caseSensitiveNoWhen false (default), matching ignores letter case. When true, case must match exactly.
useRegexNoWhen true, findText is treated as a JavaScript regular expression. An invalid pattern returns HTTP 400.
replaceAllNoWhen true (default), replaces every match. When false, replaces only the first match.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
successNoTrue when the operation succeeded.
resultNoThe rewritten text after replacements.
statsNoBefore/after text metrics and match accounting.
optionsNoEcho of the normalized options applied.

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Changed4 schema fields changedv0.5.1
    • changedInput schema / additionalProperties
      Previous value: -trueNew value: +false
    • addedInput schema / properties
      Added value: +{
      +  "caseSensitive": {
      +    "default": false,
      +    "description": "When false (default), matching ignores letter case. When true, case must match exactly.",
      +    "type": "boolean"
      +  },
      +  "findText": {
      +    "description": "Substring or regex pattern to find. Must not be empty (empty returns HTTP 400). Interpreted as a regular expression when useRegex is true.",
      +    "type": "string"
      +  },
      +  "replaceAll": {
      +    "default": true,
      +    "description": "When true (default), replaces every match. When false, replaces only the first match.",
      +    "type": "boolean"
      +  },
      +  "replaceText": {
      +    "default": "",
      +    "description": "Replacement string substituted for each match. Defaults to empty (which deletes matches).",
      +    "type": "string"
      +  },
      +  "text": {
      +    "description": "Source text to search within. Must not be empty (empty returns HTTP 400).",
      +    "type": "string"
      +  },
      +  "useRegex": {
      +    "default": false,
      +    "description": "When true, findText is treated as a JavaScript regular expression. An invalid pattern returns HTTP 400.",
      +    "type": "boolean"
      +  }
      +}
    • addedInput schema / required
      Added value: +[
      +  "text",
      +  "findText"
      +]
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "options": {
      +      "description": "Echo of the normalized options applied.",
      +      "properties": {
      +        "caseSensitive": {
      +          "description": "Whether matching was case-sensitive.",
      +          "type": "boolean"
      +        },
      +        "findText": {
      +          "description": "The find pattern used.",
      +          "type": "string"
      +        },
      +        "replaceAll": {
      +          "description": "Whether all matches were replaced.",
      +          "type": "boolean"
      +        },
      +        "replaceText": {
      +          "description": "The replacement string used.",
      +          "type": "string"
      +        },
      +        "useRegex": {
      +          "description": "Whether findText was treated as regex.",
      +          "type": "boolean"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "result": {
      +      "description": "The rewritten text after replacements.",
      +      "type": "string"
      +    },
      +    "stats": {
      +      "description": "Before/after text metrics and match accounting.",
      +      "properties": {
      +        "matches": {
      +          "description": "Match accounting for the operation.",
      +          "properties": {
      +            "found": {
      +              "description": "Total matches found for findText.",
      +              "type": "integer"
      +            },
      +            "remaining": {
      +              "description": "Matches left unreplaced (found minus replaced).",
      +              "type": "integer"
      +            },
      +            "replaced": {
      +              "description": "Number of matches actually replaced.",
      +              "type": "integer"
      +            }
      +          },
      +          "type": "object"
      +        },
      +        "original": {
      +          "description": "Statistics for the input text.",
      +          "properties": {
      +            "characters": {
      +              "description": "Unicode code-point count of the original text.",
      +              "type": "integer"
      +            },
      +            "length": {
      +              "description": "UTF-8 byte length of the original text.",
      +              "type": "integer"
      +            },
      +            "lines": {
      +              "description": "Newline-separated line count of the original text.",
      +              "type": "integer"
      +            },
      +            "text": {
      +              "description": "The original text.",
      +              "type": "string"
      +            },
      +            "words": {
      +              "description": "Count of alphabetic word runs in the original text.",
      +              "type": "integer"
      +            }
      +          },
      +          "type": "object"
      +        },
      +        "result": {
      +          "description": "Statistics for the rewritten text.",
      +          "properties": {
      +            "characters": {
      +              "description": "Unicode code-point count of the rewritten text.",
      +              "type": "integer"
      +            },
      +            "length": {
      +              "description": "UTF-8 byte length of the rewritten text.",
      +              "type": "integer"
      +            },
      +            "lines": {
      +              "description": "Newline-separated line count of the rewritten text.",
      +              "type": "integer"
      +            },
      +            "text": {
      +              "description": "The rewritten text.",
      +              "type": "string"
      +            },
      +            "words": {
      +              "description": "Count of alphabetic word runs in the rewritten text.",
      +              "type": "integer"
      +            }
      +          },
      +          "type": "object"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "success": {
      +      "description": "True when the operation succeeded.",
      +      "type": "boolean"
      +    }
      +  },
      +  "type": "object"
      +}
  2. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations (readOnlyHint, destructiveHint, idempotentHint), the description adds important behavioral details: runs locally, never mutates input, contacts no external service, and specifies rate limits (30 req/min for anonymous). It also explains what the return includes (statistics, counts). No contradiction with annotations.

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?

The description is well-structured: a clear purpose sentence, followed by usage guidance, then behavioral details. It is informative without being verbose. Could be slightly more concise by removing the 'Find and Replace Text with Optional Regex' repetition, but overall efficient.

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?

Given the tool's 6 parameters, 2 required, and the existence of an output schema, the description fully covers all relevant aspects: input constraints (empty returns HTTP 400), behavior (local, read-only, rate-limited), return value (statistics, counts), and alternatives. No gaps remain.

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?

The input schema already has 100% coverage with clear descriptions for all 6 parameters. The description's high-level summary of features (case-insensitive, regex, replace-all toggle) provides minimal additional meaning beyond the schema. Baseline 3 is appropriate here.

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 the tool performs find-and-replace on text with optional regex, and directly distinguishes itself from siblings like webdev_regex_tester and text_text_splitter by naming specific use cases for each. This meets the highest standard of purpose clarity.

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

Usage Guidelines5/5

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

The description explicitly tells when to use this tool ('for literal or regex search-and-replace') and provides named alternatives ('use webdev_regex_tester to test a pattern before applying it, or text_text_splitter to break text on a delimiter'). This is exemplary guidance.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Jambozx/onlinecybertools-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server