Skip to main content
Glama
mamrrez

Google Search Console MCP Server

build_query_regex

Read-onlyIdempotent

Build a Unicode-safe Search Console regex for a term to match common spellings across scripts and use it as a query_regex filter.

Instructions

Build a Search Console regex for a term that works in any script and matches its common spellings.

Use the result as query_regex in other tools or paste it into the Search Console UI (regex filter). RE2's \b is ASCII-only, so this uses Unicode-safe boundaries; Arabic script gets ی/ي, ک/ك, ه/ة, ا/أ/إ/آ classes with optional vowel marks and half-spaces; digits match Persian, Arabic-Indic and full-width forms; Cyrillic е/ё; case-insensitive. loose=True also lets words run together. Accent and kana variants are not covered.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
termYes
looseNo
whole_wordNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the readOnly/idempotent annotations by disclosing the RE2 ASCII-only \b rationale, the exact script-specific classes generated (Arabic ی/ي, ک/ك, ه/ة, Cyrillic е/ё), digit form handling, case-insensitivity, what loose=True does, and explicit limitations (accent and kana variants not covered). This is unusually rich behavioral context for a pure-computation tool.

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 purpose and usage, then implementation detail; every sentence adds real information about matching behavior. Slightly dense with script-specific minutiae, but the complexity of the tool justifies it.

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?

An output schema exists, so return format need not be explained. Given the tool's complexity, the description covers purpose, usage, matching behavior, edge cases, and limitations thoroughly; nothing an agent needs to invoke it correctly is missing.

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 description coverage is 0%, so the description must carry parameter meaning. It explains loose=True ('lets words run together') and implies boundary handling via the whole_word concept, but never explicitly defines the whole_word parameter or the required term's format beyond 'a term'.

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 specific verb and resource: builds a Search Console regex for a term, with Unicode/spelling-variant scope. It is immediately distinguishable from sibling tools like query_variants or top_terms, which produce data rather than regex patterns.

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?

Explicitly states how to use the output: 'Use the result as query_regex in other tools or paste it into the Search Console UI (regex filter).' This gives clear context, though it does not name the specific sibling tools that accept query_regex or state when-not to use it.

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