| 开发者 | helpstring |
|---|---|
| 更新时间 | 2026年10月5日 00:08 |
| PHP版本: | 7.4 及以上 |
| WordPress版本: | 7.1 |
| 版权: | GPLv2 or later |
| 版权网址: | 版权信息 |
create_post / update_post — common core post fields: title, content,
excerpt, slug, author, scheduling date (planned posts), comment and ping
status, password protection, sticky, post format, page attributes
(parent, template, order).categories_names / tags_names resolve names to
terms; missing tags are created automatically.list_posts, get_post, get_post_markdown — search and read content in
agent-friendly formats.list_comments, moderate_comment — triage the comment queue: the agent
sorts pending comments and spam, you decide what gets approved. Author
email and IP address are never handed to the agent.list_revisions, compare_revisions, restore_revision — read a post's
revision history and roll back to an earlier one. Restoring follows the
same review boundary as update_post (published or scheduled content
cannot be touched) and is itself reversible, because WordPress saves the
pre-restore state as a new revision before restoring.list_terms, get_site_info, get_activity — context and audit trail.upload_media, upload_media_base64 — media library uploads.webmcp_cockpit_tools filter — anything a PHP callback can do becomes an
agent tool.apply_filters( 'webmcp_cockpit_tools', $tools ) with a name, description,
JSON schema and PHP callback. Custom tools appear alongside the built-in ones
in the browser agent's tool list.
ostheimer-webmcp-cockpit folder to /wp-content/plugins/, or install
it through the WordPress plugin directory.document.modelContext). Chrome 149+
offers WebMCP through an origin trial or the
chrome://flags/#enable-webmcp-testing flag for local testing. WebMCP is in
early preview and its API may change.No. By design the agent can only create or update drafts and content in the dedicated review status. Published or scheduled content cannot be changed or moved by an agent. Publishing is a separate, capability-protected action that a human performs in the review queue.
Any compatible browser agent or extension that uses the experimental WebMCP
API (document.modelContext). The Model Context Tool Inspector can list and
manually call tools for testing. Its natural-language prompts may be processed
by an external AI provider, so review the extension’s current terms before
using private content.
It can triage them. list_comments shows pending, approved or spam comments,
and moderate_comment approves, unapproves or marks a single one as spam.
Both require the moderate_comments capability, so a subscriber or author
account cannot touch the queue.
Comment listings never include the author's email address or IP address. The
agent does not need either to sort spam from real comments, and both would
leave your site with the response.
Yes, but the same review boundary applies as everywhere else: list_revisions
and compare_revisions need the edit_post capability on the post the
revision belongs to, and restore_revision can only act where update_post
could also write — drafts and content in the pending review status. A
published or scheduled post's revisions can be listed and compared, but not
restored by an agent. Restoring is itself reversible: WordPress saves the
pre-restore state as a new revision first, exactly as it does when you
restore a revision by hand in wp-admin.
The plugin itself does not send your content to the plugin developer or another third-party service. Tool calls reach your own WordPress REST API using your logged-in session. However, the browser, AI agent, or extension you choose may send prompts, page content, tool inputs, or tool results to its provider. Review that provider’s terms and privacy policy before using private content.
No separate MCP server or plugin API key is required. The tools live on the WordPress admin page and the browser mediates between the agent and that page. The browser agent itself may still require its own account or configuration.
Chrome 149+ exposes experimental WebMCP through an origin trial or the
chrome://flags/#enable-webmcp-testing flag for local testing. Other browsers
or extensions can work if they implement the current draft. WebMCP is an early
preview, not a W3C Standard, and support may change. WordPress continues to
work normally when WebMCP is unavailable.
Yes. SEO title, meta description and canonical URL written by the agent go directly into the active SEO plugin's fields. Without an SEO plugin, portable custom fields are used.
Base64 image uploads accept PNG, JPEG, WebP and GIF up to
min( wp_max_upload_size(), 10 MB ) of decoded data. The JSON request body is
roughly 1.37× the image size, so your host's post_max_size must be at least
that; the error message names the exact limit when it is exceeded.
Posts and pages are supported out of the box. On the plugin's settings page
(Tools → Settings) you choose which of the two agents may work with;
content of a type you switch off stays out of reach, drafts, revisions and
comments included. Additional post types and capabilities can be added with the
webmcp_cockpit_tools filter — for example WooCommerce product tools.
Only logged-in users with the edit_posts capability (authors, editors,
administrators). Media uploads additionally require upload_files,
publishing requires the publish capability. Guests and subscribers get
nothing.
list_revisions shows a post's saved revisions
(ID, date, author display name, short excerpt — no email addresses),
compare_revisions returns two of them in full (title, content, date,
author) for the agent to compare itself, and restore_revision rolls a
post back to one.restore_revision reuses the exact review-boundary check update_post
already enforces: it can only write where an agent could also update the
post directly, so published or scheduled content stays untouched. The
action is reversible — WordPress saves the pre-restore state as a new
revision before restoring, the same as a human restoring from wp-admin.wmcp_post_type_not_allowed (HTTP 403) with the allowed
types, but only after capability and nonce checks passed, so callers
without access learn nothing about the configuration.get_site_info and the create_post schema now report only the allowed
types, and create_post defaults to the first of them.list_comments triages pending, approved or spam
comments, moderate_comment approves, unapproves or spams a single one.
Both require the moderate_comments capability; the moderation call is
rate limited and recorded in the activity log like every other write.ostheimer-webmcp-cockpit./wp-admin/)
in addition to the dedicated Cockpit page.list_posts and get_post.create_post and update_post schemas for author, scheduling,
password, sticky, post format, page attributes and canonical URL fields.isError: true plus a
stable code, following the MCP CallToolResult convention) instead of
relying on localized text prefixes. The readable, translatable message
stays unchanged.upload_media, formats/size limit/filename handling for
upload_media_base64, precedence and failure behaviour for
featured_image_url/featured_media_id, and the warning behaviour of
create_post when a featured image fails.tests/) and documentation for server-side edge cases.featured_image_url (e.g. a URL
that returns no image) no longer reports success and no longer touches an
existing featured image; imported attachments are verified as real images
from the downloaded bytes, failed imports are cleaned up.-5) and distinguish URL format errors from network/DNS
errors.featured_media_id values now return a clear error instead of
a silent success; attachments are validated for existence and image type.media_rejected entries.upload_media_base64 tool — agents can upload self-generated images
(PNG, JPEG, WebP, GIF) directly into the media library without a public URL.
Real MIME type is verified from the decoded bytes; size capped at 10 MB.featured_media_id parameter for create_post/update_post — assign
a featured image from an existing media ID (takes precedence over
featured_image_url).