| 开发者 | kevp75 |
|---|---|
| 更新时间 | 2026年12月2日 00:42 |
| PHP版本: | 8.2 及以上 |
| WordPress版本: | 7.2 |
| 版权: | MIT |
| 版权网址: | 版权信息 |
Link headers pointing agents to your API catalog, agent skills index, and MCP server card. This is how agents find your discovery documents without having to guess URLs.
API Catalog — /.well-known/api-catalog
Publishes a machine-readable catalog of your site's APIs in the application/linkset+json format defined by RFC 9727. Each entry in the catalog can point to an OpenAPI specification, human-readable documentation, and a health/status endpoint. If you have not configured any entries yet, the plugin serves a sensible fallback automatically so the endpoint is always valid.
Agent Skills Index — /.well-known/agent-skills/index.json
Publishes a skills discovery index per the Agent Skills Discovery RFC v0.2.0. This tells agents what your site can do — search your blog, browse your portfolio, submit a contact form, and so on.
Skills are built from three sources:
/.well-known/mcp/server-card.json
Publishes an MCP Server Card (SEP-1649) identifying your site to Model Context Protocol clients. Configurable name, version, description, transport endpoint, and a capability list. If you do not have an MCP server running yet, just leave the transport blank to publish a card without a transport endpoint.
OAuth / OIDC Discovery — /.well-known/openid-configuration or /.well-known/oauth-authorization-server
If your site exposes protected APIs that require authentication, this feature publishes the discovery metadata agents need to authenticate. Choose OpenID Connect Discovery 1.0 or RFC 8414 metadata in the settings. The plugin publishes metadata for an existing authorization server. Disabled by default — only enable it if you have the infrastructure in place.
OAuth Protected Resource Metadata — /.well-known/oauth-protected-resource
Complements the OAuth/OIDC feature by publishing RFC 9728 Protected Resource Metadata. Disabled by default.
robots.txt Content Signals
Appends Content Signals directives to the virtual robots.txt served by WordPress, declaring your preferences for how AI systems may use your content:
text/markdown with a nonzero preference at least as high as text/html. Requests that do not prefer Markdown continue through the normal WordPress response.
WebMCP
Adds a footer script that checks for and calls navigator.modelContext.provideContext(), exposing your site's key actions as tools to AI agents running in the browser. Built-in tools include blog search, portfolio navigation, and contact page navigation — each individually toggleable.
llms.txt and llms-full.txt
When enabled, generates physical llms.txt and llms-full.txt files in the WordPress installation directory per the llmstxt.org specification. These files give AI systems a structured, readable index of your site's content — who you are, what pages exist, and what your posts are about.
llms.txt contains your site header and a clean list of links by content type. llms-full.txt contains the same structure but expands each entry with an excerpt or truncated content block so AI systems can understand the content without fetching every URL.
WordPress cron handles automatic regeneration after eligible content is saved, its publish status changes, or plugin settings are saved. Generated listings use published content without post passwords. A manual Regenerate button is available in the llms.txt settings tab. If your host prevents direct file writes, the generated content is displayed in the admin as a copyable textarea so you can create the files manually.
Automatic file generation is available on single-site installations. Files from earlier versions and manually managed files are left in place unless the plugin has a record of writing that exact content. Review and remove or archive existing files before regenerating if you want the plugin to manage those paths.
Configurable options include a custom intro block, toggling pages and posts independently, selecting additional custom post types, setting the excerpt word limit for llms-full.txt, and defining optional additional links that appear under an ## Optional section in both files.
Developer Filters
These filters let themes and other plugins extend the plugin's output without touching settings:
kp_agent_skills — add entries to the agent skills index:
add_filter( 'kp_agent_skills', function ( array $skills ): array {
$skills[] = [
'name' => 'my-skill',
'type' => 'api',
'description' => 'Does something useful.',
'url' => 'https://yoursite.com/api/endpoint',
];
return $skills;
} );
kp_webmcp_tools — add tools to the WebMCP context:
add_filter( 'kp_webmcp_tools', function ( array $tools ): array {
// $tools is the PHP array that becomes the JS tools array
return $tools;
} );
kp_agent_ready_llms_post_limit — set the maximum posts queried per content type for each llms.txt generation run. The default is -1 (unlimited). The second filter argument is the post type.
kp-agent-ready folder to wp-content/plugins/.The API catalog, agent skills index, and MCP server card are available after activation. Link headers, Content Signals, Markdown negotiation, WebMCP, and blog skills are enabled by default. Enable OAuth discovery, OAuth protected resource metadata, or llms.txt generation in the settings when needed.
/.well-known/ directory?It is a reserved URL path (defined by RFC 8615) where internet standards place well-known resources — things like Let's Encrypt challenge files and increasingly AI agent discovery documents. The plugin serves these paths from WordPress without physical discovery files.
The endpoint will serve whatever data you have entered in the settings, even if incomplete. Only enable this feature if you have a working OAuth or OIDC server — otherwise the metadata it publishes will be misleading to agents.
Network activation is blocked. Activate the plugin individually on each site that needs it.
Yes — see the Developer Filters section in the Description tab.
kp prefix to kpagre to meet WordPress.org prefix length requirementsjson_encode() with wp_json_encode() in WellKnown respond()wp_kses() escaping for constructed form HTMLsprintf() description strings in __() for i18n compliance in WellKnown buildSkills()esc_url_raw() to MCP server card contact field output in WellKnown serveMcpCard()delete_option() calls in uninstall.php for options that no longer exist