Skip to main content
Glama
Cicatriiz

Consumer Rights Wiki MCP Server

search_wiki

Search the Consumer Rights Wiki to find articles about privacy violations, dark patterns, and deceptive pricing practices. Get information on modern consumer exploitation issues.

Instructions

Search for articles in the Consumer Rights Wiki

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesSearch query
limitNoNumber of results to return (default: 10, max: 50)

Implementation Reference

  • The main handler function that implements the logic for the 'search_wiki' tool. It destructures the input arguments, makes an API request to the wiki search endpoint, processes the response, and returns formatted search results including titles, snippets, sizes, and URLs.
    private async searchWiki(args: any) {
      const { query, limit = 10 } = args;
    
      const data = await this.makeApiRequest({
        action: 'query',
        list: 'search',
        srsearch: query,
        srlimit: Math.min(limit, 50).toString(),
        srprop: 'size|wordcount|timestamp|snippet',
      });
    
      if (data.error) {
        throw new McpError(ErrorCode.InternalError, data.error.info);
      }
    
      const results = data.query?.search || [];
    
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify({
              query: query,
              totalResults: data.query?.searchinfo?.totalhits || 0,
              results: results.map((result: any) => ({
                title: result.title,
                size: result.size,
                wordcount: result.wordcount,
                timestamp: result.timestamp,
                snippet: result.snippet.replace(/<[^>]*>/g, ''), // Remove HTML tags
                url: `${WIKI_BASE_URL}/${result.title.replace(/ /g, '_')}`,
              })),
            }, null, 2),
          },
        ],
      };
    }
  • The input schema for the 'search_wiki' tool, defining the expected parameters: a required 'query' string and an optional 'limit' number (default 10, max 50).
    inputSchema: {
      type: 'object',
      properties: {
        query: {
          type: 'string',
          description: 'Search query',
        },
        limit: {
          type: 'number',
          description: 'Number of results to return (default: 10, max: 50)',
          default: 10,
        },
      },
      required: ['query'],
    },
  • src/index.ts:63-81 (registration)
    The tool descriptor registration for 'search_wiki' in the ListTools response, including name, description, and input schema.
    {
      name: 'search_wiki',
      description: 'Search for articles in the Consumer Rights Wiki',
      inputSchema: {
        type: 'object',
        properties: {
          query: {
            type: 'string',
            description: 'Search query',
          },
          limit: {
            type: 'number',
            description: 'Number of results to return (default: 10, max: 50)',
            default: 10,
          },
        },
        required: ['query'],
      },
    },
  • src/index.ts:169-170 (registration)
    The switch case in the CallToolRequest handler that routes calls to the 'search_wiki' handler function.
    case 'search_wiki':
      return this.searchWiki(request.params.arguments);
Behavior2/5

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

No annotations are provided, so the description carries full burden for behavioral disclosure. It mentions searching but doesn't describe how results are returned (e.g., relevance ranking, pagination), what fields are included in results, error conditions, or performance characteristics. For a search tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

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 a single, efficient sentence that directly states the tool's function without unnecessary words. It's front-loaded with the core purpose and avoids redundancy, making it easy to parse quickly. Every part of the sentence contributes essential information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the lack of annotations and output schema, the description is insufficient for a search tool. It doesn't explain what the search returns (e.g., article titles, snippets, metadata), how results are structured, or any limitations like timeouts or result quality. For a tool with 2 parameters and no structured output documentation, more context is needed to use it effectively.

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 100%, with both parameters ('query' and 'limit') well-documented in the schema itself. The description doesn't add any parameter-specific information beyond what the schema provides, such as search syntax examples or result format details. This meets the baseline for high schema coverage but doesn't enhance understanding.

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 action ('Search for articles') and resource ('Consumer Rights Wiki'), making the purpose immediately understandable. However, it doesn't differentiate this search tool from potential sibling tools like 'get_recent_changes' or 'get_categories' that might also retrieve wiki content, so it doesn't reach the highest score.

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?

The description provides no guidance on when to use this tool versus alternatives. With siblings like 'get_page_content' and 'get_page_info' available, there's no indication whether this is for general discovery, specific lookups, or how it differs from other retrieval methods. It merely states what it does, not when to choose it.

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/Cicatriiz/consumer-rights-wiki-mcp'

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