Skip to main content
Glama

WordPress: site-wide header and footer snippets

wp_snippets_get
Read-onlyIdempotent

Site-wide snippets printed by header/footer plugins (Header and Footer Scripts, Insert Headers and Footers) and the theme's own script boxes (e.g. _crb_footer_script), each split into its blocks so one can be named exactly for wp_snippet_remove. Each block says whether it is on the live home page now (on_live_page), and each option whether its plugin is active (printing): a stored snippet that isn't printed changes nothing for visitors. Needs Bridge 1.7.0+ (theme boxes and printing 1.7.1+) and an administrator's application password. Changes nothing.

Input Schema

NameRequiredDescriptionDefault
siteYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

B3.4/5.0
Behavior4/5

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

Beyond the readOnlyHint/idempotent annotations, the description discloses real prerequisites: Bridge 1.7.0+ (1.7.1+ for theme boxes and printing) and an administrator's application password, plus the 'Changes nothing' confirmation. It also explains the semantic distinction between on_live_page and printing (a stored snippet that isn't printed changes nothing for visitors), which is genuine behavioral insight an agent could not get from annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

It is a single dense run-on sentence with stacked parentheticals that packs a lot of value but reads poorly. The resource is front-loaded correctly, yet the version and auth prerequisites are buried mid-sentence rather than surfaced as a separate note.

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?

With no output schema, the description does the work of describing the return shape: snippets split into blocks, each block carrying on_live_page, each option carrying printing. Combined with the auth/version prerequisites, an agent can call and interpret this correctly; only the identification of 'site' remains underspecified.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% and the single parameter 'site' is never explained – the description does not say whether it is a URL, a site key from wp_list_sites, or a connected-account identifier. With only one parameter this is a small surface area, but the description leaves the agent to guess the accepted form.

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 names the exact resource (site-wide header/footer snippets from Header and Footer Scripts, Insert Headers and Footers, and theme script boxes like _crb_footer_script) and explains that it returns them split into blocks. It is clearly distinguishable from siblings, though it never states the verb directly – the reader infers 'retrieve/list' from the name and from the reference to wp_snippet_remove.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied rather than stated: blocks are returned 'so one can be named exactly for wp_snippet_remove', which tells the agent this is a lookup step preceding removal. There is no explicit when-not guidance or comparison against alternatives such as wp_theme_options_get or wp_check_site.

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.