21-Tool OAuth 2.1 AI MCP Server, Safe Mode Simulator, Checkpoints & Pulse
Complete operational reference for KadiCache’s 21 MCP tools (20 Free Core incl. manage_script_manager + 1 Pro), 11 telemetry resources, 6 guided prompts, OAuth 2.1 + PKCE scopes, Safe Mode sandbox simulation, and 1-click rollback.
- Ships an industry-first Model Context Protocol (
MCP 2025-06-18) Streamable HTTP server right inside Free Core (+ Cloud Pro extension)—connecting Claude Code, Claude Desktop, Cursor, VS Code, ChatGPT, Antigravity, and KadiCache Pulse directly to WordPress. - Secured by OAuth 2.1 + PKCE (
S256) and SHA-256 hashed scoped tokens across 4 strict permission tiers (read,operate,configure,destructive) with rate limiting (McpRateLimiter.php). - Zero-Blind-Edits Architecture:
McpSimulator.phptests candidate settings and Script Manager rules in memory on live pages before saving,McpApprovals.phpgates destructive actions behind human consent (ap_...), andMcpCheckpoints.phpwrites atomic rollback snapshots (cp_...). - Exposes 21 typed tools (including
manage_script_manager), 11 live JSON/Aurora UI resources, 6 guided diagnostic prompts, and an immutable Audit Log (McpAuditLog.php).
Safe AI & Fleet Operations Without Giving Bots Blind Root Access#
Giving an AI coding agent raw SSH or unrestricted wp_options write access on a live WooCommerce store is terrifying: a single hallucinated option could break jQuery on checkout or wipe your CDN cache during peak traffic.
KadiCache solves AI governance from first principles inside WP Admin -> KadiCache -> AI & MCP (McpServer.php, McpCatalog.php, McpSchemaRegistry.php, McpSimulator.php, McpApprovals.php, and McpCheckpoints.php). Every AI assistant and KadiCache Pulse connection operates through typed schemas, sandboxed simulation, human approval gates, and instant 1-click checkpoints.
Authentication & The 4 Least-Privilege Permission Scopes (McpOAuth.php & McpTokenStore.php)#
Connect your AI client in 15 seconds either via OAuth 2.1 + PKCE (S256) browser consent (McpConsentRenderer.php) or by minting a Scoped Token (McpTokenStore::mint(), stored solely as a one-way SHA-256 hash with optional day expiration):
| MCP Permission Scope | Allowed Operations | Safety Boundary |
|---|---|---|
read | Read status, URL diagnostics, Script Manager asset inspection (inspect_url/list_rules), settings (secrets stripped!), preload queue, DB candidate counts, RUM, and Cloudflare analytics | 100% read-only — cannot mutate any setting or purge cache |
operate | Purge cache (all / urls), start/pause/resume preload, repair runtime drop-in, probe object cache, and run PageSpeed audits | Operational maintenance without altering optimization configuration |
configure | Run simulate_settings, apply verified update_settings / optimize_site presets, manage Script Manager rules (simulate_rules/upsert_rules/delete_rules/set_mode), manage Cloudflare settings, and rollback cp_* checkpoints | Automatically creates a McpCheckpoints rollback snapshot (settings + Script Manager rules) before saving! |
destructive | Queue clean_database, manage_script_manager reset_all, or full manage_cloudflare purge_zone | Still requires a single-use human approval_token (ap_...) approved by a site admin in WP Admin! |
Complete Reference: All 21 KadiCache MCP Tools (McpSchemaRegistry.php)#
| # | Tool Name | Required Scope | Exact Capability & Key Parameters |
|---|---|---|---|
01 | get_status | read | Live cache health, Early Drop-In state, Script Manager status, storage usage, 24h/7d hit ratios, RUM 24h p75, preload, CDN/Cloudflare/Varnish & runtime guards |
02 | diagnose_url | read | Probes any same-site url across Desktop & Mobile cache states, anonymous loopback headers, cookies, jQuery inline protection & conflict advice |
03 | get_settings | read | Reads sanitized settings (section: all, cache, preload, optimization, lazy, fonts, cloudflare, cdn, bloat, database, advanced) + modified_keys |
04 | get_preload_status | read | Sitemap warmup progress, queue counts, pace, uncacheable URLs & discovered XML sitemaps |
05 | inspect_database | read | Non-destructive candidate counts across all 8 DatabaseCleanupItems categories |
06 | get_approval_status | read | Polls whether an administrator approved or denied a gated approval_token (ap_...) |
07 | purge_cache | operate | Purges scope: "all" (with optional preload_after) or up to 50 urls in soft or hard mode |
08 | manage_preload | operate | Runs start, pause, resume, or queue_urls (up to 50 public URLs) |
09 | repair_runtime | operate | Repairs site bootstrap, verifies advanced-cache.php, and optionally runs enable_early |
10 | verify_integrations | operate | Live probe for browser_cache, cloudflare, varnish, cdn, or all |
11 | run_pagespeed_audit | operate | Runs Google PageSpeed v5 + CrUX (mobile/desktop, optional compare_bypass: true speedup delta) |
12 | simulate_settings | configure | Sandbox Safe Mode: tests candidate changes in memory on up to 3 public URLs without touching live options or visitor cache! |
13 | update_settings | configure | Validates, runs simulate_first (default: true), records a cp_* checkpoint, and atomically saves changes |
14 | optimize_site | configure | Builds conflict-aware safe, balanced, or woocommerce_safe preset (dry_run supported), simulates, checkpoints, and applies |
15 | rollback_checkpoint | configure | Atomically restores KadiCache settings and Script Manager rules from checkpoint_id (cp_... or "latest") |
16 | get_rum_analytics | read | Queries real-visitor p75 Core Web Vitals (1h/24h/7d/30d, mobile/desktop, hit/miss, path, country, culprit selectors) |
17 | manage_cloudflare | read / configure / destructive | Reads analytics/25 zone settings (get_state), toggles edge_html / wp_waf rules, updates APO, applies preset, or runs purge_zone (ap_* gated) |
18 | manage_object_cache | read / operate / configure | Runs get_state, live probe, subsite/full flush, enable, or disable across all 7 drivers + AutoloadAnalyzer |
19 | clean_database | destructive | Queues bounded cleanup for selected items—strictly gated by owner approval_token (ap_...) |
20 | manage_script_manager | read / configure / destructive | Action-scoped Per-Page Script Manager: inspect_url (with is_critical_layout flags & /uploads/ owner mapping), list_rules, simulate_rules (blocks orphaned_dependents & critical_layout_disabled), upsert_rules (with simulate_first: true, auto checkpoint, and signed 10-minute preview_url when testing_mode: true), delete_rules, set_mode, or reset_all (ap_* gated) |
21 | manage_pro_cloud | read / operate (Cloud Pro) | Inspects Cloud Pro connection status, optimization queue KPIs, and triggers safe page reprocessing |
All 11 Live MCP Resources & 6 Guided Diagnostic Prompts#
- 11 Readable MCP Resources:
kadicache://site/status,kadicache://site/settings,kadicache://assets/script-manager,kadicache://diagnostics/runtime,kadicache://analytics/visits,kadicache://vitals/pagespeed,kadicache://vitals/rum,kadicache://edge/cloudflare,kadicache://cloud/status(Cloud Pro), plus interactive Aurora HTML/SVG UI cards (ui://kadicache/cardandui://kadicache/rendered/latest). - 6 Built-In Guided Prompts:
diagnose-url,safe-speed-tune,boost-hit-ratio,safe-delay-js,safe-script-audit, andanalyze-real-user-vitals.
Connecting Unlimited Free Sites to KadiCache Pulse (/pulse)#
Every Free Core and Cloud Pro installation can also link to KadiCache Pulse—giving agencies and multi-site owners a single fleet dashboard displaying cache hit rates, p75 RUM Core Web Vitals, object-cache health, remote purge/preload triggers, and 1-click checkpoint rollbacks via lightweight event-driven deltas (0 background polling load on your WordPress server).
Example Guided Prompt Workflows in Claude Code, Cursor & Antigravity#
Instead of typing multi-step instructions from scratch, invoke any of KadiCache’s 6 built-in MCP prompts directly in your editor (diagnose-url, safe-speed-tune, boost-hit-ratio, safe-delay-js, safe-script-audit, or analyze-real-user-vitals): each prompt instructs the assistant to inspect live telemetry first, validate candidate changes in simulate_settings or manage_script_manager(action="simulate_rules"), and report the resulting checkpoint_id (cp_...).
Frequently Asked Operational Questions
Are raw API keys, Cloudflare tokens, or WordPress salts ever exposed to AI assistants via get_settings?
What happens if update_settings detects an unguarded inline jQuery error during simulation?
How do I undo an AI-applied setting or Script Manager change if I change my mind?
Is the 20/21-Tool MCP Server locked behind a paid plan?
Does enabling MCP add overhead to normal visitor pageviews?
Creator of KadiCache’s Early PHP Drop-In, 7-Driver Object Cache Engine, Cloud Remove Unused CSS, and Zero-CLS Lazy Render pipeline.