Skip to main content
Glama

wp_seo_test_integration

Test SEO plugin integration on WordPress sites to detect installed plugins and verify metadata access for proper SEO functionality.

Instructions

Test SEO plugin integration and detect available SEO plugins on the WordPress site

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteNoSite identifier for multi-site setups
checkPluginsNoCheck which SEO plugins are installed and active
testMetadataAccessNoTest ability to read/write SEO metadata

Implementation Reference

  • Core implementation of the wp_seo_test_integration tool logic, performing SEO plugin detection, metadata access tests, and generating recommendations.
    /**
     * Test SEO plugin integration and WordPress API connectivity
     */
    async testSEOIntegration(params: SEOToolParams): Promise<unknown> {
      const siteLogger = LoggerFactory.tool("wp_seo_test_integration", params.site);
    
      return await siteLogger.time("Test SEO integration", async () => {
        try {
          const seoClient = await this.getSEOClient(params.site);
    
          // Test the integration
          const integrationTest = await seoClient.testSEOIntegration();
    
          // Get some sample SEO data
          let sampleSEOData = null;
          if (integrationTest.canReadMetadata && integrationTest.samplePostsWithSEO > 0) {
            try {
              const posts = await seoClient.getPosts({ per_page: 1, status: ["publish"] });
              if (posts && posts.length > 0) {
                sampleSEOData = await seoClient.getSEOMetadata(posts[0].id);
              }
            } catch (_error) {
              // Sample data fetch failed, but that's okay
              this.logger.debug("Failed to fetch sample SEO data", { _error: _error });
            }
          }
    
          const result = {
            integrationTest,
            sampleSEOData,
            recommendations: this.generateIntegrationRecommendations(integrationTest),
            testedAt: new Date().toISOString(),
          };
    
          siteLogger.info("SEO integration test completed", {
            plugin: integrationTest.pluginDetected,
            canRead: integrationTest.canReadMetadata,
            canWrite: integrationTest.canWriteMetadata,
            postsWithSEO: integrationTest.samplePostsWithSEO,
          });
    
          return result;
        } catch (_error) {
          handleToolError(_error, "test SEO integration", {
            site: params.site,
          });
          throw _error;
        }
      });
    }
  • MCP protocol handler entry point for wp_seo_test_integration, parses arguments and delegates to SEOTools.testSEOIntegration method.
    export async function handleTestSEOIntegration(
      client: WordPressClient,
      args: Record<string, unknown>,
    ): Promise<unknown> {
      const logger = LoggerFactory.tool("wp_seo_test_integration");
    
      try {
        const seoTools = getSEOToolsInstance();
        const params: SEOToolParams = {
          checkPlugins: args.checkPlugins as boolean,
          testMetadataAccess: args.testMetadataAccess as boolean,
          site: args.site as string,
        };
    
        return await seoTools.testSEOIntegration(params);
      } catch (error) {
        logger.error("Failed to test SEO integration", { error, args });
        throw error;
      }
    }
  • Tool definition including name, description, and input schema for wp_seo_test_integration.
    export const testSEOIntegrationTool: Tool = {
      name: "wp_seo_test_integration",
      description: "Test SEO plugin integration and detect available SEO plugins on the WordPress site",
      inputSchema: {
        type: "object",
        properties: {
          checkPlugins: {
            type: "boolean",
            description: "Check which SEO plugins are installed and active",
          },
          testMetadataAccess: {
            type: "boolean",
            description: "Test ability to read/write SEO metadata",
          },
          site: {
            type: "string",
            description: "Site identifier for multi-site setups",
          },
        },
        required: [],
      },
    };
  • Handler mapping registration that associates 'wp_seo_test_integration' with its handler function for MCP tool registration.
    const handlers: Record<string, unknown> = {
      wp_seo_analyze_content: handleAnalyzeContent,
      wp_seo_generate_metadata: handleGenerateMetadata,
      wp_seo_bulk_update_metadata: handleBulkUpdateMetadata,
      wp_seo_generate_schema: handleGenerateSchema,
      wp_seo_validate_schema: handleValidateSchema,
      wp_seo_suggest_internal_links: handleSuggestInternalLinks,
      wp_seo_site_audit: handlePerformSiteAudit,
      wp_seo_track_serp: handleTrackSERPPositions,
      wp_seo_keyword_research: handleKeywordResearch,
      wp_seo_test_integration: handleTestSEOIntegration,
      wp_seo_get_live_data: handleGetLiveSEOData,
    };
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions testing and detection but doesn't clarify key traits: whether this is a read-only or write operation, potential side effects (e.g., if testing metadata access involves writes), performance impact, or error handling. For a tool with no annotation coverage, this is a significant gap in transparency.

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 purpose without unnecessary words. It's front-loaded with the core functionality and appropriately sized for its scope, making it easy to parse quickly.

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 testing and detection operations, the description is incomplete. No annotations are provided to clarify safety or behavior, and there's no output schema to explain return values. The description lacks details on what 'test' entails (e.g., diagnostic output, success/failure indicators) or how results are presented, leaving gaps for an agent to understand the tool fully.

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 description adds no parameter-specific information beyond what the input schema provides. Since schema description coverage is 100%, the schema already documents all three parameters (site, checkPlugins, testMetadataAccess) with clear descriptions. The baseline score of 3 is appropriate as the schema does the heavy lifting, and the description doesn't add extra semantic context.

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 tool's purpose: 'Test SEO plugin integration and detect available SEO plugins on the WordPress site.' It specifies the verb ('test' and 'detect') and resource ('SEO plugin integration' and 'available SEO plugins'), making it understandable. However, it doesn't explicitly differentiate from sibling SEO tools like 'wp_seo_analyze_content' or 'wp_seo_site_audit', which keeps it from a perfect 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. It doesn't mention any prerequisites, exclusions, or specific contexts for usage, such as during site setup or troubleshooting. With many sibling tools available, including other SEO-related ones, this lack of differentiation leaves the agent without clear usage cues.

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/docdyhr/mcp-wordpress'

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