Skip to main content
Glama
SEO-Review-Tools

SEO Review Tools - MCP server

Official

get_keyword_statistics

Retrieve keyword statistics including search volume, competition, and trends to analyze SEO performance and identify optimization opportunities.

Instructions

Get keyword statistics from SEO Review Tools.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keywordsYesThe keywords to get statistics for.
hlNoThe language for the response.
locationNoThe location for the keyword statistics.

Implementation Reference

  • The handler function `executeFunction` that implements the core logic: constructs and sends a POST request to the SEO Review Tools API for keyword statistics, handles response and errors.
    const executeFunction = async ({ keywords, hl = 'English', location = 'United States' }) => {
      const baseUrl = 'https://api.seoreviewtools.com/keyword-statistics/';
      const token = process.env.SEO_API_WORKSPACE_API_KEY;
    
      try {
        // Construct the request body
        const body = JSON.stringify({ keywords });
    
        // Set up headers for the request
        const headers = {
          'Content-Type': 'application/json',
          'X-API-Key': token
        };
    
        // Construct the URL with query parameters
        const url = new URL(baseUrl);
        url.searchParams.append('hl', hl);
        url.searchParams.append('location', location);
    
        // Perform the fetch request
        const response = await fetch(url.toString(), {
          method: 'POST',
          headers,
          body
        });
    
        // Check if the response was successful
        if (!response.ok) {
          const errorData = await response.json();
          throw new Error(errorData);
        }
    
        // Parse and return the response data
        const data = await response.json();
        return data;
      } catch (error) {
        console.error('Error getting keyword statistics:', error);
        return { error: 'An error occurred while getting keyword statistics.' };
      }
    };
  • The JSON schema defining the tool's input parameters: required 'keywords' array, optional 'hl' and 'location' strings.
    parameters: {
      type: 'object',
      properties: {
        keywords: {
          type: 'array',
          items: {
            type: 'string'
          },
          description: 'The keywords to get statistics for.'
        },
        hl: {
          type: 'string',
          description: 'The language for the response.'
        },
        location: {
          type: 'string',
          description: 'The location for the keyword statistics.'
        }
      },
      required: ['keywords']
    }
  • The `apiTool` export containing the handler reference, tool name, description, and schema; loaded dynamically by `discoverTools()`.
    const apiTool = {
      function: executeFunction,
      definition: {
        type: 'function',
        function: {
          name: 'get_keyword_statistics',
          description: 'Get keyword statistics from SEO Review Tools.',
          parameters: {
            type: 'object',
            properties: {
              keywords: {
                type: 'array',
                items: {
                  type: 'string'
                },
                description: 'The keywords to get statistics for.'
              },
              hl: {
                type: 'string',
                description: 'The language for the response.'
              },
              location: {
                type: 'string',
                description: 'The location for the keyword statistics.'
              }
            },
            required: ['keywords']
          }
        }
      }
    };
    
    export { apiTool };
  • tools/paths.js:1-10 (registration)
    The `toolPaths` array includes the path to this tool's module, used by `discoverTools()` to dynamically import it.
    export const toolPaths = [
      'seo-api-workspace/seo-ap-is-seo-review-tools/get-website-traffic.js',
      'seo-api-workspace/seo-ap-is-seo-review-tools/get-authority.js',
      'seo-api-workspace/seo-ap-is-seo-review-tools/get-serp.js',
      'seo-api-workspace/seo-ap-is-seo-review-tools/post-bulk-website-traffic.js',
      'seo-api-workspace/seo-ap-is-seo-review-tools/get-backlinks.js',
      'seo-api-workspace/seo-ap-is-seo-review-tools/get-seo-content-score.js',
      'seo-api-workspace/seo-ap-is-seo-review-tools/get-keyword-statistics.js',
      'seo-api-workspace/seo-ap-is-seo-review-tools/get-keyword-suggestions.js'
    ];
  • lib/tools.js:7-16 (registration)
    The `discoverTools()` function dynamically imports all tools from `toolPaths`, including this one, and extracts the `apiTool` for registration in the MCP server.
    export async function discoverTools() {
      const toolPromises = toolPaths.map(async (file) => {
        const module = await import(`../tools/${file}`);
        return {
          ...module.apiTool,
          path: file,
        };
      });
      return Promise.all(toolPromises);
    }
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure but only states the basic action without details on permissions, rate limits, response format, or potential side effects. This is inadequate for a tool that likely involves external API calls and data retrieval.

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 with zero wasted words, making it easy to parse and understand quickly. It's appropriately sized for its purpose without unnecessary elaboration.

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 complexity of keyword statistics tools, no annotations, and no output schema, the description is insufficient. It lacks details on what statistics are returned, how results are structured, or any behavioral traits, leaving significant gaps for agent understanding.

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%, so the schema already documents all parameters (keywords, hl, location) adequately. The description adds no additional meaning beyond what the schema provides, such as examples or constraints, resulting in a baseline score.

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 ('Get') and resource ('keyword statistics from SEO Review Tools'), making the purpose immediately understandable. However, it doesn't differentiate this tool from sibling tools like 'get_keyword_suggestions' or 'get_serp', which might also involve keyword-related data, 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 like 'get_keyword_suggestions' or 'get_serp'. It lacks context about specific use cases, prerequisites, or exclusions, leaving the agent with minimal direction for tool selection.

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/SEO-Review-Tools/SEO-API-MCP'

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