Skip to main content
Glama

wp_set_seo_meta

Set a page's SEO META DESCRIPTION, SEO title, ROBOTS directive and/or CANONICAL URL — the go-to tool for 'fix my missing meta description' and for keeping a draft/duplicate out of the index (robots='noindex,nofollow'). Omit post_id to target the homepage. Writes the active SEO plugin's fields (Yoast/RankMath/AIOSEO); if the site has NO SEO plugin the XeoRank Connector renders the tags itself, so this works on any WordPress site. The response echoes applied_values READ BACK from the provider — trust that, not the input. Requires Connector >= 0.7.5; robots/canonical_url need >= 0.9.17 (on error='connector_update_required', tell the user to update the plugin). Keep descriptions 70–165 characters.

Input Schema

NameRequiredDescriptionDefault
robotsNoRobots directive: 'noindex,nofollow', 'noindex', 'index,follow', … Unknown tokens are refused, never ignored.
post_idNoPage/post ID. Omit for the homepage (static front page).
site_idYesThe WordPress site ID
seo_titleNoOptional SEO title override
canonical_urlNoAbsolute http(s) canonical URL for the page (e.g. point a duplicate at its original)
meta_descriptionNoThe meta description text (70–165 chars recommended)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the annotations: it discloses the write target (active SEO plugin's fields), a fallback path when no plugin exists, the required Connector versions per field, the specific error code and remediation ('connector_update_required'), and critically that the response's applied_values are read back from the provider and should be trusted over the input. This is exactly the mutation context annotations cannot carry.

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-loads the core action and packs version requirements, fallback behavior, and response-trust guidance into one dense paragraph with no filler. Slightly long, but nearly every clause carries operational value; only the character-count reminder is redundant with the schema.

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?

With no output schema, the description compensates by explaining the return contract (applied_values read back from the provider). It also covers mutation scope, plugin-fallback behavior, version gating, and error handling, leaving nothing an agent needs to invoke it safely.

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 both robots token behavior and the homepage default are already documented in the schema. The description's '70–165 characters' and post_id-omission notes largely restate that, adding little new syntax or format meaning beyond what the schema provides. Baseline 3 is appropriate.

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 ('Set') plus the exact resources touched (meta description, SEO title, robots directive, canonical URL), and immediately contrasts with the read-side sibling wp_get_seo_meta. An agent can route correctly without opening the schema.

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?

Gives concrete trigger scenarios ('fix my missing meta description', keeping a draft/duplicate out of the index) and the homepage targeting rule (omit post_id). It stops short of naming when NOT to use it versus siblings like generate_schema_markup or wp_patch_page, so it is clear context rather than explicit exclusion guidance.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources