Skip to main content
Glama

Get Page HTML

wp_get_page_html
Read-only

Retrieve the rendered HTML of any page on the connected WordPress site. Use this to verify changes you made actually rendered correctly — check headlines, content, meta tags, links, or layout after creating/updating posts, pages, or theme files. Returns cleaned HTML (scripts and styles stripped to save tokens). Supports public pages, drafts (via preview), and custom URLs.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoPage URL on the connected site (e.g. "https://example.com/about"). Must belong to the connected site — external URLs are rejected. If omitted, fetches the homepage.
post_idNoPost/page ID to fetch. Automatically resolves the permalink. Works for drafts too.
site_idNoSite ID to target (optional if you have only one connected site)
selectorNoCSS selector to extract a specific section (e.g. "article", ".entry-content", "#main"). Returns only the matched element's HTML. Omit to get the full page body.
include_metaNoIf true, also returns <head> meta tags (title, description, og:tags, canonical). Useful for SEO verification. Default: false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / url / description
      Previous value: -"Full page URL to fetch (e.g. \"https://example.com/about\"). If omitted, fetches the homepage."New value: +"Page URL on the connected site (e.g. \"https://example.com/about\"). Must belong to the connected site — external URLs are rejected. If omitted, fetches the homepage."
  2. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already cover safety (readOnly, non-destructive, openWorld), so the bar is lower. The description adds real behavioral value: output is cleaned HTML with scripts and styles stripped to save tokens, drafts are reachable via preview, and external URLs are rejected — none of which is in the annotations.

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?

Three tight sentences, front-loaded with the core action, then the use case, then the return behavior. The verification examples (headlines, meta tags, links, layout) earn their place by clarifying what 'verify' means.

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?

No output schema exists, so the description must explain return values — and it does ('Returns cleaned HTML (scripts and styles stripped to save tokens)'), along with the supported URL/draft cases. An agent has everything needed to call it correctly.

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 every parameter is already documented (url, post_id, site_id, selector, include_meta). The description adds no parameter-level detail beyond the schema, so the baseline 3 applies.

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 (retrieve) and resource (rendered HTML of a page) and clarifies the value proposition: seeing what actually rendered, which distinguishes it from structured-data siblings like wp_get_page or wp_get_post.

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 explicit when-to-use context ('verify changes you made actually rendered correctly' after create/update operations) and notes supported cases (public pages, drafts via preview, custom URLs). It stops short of naming an alternative sibling to use instead when you want structured data rather than HTML.

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