Skip to main content
Glama

get_post

Read-only

Retrieve a single WordPress post or page by ID with full content in raw, rendered, or plain text format, ready to pass back unchanged for updates.

Instructions

Retrieve a single WordPress post or page by ID, including its full content. By default the content is the editable source (with Gutenberg block markup), which can be passed back to update_post unchanged.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "post_id": "<post_id>"
    },
    "name": "get_post"
  }
}

Input Schema

NameRequiredDescriptionDefault
formatNoHow to return the content. 'raw': editable source (requires edit permission; falls back to rendered HTML otherwise). 'rendered': HTML as displayed on the site. 'text': plain text with tags removed. Defaults to 'raw'.raw
post_idYesPost or page ID to retrieve
post_typeNoContent type to retrieve. Defaults to 'post'.post

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare read-only and closed-world behavior; the description adds that default content is editable source with Gutenberg block markup and is safe for round-tripping to update_post. It does not cover error cases or returned metadata, but the added context is meaningful.

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?

Two sentences, front-loaded with purpose and then the important default/round-trip caveat. No redundant or filler wording.

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

Completeness4/5

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

For a simple read-only fetch tool with complete schema documentation and annotations, the description covers the resource, identifier, content scope, and default format behavior. It could mention the returned post object shape, but output details are less critical for this retrieval tool.

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 coverage is 100% and the schema fully documents post_id, post_type, and the format enum including raw fallback behavior. The description restates the default raw/editable-source behavior but adds little parameter-level meaning beyond the schema.

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?

States a specific verb ('Retrieve'), resource ('single WordPress post or page'), identifier ('by ID'), and scope ('including its full content'). It implicitly distinguishes single-item retrieval from list siblings like get_posts/get_pages, though it does not name them.

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?

Explains the default content mode and the round-trip use case: pass the raw content back to update_post unchanged. Gives clear context but no explicit when-not-to-use guidance or named alternatives such as get_posts/get_pages.

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