Founder pricing · Pro from €29/year. Keep your rate while subscribed.Founder pricing · Pro from €29/year See founder plans Founder pricing · Pro €29/year →

REFERENCE · WORDPRESS MCP

WordPress MCP tool reference

Explore the tools your AI agent can use to inspect, build and maintain WordPress with DiviOps. Start with a task, then open a tool for its parameters and constraints.

Use these tools through a connected AI client such as Codex or Claude Code. You can describe the outcome you want; you do not need to memorize tool names.

Browse the tools →

Start with an outcome

“Review this page’s presets before we change its design.”
Your agent can inspect the page, audit preset references and propose a focused update.

“Check the SEO title and description for this article.”
Inspect the available SEO provider, read its metadata and review a proposed change.

“Build a campaign draft around this product.”
Where the required Pro and FluentCart capabilities are available, your agent can inspect the product and prepare a native campaign workflow.

Browse the tool reference

Availability follows your connected site. This reference covers 100 Free and 40 conditional Pro tool definitions in the released MCP package. Pro tools require the relevant module, integration and capabilities. Free tools can also depend on permissions, installed plugins or server configuration. Your connected client may expose fewer tools.

Reference reviewed: 12 October 2026 · MCP server 1.5.72. Parameters come from the released package schemas. This is a package reference, not a live-site capability check. Reconnect after server, plugin, theme or target changes, then check the refreshed catalog before using a tool.

140 tools in this released-package reference

Pages and content

diviops_module_cloneClone a module by deep-copying its block JSON and inserting it next to the source within the same parent container.Free

Clone a module by deep-copying its block JSON and inserting it next to the source within the same parent container. Position controls before/after placement (default "after"). Module IDs are reassigned by Divi at render time from the block tree position, so the clone gets fresh IDs automatically. Same targeting pattern as diviops_module_lock. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing module returns code "not_found" with error.data.target_kind = "module", malformed parent containers surface code "divi_error" (HTTP 500). Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "label": {
      "description": "Admin label of the module to clone (exact match)",
      "type": "string"
    },
    "match_text": {
      "description": "Text to search for in module markup (case-insensitive)",
      "type": "string"
    },
    "auto_index": {
      "description": "Auto-index in \"type:N\" format",
      "type": "string"
    },
    "occurrence": {
      "default": 1,
      "description": "Which occurrence when multiple modules share the same label (1-based)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "position": {
      "default": "after",
      "description": "Place the clone \"before\" or \"after\" the source module within its parent.",
      "type": "string",
      "enum": [
        "before",
        "after"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "occurrence",
    "position",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_module_getInspect one module by its position or a stable selector.Free

Get one targeted Divi module/block from a page, post, or Theme Builder layout by auto_index (e.g. "text:5"), admin label, or text content. Uses the same selector validation as diviops_module_update: pass exactly one of auto_index, label, or match_text; use occurrence with duplicate labels. Default mode returns identity, block name, admin label, auto_index, text preview, source bounds, and a compact attr summary. Use full: true to include decoded attrs and raw serialized block markup for the matched module only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing module returns code "not_found" with error.data = { target_kind: "module", target_mode, target_value, page_id }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "WordPress post/layout ID whose Divi block content should be searched"
    },
    "label": {
      "description": "Admin label of the module (exact match)",
      "type": "string"
    },
    "match_text": {
      "description": "Text to find in module attrs/innerContent (case-insensitive substring, first match)",
      "type": "string"
    },
    "auto_index": {
      "description": "Auto-index target in \"type:N\" format (e.g. \"text:5\", \"icon:3\"). Get from diviops_page_get_layout.",
      "type": "string"
    },
    "occurrence": {
      "default": 1,
      "description": "Which occurrence to target when multiple modules share the same label (1-based)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "full": {
      "default": false,
      "description": "Include decoded attrs and raw serialized block markup for the matched module only",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "occurrence",
    "full"
  ],
  "additionalProperties": false
}
diviops_module_lockLock a module so VB users cannot edit it.Free

Lock a module so VB users cannot edit it. Sets attrs.locked = {desktop: {value: "on"}} per Divi's per-breakpoint convention (verified via VB-save probe). Locked modules render normally on frontend; only VB-side editing is gated. Same targeting pattern as diviops_module_update — pick one of label / match_text / auto_index. Use diviops_module_unlock to reverse. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing module returns code "not_found" with error.data.target_kind = "module". Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "label": {
      "description": "Admin label of the module to lock (exact match)",
      "type": "string"
    },
    "match_text": {
      "description": "Text to search for in module markup (case-insensitive)",
      "type": "string"
    },
    "auto_index": {
      "description": "Auto-index in \"type:N\" format (e.g. \"text:3\")",
      "type": "string"
    },
    "occurrence": {
      "default": 1,
      "description": "Which occurrence when multiple modules share the same label (1-based)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "occurrence",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_module_moveMove a module to a new position on the page.Free

Move a module to a new position on the page. Specify source and target blocks using auto_index (e.g. "text:3"), admin label, or text content. Position "before" or "after" the target. Works with any block type including sections, rows, and modules. Both blocks are found in the original content, so auto_index values refer to positions before the move. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing source/target blocks return code "not_found" with error.data = { target_kind: "block", context: "source"|"target", ... }, moving a block into itself returns code "module.overlap" (HTTP 400). Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "source_label": {
      "description": "Admin label of the module to move",
      "type": "string"
    },
    "source_match_text": {
      "description": "Text to search for in source module (case-insensitive)",
      "type": "string"
    },
    "source_auto_index": {
      "description": "Auto-index of the module to move in \"type:N\" format (e.g. \"text:3\")",
      "type": "string"
    },
    "source_occurrence": {
      "default": 1,
      "description": "Which occurrence when multiple sources match by label (1-based)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "target_label": {
      "description": "Admin label of the reference module",
      "type": "string"
    },
    "target_match_text": {
      "description": "Text to search for in target module (case-insensitive)",
      "type": "string"
    },
    "target_auto_index": {
      "description": "Auto-index of the reference module in \"type:N\" format (e.g. \"text:5\")",
      "type": "string"
    },
    "target_occurrence": {
      "default": 1,
      "description": "Which occurrence when multiple targets match by label (1-based)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "position": {
      "type": "string",
      "enum": [
        "before",
        "after"
      ],
      "description": "Place the source before or after the target"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "source_occurrence",
    "target_occurrence",
    "position",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_module_unlockUnlock a module by removing attrs.locked entirely.Free

Unlock a module by removing attrs.locked entirely. Matches Divi VB's convention: unlocked = attribute absent (NOT {value: 'off'}) — VB doesn't write a falsy value on unlock, it removes the field. Same targeting pattern as diviops_module_lock. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing module returns 'not_found' with `error.data.target_kind = "module"`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "label": {
      "description": "Admin label of the module to unlock (exact match)",
      "type": "string"
    },
    "match_text": {
      "description": "Text to search for in module markup (case-insensitive)",
      "type": "string"
    },
    "auto_index": {
      "description": "Auto-index in \"type:N\" format",
      "type": "string"
    },
    "occurrence": {
      "default": 1,
      "description": "Which occurrence when multiple modules share the same label (1-based)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "occurrence",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_module_updateUpdate specific attributes of a module.Free

Update specific attributes of a module. Target by auto_index (e.g. "text:5"), admin label, or text content. Uses dot notation for attribute paths. Example: {"content.decoration.headingFont.h2.font.desktop.value.color": "#ff0000"}. For paths whose key segments contain literal dots — notably Composable Settings preset slots like groupPreset["title.decoration.spacing"] — escape the inner dots with `\.` to keep the segment intact: {"groupPreset.title\\.decoration\\.spacing.presetId": ["uuid"]}. Priority: auto_index > label > match_text. Use occurrence with label when duplicates exist. match_text is a convenience selector: for generic or repeated visible text, prefer auto_index from diviops_page_get_layout/module_get. Content-slot mismatches such as writing a heading `title.innerContent` path into a matched divi/text block are rejected with invalid_input instead of silently storing never-rendered attrs. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing module returns code "not_found" with error.data = { target_kind: "module", target_mode, target_value, page_id }, non-array attrs returns code "invalid_input" with error.data.field = "attrs", malformed Divi block markup surfaces code "divi_error" (HTTP 500). Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "label": {
      "description": "Admin label of the module (exact match)",
      "type": "string"
    },
    "match_text": {
      "description": "Text to find in module innerContent (case-insensitive substring, first match)",
      "type": "string"
    },
    "auto_index": {
      "description": "Auto-index target in \"type:N\" format (e.g. \"text:5\", \"icon:3\"). Get from diviops_page_get_layout. Takes priority over label/match_text.",
      "type": "string"
    },
    "occurrence": {
      "default": 1,
      "description": "Which occurrence to target when multiple modules share the same label (1-based)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "attrs": {
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {},
      "description": "Attribute paths (dot notation) and their new values"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "occurrence",
    "attrs",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_page_createCreate a new WordPress page, optionally with Divi block content.Free

Create a new WordPress page, optionally with Divi block content. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; non-string content or invalid status return code 'invalid_input' with `error.data` documenting the failed field. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "Page title"
    },
    "content": {
      "default": "",
      "description": "Page content in Divi block markup format",
      "type": "string"
    },
    "status": {
      "default": "draft",
      "description": "Post status",
      "type": "string",
      "enum": [
        "draft",
        "publish",
        "private"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "title",
    "content",
    "status",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_page_getGet detailed info about a specific page including its raw Divi block content and content_checksum (`sha256:` over the exact post_content bytes) for stale-write protection.Free

Get detailed info about a specific page including its raw Divi block content and content_checksum (`sha256:` over the exact post_content bytes) for stale-write protection. Default response is unchanged and unbounded. Optional bounded:true requires page_get_bounded_utf8_v1 and returns only raw UTF-8 content chunks (at most 4096 bytes), id, encoding, full-page content_checksum, total_bytes, offset, chunk_bytes, next_offset (null at completion), and complete. MCP text is limited to 32 KiB including escaping/metadata. Start at offset:0; continue with next_offset and the initial expected_checksum until complete:true. Drift refuses even same-length edits; discard chunks and restart. No parser reconstruction, fallback, or snapshot storage. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing page_id returns ok:false with code 'not_found' and a hint pointing to diviops_page_list in legacy mode.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "bounded": {
      "description": "Opt into checksum-bound UTF-8 chunks; omitted/false preserves the legacy response.",
      "type": "boolean"
    },
    "offset": {
      "description": "Byte offset for bounded mode; defaults to zero. Use the returned next_offset.",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "expected_checksum": {
      "description": "Required for nonzero bounded offsets; the exact initial full-page content_checksum.",
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    }
  },
  "required": [
    "page_id"
  ],
  "additionalProperties": false
}
diviops_page_get_layoutGet the parsed block tree for a page.Free

Get the parsed block tree for a page. Returns slim targeting metadata by default (block names, admin labels, text previews, auto_index). Use full: true for complete attrs (warning: can be very large on complex pages). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing page_id returns ok:false with code 'not_found'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "full": {
      "default": false,
      "description": "Include full block attrs and raw content (default: false for slim mode)",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "full"
  ],
  "additionalProperties": false
}
diviops_page_listList pages/posts in the WordPress site.Free

List pages/posts in the WordPress site. Returns title, ID, URL, status, and whether each page uses Divi builder. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "post_type": {
      "default": "page",
      "description": "Post type to query: \"page\", \"post\", or custom type",
      "type": "string"
    },
    "per_page": {
      "default": 20,
      "description": "Number of results per page (max 100)",
      "type": "number"
    },
    "page": {
      "default": 1,
      "description": "Page number",
      "type": "number"
    }
  },
  "required": [
    "post_type",
    "per_page",
    "page"
  ],
  "additionalProperties": false
}
diviops_page_settings_getRead ordinary WordPress page background settings: stored values/presence, native defaults and a settings_checksum.Free

Read ordinary WordPress page background settings: stored values/presence, native defaults and a settings_checksum. These are not computed browser colors. Requires edit permission. No Theme Builder layout or global Theme Options access.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    }
  },
  "required": [
    "page_id"
  ],
  "additionalProperties": false
}
diviops_page_settings_updateSet/clear Content Area and Section backgrounds on ordinary WordPress pages.Free

Set/clear Content Area and Section backgrounds on ordinary WordPress pages. Read settings first and pass settings_checksum as expected_checksum. Omission preserves; null deletes the override; empty strings are rejected. Colors: #RGB/#RRGGBB, bounded rgb()/rgba(), or transparent. Existing dynamic values are preserved when omitted but new dynamic values are unsupported. Explicit defaults may be normalized away by native Divi save. Refuses native background drafts. Applies post-scoped CSS/dynamic-assets cache refresh, without canvas-reference cleanup; no-op does not flush. If cache_refresh_failed reports settings_applied, read state and retry cache flush, not the write. Optimistic checksum is not an editor lock. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "expected_checksum": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "settings": {
      "type": "object",
      "properties": {
        "content_area_background": {
          "type": [
            "string",
            "null"
          ]
        },
        "section_background": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "additionalProperties": false
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "expected_checksum",
    "settings",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_page_trashTrash or permanently delete a page/post.Free

Trash or permanently delete a page/post. Defaults to trash (reversible via WP Admin → Trash). Pass force=true to permanently delete (wp_delete_post — irreversible). Idempotent: trashing an already-trashed post returns ok:true with `data.already_trashed = true` (repeat-safe semantics for AI-agent retries). Pass dry_run=true to preview the standard `data.plan = { summary, changes[] }` without mutating. Replaces wp-cli `post delete --force=0|1` routing for AI-agent callers (typed input, deterministic envelope). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing post_id returns 'not_found', delete-permission failures return 'forbidden' (HTTP 403).

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "post_id": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "WordPress post/page ID"
    },
    "force": {
      "default": false,
      "description": "When true, permanently delete (skips trash). Default false moves to trash.",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "post_id",
    "force",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_page_update_contentUpdate the content of a page with Divi block markup.Free

Update the content of a page with Divi block markup. The content should be valid WordPress block markup using divi/* blocks. IMPORTANT: This overwrites the entire page content. Pass expected_checksum from diviops_page_get to refuse stale writes; omission preserves the legacy unconditional-write contract. Optionally set retain_content:true with dry_run:true and expected_checksum to retain a successful candidate in this process for 5 minutes (2 MiB each, 8 references / 8 MiB total). Returns data.content_ref, content_checksum, expires_at alongside the dry-run plan. Apply using content_ref instead of content, repeating the same page_id, expected_checksum and backup intent. References are process-local and single-use, consumed before writer dispatch even on failure; never automatically retry. Restart/expiry requires a new dry-run. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing page_id returns 'not_found', edit-permission failures return 'forbidden' (HTTP 403), stale content returns 'page.content_drift' (HTTP 409), and non-string content returns 'invalid_input' with `error.data = { field, received_type }`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID to update"
    },
    "content": {
      "description": "Full page content in WordPress block markup format (<!-- wp:divi/section -->...<!-- /wp:divi/section -->)",
      "type": "string"
    },
    "content_ref": {
      "description": "Single-use reference from a successful retained dry-run; apply only, mutually exclusive with content.",
      "type": "string"
    },
    "retain_content": {
      "description": "Retain content only on an explicitly confirmed successful dry-run. Requires expected_checksum. content_checksum hashes exact submitted UTF-8 bytes, not normalized persisted bytes. Capacity and the 5-minute TTL begin before the upstream request. MCP-process-local, not isolated per client session.",
      "type": "boolean"
    },
    "expected_checksum": {
      "description": "Optional review binding from diviops_page_get.content_checksum. When supplied, drift refuses with no force path.",
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_page_update_metaUpdate page/post metadata fields without touching post_content.Free

Update page/post metadata fields without touching post_content. Supports title, slug, parent, and menu_order; use diviops_page_update_status for status changes. Slug input must already be in sanitized WordPress post_name form. When a published post's slug changes, preserve_old_slug defaults to true and records the previous slug in _wp_old_slug so WordPress old-slug redirects can work. Returns readback fields after apply. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing page_id or invalid parent returns 'not_found', edit-permission failures return 'forbidden' (HTTP 403), invalid/empty slug or malformed field values return 'invalid_input' with `error.data` documenting the field and sanitized slug where relevant. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "WordPress post/page ID to update"
    },
    "title": {
      "description": "New post_title. Omit to leave unchanged.",
      "type": "string"
    },
    "slug": {
      "description": "New post_name. Must already be sanitized, e.g. 'legal-notice'.",
      "type": "string"
    },
    "parent": {
      "description": "New post_parent. Use 0 for no parent.",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "menu_order": {
      "description": "New menu_order value.",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "preserve_old_slug": {
      "default": true,
      "description": "When true, record the previous slug in _wp_old_slug for published posts when slug changes.",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "preserve_old_slug",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_page_update_statusUpdate a page's post_status.Free

Update a standard WordPress post or page's post_status; custom post types and attachments are not supported. Valid statuses: publish, draft, private, pending, future. status='future' requires date_gmt (ISO 8601 UTC, must be in the future) — server writes both post_date_gmt and the site-tz post_date so WP's scheduler picks it up. status='publish' on a previously-scheduled post clears the future date so it publishes immediately. Idempotent: same-status update returns ok:true with `data.noop = true`. Pass dry_run=true to preview the standard `data.plan = { summary, changes[] }` without mutating. Replaces wp-cli `post update --post_status=...` routing. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing post_id returns 'not_found', edit-permission failures return 'forbidden' (HTTP 403); status enum violations and date_gmt validation failures return 'invalid_input' with `error.data` documenting the field.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "post_id": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "WordPress post/page ID"
    },
    "status": {
      "type": "string",
      "enum": [
        "publish",
        "draft",
        "private",
        "pending",
        "future"
      ],
      "description": "Target post status"
    },
    "date_gmt": {
      "description": "Required when status='future'. ISO 8601 UTC datetime (e.g. '2026-06-01T09:00:00Z'). Must be in the future.",
      "type": "string"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "post_id",
    "status",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_section_appendAppend a Divi section to an existing page without overwriting other content.Free

Append a Divi section to an existing page without overwriting other content. Use this to incrementally build pages. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing page_id returns 'not_found' with `error.data.target_kind = "page"`, edit-permission failures return 'forbidden' (HTTP 403), non-string content or invalid position returns 'invalid_input' with `error.data = { field, ... }`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "content": {
      "type": "string",
      "description": "Section block markup to append (<!-- wp:divi/section ...-->...<!-- /wp:divi/section -->)"
    },
    "position": {
      "default": "end",
      "description": "Where to insert: \"start\" or \"end\" (default)",
      "type": "string",
      "enum": [
        "start",
        "end"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "content",
    "position",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_section_getGet the raw block markup of a section.Free

Get the raw block markup of a section. Target by admin label OR text content. Use occurrence when multiple sections match. Returns total_matches warning when duplicates exist. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing section returns 'not_found' with `error.data.target_kind = "section"`.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "label": {
      "description": "Admin label of the section to retrieve",
      "type": "string"
    },
    "match_text": {
      "description": "Text to search for in section content (case-insensitive substring)",
      "type": "string"
    },
    "occurrence": {
      "default": 1,
      "description": "Which match to target (1-based, default: 1)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    }
  },
  "required": [
    "page_id",
    "occurrence"
  ],
  "additionalProperties": false
}
diviops_section_removeRemove a section from a page.Free

Remove a section from a page. Target by admin label OR text content. Use occurrence when multiple sections match. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; section selectors lack identity-preserving repeat-call detection so a removal of an already-removed section returns 'not_found' (HTTP 404) — the side-effect (section is gone) holds regardless of how many times you call. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "label": {
      "description": "Admin label of the section to remove",
      "type": "string"
    },
    "match_text": {
      "description": "Text to search for in section content (case-insensitive substring)",
      "type": "string"
    },
    "occurrence": {
      "default": 1,
      "description": "Which match to target (1-based, default: 1)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "occurrence",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_section_replaceReplace a section on a page.Free

Replace a section on a page. Target by admin label OR text content. Use occurrence when multiple sections match. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing section returns 'not_found' with `error.data = { target_kind: "section", ... }`, missing/ambiguous selectors return 'invalid_input' with `error.data.reason`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "number",
      "description": "WordPress post/page ID"
    },
    "label": {
      "description": "Admin label of the section to replace",
      "type": "string"
    },
    "match_text": {
      "description": "Text to search for in section content (case-insensitive substring)",
      "type": "string"
    },
    "content": {
      "type": "string",
      "description": "New section block markup to replace the matched section"
    },
    "occurrence": {
      "default": 1,
      "description": "Which match to target (1-based, default: 1)",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "content",
    "occurrence",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}

Presets and design tokens

diviops_custom_css_getRead raw site-wide Additional CSS for the active stylesheet, its legacy Divi mirror and a complete state checksum.Free

Read raw site-wide Additional CSS for the active stylesheet, its legacy Divi mirror and a complete state checksum. Requires admin and edit_css. Existing initialized native CSS post only; initialize or reconcile through Divi Theme Options > General > Custom CSS, then reread and verify the mirror agrees. Customizer alone may leave a divergent mirror. Refuses preprocessed CSS and unsupported data hooks. This is not computed browser CSS or generic Theme Options access.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_custom_css_restorePreview or restore only the CSS post/mirror owned by a custom_css_upsert snapshot.Free

Preview or restore only the CSS post/mirror owned by a custom_css_upsert snapshot. Read current custom_css_get and pass its checksum. Defaults to preview; dry_run:false commits. Requires admin and edit_css, matching active stylesheet/post identity and unexpired verified snapshot. Refuses conflicting third-party changes; no whole-option restore, CSS post deletion or cache/revision rollback. On incomplete recovery inspect recovered and record_verified; do not blindly retry.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "snapshot_id": {
      "type": "string",
      "pattern": "^css_[a-f0-9-]{36}$"
    },
    "expected_checksum": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "dry_run": {
      "default": true,
      "type": "boolean"
    }
  },
  "required": [
    "snapshot_id",
    "expected_checksum",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_custom_css_upsertAppend or replace one named site-wide CSS block while preserving unrelated bytes.Free

Append or replace one named site-wide CSS block while preserving unrelated bytes. Read custom_css_get and pass checksum as expected_checksum. Defaults to preview; explicitly pass dry_run:false to commit the same proposal. Uses a mandatory seven-day CSS recovery snapshot and exact readback. Requires existing initialized active-theme CSS storage, admin and edit_css; no generic option writes or new CSS posts. Refuses ambiguous markers and raw unquoted URL grouping; use quoted or base64 URLs. A failure or cancellation does not prove no write: read state and inspect snapshot/recovered/record_verified before further action. Optimistic checksum is not a native-editor lock.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "pattern": "^[a-z][a-z0-9-]{0,63}$"
    },
    "css": {
      "type": "string",
      "maxLength": 262144
    },
    "expected_checksum": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "dry_run": {
      "default": true,
      "type": "boolean"
    }
  },
  "required": [
    "name",
    "css",
    "expected_checksum",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_global_color_audit_storageCheck where global colors are stored and find inconsistencies.Free

Audit the global_colors STORAGE LOCATION landscape (#719 contract). Aggregates entries across all candidate paths for the global_colors surface with per-entry provenance via `_meta.entry_sources = { <id>: { path, provenance } }`. Provenance vocabulary: `et_divi_nested` (canonical 5.x — `et_divi.et_global_data.global_colors`), `top_level` (hypothetical standalone option, not observed on tested 5.5.x substrates), `wp_customizer` (the five WP-customizer-bound defaults — gcid-primary-color / gcid-secondary-color / gcid-heading-color / gcid-body-color / gcid-link-color, sourced from GlobalData::$customizer_colors). Warnings: `id_collision` (same id across two paths). The user palette overrides customizer defaults when both present (matches Divi's render-side behavior at GlobalData::get_global_colors). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_global_color_createAdd a new global color to Divi's palette.Free

Add a new global color to Divi's palette. The plugin mints a fresh `gcid-<uuid>` ID (the server forwards the color entry without an id and the WP-side handler generates one) and writes to the et_global_data option in the canonical Divi shape `{color, folder, label, lastUpdated, status, usedInPosts}`. The color appears in the VB color picker after save and can be referenced via `$variable({type:color,value:{name:gcid-...}})$` tokens. Note: Divi's AI Agent bundle has a Zod schema gap that drops `label` on its own writes — our PHP path goes around that bug by writing directly to the option. CONCURRENCY: this is a read-modify-write on a single WP option with no conflict detection. If a Visual Builder session holds stale global data, its next save can clobber colors written here in the interim. Coordinate writes when VB sessions are active, or have the user reload VB after MCP color writes. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; input-shape rejections (non-CSS color value, missing required `color` for a new entry) return code 'invalid_input' with `error.data` documenting the failed field. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "color": {
      "type": "string",
      "description": "CSS color value — hex (e.g. \"#ff0000\", \"#ff0000aa\") or functional rgba/hsla notation. Bare keywords like \"red\" are not accepted."
    },
    "label": {
      "description": "Human-readable label shown in the VB color picker (e.g. \"Brand Red\"). Optional — defaults to empty (matches Divi's stock palette which leaves labels blank).",
      "type": "string"
    },
    "folder": {
      "description": "Folder name for grouping colors in the picker UI. Optional — defaults to empty (no folder).",
      "type": "string"
    },
    "status": {
      "default": "active",
      "description": "Color status — \"active\" (default, visible in picker) or \"archived\" (hidden but preserved).",
      "type": "string",
      "enum": [
        "active",
        "archived"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "color",
    "status",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_global_color_deleteDelete a global color from the registry by gcid.Free

Delete a global color from the registry by gcid. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Live-reference detection uses parse_blocks over post_content across pages / TB layouts / library / canvas + the preset registry (mirrors diviops_variable_delete) — MCP-authored content is detected reliably, not just VB-saved content. Returns code 'conflict' (HTTP 409) when references exist with `error.data = { id, ref_count, locations[], scan_truncated, scanned_posts }`. Pass `force: true` to override; orphan refs will render as invalid CSS until pages are re-authored. Always refuses to delete the 5 customizer-bound defaults (gcid-primary-color, gcid-secondary-color, gcid-heading-color, gcid-body-color, gcid-link-color) regardless of force — returns code 'variable.customizer_default_immutable' (HTTP 403) with `error.data = { id, managed_by: 'wp_customizer' }`. Missing gcids return 'not_found' (HTTP 404). Malformed gcid (empty or missing `gcid-` prefix) returns 'invalid_input'. CONCURRENCY: same VB-session race caveat as diviops_global_color_create — an active VB session's next save can re-introduce a color we just deleted if the session held stale data. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "gcid": {
      "type": "string",
      "description": "Global color ID to delete (must start with \"gcid-\")."
    },
    "force": {
      "default": false,
      "description": "If true, delete even when live references exist. Customizer-bound defaults remain protected regardless.",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "gcid",
    "force",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_global_color_listGet the global color palette defined in Divi.Free

Get the global color palette defined in Divi. Returns `{ colors, customizer }` — `colors` is the user-defined palette stored under `et_divi.et_global_data.global_colors` (read via the #719 priority-ordered probe); `customizer` surfaces the five WP-customizer-bound defaults (gcid-primary-color / gcid-secondary-color / gcid-heading-color / gcid-body-color / gcid-link-color) sourced from `\ET\Builder\Packages\GlobalData\GlobalData::$customizer_colors`. Top-level `_meta.source_path` + `_meta.probed_paths` document which storage path yielded the user palette; `_meta.customizer_source` describes the customizer-bound default surface. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_global_color_updateUpdate an existing global color by gcid.Free

Update an existing global color by gcid. Only provided fields are updated; omitted fields are preserved. The lastUpdated timestamp is bumped on every write. Use diviops_global_color_list first to find the gcid for a color. NOTE: the underlying upsert is merge-mode — supplying a gcid that doesn't yet exist creates a new color with that gcid (provided it satisfies the gcid charset/length rules) rather than failing as 'not found'. Pre-check via diviops_global_color_list if you need strict-update semantics. CONCURRENCY: same VB-session race caveat as diviops_global_color_create — the write is read-modify-write on a single WP option, so an active VB session's next save can clobber this update. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; malformed gcid charset/length returns code 'invalid_input' with `error.data` documenting the failed field; non-CSS color value returns code 'invalid_input'; attempts to write to a customizer-bound default (gcid-primary-color / gcid-secondary-color / gcid-heading-color / gcid-body-color / gcid-link-color) return code 'variable.customizer_default_immutable' (HTTP 403) with `error.data = { id, managed_by: 'wp_customizer' }` — same code as diviops_variable_delete because the identity is identical (5.4+ unified gcid-* into the variable manager while preserving customizer-binding for the five legacy defaults). Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "gcid": {
      "type": "string",
      "description": "Global color ID, e.g. \"gcid-abc123...\" (must start with \"gcid-\"). Get from diviops_global_color_list."
    },
    "color": {
      "description": "New CSS color value — hex or rgba/hsla notation. Omit to keep existing.",
      "type": "string"
    },
    "label": {
      "description": "New human-readable label. Pass empty string to clear.",
      "type": "string"
    },
    "folder": {
      "description": "New folder. Pass empty string to clear.",
      "type": "string"
    },
    "status": {
      "description": "Change status — \"active\" or \"archived\". Omit to keep existing.",
      "type": "string",
      "enum": [
        "active",
        "archived"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "gcid",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_global_font_audit_storageCheck where global fonts are stored and find inconsistencies.Free

Audit the global_fonts STORAGE LOCATION landscape (#719 contract). Aggregates entries across the gfid-* catalog (`et_divi.et_global_data.global_fonts`) AND the local-hosted `et_uploaded_fonts` Pattern B surface with per-entry provenance via `_meta.entry_sources = { <id>: { path, provenance } }`. Provenance vocabulary: `gfid_catalog` (Google CDN canonical), `uploaded_local` (file-uploaded local-hosted fonts per `reference_local_hosted_fonts_eu_pattern`). Warnings: `id_collision` (same id in both — upstream contract violation since the two surfaces are key-namespace-disjoint by convention). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_global_font_createCreate a new global font in DiviOps's registry under `et_global_data.global_fonts`.Free

Create a new global font in DiviOps's registry under `et_global_data.global_fonts`. Mints a fresh `gfid-<uuid>` if `id` is omitted; otherwise uses the supplied id (must match `gfid-[0-9a-z-]{1,80}`; auto-prefixes `gfid-` if missing). Strict create — collision on existing id returns `conflict` (HTTP 409) with `error.data = { id, existing }`; use diviops_global_font_update to modify an existing record. Stored shape: `{ family, source, weights[], subsets[], label, fallback, status, lastUpdated }`. Required: `family` (CSS family name, e.g. "Sora") + `source` (one of `google`/`system`/`custom`). Distinct from `diviops_variable_create({type:"fonts"})` which writes `gvid-*` font tokens to the variable manager — `global_font_*` is the DiviOps catalog presets bind via `gfid-` slugs. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; input-shape rejections (malformed id, invalid source enum, non-array weights/subsets, missing required `family`/`source` for a new entry) collapse onto `invalid_input` with structured `error.data`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "family": {
      "type": "string",
      "description": "CSS font family name (e.g. \"Sora\", \"Inter\", \"JetBrains Mono\"). Stored as the bare name; consumers wrap in single quotes when emitting CSS."
    },
    "source": {
      "type": "string",
      "enum": [
        "google",
        "system",
        "custom"
      ],
      "description": "Font source: \"google\" (Google Fonts), \"system\" (system/web-safe families), or \"custom\" (self-hosted/CDN)."
    },
    "id": {
      "description": "Optional explicit gfid (e.g. \"gfid-oa-sora\"). Auto-prefixes `gfid-` if missing; must match `[0-9a-z-]{1,80}` after the prefix. Omit to mint a fresh `gfid-<uuid>`.",
      "type": "string"
    },
    "weights": {
      "description": "Font weights to load. Accepts integers (100,200,...,900) or keyword strings (\"normal\",\"bold\",\"lighter\",\"bolder\"). Defaults to []. Drives Google Fonts URL composition + loader hints.",
      "type": "array",
      "items": {
        "type": [
          "number",
          "string"
        ]
      }
    },
    "subsets": {
      "description": "Character subsets (e.g. [\"latin\",\"latin-ext\"]). Defaults to []. Permissive — not allowlisted server-side (Google adds new subsets regularly).",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "label": {
      "description": "Human-readable display label. Defaults to the family name.",
      "type": "string"
    },
    "fallback": {
      "description": "CSS fallback chain appended after the family name (e.g. \"sans-serif\", \"Georgia, serif\"). Defaults to empty.",
      "type": "string"
    },
    "status": {
      "default": "active",
      "description": "Font status — \"active\" (visible) or \"archived\" (hidden but preserved).",
      "type": "string",
      "enum": [
        "active",
        "archived"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "family",
    "source",
    "status",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_global_font_deleteDelete a global font from the registry by gfid.Free

Delete a global font from the registry by gfid. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Live-reference detection uses parse_blocks over post_content across pages / TB layouts / library / canvas + the preset registry (parallel to diviops_variable_delete / diviops_global_color_delete) — MCP-authored content is detected reliably. Returns code 'conflict' (HTTP 409) when references exist with `error.data = { id, ref_count, locations[], scan_truncated, scanned_posts }`. Pass `force: true` to override; orphan refs will fall back to the browser default until pages are re-authored. Missing gfid returns 'not_found' (HTTP 404) with `error.data = { id }`. Malformed gfid (empty or missing `gfid-` prefix) returns 'invalid_input'. Unlike global_color_delete, no customizer-bound `gfid-*` defaults exist to protect — the Divi customizer-bound font defaults live in `heading_font` / `body_font` plain WP options, not this registry. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Global font ID to delete (must start with \"gfid-\")."
    },
    "force": {
      "default": false,
      "description": "If true, delete even when live references exist.",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "force",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_global_font_listList registered global fonts and locally hosted fonts.Free

List the DiviOps-managed global fonts registered under `et_divi.et_global_data.global_fonts` (gfid-* Google catalog) AND the local-hosted Pattern B fonts registered under `et_uploaded_fonts` (per #719 AC #9). Returns `{ count, fonts, uploaded_count, uploaded_fonts }` — both maps always emitted as JSON objects (consistent shape across empty/populated substrates). Top-level `_meta.sources` discriminates the two surfaces with `provenance: "gfid_catalog"` vs `provenance: "uploaded_local"`. Distinct from the variable-manager font tokens (`gvid-*` under `et_global_data.global_variables.fonts`, surfaced via `diviops_variable_list({type:"fonts"})`) — `global_font_*` is the DiviOps-controlled font catalog presets bind to via canonical `gfid-` slugs. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_global_font_updateUpdate an existing global font by gfid.Free

Update an existing global font by gfid. Strict update — `id` must reference an existing record; unknown gfid returns `not_found` (HTTP 404) with `error.data = { id }` (unlike `diviops_global_color_update`'s merge-mode semantics). Partial: only supplied fields are written, omitted fields preserved; `lastUpdated` bumped on every write. To rename a font's family slug, use diviops_global_font_delete + diviops_global_font_create — `family` itself can be updated in place but the `gfid` identity is immutable via this tool. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; malformed id charset/length returns 'invalid_input'; missing `id` returns 'invalid_input' with `error.data.missing = "id"`; invalid source enum / non-array weights / non-array subsets return 'invalid_input' with structured `error.data`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Global font ID (e.g. \"gfid-oa-sora\"). Required. Get from diviops_global_font_list."
    },
    "family": {
      "description": "New CSS family name. Omit to keep existing.",
      "type": "string"
    },
    "source": {
      "description": "New source. Omit to keep existing.",
      "type": "string",
      "enum": [
        "google",
        "system",
        "custom"
      ]
    },
    "weights": {
      "description": "New weights array. Omit to keep existing; pass [] to clear.",
      "type": "array",
      "items": {
        "type": [
          "number",
          "string"
        ]
      }
    },
    "subsets": {
      "description": "New subsets array. Omit to keep existing; pass [] to clear.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "label": {
      "description": "New label. Pass empty string to clear.",
      "type": "string"
    },
    "fallback": {
      "description": "New CSS fallback chain. Pass empty string to clear.",
      "type": "string"
    },
    "status": {
      "description": "New status — \"active\" or \"archived\". Omit to keep existing.",
      "type": "string",
      "enum": [
        "active",
        "archived"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_preset_auditAudit all Divi presets (module + group).Free

Audit all Divi presets (module + group). Each entry reports `block_ref_count` (page-content refs via modulePreset / groupPreset block markup), `group_ref_count` (in-registry chain refs from other presets — module presets via top-level `groupPresets.<slot>.presetId`, group presets via `attrs.groupPreset.<slot>.presetId`), and `referenced` (true if either > 0). Group presets that are chain-referenced also expose `referenced_by_presets` (UUIDs of the presets that wire them in — typically module presets, but type-agnostic). Use this before deleting — orphan-cleanup based only on page refs would silently wipe load-bearing chain-wired group presets (font, border, box-shadow, spacing, button). Also reports `orphan_default_pointers`: per-bucket `default` pointers that reference a UUID no longer present in `items[]` (caused by past unsafe deletes). Render-safe but blocks Divi's lazy recreate-on-VB-use path; clear via diviops_preset_set_default with unset=true on the affected module/group. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_preset_audit_storageInspect preset storage and detect inconsistencies.Free

Audit the D5 preset STORAGE LOCATION landscape (#719 contract). Distinct from `diviops_preset_audit` (which audits preset CONTENT — usage refs, orphans, defaults). Aggregates entries across the canonical top-level `et_divi_builder_global_presets_d5` and the legacy nested `et_divi.builder_global_presets_d5` scratchpad on upgraded substrates, with per-entry provenance via `_meta.entry_sources = { <id>: { path, provenance } }`. Provenance vocabulary: `d5_top_level` (canonical), `d5_nested_scratchpad` (upgrade artifact), `legacy_d4_ng` (D4-era `et_divi_builder_global_presets_ng` store — OUT-OF-BAND per the banner, surfaced via entry_sources only, NEVER merged into the D5 aggregate). Warnings: `id_collision` (same id across D5 paths, same top-level shape), `shape_inconsistency` (same id, divergent top-level keys), `ng_non_empty` (legacy D4 store contains content; surface for inventory). Use this to diagnose substrate state before/after upgrades — agents do NOT auto-migrate; surfacing state is the contract. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; the routing-provenance fields sit on top-level `_meta`.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_preset_cleanupClean up presets.Free

Clean up presets. Default: remove spam presets. Optional: dedup=true to also remove duplicates, action="rename_strip_prefix" with prefix to strip a name prefix, or action="remove_orphans" with scope="spam"|"all" to remove unreferenced presets. Use dry_run: true (default) to preview the standard `data.plan = { summary, changes[] }` without mutating; legacy removed/renamed/deduped summary arrays are preserved as sibling metadata. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "dry_run": {
      "default": true,
      "description": "If true, preview changes without applying. Set false to execute.",
      "type": "boolean"
    },
    "dedup": {
      "default": false,
      "description": "Remove duplicate presets with identical attrs within the same module.",
      "type": "boolean"
    },
    "action": {
      "description": "Action: \"rename_strip_prefix\" strips a prefix, \"remove_orphans\" removes unreferenced presets.",
      "type": "string"
    },
    "prefix": {
      "description": "Prefix to strip when action is \"rename_strip_prefix\" (e.g. \"Online Courses \").",
      "type": "string"
    },
    "scope": {
      "default": "spam",
      "description": "Scope for remove_orphans: \"spam\" (only spam-named orphans) or \"all\" (all non-default orphans).",
      "type": "string",
      "enum": [
        "spam",
        "all"
      ]
    }
  },
  "required": [
    "dry_run",
    "dedup",
    "scope"
  ],
  "additionalProperties": false
}
diviops_preset_createCreate a new preset in the Divi 5 registry.Free

Create a new preset in the Divi 5 registry. For module presets, supply module_name (e.g. "divi/column", "divi/button", "divi/section"), name, and attrs. For group (attribute-level) presets, set type="group" and supply group_name ("divi/font", "divi/button", etc.), group_id ("designTitleText", "button", etc.), and optionally primary_attr_name. Pass dry_run: true to preview the change plan without mutating state. Optional group_presets replaces the native root groupPresets map on module presets only; omission preserves links and {} clears. Slot/group buckets and existing references are validated before writes, including dry-run. attrs.groupPresets is rejected; use group_presets instead. Requires preset_composition_v1; older or unverified plugins refuse composition before dispatch. NOTE: dry_run plan does not pre-allocate the UUID — that's generated at apply time. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Per-bucket name uniqueness check: a name collision in the same `(bucket, bucket_key)` returns code 'conflict' (HTTP 409) with `error.data = { existing_preset_id, bucket, bucket_key, name }` so callers can branch on reuse / rename / preset_update. Bucket coordinates are the natural addressing scope: a 'Hero Title' font preset and a 'Hero Title' button preset coexist (different buckets), but two 'Hero Title' presets under `group/divi/font` collide. Input-shape rejections (missing module_name/name/attrs, type outside [module,group], group preset without group_name/group_id) return code 'invalid_input' with structured `error.data` documenting the failed field.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "group_presets": {
      "description": "Module presets only. Native root groupPresets slot map: { 'title.decoration.font': { presetId: ['existing-id'], groupName: 'divi/font', segmentBoundary?: 0 } }. Existing IDs must belong to the slot's group bucket. Replaces the entire root map; omitted preserves, {} clears. Never put groupPresets in attrs. Requires preset_composition_v1.",
      "type": "object",
      "propertyNames": {
        "type": "string",
        "minLength": 1
      },
      "additionalProperties": {
        "type": "object",
        "properties": {
          "presetId": {
            "minItems": 1,
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            }
          },
          "groupName": {
            "type": "string",
            "minLength": 1
          },
          "segmentBoundary": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "presetId",
          "groupName"
        ],
        "additionalProperties": false
      }
    },
    "module_name": {
      "type": "string",
      "description": "Divi module slug (e.g. \"divi/column\", \"divi/button\", \"divi/section\"). For group presets, this is still required and describes the module the preset originated from."
    },
    "name": {
      "type": "string",
      "description": "Display name for the new preset"
    },
    "attrs": {
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {},
      "description": "Full module attribute bag (same shape as a module's top-level attrs in block markup). Saved to attrs, styleAttrs, and renderAttrs — matches VB save semantics so render cache stays in sync with edit state."
    },
    "type": {
      "default": "module",
      "description": "\"module\" (default) or \"group\" for attribute-level presets.",
      "type": "string",
      "enum": [
        "module",
        "group"
      ]
    },
    "group_name": {
      "description": "Group name (e.g. \"divi/font\", \"divi/button\"). Required when type=\"group\".",
      "type": "string"
    },
    "group_id": {
      "description": "Group id (e.g. \"designTitleText\", \"designText\", \"button\"). Required when type=\"group\".",
      "type": "string"
    },
    "primary_attr_name": {
      "description": "Primary attr name for the group (e.g. \"title\" for designTitleText). Optional.",
      "type": "string"
    },
    "make_default": {
      "description": "If true, set this newly-created preset as the default for its module/group after creation. Defaults apply to NEW instances only — existing modules keep their current preset bindings (use diviops_preset_reassign for retroactive swaps). Saves a round-trip vs. calling diviops_preset_set_default after creation.",
      "type": "boolean"
    },
    "priority": {
      "description": "Stack-merge priority. When this preset participates in a stacked-preset arrangement, Divi sorts ascending and merges in priority order — higher number wins the cascade. Default in Divi is 10 when omitted.",
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "module_name",
    "name",
    "attrs",
    "type",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_preset_deleteDelete a specific preset by ID.Free

Delete presets by exact ID. Legacy preset_id mode checks only the bucket default, NOT references; force=true deletes a default and clears its pointer. Additive preset_ids mode accepts 1-200 unique IDs, refuses defaults, references, unknown/ambiguous IDs, stale registry and incomplete evidence; force cannot bypass these checks. Preview with dry_run:true returns an exact plan and registry_checksum; apply requires expected_registry_checksum and rescans references. Scans all post_content (including revisions/Theme Builder), postmeta, canonical preset definitions/default pointers; conservative matches refuse. Evidence limits: 10000 rows per table, 64 MiB post evidence, nesting 64; unsupported/malformed evidence refuses. Only selected records are removed, in one registry write. No content edits, normalization, transactional guarantee or automatic rollback. Keep other writers idle. Real dry_run in either mode and all exact-set calls require preset_delete_exact_v1; older/unknown plugin capability refuses before dispatch. Returns the standardized envelope; exact-set conflicts carry error.data.reason. Legacy missing IDs return not_found.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "preset_id": {
      "description": "Legacy single ID; mutually exclusive with preset_ids. No reference safeguard.",
      "type": "string",
      "minLength": 1
    },
    "preset_ids": {
      "description": "Exact guarded selection, never name/duplicate heuristics.",
      "minItems": 1,
      "maxItems": 200,
      "type": "array",
      "items": {
        "type": "string",
        "pattern": "^[A-Za-z0-9_-]{1,128}$"
      }
    },
    "dry_run": {
      "description": "True previews with zero writes; false/omitted applies. Capability-gated in both modes.",
      "type": "boolean"
    },
    "expected_registry_checksum": {
      "description": "Exact preview registry_checksum, required for preset_ids apply only.",
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "force": {
      "description": "Legacy preset_id only: delete a default and clear its pointer. Ignored in exact-set mode; never bypasses its safeguards.",
      "type": "boolean"
    }
  },
  "additionalProperties": false
}
diviops_preset_inspectInspect one Divi 5 preset UUID without writing.Free

Inspect one Divi 5 preset UUID without writing. Returns bucket/type/module/group coordinates, attrs/styleAttrs/renderAttrs, outgoing root groupPresets map (empty object when absent), storage path and provenance, block plus preset-chain reference counts with sample consumers, explicit partial coverage, and direct variable_references.ids to join with diviops_variable_list (absent IDs remain unresolved). Includes geometry-scope warnings for layout/position/sizing/transform attrs and a warning for nested D5 or legacy _ng duplicates. Zero references is not deletion approval; stored definitions are not computed styles. This is intentionally narrower than diviops_preset_audit and has no repair mode. Missing UUID returns not_found.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "preset_id": {
      "type": "string",
      "minLength": 1,
      "description": "Preset UUID to inspect."
    }
  },
  "required": [
    "preset_id"
  ],
  "additionalProperties": false
}
diviops_preset_reassignReassign a preset UUID across page content.Free

Reassign a preset UUID across page content. Covers both module-level refs (`attrs.modulePreset[...]`) and attribute-level group-preset refs (`attrs.groupPreset.<slot>.presetId`), plus — for group presets — registry chain refs: module-bucket presets via top-level `groupPresets.<slot>.presetId`, group-bucket presets via `attrs.groupPreset.<slot>.presetId`. The `scope` param controls which ref types are walked (default "both", auto-selects based on new_uuid's bucket). Cross-bucket swaps (module ↔ group) are rejected with code 'preset.bucket_mismatch' (HTTP 400) carrying `error.data = { old_bucket, new_bucket }`. Explicit scope mismatch with new_uuid's bucket returns code 'preset.scope_mismatch' (HTTP 400) with `error.data = { scope, new_bucket }`. When `strip_inline=true` (default), strips inline attrs that duplicate the new preset's attrs (otherwise inline wins over preset): for module scope, strips from block root; for group scope, strips per-slot using Divi's own slot→target-path resolver (handles composite button groups, `-id-classes` suffix, FormField/checkbox/radio `attrName` mappings, cross-module translation). Both scopes enforce a singular-stack guard (skip strip when slot holds multiple presets). Unmappable group slots skip strip and emit a per-slot advisory at `summary.strip_advisory_per_slot[<module>::<slot>]`; neighbor slots are unaffected. Defaults to dry-run — set mode="apply" to actually rewrite. Use this to consolidate repeated inline styling into a reusable preset after creating one with diviops_preset_create. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing/invalid inputs return code 'invalid_input' with structured `error.data` documenting the failed field; new_uuid not in registry returns code 'not_found'; oversized page_ids batch returns code 'preset.too_many_pages' with `error.data = { received, max_pages }`.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "old_uuid": {
      "type": "string",
      "description": "Preset UUID to replace (can be a dangling/orphan UUID)"
    },
    "new_uuid": {
      "type": "string",
      "description": "New preset UUID to insert. Must already exist in the registry."
    },
    "page_ids": {
      "description": "Restrict to specific post IDs. Omit to scan all pages and posts.",
      "type": "array",
      "items": {
        "type": "integer",
        "exclusiveMinimum": 0,
        "maximum": 9007199254740991
      }
    },
    "mode": {
      "default": "dry-run",
      "description": "\"dry-run\" (default) returns the diff without writing. \"apply\" rewrites page content (and registry chains for group-scope swaps).",
      "type": "string",
      "enum": [
        "dry-run",
        "apply"
      ]
    },
    "strip_inline": {
      "default": true,
      "description": "If true (default), strip inline attrs that deep-equal the new preset's attrs so the preset actually takes effect. Applies to both module-scope (block-root strip) and group-scope (per-slot strip via Divi's target-path resolver). Singular-stack guard enforced at both scopes — strip is skipped when the modulePreset stack or a groupPreset slot holds multiple presets. Unmappable group slots skip strip with a per-slot advisory. Set false to swap UUIDs only.",
      "type": "boolean"
    },
    "scope": {
      "default": "both",
      "description": "\"module\" walks `attrs.modulePreset[...]` only. \"group\" walks `attrs.groupPreset.<slot>.presetId` plus registry chain refs (top-level `groupPresets.<slot>.presetId` on module presets, `attrs.groupPreset.<slot>.presetId` on group presets). \"both\" (default) auto-selects based on new_uuid's bucket — module/group identity is disjoint, so there is one valid walk per swap. An explicit \"module\" or \"group\" rejects if new_uuid is in the wrong bucket.",
      "type": "string",
      "enum": [
        "module",
        "group",
        "both"
      ]
    }
  },
  "required": [
    "old_uuid",
    "new_uuid",
    "mode",
    "strip_inline",
    "scope"
  ],
  "additionalProperties": false
}
diviops_preset_registry_doctorAudit the canonical Divi 5 preset registry for non-integer created/updated metadata and stale or failed preset chunk transients. repair=false is always read-only. repair=true only converts parseable ISO timestamps to integer milliseconds, creates a non-autoloaded backup before mutation, preserves unrelated preset payloads, and can optionally clear stale/failed matching chunk transients after a successful repair.Free

Audit the canonical Divi 5 preset registry for non-integer created/updated metadata and stale or failed preset chunk transients. repair=false is always read-only. repair=true only converts parseable ISO timestamps to integer milliseconds, creates a non-autoloaded backup before mutation, preserves unrelated preset payloads, and can optionally clear stale/failed matching chunk transients after a successful repair. Unsupported timestamp values are reported but never normalized. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "repair": {
      "default": false,
      "description": "Enable the narrow ISO timestamp repair path.",
      "type": "boolean"
    },
    "clear_chunk_transients": {
      "default": false,
      "description": "After successful repair, clear only stale or failed matching Divi preset chunk transients.",
      "type": "boolean"
    },
    "dry_run": {
      "default": true,
      "description": "Preview repair and transient cleanup without mutation.",
      "type": "boolean"
    },
    "limit": {
      "default": 100,
      "description": "Maximum findings and transient rows to return.",
      "type": "integer",
      "minimum": 1,
      "maximum": 500
    }
  },
  "required": [
    "repair",
    "clear_chunk_transients",
    "dry_run",
    "limit"
  ],
  "additionalProperties": false
}
diviops_preset_scan_orphansScan page content for modulePreset UUIDs that are not in the D5 registry.Free

Scan page content for modulePreset UUIDs that are not in the D5 registry. Categorizes as dangling orphans (preset was deleted, reference remains) or D4-legacy candidates (preset exists in the legacy builder_global_presets_ng option but not in D5). Use before diviops_preset_reassign to identify stale UUIDs for consolidation. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_preset_set_defaultSet or clear the per-module/group default preset.Free

Set or clear the per-module/group default preset. Two addressing modes: (1) preset_id mode — walks both buckets to locate the preset by UUID, then points the containing module/group's `default` slot at it (or clears it with unset=true). (2) Bucket-addressed clear — pass type + module + unset=true to clear an orphan default pointer when the preset_id no longer exists in items[] (the preset_id walk path can't locate orphans — that's the very state being repaired; surfaced via diviops_preset_audit's `orphan_default_pointers`). Defaults apply to NEW module instances only — existing modules keep their current preset bindings (use diviops_preset_reassign for retroactive swaps). Use diviops_preset_audit's `is_default` and `orphan_default_pointers` fields to verify state before/after. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing preset_id (and not in bucket-addressed-clear mode) / bucket-addressed mode without unset=true return code 'invalid_input'; missing preset / unknown bucket returns 'not_found'. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "preset_id": {
      "description": "Preset UUID. Bucket (module vs. group) and target module/group are auto-resolved from the registry — no need to specify them. Required unless using bucket-addressed clear (type + module + unset=true) to repair an orphan default pointer.",
      "type": "string"
    },
    "type": {
      "description": "Bucket-addressed clear: bucket type. Required together with `module` and `unset=true` to clear an orphan default pointer (UUID gone from items[] but `default` still references it).",
      "type": "string",
      "enum": [
        "module",
        "group"
      ]
    },
    "module": {
      "description": "Bucket-addressed clear: module slug or group key (e.g. \"divi/blurb\", \"divi/font\"). Required together with `type` and `unset=true`.",
      "type": "string"
    },
    "unset": {
      "description": "If true, clear the default pointer. With preset_id, clears the bucket containing that preset. With type+module, clears that bucket directly (use this form for orphan-pointer repair). Defaults to false (set the preset as the default — preset_id required).",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_preset_updateUpdate a specific preset by ID.Free

Update a specific preset by ID. Can rename, replace its style attributes, and/or change its stack priority. Note: Divi serves frontend CSS from a per-post static cache at wp-content/et-cache/{post_id}/ that wp cache flush does NOT invalidate — if you're verifying a preset change on the rendered frontend, delete that dir for affected pages to force regeneration. Server-side preset state updates immediately; only the pre-rendered CSS file is stale. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing preset_id returns code 'not_found' with a hint to diviops_preset_audit. Pass dry_run: true to preview the change plan without mutating state. Optional group_presets replaces the native root groupPresets map on module presets only; omission preserves links and {} clears. Slot/group buckets and existing references are validated before writes, including dry-run. attrs.groupPresets is rejected; use group_presets instead. Requires preset_composition_v1; older or unverified plugins refuse composition before dispatch.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "preset_id": {
      "type": "string",
      "description": "Preset ID (UUID or short ID)"
    },
    "group_presets": {
      "description": "Module presets only. Native root groupPresets slot map: { 'title.decoration.font': { presetId: ['existing-id'], groupName: 'divi/font', segmentBoundary?: 0 } }. Existing IDs must belong to the slot's group bucket. Replaces the entire root map; omitted preserves, {} clears. Never put groupPresets in attrs. Requires preset_composition_v1.",
      "type": "object",
      "propertyNames": {
        "type": "string",
        "minLength": 1
      },
      "additionalProperties": {
        "type": "object",
        "properties": {
          "presetId": {
            "minItems": 1,
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            }
          },
          "groupName": {
            "type": "string",
            "minLength": 1
          },
          "segmentBoundary": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "presetId",
          "groupName"
        ],
        "additionalProperties": false
      }
    },
    "name": {
      "description": "New display name for the preset",
      "type": "string"
    },
    "attrs": {
      "description": "New style attributes (replaces attrs, styleAttrs, and renderAttrs — matches VB save semantics so render cache stays in sync with edit state)",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {}
    },
    "priority": {
      "description": "Stack-merge priority. When this preset is part of a stacked-preset arrangement (e.g. base typography + brand override on the same module/group slot), Divi sorts presets ascending and merges in priority order, so a higher number wins the cascade. Default in Divi is 10 when omitted. Only meaningful for presets that participate in a stack — solo presets render the same regardless of priority.",
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "preset_id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_variable_createCreate a design token variable in the Divi Variable Manager.Free

Create a design token variable in the Divi Variable Manager. Colors (type "colors") use gcid-* IDs and hex values. Numbers/strings/etc use gvid-* IDs. For type="numbers" fluid tokens, pass min+max shorthand (anchors default to 320px/1920px) or explicit targets — server generates arithmetically-correct clamp() formulas. All-px inputs emit px (safe default, root-agnostic). Rem inputs OR rem output require explicit opt-in: pass output_unit="rem" (accepts the 1rem=16px default) or root_font_size_px:N (declares your site's actual root font-size for correct rem emission on non-16px-root sites). Mutually exclusive with value. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; input-shape rejections (invalid type, fluid+value conflict, rem-without-opt-in, malformed id, non-hex color, etc.) return ok:false with code 'invalid_input' and `error.data` documenting the failed field. Algorithmic clamp() failures return code 'variable.fluid_generation_failed' with `error.data = { min, max, targets, reason }`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "type": {
      "type": "string",
      "enum": [
        "colors",
        "numbers",
        "strings",
        "images",
        "links",
        "fonts",
        "gradients"
      ],
      "description": "Variable type"
    },
    "id": {
      "description": "Variable ID (e.g. \"gcid-oa-accent\" for colors, \"gvid-oa-size-xl\" for numbers). Auto-generated if omitted.",
      "type": "string"
    },
    "label": {
      "type": "string",
      "description": "Human-readable label shown in the VB Variable Manager"
    },
    "value": {
      "description": "Variable value (required unless using fluid min/max/targets for type=numbers, OR the structured `gradient` object for type=gradients): hex color for colors (e.g. \"#3a7a6a\"), CSS value for numbers (e.g. \"clamp(30px, 8vw, 100px)\" or \"2rem\"), arbitrary text/URL for strings/links/images. For type=gradients do NOT pass a CSS gradient string here — it stores an unrenderable variable; use the `gradient` object instead (or pass a full $variable({\"type\":\"gradient\",…})$ token verbatim).",
      "type": "string"
    },
    "gradient": {
      "description": "Structured gradient settings for type=\"gradients\" (5.7.4). The server serializes the canonical $variable({\"type\":\"gradient\",value:{name:\"gradient\",settings:{…}}})$ token that Divi resolves to a defined --gvid-* custom property. REQUIRED for a renderable gradient variable — a raw CSS-string `value` is rejected. Ignored for non-gradient types.",
      "type": "object",
      "properties": {
        "stops": {
          "minItems": 2,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "position": {
                "type": [
                  "string",
                  "number"
                ]
              },
              "color": {
                "type": "string"
              }
            },
            "required": [
              "position",
              "color"
            ],
            "additionalProperties": false
          },
          "description": "Gradient color stops, min 2. position = unitless number 0–100 (string or number; PHP normalizes to string); color = hex or a $variable(gcid-…)$ token."
        },
        "type": {
          "description": "Gradient type (default linear). circular/elliptical render as radial-gradient(circle|ellipse …); conic as conic-gradient. NOTE: the enum is circular/elliptical, NOT \"radial\".",
          "type": "string",
          "enum": [
            "linear",
            "circular",
            "elliptical",
            "conic"
          ]
        },
        "direction": {
          "description": "CSS angle for linear/conic (default \"180deg\"), e.g. \"90deg\".",
          "type": "string"
        },
        "directionRadial": {
          "description": "Position keyword for circular/elliptical/conic (default \"center\"), e.g. \"top left\".",
          "type": "string"
        },
        "length": {
          "description": "Gradient length (default \"100%\").",
          "type": "string"
        },
        "repeat": {
          "description": "Repeat the gradient (default \"off\").",
          "type": "string",
          "enum": [
            "on",
            "off"
          ]
        },
        "overlaysImage": {
          "description": "Place gradient above a background image (default \"off\").",
          "type": "string",
          "enum": [
            "on",
            "off"
          ]
        }
      },
      "required": [
        "stops"
      ],
      "additionalProperties": false
    },
    "min": {
      "description": "Fluid minimum value (e.g. \"20px\" or \"1.25rem\"). Paired with max. Anchors default to 320px/1920px. Rem inputs require explicit opt-in via output_unit or root_font_size_px. type=\"numbers\" only.",
      "type": "string"
    },
    "max": {
      "description": "Fluid maximum value (e.g. \"60px\" or \"3.75rem\"). Paired with min.",
      "type": "string"
    },
    "targets": {
      "description": "Explicit two-anchor fluid spec, object keyed by viewport width (px only). Example: {\"320px\":\"20px\",\"1920px\":\"60px\"} → clamp(20px, 12px + 2.5vw, 60px). Exactly 2 entries required. type=\"numbers\" only. Mutually exclusive with min/max. Rem values require explicit opt-in via output_unit or root_font_size_px.",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "string"
      }
    },
    "output_unit": {
      "description": "Unit for generated clamp formula. Omit for all-px inputs (safe default — emits px, root-agnostic). Pass \"rem\" to emit rem (accepts the 1rem=16px assumption unless root_font_size_px is also passed); required when inputs include rem unless root_font_size_px is passed. Pass \"px\" to force px output regardless of input unit.",
      "type": "string",
      "enum": [
        "rem",
        "px"
      ]
    },
    "root_font_size_px": {
      "description": "Site's root font-size in px (positive number), used for correct rem↔px conversion in the generated clamp() formula. Defaults to 16 (standard browser default) when omitted. Pass explicitly for sites that customize `html { font-size }` (e.g. 10 for `html { font-size: 62.5% }`, 20 for `html { font-size: 20px }`). Also counts as an opt-in signal for rem emission — passing it alone (without output_unit) implies rem output. Only applies when min/max/targets is used.",
      "type": "number",
      "exclusiveMinimum": 0
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "type",
    "label",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_variable_create_fluid_systemCreate a coordinated set of fluid typography, spacing and radius variables.Free

Batch-emit a fluid typography + spacing + radius variable set in one call — mirrors Divi 5.4.0's Variable Generator Modal at the algorithm level (clamp() math is identical to diviops_variable_create's fluid mode) but layers profile-selectable anchors over it. Each category is independent and optional. Use for: (1) bootstrapping a design system in one call instead of 20+ individual diviops_variable_create invocations; (2) mirroring ET's variable layout so your tokens coexist with VB-generated ones in the Variable Manager; (3) deterministic preflight via dry_run before committing the registry change. By default, refuses to overwrite existing IDs (returns them in `skipped`) — pass overwrite=true to update in place. Persists in a single atomic write to the variable registry; mid-batch failures roll back cleanly. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; input-shape rejections (invalid namespace, no categories, invalid profile, plan ID collision, etc.) return code 'invalid_input' with `error.data` documenting the failed field. Algorithmic scale-generation failures (degenerate ratios/anchors caught inside compute_typography_scale or compute_size_scale) return code 'variable.fluid_system_generation_failed' with `error.data = { profile, categories, reason }`.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "profile": {
      "default": "divi-default",
      "description": "Anchor preset for the underlying clamp() math. \"divi-default\" (360→1350) matches Divi 5.4.0's Variable Generator Modal defaults; \"wide\" (320→1920) covers a wider device span (the diviops convention); \"custom\" requires custom_anchors. Affects ALL three categories uniformly.",
      "type": "string",
      "enum": [
        "divi-default",
        "wide",
        "custom"
      ]
    },
    "custom_anchors": {
      "description": "Required when profile=\"custom\". Defines the (min_viewport_px, max_viewport_px) pair the clamp() formulas anchor to. max must be > min. (The profile/custom_anchors pairing is also enforced server-side, returning 400 invalid_profile if profile=\"custom\" is sent without custom_anchors.)",
      "type": "object",
      "properties": {
        "min_viewport_px": {
          "type": "number",
          "exclusiveMinimum": 0
        },
        "max_viewport_px": {
          "type": "number",
          "exclusiveMinimum": 0
        }
      },
      "required": [
        "min_viewport_px",
        "max_viewport_px"
      ],
      "additionalProperties": false
    },
    "typography": {
      "type": "object",
      "properties": {
        "base_px": {
          "type": "number",
          "exclusiveMinimum": 0,
          "description": "Base body size in px. Step N's value = base_px × ratio^(steps-1). h1 = largest (top of chain), hN = base."
        },
        "ratio": {
          "anyOf": [
            {
              "type": "number",
              "exclusiveMinimum": 0
            },
            {
              "type": "string",
              "enum": [
                "minor-second",
                "major-second",
                "minor-third",
                "major-third",
                "perfect-fourth",
                "augmented-fourth",
                "perfect-fifth",
                "golden"
              ]
            }
          ],
          "description": "Modular-scale ratio. Pass a named scale ('major-third'=1.25, 'perfect-fifth'=1.5, 'golden'=1.618, etc.) or a raw number. Step N is base × ratio^(steps-N), so h1 (step 1) is the largest size when steps>1."
        },
        "steps": {
          "type": "integer",
          "minimum": 1,
          "maximum": 20,
          "description": "Number of typography steps to emit (e.g. 6 = h1..h6). Cap is 20 to prevent runaway scale chains."
        },
        "max_ratio": {
          "description": "Optional ratio at max viewport. Defaults to ratio (same chain at both anchors). Pass a larger value (e.g. ratio=1.2 + max_ratio=1.333) for a more dramatic scale on large screens.",
          "anyOf": [
            {
              "type": "number",
              "exclusiveMinimum": 0
            },
            {
              "type": "string",
              "enum": [
                "minor-second",
                "major-second",
                "minor-third",
                "major-third",
                "perfect-fourth",
                "augmented-fourth",
                "perfect-fifth",
                "golden"
              ]
            }
          ]
        },
        "fluid_growth": {
          "description": "Multiplicative growth factor at max viewport. Default 1.0 = discrete (each step emits a fixed value, no clamp growth). Common values: 1.2-1.5 for moderate fluid scaling. Step N's clamp goes from `base × ratio^(steps-N)` at min_viewport to `base × max_ratio^(steps-N) × fluid_growth` at max_viewport.",
          "type": "number",
          "exclusiveMinimum": 0
        },
        "name_prefix": {
          "description": "ID prefix per step. Default 'h' → IDs become gvid-{namespace}-size-h1..hN. Pass 'display' for hero sizes ('gvid-{namespace}-size-display1..').",
          "type": "string"
        }
      },
      "required": [
        "base_px",
        "ratio",
        "steps"
      ],
      "additionalProperties": false
    },
    "spacing": {
      "type": "object",
      "properties": {
        "min_px": {
          "type": "number",
          "minimum": 0
        },
        "max_px": {
          "type": "number",
          "exclusiveMinimum": 0
        },
        "steps": {
          "type": "integer",
          "minimum": 1,
          "maximum": 30
        },
        "scale": {
          "default": "linear",
          "description": "Distribution between min_px and max_px. 'linear' = equal arithmetic spacing (best for spacing scales). 'geometric' = equal multiplicative spacing (best for typography-like scales). geometric requires min_px > 0.",
          "type": "string",
          "enum": [
            "linear",
            "geometric"
          ]
        },
        "fluid_growth": {
          "description": "Multiplicative growth factor at max viewport. Default 1.0 = discrete (each spacing token is constant across viewports — typical design-system behavior). > 1.0 = fluid (each token scales from `value` at min_viewport to `value × fluid_growth` at max_viewport).",
          "type": "number",
          "exclusiveMinimum": 0
        },
        "name_prefix": {
          "description": "ID prefix. Default 'space' → gvid-{namespace}-space-1..N.",
          "type": "string"
        }
      },
      "required": [
        "min_px",
        "max_px",
        "steps",
        "scale"
      ],
      "additionalProperties": false
    },
    "radius": {
      "type": "object",
      "properties": {
        "min_px": {
          "type": "number",
          "minimum": 0
        },
        "max_px": {
          "type": "number",
          "exclusiveMinimum": 0
        },
        "steps": {
          "type": "integer",
          "minimum": 1,
          "maximum": 30
        },
        "scale": {
          "default": "linear",
          "type": "string",
          "enum": [
            "linear",
            "geometric"
          ]
        },
        "fluid_growth": {
          "description": "Multiplicative growth factor at max viewport. Default 1.0 = discrete. Most radius tokens stay discrete; pass > 1.0 only when you want corners to grow with viewport.",
          "type": "number",
          "exclusiveMinimum": 0
        },
        "name_prefix": {
          "description": "ID prefix. Default 'rounded' → gvid-{namespace}-rounded-1..N.",
          "type": "string"
        }
      },
      "required": [
        "min_px",
        "max_px",
        "steps",
        "scale"
      ],
      "additionalProperties": false
    },
    "namespace": {
      "default": "oa",
      "description": "Namespace inserted into every generated ID (gvid-{namespace}-*). Default 'oa' matches existing diviops convention. Validated against [a-z0-9_-]+ on both client and server (rejects rather than sanitizes — see message for rationale).",
      "type": "string",
      "pattern": "^[a-z0-9_-]+$"
    },
    "output_unit": {
      "description": "Unit for emitted clamp() formulas. Defaults to \"px\" (root-agnostic, safe). Pass \"rem\" to opt into rem emission (bakes the 1rem=16px assumption unless root_font_size_px is also passed).",
      "type": "string",
      "enum": [
        "rem",
        "px"
      ]
    },
    "root_font_size_px": {
      "description": "Site's actual root font-size in px. Pass for non-16px-root sites (e.g. 10 for `html { font-size: 62.5% }`). Passing this alone implies output_unit='rem'.",
      "type": "number",
      "exclusiveMinimum": 0
    },
    "dry_run": {
      "default": false,
      "description": "Preview the standard dry-run plan without persisting. The response also preserves `created`/`skipped` diagnostics so callers can audit IDs and clamp() values before committing.",
      "type": "boolean"
    },
    "overwrite": {
      "default": false,
      "description": "When false (default), existing IDs land in `skipped` with the existing value. When true, each existing ID is updated in place (label + value rewritten, order preserved).",
      "type": "boolean"
    }
  },
  "required": [
    "profile",
    "namespace",
    "dry_run",
    "overwrite"
  ],
  "additionalProperties": false
}
diviops_variable_deleteDelete a design token variable by ID.Free

Delete a design token variable by ID. Auto-detects storage from ID prefix (gcid-* = colors, gvid-* = numbers/strings/etc). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Live-reference collision returns ok:false with code 'conflict' (HTTP 409) and `error.data = { id: string, ref_count: number, locations: object[] }` so callers can audit before re-issuing with force=true. The `locations` array is a discriminated union by `type` — content surfaces emit `{ type: 'page'|'post'|'et_header_layout'|'et_body_layout'|'et_footer_layout'|'et_pb_layout'|'et_pb_canvas', post_id: number, title: string }` (post_type as `type` so the Theme Builder + library + canvas flavors are distinguishable); preset-registry refs emit `{ type: 'preset', bucket: 'module'|'group', module: string, preset_uuid: string, preset_name: string }`. This shape is the precedent for any future conflict envelope carrying structured `error.data` collections. Run diviops_variable_scan_orphans first to see where the references live. Customizer-bound color defaults (gcid-primary-color, gcid-secondary-color, gcid-heading-color, gcid-body-color, gcid-link-color) are managed via WP Customizer theme options and reject with code 'variable.customizer_default_immutable' (HTTP 403). Missing IDs return 'not_found' (HTTP 404). Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Variable ID to delete (e.g. \"gcid-oa-accent\" or \"gvid-oa-size-xl\")"
    },
    "force": {
      "default": false,
      "description": "Delete even if live references exist. Orphans will remain in page/preset content and render as invalid CSS on the frontend — run diviops_variable_scan_orphans afterwards to audit.",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "force",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_variable_listList all design token variables from the Divi Variable Manager.Free

List all design token variables from the Divi Variable Manager. Colors (gcid-*) come from et_global_data, numbers/strings/etc (gvid-*) from et_divi_global_variables. Filter by type or stored ID prefix. The `prefix` parameter does not match labels; for semantic names such as `oa-*` labels on UUID-backed Divi variables, list by type and filter returned labels client-side. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; invalid `type` returns ok:false with code 'invalid_input'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "type": {
      "description": "Filter by variable type",
      "type": "string",
      "enum": [
        "colors",
        "numbers",
        "strings",
        "images",
        "links",
        "fonts",
        "gradients"
      ]
    },
    "prefix": {
      "description": "Filter by stored ID prefix only. Does not match labels; for semantic names such as \"oa-*\" labels, list by type and filter returned labels client-side.",
      "type": "string"
    }
  },
  "additionalProperties": false
}
diviops_variable_scan_orphansFind missing design-token references and unused variables.Free

Scan pages, Theme Builder layouts (header/body/footer), Divi Library items, canvas pages, and the preset registry for gvid-/gcid- references that have no backing entry in the Variable Manager (orphans), plus variables defined but referenced nowhere (unused). Orphans render as invalid CSS on the frontend — the $variable()$ resolver falls through with no fallback. Use after a deletion with force=true, or periodically as a hygiene check. Also reports incompatible_variables: exact legacy non-color IDs, whether defined, type (null if undefined), known reference count and locations. These can be defined and referenced without being orphans. scan_scope describes coverage and truncation; zero known references is not proof safe to delete. Recreate reviewed replacements and update reviewed references; never silently lowercase IDs. ID compatibility is not frontend rendering verification. Symmetric to diviops_preset_scan_orphans. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_variable_used_on_pageIdentify the design variables used by one page.Free

Return native-detected numeric/font variable IDs for a single page — the set Divi 5.4.0+ uses to scope selective `:root{--gvid-*}` CSS variable emission. Walks the same content stack the frontend assembles: post_content + active Theme Builder header/body/footer template content + appended canvas content (interaction targets etc.), plus presets referenced by that content. NOTE: this is `gvid-*` only — color variables (`gcid-*`) are emitted via a separate path (`GlobalData` color block) that is NOT scoped per-page in 5.4.0; this tool returns gvid IDs only. Native detection may truncate incompatible legacy IDs; this is not proof of successful CSS emission or a complete recovery inventory. Use diviops_variable_scan_orphans for full recognized legacy IDs and known locations. Use this tool to debug why a numeric/font variable doesn't render on a specific page. Read-only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { post_id, variable_ids (sorted, deduped), count, tb_template_ids }. Missing post_id returns 'not_found'; non-positive post_id returns 'invalid_input'; a Divi 5 environment without the `\\ET\\Builder\\FrontEnd\\Assets\\DetectFeature` class (e.g. Divi 4 active, or Divi disabled) returns 'wp_error' (HTTP 500) with a hint to activate Divi 5.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "post_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "WordPress post/page ID. The page does not need to be Divi-built — TB templates and canvases attached to non-Divi posts are still scanned."
    }
  },
  "required": [
    "post_id"
  ],
  "additionalProperties": false
}

Theme Builder and menus

diviops_menu_createCreate a WordPress nav menu by name, optionally with a requested slug.Free

Create a WordPress nav menu by name, optionally with a requested slug. Free/core single-site menu authoring primitive. Requires edit_theme_options. Existing same-name or same-slug menus return ok:true with noop:true instead of creating duplicates. Does not assign the menu to a location; follow with diviops_menu_location_assign. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "minLength": 1,
      "description": "Menu display name, e.g. Primary"
    },
    "slug": {
      "description": "Optional sanitized menu slug. Omit to let WordPress derive it.",
      "type": "string"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "name",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_menu_getFetch one WordPress nav menu with normalized flat items and a nested item tree.Free

Fetch one WordPress nav menu with normalized flat items and a nested item tree. Free/core, read-only. Requires edit_theme_options. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing menu_id returns not_found.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "menu_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "WordPress nav menu term ID"
    }
  },
  "required": [
    "menu_id"
  ],
  "additionalProperties": false
}
diviops_menu_item_add_customAppend a custom URL item to an existing WordPress nav menu.Free

Append a custom URL item to an existing WordPress nav menu. Free/core single-site menu authoring primitive. Requires edit_theme_options. URL validation allows only http, https, root-relative paths, same-page hashes, mailto, and tel; protocol-relative/javascript/data URLs are rejected. Existing same URL under the same parent with the same label returns noop:true. No delete, reorder, or broad reconcile path. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "menu_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "WordPress nav menu term ID"
    },
    "label": {
      "type": "string",
      "minLength": 1,
      "description": "Menu item label"
    },
    "url": {
      "type": "string",
      "minLength": 1,
      "description": "Allowed URL: http(s), root-relative path, #hash, mailto, or tel"
    },
    "parent_item_id": {
      "default": 0,
      "description": "Optional parent menu item ID from diviops_menu_get; 0 for top level.",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "menu_id",
    "label",
    "url",
    "parent_item_id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_menu_item_add_pageAppend a readable published page to an existing WordPress nav menu.Free

Append a readable published page to an existing WordPress nav menu. Free/core single-site menu authoring primitive. Requires edit_theme_options plus read access to the page. Validates menu, page status/visibility, and optional parent menu item. Existing same page under the same parent returns noop:true; a different existing label returns conflict because item-update/reorder are deferred. No delete, reorder, or broad reconcile path. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "menu_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "WordPress nav menu term ID"
    },
    "page_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Published page ID to add"
    },
    "label": {
      "description": "Optional menu label. Defaults to the page title.",
      "type": "string"
    },
    "parent_item_id": {
      "default": 0,
      "description": "Optional parent menu item ID from diviops_menu_get; 0 for top level.",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "menu_id",
    "page_id",
    "parent_item_id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_menu_listList WordPress nav menus, registered theme locations, and current location assignments.Free

List WordPress nav menus, registered theme locations, and current location assignments. Free/core, read-only. Requires the WordPress user to have edit_theme_options. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { menus[], count, registered_locations, assigned_locations }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_menu_location_assignAssign an existing WordPress nav menu to a registered theme location discovered from the current theme.Free

Assign an existing WordPress nav menu to a registered theme location discovered from the current theme. Free/core single-site menu authoring primitive. Requires edit_theme_options. Rejects arbitrary location strings; call diviops_menu_list first and use data.registered_locations keys. Reassigning the same menu/location returns noop:true. No location removal path in this MVP. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "menu_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "WordPress nav menu term ID"
    },
    "location": {
      "type": "string",
      "minLength": 1,
      "description": "Registered theme location key from diviops_menu_list"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "menu_id",
    "location",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_tb_layout_block_insertInsert one or more serialized Divi blocks into an existing Theme Builder layout without replacing the whole layout.Free

Insert one or more serialized Divi blocks into an existing Theme Builder layout without replacing the whole layout. Target a unique parent with `parent_selector` (for example `divi/group[adminLabel="Legal Col"]`, or `divi/group` only when it is unique) or an explicit zero-based `parent_path` from the parsed block tree such as `0.1.2`. `position=append|prepend` inserts as children of the target block; `position=before|after` inserts beside the target within its parent. Ambiguous selectors return ok:false with code 'invalid_input'; missing targets return 'not_found'. Inserted named blocks and the target must be native Divi modules or custom modules registered through Divi; unrelated stored siblings are preserved. This registration check does not validate extension-specific attribute schemas or child-container rules. The route parses and validates the inserted blocks, rejects malformed serialization (literal pseudo-escapes such as bare `u003c` are allowed in native Code content strings), validates the final serialized layout before saving, and returns a no-op when the exact requested block sequence already exists at the insertion point. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "layout_id": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "Theme Builder layout post ID to mutate"
    },
    "parent_selector": {
      "description": "Unique selector such as `divi/group[adminLabel=\"Legal Col\"]` or `divi/column`. Provide exactly one of parent_selector or parent_path.",
      "type": "string"
    },
    "parent_path": {
      "description": "Zero-based parsed-tree path such as `0`, `0.1`, or `0.1.2`. Provide exactly one of parent_selector or parent_path.",
      "type": "string"
    },
    "position": {
      "default": "append",
      "description": "Where to insert relative to the target block.",
      "type": "string",
      "enum": [
        "append",
        "prepend",
        "before",
        "after"
      ]
    },
    "content": {
      "type": "string",
      "description": "One or more serialized Divi blocks to insert"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "layout_id",
    "position",
    "content",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_tb_layout_getGet a Theme Builder layout's block markup content (header, body, or footer).Free

Get a Theme Builder layout's block markup content (header, body, or footer). Use the layout IDs from diviops_tb_template_list. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing layout_id returns ok:false with code 'not_found' and a hint pointing to diviops_tb_template_list.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "layout_id": {
      "type": "number",
      "description": "Layout post ID (from template header_layout_id, body_layout_id, or footer_layout_id)"
    }
  },
  "required": [
    "layout_id"
  ],
  "additionalProperties": false
}
diviops_tb_layout_updateUpdate a Theme Builder layout's block markup (header, body, or footer).Free

Update a Theme Builder layout's block markup (header, body, or footer). Replaces the full content. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing layout_id returns ok:false with code 'not_found'. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "layout_id": {
      "type": "number",
      "description": "Layout post ID to update"
    },
    "content": {
      "type": "string",
      "description": "New block markup content"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "backup": {
      "default": false,
      "description": "When true on supported content writes, capture a rollback snapshot before applying. dry_run + backup only reports the planned snapshot and does not create one.",
      "type": "boolean"
    }
  },
  "required": [
    "layout_id",
    "content",
    "dry_run",
    "backup"
  ],
  "additionalProperties": false
}
diviops_tb_template_createCreate a Theme Builder template with custom header and/or footer.Free

Create a Theme Builder template with custom header and/or footer. Automatically creates layout posts, sets conditions, and links to Theme Builder. Pass condition="default" (case-insensitive) or an empty string to register the template as the catch-all Default Website Template — the route writes the `_et_default = '1'` flag with an empty `_et_use_on`, matching the meta shape Divi's TB router gates the default route on; any other condition string lands in `_et_use_on` unchanged. Default Website Template is a singleton scoped to the active Theme Builder master: if the active master's `_et_template` linked list already names an et_template carrying `_et_default = '1'` (regardless of `_et_enabled` status — the router resolves by linked-list position before checking the enable-gate, so a disabled existing default linked ahead of the new one would still shadow it), the route rejects with code `tb_template.default_already_exists` (HTTP 409) and `error.data.existing_default_id` + `error.data.master_post_id`. Templates outside the active master's linked list (orphan defaults, library-cloned-master defaults) cannot shadow the router's pick and DO NOT block creation. Caller resolves a real conflict by trashing the existing default (diviops_tb_template_trash) or pinning this template to a specific condition; the route never silently flips the existing default's flag or proceeds with non-deterministic router state. If the Theme Builder master post is missing (fresh substrate that never opened Divi → Theme Builder in WP Admin), the route auto-bootstraps one with the same shape Divi creates on first admin visit and returns `data.master_post_bootstrapped: true` so callers can audit the side-effect. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; failures during master-post bootstrap or template/layout insert surface the underlying WP_Error code (commonly `db_insert_error`, `db_update_error`, or other slugs from the WordPress vocabulary), not a generic `wp_error` — branch on `error.code` against the WP slug, not against a hard-coded string. The literal `wp_error` slug only surfaces when the upstream WP_Error has an empty code. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "Template name (e.g. \"Landing Pages\")"
    },
    "condition": {
      "type": "string",
      "description": "Condition string. Pass \"default\" (case-insensitive) or \"\" for the catch-all Default Website Template (sets `_et_default = 1`). Otherwise a Divi router-recognized location string such as \"singular:post_type:page:all\", \"singular:post_type:project:all\", \"archive:taxonomy:category:all\", \"homepage\", or \"404\" (lands in `_et_use_on`)."
    },
    "header_content": {
      "default": "",
      "description": "Header block markup. Empty links the active enabled default template’s header layout and enabled state at creation; otherwise uses native-theme fallback. Links are not automatically rebound if the default layout ID changes. Invalid inheritance is refused; dry_run reports resolved regions.",
      "type": "string"
    },
    "footer_content": {
      "default": "",
      "description": "Footer block markup. Empty links the active enabled default template’s footer layout and enabled state at creation; otherwise uses native-theme fallback. Links are not automatically rebound if the default layout ID changes. Invalid inheritance is refused; dry_run reports resolved regions.",
      "type": "string"
    },
    "body_content": {
      "default": "",
      "description": "Body block markup (omitted/empty = existing no-custom-body behavior). Nonempty content requires plugin capability tb_template_create_body; returns body_layout_id. No global Theme Builder save or legacy cleanup.",
      "type": "string"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "title",
    "condition",
    "header_content",
    "footer_content",
    "body_content",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_tb_template_listList all Theme Builder templates with their conditions, layout IDs, and enabled status.Free

List all Theme Builder templates with their conditions, layout IDs, and enabled status. Shows which template applies to which pages/post types. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "per_page": {
      "default": 50,
      "description": "Results per page (max 100)",
      "type": "number",
      "maximum": 100
    },
    "page": {
      "default": 1,
      "description": "Page number",
      "type": "number"
    }
  },
  "required": [
    "per_page",
    "page"
  ],
  "additionalProperties": false
}
diviops_tb_template_trashTrash (or permanently delete) a Theme Builder template AND its linked header/body/footer layouts AND scrub the `_et_template` meta refs on the Theme Builder master post.Free

Trash (or permanently delete) a Theme Builder template AND its unshared linked header/body/footer layouts AND scrub the `_et_template` meta refs on the Theme Builder master post. Closes the orphan-meta gap left by `diviops_page_trash` / wp-cli `post delete` on linked layouts: the typed wrapper performs ordered cleanup. Layouts referenced by another template (including disabled, trashed, library or orphan templates) are preserved in both modes and reported in data.preserved_layouts; previews exclude them from destructive changes. A failed reference check aborts before mutations. Defaults to trash (reversible via WP Admin → Trash). Pass `force=true` to permanently delete (wp_delete_post — irreversible, one-shot: a repeat call after a successful force-delete returns 'not_found' because the template post is gone from the DB). Idempotency applies to the default trash mode only: a repeat call after a successful trash-mode cleanup returns ok:true with `data.already_trashed = true` (mirrors `diviops_page_trash`). If a prior trash-mode call partially succeeded (some layouts already trashed, master meta still carries refs), the next call detects already-trashed targets via pre-state checks, skips the no-op WP destructor calls (which would otherwise return false), and still runs the meta scrub — `data.linked_layouts[].skipped` and `data.template_skipped` flag the targets that were already at the end-state. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing template_id returns 'not_found' (HTTP 404), delete-permission failures return 'forbidden' (HTTP 403); per-step trash/delete/meta-scrub failures return the namespaced 'tb_template.command_failed' (HTTP 500) with `error.data.failed_step` ∈ { 'layout_references', 'layout_destroy', 'template_destroy', 'meta_scrub' } plus `template_id` and `force`. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "template_id": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "Theme Builder template post ID (the `et_template` post). Discover via diviops_tb_template_list — NOT the linked layout IDs."
    },
    "force": {
      "default": false,
      "description": "When true, permanently delete (skips trash). Default false moves to trash.",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "template_id",
    "force",
    "dry_run"
  ],
  "additionalProperties": false
}

Reusable layouts and overlays

diviops_canvas_createCreate a canvas (off-canvas workspace) linked to a page.Free

Create a canvas (off-canvas workspace) linked to a page. Used for popups, off-canvas menus, modals. Content uses standard Divi block markup. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing parent_page_id returns ok:false with code 'not_found'; non-string content / malformed canvas_id / append_to_main outside {above, below} returns 'invalid_input'. Returns code 'conflict' (HTTP 409) when a canvas with the same title already exists under the same parent_page_id — error.data = { existing_canvas_id, parent_page_id, title }. Mirrors diviops_preset_create's uniqueness contract. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "Canvas name (e.g. \"Popup Menu\", \"Modal Contact Form\")"
    },
    "parent_page_id": {
      "type": "number",
      "description": "Parent page post ID"
    },
    "content": {
      "default": "",
      "description": "Divi block markup for canvas content",
      "type": "string"
    },
    "canvas_id": {
      "description": "Canvas UUID (auto-generated if omitted)",
      "type": "string"
    },
    "append_to_main": {
      "description": "Auto-append position relative to main content",
      "type": "string",
      "enum": [
        "above",
        "below"
      ]
    },
    "z_index": {
      "description": "Layering order (higher = on top)",
      "type": "number"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "title",
    "parent_page_id",
    "content",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_canvas_deleteDelete a canvas.Free

Delete a canvas. This permanently removes the canvas post. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing canvas_post_id returns ok:false with code 'not_found'. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "canvas_post_id": {
      "type": "number",
      "description": "Canvas post ID to delete"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "canvas_post_id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_canvas_duplicateDeep-copy a canvas (post_content + canvas-specific meta: parent page, append_to_main, z_index).Free

Deep-copy a canvas (post_content + canvas-specific meta: parent page, append_to_main, z_index). Source canvas untouched. Default copy title is `<source title> (Copy)` with auto-suffix on collision (Copy 2, Copy 3, …) — use this for repeat-clone workflows. Pass an explicit `title` for a deliberate name; collisions return ok:false with code 'conflict' (HTTP 409) and `error.data = { existing_canvas_id, parent_page_id }` so callers can retrieve / rename the conflicting canvas. Pass `dry_run: true` to preview without mutating. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing canvas_post_id returns 'not_found'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "canvas_post_id": {
      "type": "number",
      "description": "Source canvas post ID"
    },
    "title": {
      "description": "Optional explicit title for the duplicate. Omit to auto-derive `<source> (Copy [N])`. Explicit collisions return 409.",
      "type": "string"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan without creating the canvas.",
      "type": "boolean"
    }
  },
  "required": [
    "canvas_post_id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_canvas_getGet a canvas's block content and metadata.Free

Get a canvas's block content and metadata. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing canvas_post_id returns ok:false with code 'not_found' and a hint pointing to diviops_canvas_list.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "canvas_post_id": {
      "type": "number",
      "description": "Canvas post ID (from diviops_canvas_list)"
    }
  },
  "required": [
    "canvas_post_id"
  ],
  "additionalProperties": false
}
diviops_canvas_listList canvases (off-canvas workspaces).Free

List canvases (off-canvas workspaces). Filter by parent page or list all. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "parent_page_id": {
      "description": "Filter by parent page ID (omit for all canvases)",
      "type": "number"
    },
    "per_page": {
      "default": 50,
      "description": "Max results (default 50, 1-100)",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "per_page"
  ],
  "additionalProperties": false
}
diviops_canvas_orphan_auditRead-only audit of et_pb_canvas posts and off-canvas reference evidence.Free

Read-only audit of et_pb_canvas posts and off-canvas reference evidence. Returns canvases[], references[], unknowns[], and summary with verdicts referenced, likely_orphan, or unknown. Ambiguous, malformed, cache-only, or weak evidence returns unknown rather than likely_orphan. No delete, cleanup, remap, cache mutation, or cross-environment apply path is performed. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "parent_page_id": {
      "description": "Optional parent page/layout post ID filter",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "include_global": {
      "default": true,
      "description": "Include canvases without parent/context evidence (default true)",
      "type": "boolean"
    },
    "include_context": {
      "default": true,
      "description": "Use _divi_canvas_parent_context as reference evidence when present",
      "type": "boolean"
    },
    "status": {
      "default": "any",
      "description": "Canvas post_status filter",
      "type": "string",
      "enum": [
        "any",
        "publish",
        "draft",
        "pending",
        "private",
        "future",
        "trash"
      ]
    },
    "per_page": {
      "default": 100,
      "description": "Max canvas posts to audit (default 100, 1-100)",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "include_global",
    "include_context",
    "status",
    "per_page"
  ],
  "additionalProperties": false
}
diviops_canvas_updateUpdate a canvas's content and/or metadata.Free

Update a canvas's content and/or metadata. Pass any subset of fields — e.g. `{canvas_post_id, title}` to rename without touching content. `content` replaces the entire canvas when present. At least one of content/title/append_to_main/z_index is required. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing canvas_post_id returns ok:false with code 'not_found'; empty / no-op payload (no content/title/append_to_main/z_index) returns 'invalid_input' with a hint pointing at the rename-only path. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "canvas_post_id": {
      "type": "number",
      "description": "Canvas post ID"
    },
    "content": {
      "description": "New block markup (replaces entire content)",
      "type": "string"
    },
    "title": {
      "description": "New canvas title",
      "type": "string"
    },
    "append_to_main": {
      "description": "Append position: \"above\", \"below\", or \"\" to clear",
      "type": "string",
      "enum": [
        "above",
        "below",
        ""
      ]
    },
    "z_index": {
      "description": "Layering order",
      "type": "number"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "canvas_post_id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_library_getGet a Divi Library item's content by ID.Free

Get a Divi Library item's content by ID. Returns the raw block markup that can be used with diviops_section_append or diviops_page_update_content. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; missing item_id returns ok:false with code 'not_found' and a hint pointing to diviops_library_list.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "item_id": {
      "type": "number",
      "description": "Library item ID"
    }
  },
  "required": [
    "item_id"
  ],
  "additionalProperties": false
}
diviops_library_listList saved Divi Library items.Free

List saved Divi Library items. Filter by layout_type (section, row, module) and scope (global, non_global). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "layout_type": {
      "description": "Filter by type: \"section\", \"row\", \"module\", or empty for all",
      "type": "string"
    },
    "scope": {
      "description": "Filter by scope: \"global\", \"non_global\", or empty for all",
      "type": "string"
    },
    "per_page": {
      "default": 50,
      "description": "Max results (default 50)",
      "type": "number"
    }
  },
  "required": [
    "per_page"
  ],
  "additionalProperties": false
}
diviops_library_saveSave Divi block markup to the Divi Library for reuse.Free

Save Divi block markup to the Divi Library for reuse. Saved items appear in the VB's "Add From Library" panel. Title-uniqueness is enforced and scoped to (layout_type, scope) — a "Hero" section and a "Hero" row coexist (different design intent), but a second "Hero" section under the same scope returns ok:false with code 'conflict' (HTTP 409) and `error.data = { existing_library_id, layout_type, scope }` so callers can retrieve the existing item and decide whether to reuse, rename, or delete-and-replace. Other rejections: missing title / non-string content / invalid layout_type or scope return 'invalid_input'. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "Display name for the library item"
    },
    "content": {
      "type": "string",
      "description": "Block markup to save (section, row, or module)"
    },
    "layout_type": {
      "default": "section",
      "description": "Type of layout: \"section\", \"row\", or \"module\"",
      "type": "string",
      "enum": [
        "section",
        "row",
        "module"
      ]
    },
    "scope": {
      "default": "non_global",
      "description": "\"global\" = synced across all uses, \"non_global\" = independent copies",
      "type": "string",
      "enum": [
        "global",
        "non_global"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "title",
    "content",
    "layout_type",
    "scope",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_template_getGet a specific Divi template with verified block markup, customizable variables, and usage notes.Free

Get a specific Divi template with verified block markup, customizable variables, and usage notes. Use this to generate pages based on proven patterns. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Missing template names return ok:false with code 'not_found' and error.data.available: string[] listing the registered template names.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "template_name": {
      "type": "string",
      "description": "Template name (e.g. \"hero-centered\", \"hero-split\", \"hero-marquee\", \"features-blurbs\", \"cta-gradient\", \"cards-flex\")"
    }
  },
  "required": [
    "template_name"
  ],
  "additionalProperties": false
}
diviops_template_listList available Divi page section templates.Free

List available Divi page section templates. Each template contains verified block markup patterns that can be used as a base for page generation. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is an array of { name, description, customizable, requires_css }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}

Inspect and validate

diviops_render_previewRender Divi block markup to HTML.Free

Render Divi block markup to HTML. Accepts EITHER inline `content` (string of block markup) OR `page_id` (loads `post_content` from the DB, requires edit_post capability on the page — useful for previewing shipped pages without round-tripping the markup blob). Provide exactly one. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { rendered_html: string }. Errors map to `invalid_input` (neither/both supplied, or invalid page_id), `forbidden` (caller lacks edit_post on the page), `not_found` (page_id does not exist), or `divi_error` (parser/render exception, with truncated message and full detail in `error.data.detail`).

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "content": {
      "description": "Divi block markup to render to HTML. Provide exactly one of {content, page_id}.",
      "type": "string"
    },
    "page_id": {
      "description": "WordPress post/page ID to read post_content from the DB. Requires edit_post capability on the page. Provide exactly one of {content, page_id}.",
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    }
  },
  "additionalProperties": false
}
diviops_schema_get_moduleGet the attribute schema for a Divi module.Free

Get the registered attribute schema for a native or Divi-registered custom module. Extension registration does not guarantee complete metadata or native rendering compatibility. Default mode 'single' returns one module's schema (optimized, ~70% smaller; pass raw: true for full). Mode 'dump_all' snapshots native Divi modules only in one call and includes a `schema_version` hash over the canonical *PresetAttrsMap.php files — build-time entry point for the skill regen pipeline; ignores `module_name` and `raw`. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "mode": {
      "default": "single",
      "description": "'single' (default): return one module's schema. 'dump_all': return native Divi modules keyed by name plus schema_version + divi_version.",
      "type": "string",
      "enum": [
        "single",
        "dump_all"
      ]
    },
    "module_name": {
      "description": "Module name, e.g. \"text\", \"image\", \"accordion\", full \"divi/text\", or a registered extension such as \"difl/faq\". Required when mode=\"single\"; ignored when mode=\"dump_all\".",
      "type": "string"
    },
    "raw": {
      "default": false,
      "description": "Return full schema including CSS selectors and VB metadata. Applies to mode='single' only.",
      "type": "boolean"
    }
  },
  "required": [
    "mode",
    "raw"
  ],
  "additionalProperties": false
}
diviops_schema_get_settingsGet Divi site settings including site info, builder version, and a narrow public allowlist of non-sensitive Divi theme options (fonts, colors, sizes).Free

Get Divi site settings including site info, builder version, and a narrow public allowlist of non-sensitive Divi theme options (fonts, colors, sizes). Useful for understanding the site context before generating content. Does not expose the raw `et_divi` option bag. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_schema_list_modulesList all available Divi modules (block types) with their names, titles, and categories.Free

List registered native Divi and Divi-registered custom modules (block types) with their names, titles, and categories. Use this to discover what modules can be used in layouts. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_validate_blocksValidate Divi block markup before saving.Free

Validate Divi block markup before saving. Accepts EITHER inline `content` (string of block markup) OR `page_id` (loads `post_content` from the DB, requires edit_post capability on the page — useful for regression checks on shipped pages without round-tripping the markup blob). Provide exactly one. Checks shared write serialization and marker integrity (literal pseudo-escapes are allowed in native Code content strings), structure (malformed comments, unknown blocks, missing builderVersion), required attributes (layout display on containers), and known pitfalls (button padding path, icon.enable, gradient enabled/positions). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { valid: bool, total_blocks: number, errors: Finding[], warnings: Finding[] } where each Finding is { block, index, code, message, path? }. Serialization failures return valid:false with invalid_serialization findings and total_blocks:0 because the tree was not walked. Note: shape errors detected in the markup surface as success-branch `data.errors[]` entries (NOT `validation_failed` envelopes) — the findings array is the payload, not an error. The envelope's error branch fires only for tool-level failures (`invalid_input` for neither/both supplied or invalid page_id; `forbidden` for missing edit_post; `not_found` for unknown page_id; `divi_error` for an exception in the walker).

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "content": {
      "description": "Divi block markup to validate. Provide exactly one of {content, page_id}.",
      "type": "string"
    },
    "page_id": {
      "description": "WordPress post/page ID to read post_content from the DB. Requires edit_post capability on the page. Provide exactly one of {content, page_id}.",
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    }
  },
  "additionalProperties": false
}

SEO metadata

diviops_seo_metadata_getRead explicit and effective semantic SEO metadata for one provider-supported post.Free

Read explicit and effective semantic SEO metadata for one provider-supported post. Free/core and explicit-metadata-only: fields depend on provider: TSF seo_title/meta_description plus a separate indexing section on 5.1.4 pages, or Rank Math seo_title/meta_description/canonical_url/noindex; no raw metadata keys or provider maps are accepted or returned. Requires edit_post before stored payload exposure. Returns exact explicit presence/value, effective provider output, deterministic checksum, provider lifecycle/capability evidence, canonical WordPress identity evidence, and cache status. Error codes include not_found, forbidden, seo.provider_absent, seo.provider_incompatible, seo.provider_unsupported, and seo.post_type_unsupported. With operation_key, returns only the historical recorded outcome for a keyed TSF/Rank Math text operation. uncertain or lock_held means stop and inspect; lookup never retries or unlocks. not_recorded is not proof of a completed noop. Returns the standardized envelope.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "operation_key": {
      "description": "Look up a text-operation key instead of current metadata; requires the same provider and target.",
      "type": "string",
      "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_-]{15,63}$"
    },
    "post_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "WordPress post/page ID to inspect. Requires edit_post on this exact target."
    },
    "provider": {
      "default": "auto",
      "description": "Provider selector. auto refuses ambiguity when both providers are active.",
      "type": "string",
      "enum": [
        "auto",
        "tsf",
        "rank_math"
      ]
    }
  },
  "required": [
    "post_id",
    "provider"
  ],
  "additionalProperties": false
}
diviops_seo_metadata_updateUpdate explicit TSF SEO metadata on one provider-supported post through the Free/core semantic contract.Free

Update one page/post using fixed provider fields and expected_checksum. TSF retains seo_title/meta_description set/clear and its original top-level checksum. TSF 5.1.4 pages additionally support canonical_url set/clear and noindex set with value=noindex or reset_default without a value; use indexing.checksum from get for these operations and tsf_ indexing restore. TSF text restore uses tsft_ snapshots and the original top-level checksum. Do not mix text and indexing changes. TSF keeps unrelated robots defaults inherited and custom canonical URLs remain under noindex. Rank Math 1.0.279 additionally supports plain-text seo_title/meta_description set/clear with its top-level checksum and typed restore; unresolved template variables and markup are refused. It supports canonical_url set/clear and noindex set with value='noindex' on pages; it preserves other robots directives and previews inherited defaults that become pinned. No generic robots arrays, force-index or noindex clear. reset_default is TSF-only. TSF text and both canonical/noindex adapters create a persistent typed recovery record before apply and return snapshot_id. To restore, omit changes and pass restore_snapshot_id with a fresh expected_checksum; restore refuses third-party changes and preserves untouched fields. Use dry_run to preview. Reads return provider-computed values, not verified frontend tags; Rank Math suppresses canonical output under noindex. Other providers, social/schema/bulk edits are unsupported. Optional operation_key correlates text-only updates/restores within one site/provider. Reuse it only with identical target, provider version, expected_checksum and input: an existing record returns a historical outcome without replaying, even if current metadata has changed. Preview/noop does not reserve a key. Indexing operations cannot use it. After a lost response, look up the key through get; uncertain/locked records stop. Runtime qualification remains separate. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "operation_key": {
      "description": "Stable caller key for one text operation (16–64 ASCII letters, digits, underscore or hyphen). Save it before calling; never change the input when reusing it.",
      "type": "string",
      "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_-]{15,63}$"
    },
    "post_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "WordPress post/page ID to update. Requires edit_post on this exact target."
    },
    "provider": {
      "default": "auto",
      "description": "Provider selector. Use auto, tsf, or rank_math.",
      "type": "string",
      "enum": [
        "auto",
        "tsf",
        "rank_math"
      ]
    },
    "expected_text_context": {
      "description": "Optional stronger context guard from text_evidence.context_checksum for reviewed text operations.",
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "expected_checksum": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$",
      "description": "Checksum from get: indexing.checksum for TSF canonical/noindex or tsf_ indexing restore; top-level checksum otherwise. No force path."
    },
    "changes": {
      "description": "Provide changes OR restore_snapshot_id. Rank Math noindex set value must be noindex.",
      "minItems": 1,
      "maxItems": 2,
      "type": "array",
      "items": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "seo_title",
                  "meta_description",
                  "canonical_url",
                  "noindex"
                ]
              },
              "action": {
                "type": "string",
                "const": "set"
              },
              "value": {
                "type": "string"
              }
            },
            "required": [
              "field",
              "action",
              "value"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "seo_title",
                  "meta_description",
                  "canonical_url",
                  "noindex"
                ]
              },
              "action": {
                "type": "string",
                "const": "clear"
              }
            },
            "required": [
              "field",
              "action"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "const": "noindex"
              },
              "action": {
                "type": "string",
                "const": "reset_default"
              }
            },
            "required": [
              "field",
              "action"
            ],
            "additionalProperties": false
          }
        ]
      }
    },
    "restore_snapshot_id": {
      "description": "Restore one recorded text or indexing operation for the selected provider; omit changes. Not a content snapshot.",
      "type": "string",
      "pattern": "^(?:rm|tsf|tsft)_[a-f0-9-]{36}$"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "post_id",
    "provider",
    "expected_checksum",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_seo_provider_listList the Free/core semantic SEO provider adapters and their installed, active, version, compatibility, field, and capability evidence.Free

List the Free/core semantic SEO provider adapters and their installed, active, version, compatibility, field, and capability evidence. Reports TSF text fields plus exact-version TSF and Rank Math canonical/noindex capabilities; never loads an inactive provider. Rank Math is source-assessed and requires native qualification. This is discovery only: it returns no post payload and provides no provider installation or activation path. Returns the standardized envelope.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_seo_rollout_advanceAfter operator confirmation of the exact plan/hash, advance at most one page.Pro

After operator confirmation of the exact plan/hash, advance at most one page. Each explicit call can advance another page; never automatically retry a lost response. Read status first. Stops on drift, permission loss or uncertain evidence. Acknowledgement binds the reviewed request but is not proof of human identity. No background work or atomic batch guarantee.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "plan_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
    },
    "plan_hash": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "acknowledgement": {
      "type": "string",
      "const": "apply_reviewed_non_atomic_text_plan"
    }
  },
  "required": [
    "plan_id",
    "plan_hash",
    "acknowledgement"
  ],
  "additionalProperties": false
}
diviops_seo_rollout_getRead the retained rollout plan, per-page outcome, operation references and handover report.Pro

Read the retained rollout plan, per-page outcome, operation references and handover report. Permission loss redacts stored content. Prepared/uncertain evidence or retained leases require stop and inspection, not blind retries. Metadata verification never claims rendered output or rankings.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "plan_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
    }
  },
  "required": [
    "plan_id"
  ],
  "additionalProperties": false
}
diviops_seo_rollout_planCreate a private immutable reviewed title/description plan for 1–20 explicit published public pages on one site/provider (TSF 5.1.4 or Rank Math 1.0.279).Pro

Create a private immutable reviewed title/description plan for 1–20 explicit published public pages on one site/provider (TSF 5.1.4 or Rank Math 1.0.279). Validates all pages without SEO writes. Show the complete before/target brief and non-atomic limits to the operator; obtain confirmation before advancing. Expires for first execution after 30 minutes. No Yoast, discovery, copy generation, robots, social or schema.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "provider": {
      "type": "string",
      "enum": [
        "tsf",
        "rank_math"
      ]
    },
    "brief": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 80
        },
        "version": {
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        }
      },
      "required": [
        "name",
        "version"
      ],
      "additionalProperties": false
    },
    "pages": {
      "minItems": 1,
      "maxItems": 20,
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "changes": {
            "minItems": 1,
            "maxItems": 2,
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "type": "object",
                  "properties": {
                    "field": {
                      "type": "string",
                      "enum": [
                        "seo_title",
                        "meta_description"
                      ]
                    },
                    "action": {
                      "type": "string",
                      "const": "set"
                    },
                    "value": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 8192
                    }
                  },
                  "required": [
                    "field",
                    "action",
                    "value"
                  ],
                  "additionalProperties": false
                },
                {
                  "type": "object",
                  "properties": {
                    "field": {
                      "type": "string",
                      "enum": [
                        "seo_title",
                        "meta_description"
                      ]
                    },
                    "action": {
                      "type": "string",
                      "const": "clear"
                    }
                  },
                  "required": [
                    "field",
                    "action"
                  ],
                  "additionalProperties": false
                }
              ]
            }
          }
        },
        "required": [
          "id",
          "changes"
        ],
        "additionalProperties": false
      }
    }
  },
  "required": [
    "provider",
    "brief",
    "pages"
  ],
  "additionalProperties": false
}
diviops_seo_rollout_recoverAfter confirmation of the separate recovery plan/hash, restore at most one page through Free conditional recovery.Pro

After confirmation of the separate recovery plan/hash, restore at most one page through Free conditional recovery. Stops at the first conflict or uncertainty and retains inverse evidence. Read status after response loss; no automatic retry, force restore or lease takeover.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "plan_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
    },
    "plan_hash": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "acknowledgement": {
      "type": "string",
      "const": "apply_reviewed_non_atomic_text_plan"
    }
  },
  "required": [
    "plan_id",
    "plan_hash",
    "acknowledgement"
  ],
  "additionalProperties": false
}
diviops_seo_rollout_recovery_planCreate a separate immutable recovery plan from verified applied references in reverse order, using Free conditional restores.Pro

Create a separate immutable recovery plan from verified applied references in reverse order, using Free conditional restores. Freezes further original advances. Show the recovery before/target and obtain operator confirmation. Later untouched fields are preserved; conflicts refuse. Basic individual recovery remains Free.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "plan_id": {
      "type": "string",
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
    },
    "plan_hash": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    }
  },
  "required": [
    "plan_id",
    "plan_hash"
  ],
  "additionalProperties": false
}

Structured fields

diviops_scf_exportExport structured field definitions as JSON.Free

Export SCF field groups, post types, taxonomies, and options pages as JSON — to a directory under the safe-root (`<WP_PATH>/.diviops-tmp/` by default, override via DIVIOPS_WP_CLI_SAFE_FS_ROOT) or to stdout. Wraps `wp scf json export`. Either `dir` or `stdout: true` is required. Filters can be combined; without filters, all items are exported. Note: SCF writes a fixed filename `acf-export-YYYY-MM-DD.json` inside `dir` — two exports on the same day silently overwrite. Copy/rename if you're archiving baselines. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { stdout: string, stderr: string }. Pre-wp-cli input rejections (neither/both of `dir`/`stdout`) return code 'invalid_input' with `error.data` documenting the failed fields. wp-cli failures map to 'scf.command_failed' (same shape as scf_status). Missing wp-cli configuration surfaces as 'scf.not_configured'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "dir": {
      "description": "Absolute output directory under the WP-CLI safe-root. Mutually exclusive with `stdout`. SCF writes a single `acf-export-YYYY-MM-DD.json` file inside this dir.",
      "type": "string"
    },
    "stdout": {
      "description": "Print JSON to stdout instead of writing a file. Mutually exclusive with `dir`.",
      "type": "boolean"
    },
    "field_groups": {
      "description": "Comma-separated field-group ACF keys (`group_abc123`) or admin titles (`My Field Group`). NOT WP post slugs — SCF matches against the def's `key` field or its `title` (case-insensitive). Use `diviops_scf_field_group_list` to discover keys (post_name column).",
      "type": "string"
    },
    "post_types": {
      "description": "Comma-separated SCF post-type def keys (`post_type_xxx`) or admin titles (`Programm`). IMPORTANT: this is the SCF def's identifier, NOT the registered post-type slug (`event`, `book`). The registered slug is what `wp post list` and REST URLs use, but SCF's filter matches against the def's `key` field or its `title`. To discover def keys, run `diviops_scf_export --stdout` (no filter) and inspect the top-level entries with `parent='post-type'`.",
      "type": "string"
    },
    "taxonomies": {
      "description": "Comma-separated SCF taxonomy def keys (`taxonomy_xxx`) or admin titles. Same caveat as `post_types`: NOT the registered taxonomy slug — the SCF def's `key` or `title`. Discover via `diviops_scf_export --stdout`.",
      "type": "string"
    },
    "options_pages": {
      "description": "Comma-separated options-page def keys or admin titles. Requires ACF PRO.",
      "type": "string"
    }
  },
  "additionalProperties": false
}
diviops_scf_field_group_getRead one SCF or ACF field group by its key or ID.Free

Fetch a single SCF/ACF field group from the `acf-field-group` post type — by ACF key (`group_abc123`, looked up via `post_name`) or by numeric WP post ID. Returns the WP post fields (post_name, post_title, post_content with serialized fields blob, post_status, post_modified). For the parsed/structured field tree including nested fields, use `diviops_scf_export --field-groups=<key> --stdout` instead. Read-only. SCF 6.8.4 dropped the legacy `wp acf field-group get` command, so this wrapper queries the post type directly via `wp post`. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is the parsed `wp post get --format=json` object. Unresolvable key (no row in the `acf-field-group` post type and not a numeric ID that wp-cli accepts) returns code 'not_found' with hint pointing to diviops_scf_field_group_list. wp-cli failures map to 'scf.command_failed'; missing wp-cli configuration surfaces as 'scf.not_configured'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "key": {
      "type": "string",
      "description": "ACF field-group key (`group_abc123`, matched against post_name) or numeric WP post ID."
    }
  },
  "required": [
    "key"
  ],
  "additionalProperties": false
}
diviops_scf_field_group_listList all SCF/ACF field groups in the database (post_name = ACF key, post_title, post_status, post_modified).Free

List all SCF/ACF field groups in the database (post_name = ACF key, post_title, post_status, post_modified). Read-only. Queries the underlying `acf-field-group` post type via `wp post list` — works on both SCF 6.8.4+ (which dropped the legacy `wp acf field-group …` family in favor of the `wp scf json` namespace) and older ACF installs. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is `Array<{ ID, post_name, post_title, post_status, post_modified }>` parsed from wp-cli's JSON output (or an empty array on no results). wp-cli failures map to 'scf.command_failed'; missing wp-cli configuration surfaces as 'scf.not_configured'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_scf_importImport SCF field groups, post types, taxonomies, options pages from a JSON file.Free

Import SCF field groups, post types, taxonomies, options pages from a JSON file. Mutates the database. File path must resolve under the safe-root (`<WP_PATH>/.diviops-tmp/` by default, override via DIVIOPS_WP_CLI_SAFE_FS_ROOT). Idempotent — existing items with matching keys are updated. Wraps `wp scf json import <file>`. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { stdout: string, stderr: string }. wp-cli failures (missing/unreadable file, malformed JSON, allowlist or FS-validator rejection) map to 'scf.command_failed' with `error.data = { exit_code, stdout, stderr, failure_kind, command }`. Missing wp-cli configuration surfaces as 'scf.not_configured'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "file": {
      "type": "string",
      "description": "Absolute path to the .json file to import. Must resolve under DIVIOPS_WP_CLI_SAFE_FS_ROOT."
    }
  },
  "required": [
    "file"
  ],
  "additionalProperties": false
}
diviops_scf_statusCompare saved field definitions with their JSON files.Free

Show SCF (Secure Custom Fields) sync status — how many field groups, post types, taxonomies, and options pages have JSON-on-disk newer than the database (or absent from DB). Read-only. Wraps `wp scf json status`. Requires SCF 6.8.4+ and WP_PATH or WP_CLI_CMD. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { stdout: string, stderr: string }. wp-cli failures map to 'scf.command_failed' with `error.data = { exit_code, stdout, stderr, failure_kind, command }` (four failure_kind branches: 'exited'/'killed'/'spawn_failed'/'rejected' — see tools.md). Missing wp-cli configuration surfaces as 'scf.not_configured'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "type": {
      "description": "Limit to a single item type. Defaults to all types. options-page requires ACF PRO.",
      "type": "string",
      "enum": [
        "field-group",
        "post-type",
        "taxonomy",
        "options-page"
      ]
    },
    "detailed": {
      "description": "List the individual pending items (key/title/type/action) instead of just counts.",
      "type": "boolean"
    }
  },
  "additionalProperties": false
}
diviops_scf_syncApply pending JSON-on-disk SCF changes to the database.Free

Apply pending JSON-on-disk SCF changes to the database. Reads JSON files from the theme/plugin acf-json directory and creates/updates DB entries. Defaults to `dry_run: true` for safety — caller must opt in to mutation. Wraps `wp scf json sync`. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { dry_run: boolean, stdout: string, stderr: string }. NOTE: `dry_run` is passed through as wp-cli's `--dry-run` flag — the upstream output shape is wp-cli's plain-text summary, NOT the standard `data.plan = { summary, changes[] }` shape used by plugin-routed `dry_run` tools. The `dry_run` boolean is reflected in the success payload so callers can branch without re-checking input args, but the SCF-on-disk preview is what wp-cli produced. wp-cli failures map to 'scf.command_failed'; missing wp-cli configuration surfaces as 'scf.not_configured'.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "type": {
      "description": "Limit sync to a single item type.",
      "type": "string",
      "enum": [
        "field-group",
        "post-type",
        "taxonomy",
        "options-page"
      ]
    },
    "key": {
      "description": "Sync only the item with this ACF key (e.g. `group_abc123`).",
      "type": "string"
    },
    "dry_run": {
      "default": true,
      "description": "Preview pending changes without mutating the database. Defaults to true. Pass `false` to commit.",
      "type": "boolean"
    }
  },
  "required": [
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_scf_text_value_updateUpdate one existing applicable top-level SCF text value on an editable post.Free

Update one existing applicable top-level SCF text value on an editable post. Free authoring; requires the scf_text_value_update plugin capability and active SCF 6.9.4, not WP-CLI or Pro. Exact expected_value precheck is not atomic CAS. Defaults to dry-run; preview before explicit apply. Single-line plain UTF-8 strings, at most 4096 bytes; empty, whitespace-only, literal 0, markup and control characters excluded in this initial contract. Calls field validation, not full native form-save validation. Provider hooks may transform values or have side effects. One update call with persisted value/reference readback; no snapshot backup, automatic rollback or retry. No definition, Divi binding/design or template writes. Error diagnostics omit values. Returns the standard envelope; stale state is scf.conflict, unchanged persisted state after an attempted change is scf.write_failed, unverified/changed readback is scf.mutation_uncertain.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "post_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "field_key": {
      "type": "string",
      "pattern": "^field_[A-Za-z0-9_]+$"
    },
    "expected_value": {
      "type": "string",
      "minLength": 1,
      "maxLength": 4096,
      "pattern": "^[^<>\\x00-\\x1f\\x7f]+$"
    },
    "value": {
      "type": "string",
      "minLength": 1,
      "maxLength": 4096,
      "pattern": "^[^<>\\x00-\\x1f\\x7f]+$"
    },
    "dry_run": {
      "default": true,
      "type": "boolean"
    }
  },
  "required": [
    "post_id",
    "field_key",
    "expected_value",
    "value",
    "dry_run"
  ],
  "additionalProperties": false
}

Commerce workflows

diviops_fc_campaign_page_applyCreate one new draft campaign page or insert/replace one exact-owned campaign-page segment on an existing Divi page.Pro

Create one new draft campaign page or insert/replace one exact-owned campaign-page segment on an existing Divi page. All PAGE profiles compose an H1 hero, product section, and H2 closing section; SECTION is unchanged. Choose preset_campaign_page_flexible_v1 for native Divi Image/Text plus one native Buy Now in the product section, no ProductCard: 16 modules, exactly seven distinct installed preset roles (section, row, column, heading, body, image, buy_now). It requires image_attachment_id: an existing readable WordPress raster-image attachment. The sanitized product title and attachment identity/URL/alt/dimensions are authoring snapshots bound to confirmation; empty alt falls back to the product title. No image import/fetch, stored price/stock, or automatic catalog/image syncing. Native Buy Now retains live FluentCart behavior. Choose preset_campaign_page_native_card_v1 for a short page with one native card CTA: 14 modules, exactly six installed preset roles (section, row, column, heading, body, product_card), and closing copy referring to the card above. The existing preset_campaign_page_v1 intentionally repeats the CTA with native Buy Now below the closing copy: 15 modules and seven roles including buy_now and product_card. image_attachment_id and the image role are forbidden for both card profiles. It accepts one published storefront-ready FluentCart product. Dry-run audits presets and returns exact preset checksums, page markup, validation/render evidence, rollback plan, and a profile-bound plan checksum. Apply requires those exact preset checksums plus confirm_plan_sha256. Existing-page writes also require page_update_content_expected_checksum, an exact page checksum, mandatory backup, and either start/end insertion or a same-profile prior receipt. Cross-profile receipts are refused, not migrated. New pages are always drafts with an explicit title and sanitized slug; their rollback is exact page trash. The workflow never creates or repairs presets, accepts arbitrary copy/design input, publishes a page, or mutates FluentCart commerce state. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Published FluentCart product ID whose storefront_links.ready is true."
    },
    "profile": {
      "type": "string",
      "enum": [
        "preset_campaign_page_v1",
        "preset_campaign_page_native_card_v1",
        "preset_campaign_page_flexible_v1"
      ]
    },
    "image_attachment_id": {
      "description": "Required only for preset_campaign_page_flexible_v1; forbidden for other profiles. Existing readable WordPress raster-image attachment; no URL/import/fetch.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "destination": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "mode": {
              "type": "string",
              "const": "new_draft"
            },
            "title": {
              "type": "string",
              "minLength": 1,
              "maxLength": 200
            },
            "slug": {
              "type": "string",
              "maxLength": 200,
              "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
            }
          },
          "required": [
            "mode",
            "title",
            "slug"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "mode": {
              "type": "string",
              "const": "existing_page"
            },
            "page_id": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "expected_page_checksum": {
              "type": "string",
              "pattern": "^sha256:[a-f0-9]{64}$"
            },
            "position": {
              "type": "string",
              "enum": [
                "start",
                "end"
              ]
            },
            "receipt": {
              "type": "object",
              "properties": {
                "schema": {
                  "type": "string",
                  "const": "diviops.fluentcart_campaign_page.receipt.v1"
                },
                "page_id": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "product_id": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "profile": {
                  "type": "string",
                  "enum": [
                    "preset_campaign_page_v1",
                    "preset_campaign_page_native_card_v1",
                    "preset_campaign_page_flexible_v1"
                  ]
                },
                "section_labels": {
                  "type": "object",
                  "properties": {
                    "hero": {
                      "type": "string"
                    },
                    "product": {
                      "type": "string"
                    },
                    "closing": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "hero",
                    "product",
                    "closing"
                  ],
                  "additionalProperties": false
                },
                "segment_sha256": {
                  "type": "string",
                  "pattern": "^sha256:[a-f0-9]{64}$"
                },
                "page_sha256": {
                  "type": "string",
                  "pattern": "^sha256:[a-f0-9]{64}$"
                },
                "preset_bindings_sha256": {
                  "type": "string",
                  "pattern": "^sha256:[a-f0-9]{64}$"
                },
                "addon_version": {
                  "type": "string",
                  "const": "1.0.0"
                },
                "addon_schema_sha256": {
                  "type": "string",
                  "pattern": "^sha256:[a-f0-9]{64}$"
                },
                "builder_version": {
                  "type": "string",
                  "minLength": 1
                }
              },
              "required": [
                "schema",
                "page_id",
                "product_id",
                "profile",
                "section_labels",
                "segment_sha256",
                "page_sha256",
                "preset_bindings_sha256",
                "addon_version",
                "addon_schema_sha256",
                "builder_version"
              ],
              "additionalProperties": false
            }
          },
          "required": [
            "mode",
            "page_id",
            "expected_page_checksum"
          ],
          "additionalProperties": false
        }
      ]
    },
    "preset_roles": {
      "type": "object",
      "properties": {
        "section": {
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        },
        "row": {
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        },
        "column": {
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        },
        "heading": {
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        },
        "body": {
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        },
        "product_card": {
          "description": "Required for both card profiles; forbidden for preset_campaign_page_flexible_v1.",
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        },
        "buy_now": {
          "description": "Required for legacy and flexible profiles; forbidden for preset_campaign_page_native_card_v1.",
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        },
        "image": {
          "description": "Required only for preset_campaign_page_flexible_v1; forbidden for other profiles.",
          "type": "string",
          "minLength": 1,
          "maxLength": 128
        }
      },
      "required": [
        "section",
        "row",
        "column",
        "heading",
        "body"
      ],
      "additionalProperties": false
    },
    "expected_preset_checksums": {
      "description": "Exact role checksums returned by dry-run. Required for apply.",
      "type": "object",
      "properties": {
        "section": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "row": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "column": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "heading": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "body": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "product_card": {
          "description": "Required for both card profiles; forbidden for preset_campaign_page_flexible_v1.",
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "buy_now": {
          "description": "Required for legacy and flexible profiles; forbidden for preset_campaign_page_native_card_v1.",
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "image": {
          "description": "Required only for preset_campaign_page_flexible_v1; forbidden for other profiles.",
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        }
      },
      "required": [
        "section",
        "row",
        "column",
        "heading",
        "body"
      ],
      "additionalProperties": false
    },
    "confirm_plan_sha256": {
      "description": "Exact confirmation.plan_sha256 returned by dry-run. Required for apply.",
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "product_id",
    "profile",
    "destination",
    "preset_roles",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_campaign_page_refreshRefresh only the reviewed product title and/or explicitly selected image in one polished flexible campaign on a draft page.Pro

Refresh only the reviewed product title and/or explicitly selected image in one polished flexible campaign on a draft page. Preserves its 16-block segment, seven existing module-preset bindings, all local design/copy and single native BuyNow. Requires exact current page checksum and explicit section/H1/Image auto-indices, not a generator receipt. Defaults to dry-run; apply requires its exact confirmation.plan_sha256 and rechecks consumed product/image state. No-op creates no backup or write. Changed content delegates once to the Free checksum/backup writer; its existing failure compensation may restore content. Returns maintenance evidence, never a PAGE/SECTION receipt. No automatic catalog sync, preset repair, publication or commerce mutation.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Explicit editable draft page, never a receipt-derived target."
    },
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Ready product matching the existing native BuyNow variation."
    },
    "expected_page_checksum": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "refresh": {
      "type": "string",
      "enum": [
        "title",
        "image",
        "title_and_image"
      ]
    },
    "targets": {
      "type": "object",
      "properties": {
        "section_auto_index": {
          "type": "string",
          "pattern": "^section:[1-9][0-9]*$"
        },
        "heading_auto_index": {
          "type": "string",
          "pattern": "^heading:[1-9][0-9]*$"
        },
        "image_auto_index": {
          "type": "string",
          "pattern": "^image:[1-9][0-9]*$"
        }
      },
      "required": [
        "section_auto_index",
        "heading_auto_index",
        "image_auto_index"
      ],
      "additionalProperties": false,
      "description": "Current-layout indices for the first campaign section, hero H1 and product Image; no label/text guessing."
    },
    "image_attachment_id": {
      "description": "Required for image/title_and_image; forbidden for title. Existing readable raster attachment only.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "confirm_plan_sha256": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$"
    },
    "dry_run": {
      "default": true,
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "product_id",
    "expected_page_checksum",
    "refresh",
    "targets",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_campaign_section_applyCreate or replace one receipt-owned FluentCart campaign section on an existing Divi page.Pro

Create or replace one receipt-owned FluentCart campaign section on an existing Divi page. The fixed product_card_buy_now_v1 profile uses only the official fluent-cart-divi/product-card and fluent-cart-divi/buy-now modules. Requires a published storefront-ready product, active supported FluentCart Divi Modules 1.0.0 schemas, an exact page checksum, and exactly one of position=start|end or the prior receipt. Dry-run returns exact generated block markup, validation/render evidence, the rollback plan, and a planned receipt. Apply always creates a rollback backup, refuses page drift, validates and renders before writing, verifies exact readback, and returns the receipt required for any replacement. It never mutates products, prices, variants, orders, customers, cart, taxes, or checkout behavior. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Existing WordPress page ID."
    },
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Published FluentCart product ID whose storefront_links.ready is true."
    },
    "profile": {
      "type": "string",
      "const": "product_card_buy_now_v1",
      "description": "The only supported fixed presentation profile."
    },
    "expected_page_checksum": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$",
      "description": "Exact diviops_page_get.content_checksum reviewed for this write."
    },
    "position": {
      "description": "Create at the start or end of the page. Mutually exclusive with receipt.",
      "type": "string",
      "enum": [
        "start",
        "end"
      ]
    },
    "receipt": {
      "description": "Prior exact-owned receipt for replacement. Mutually exclusive with position.",
      "type": "object",
      "properties": {
        "schema": {
          "type": "string",
          "const": "diviops.fluentcart_campaign_section.receipt.v1"
        },
        "page_id": {
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        },
        "product_id": {
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        },
        "profile": {
          "type": "string",
          "const": "product_card_buy_now_v1"
        },
        "section_label": {
          "type": "string",
          "minLength": 1
        },
        "section_sha256": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "page_sha256": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "addon_version": {
          "type": "string",
          "const": "1.0.0"
        },
        "addon_schema_sha256": {
          "type": "string",
          "pattern": "^sha256:[a-f0-9]{64}$"
        },
        "builder_version": {
          "type": "string",
          "minLength": 1
        }
      },
      "required": [
        "schema",
        "page_id",
        "product_id",
        "profile",
        "section_label",
        "section_sha256",
        "page_sha256",
        "addon_version",
        "addon_schema_sha256",
        "builder_version"
      ],
      "additionalProperties": false
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "page_id",
    "product_id",
    "profile",
    "expected_page_checksum",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_download_attachAttach an already-present server-side ZIP as a FluentCart downloadable-file row (Pro tier; V3.4; requires FluentCart Pro installed + activated).Pro

Attach an already-present server-side ZIP as a FluentCart downloadable-file row (Pro tier; V3.4; requires FluentCart Pro installed + activated). This is NOT a binary upload tool: `file_path` must resolve to a readable .zip on the WordPress server under ABSPATH or the uploads directory. Apply mode copies the validated file into FluentCart's managed `wp-content/uploads/fluent-cart/*__fluent-cart__*.zip` storage before creating the row, because FluentCart's signed package endpoint serves that managed filename shape. The response never exposes file paths, file URLs, download identifiers, signed URLs, or buyer URLs. Required: product_id, file_path. Optional: file_name (defaults to basename(file_path), must end in .zip), title (defaults to filename without .zip), variation_ids (must belong to this product; empty means all variants), expected_sha1, expected_size, allow_duplicate (default false), dry_run. Duplicate detection rejects an existing row with the same file_name or title unless allow_duplicate:true is passed. Expected hash/size let operators verify the server-side file matches the locally built artifact before creating the row. Apply-mode success payload is { product_id, created: DownloadRow, downloads: DownloadRow[] } with DownloadRow metadata only. This tool only creates the download row and enables manage_downloadable; it does NOT set license_settings.global_update_file — follow with diviops_fc_license_settings_update using the created row ID. Error codes: invalid_input (400), not_found (404), fluentcart.download_duplicate (409), fluentcart.module_inactive (412), fluentcart.command_failed (500). Idempotency: false; repeat calls are rejected by duplicate detection unless allow_duplicate:true. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    },
    "file_path": {
      "type": "string",
      "minLength": 1,
      "description": "Server-side .zip path under ABSPATH or wp_upload_dir().basedir. Relative paths resolve under ABSPATH. No local-client upload occurs."
    },
    "file_name": {
      "description": "Download filename shown to buyers/admins. Defaults to basename(file_path). Must end in .zip.",
      "type": "string",
      "minLength": 1
    },
    "title": {
      "description": "FluentCart download title. Defaults to file_name without the .zip suffix.",
      "type": "string",
      "minLength": 1
    },
    "variation_ids": {
      "description": "Optional product variation IDs this download applies to. Omit or pass [] for all variants.",
      "type": "array",
      "items": {
        "type": "integer",
        "exclusiveMinimum": 0,
        "maximum": 9007199254740991
      }
    },
    "expected_sha1": {
      "description": "Optional SHA1 of the expected server-side file. Mismatch aborts before mutation.",
      "type": "string",
      "pattern": "^[a-fA-F0-9]{40}$"
    },
    "expected_size": {
      "description": "Optional byte size of the expected server-side file. Mismatch aborts before mutation.",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "allow_duplicate": {
      "description": "Default false. When false, an existing row with the same file_name or title returns fluentcart.download_duplicate.",
      "type": "boolean"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "product_id",
    "file_path",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_download_listList FluentCart downloadable-file rows for a product (Pro tier; V3.4; requires FluentCart Pro installed + activated).Pro

List FluentCart downloadable-file rows for a product (Pro tier; V3.4; requires FluentCart Pro installed + activated). Read-only metadata surface for store artifact deployment. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { product_id, downloads: DownloadRow[] }. DownloadRow is { id, title, file_name, driver, file_size, type, variation_ids, is_update_file } — metadata only, never file_path, file_url, download_identifier, signed URLs, or buyer URLs. `is_update_file` is derived from the product's license_settings.global_update_file pointer when present. Use this before `diviops_fc_license_settings_update` so the updater pointer can be set to the plugin ZIP row, not the suite ZIP row. Error codes: invalid_input (400), not_found (404), fluentcart.module_inactive (412), fluentcart.query_failed (500). Idempotency: read-only.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    }
  },
  "required": [
    "product_id"
  ],
  "additionalProperties": false
}
diviops_fc_gateway_getFetch a single FluentCart payment gateway by method slug with secrets redacted (Pro tier; V3.2).Pro

Fetch a single FluentCart payment gateway by method slug with secrets redacted (Pro tier; V3.2). Read-only. Same row shape as diviops_fc_gateway_list plus a `field_metadata` array describing what settings the gateway accepts (key + label + type + description from the gateway's `fields()` map) WITHOUT any stored values. `method` is one of the registered slugs from diviops_fc_gateway_list — common values: `offline_payment` (COD, local-safe, no webhook, no real money — the slug to use for local smoke runs), `stripe`, `paypal`, `paystack`, `airwallex`, `paddle` (Pro), `mollie` (Pro), `authorize_net` (Pro). NEVER returns credential values; field_metadata is metadata-only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload: { gateway: GatewayRow }. Error codes: invalid_input (HTTP 400) when method is empty; not_found (HTTP 404) when the slug is not registered (hint: "Call diviops_fc_gateway_list to see the registered method slugs."); fluentcart.module_inactive (412); fluentcart.command_failed (500). Useful for confirming the local-safe gateway is enabled before a smoke run, and for surfacing whether Paddle / Stripe / etc. is registered without exposing keys.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "method": {
      "type": "string",
      "minLength": 1,
      "description": "Gateway method slug — e.g. `offline_payment`, `stripe`, `paypal`, `paddle`, `mollie`. Run diviops_fc_gateway_list first to enumerate registered slugs."
    }
  },
  "required": [
    "method"
  ],
  "additionalProperties": false
}
diviops_fc_gateway_listList FluentCart registered payment gateways with secrets redacted (Pro tier; V3.2).Pro

List FluentCart registered payment gateways with secrets redacted (Pro tier; V3.2). Read-only. Returns one row per gateway registered with FluentCart's GatewayManager — each row carries `method`, `title`, `admin_title`, `label`, `route`, `enabled`, `upcoming`, `requires_pro`, `no_real_money` (true for offline/COD), `local_safe`, `webhook_required` (capability hint — reachability is NOT probed), `credentials_configured` (best-effort boolean inferred without reading credential values), `supports.subscriptions`, `supports.refund`, `settings_summary` (allowlisted non-secret fields only — `is_active`, `payment_mode`, `checkout_mode`, `checkout_label`, `checkout_logo`, `checkout_instructions`, `provider`, `define_*_keys` boolean flags, `*_is_encrypted` flags), `settings_source` (e.g. `fct_meta:fluent_cart_payment_settings_stripe`), `description`, `brand_color`, and a sanitized `meta` bag. NEVER returns: API keys, secret keys, publishable keys, webhook signing secrets, client IDs, customer IDs, vendor/seller IDs, tokens, or any value matching the credential-substring heuristic. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload: { gateways: GatewayRow[], count }. Error codes: fluentcart.module_inactive (412); fluentcart.command_failed (500). Use as the discovery call before diviops_fc_gateway_get to inspect a specific method.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_fc_license_activations_listList a FluentCart license's activation rows (Pro tier; V3.1; requires FluentCart Pro + Licensing module).Pro

List a FluentCart license's activation rows (Pro tier; V3.1; requires FluentCart Pro + Licensing module). Read-only. Returns one row per `fct_license_activations` entry for the license, including the joined `fct_license_sites.site_url` (the NORMALIZED form — scheme + trailing slash + `www.` prefix stripped per LicenseHelper::sanitizeSiteUrl — not the raw URL the consumer submitted). Filterable by status (active/inactive/deactivated). License keys are NEVER returned by this endpoint. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload: { license_id, activations: Activation[], count, filters: { status } }. Activation row: id, license_id, site_id, site_url, status, is_local, product_id, variation_id, activation_method, last_update_date, last_update_version, created_at, updated_at. Error codes: invalid_input (HTTP 400); not_found (HTTP 404) when the license doesn't exist; fluentcart.module_inactive (HTTP 412); fluentcart.licensing_unavailable (HTTP 412); fluentcart.query_failed (HTTP 500). Useful for smoke verification (count + site_url presence) and for the activation-cap test described in the diviops-fluentcart skill.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "license_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart license ID whose activation rows to list (fct_licenses.id)."
    },
    "status": {
      "description": "Activation row status filter (fct_license_activations.status).",
      "type": "string",
      "enum": [
        "active",
        "inactive",
        "deactivated"
      ]
    }
  },
  "required": [
    "license_id"
  ],
  "additionalProperties": false
}
diviops_fc_license_changelog_getRead the FluentCart Pro software-license changelog HTML for a product (Pro tier; V3.4; requires FluentCart Pro installed + activated).Pro

Read the FluentCart Pro software-license changelog HTML for a product (Pro tier; V3.4; requires FluentCart Pro installed + activated). This reads ProductMeta meta_key='_fluent_sl_changelog', the field FluentCart Pro shows in Product → License Settings → Changelog Description. Read-only. Returns the standardized envelope { ok, data?, error }; success payload is { product_id, changelog_html, is_empty, storage_meta_key }. Error codes: invalid_input (400), not_found (404), fluentcart.module_inactive (412), fluentcart.query_failed (500). Idempotency: read-only.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    }
  },
  "required": [
    "product_id"
  ],
  "additionalProperties": false
}
diviops_fc_license_changelog_updateWrite the FluentCart Pro software-license changelog HTML for a product (Pro tier; V3.4; requires FluentCart Pro installed + activated).Pro

Write the FluentCart Pro software-license changelog HTML for a product (Pro tier; V3.4; requires FluentCart Pro installed + activated). This writes ProductMeta meta_key='_fluent_sl_changelog', the field FluentCart Pro shows in Product → License Settings → Changelog Description. Input is sanitized by WordPress wp_kses_post on the plugin side. Supports dry_run and no-op detection. Success payload is { product_id, changed, changelog_html } or { noop:true, dry_run, product_id, changelog_html }. Error codes: invalid_input (400), not_found (404), fluentcart.module_inactive (412), fluentcart.command_failed (500). Idempotency: conditional — identical repeat is a no-op. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    },
    "changelog_html": {
      "type": "string",
      "description": "Buyer/update-facing changelog HTML. Sanitized with wp_kses_post before storage."
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "product_id",
    "changelog_html",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_license_getFetch a single FluentCart Pro license by ID (Pro tier; V3.1; requires FluentCart Pro + Licensing module).Pro

Fetch a single FluentCart Pro license by ID (Pro tier; V3.1; requires FluentCart Pro + Licensing module). Read-only by default. The default response redacts the license key to `redacted_key` only (first 4 + last 4 with ellipsis). To surface the full key, pass BOTH `include_license_key: true` AND `confirm_secret_handling: true` — the response then carries `license.license_key` plus `_meta.contains_secret: true` naming the secret field. **Full license keys must never be pasted into PRs, issues, Slack, or any external surface.** Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Success payload: { license: { id, status, product_id, variation_id, order_id, customer_id, subscription_id, limit, activation_count, expiration_date, created_at, updated_at, redacted_key, license_key? } }. limit semantics: 0 = unlimited per License::getActivationLimit; positive integers are the actual activation cap. Error codes: invalid_input (HTTP 400) when id is non-positive or include_license_key was passed without confirm_secret_handling; not_found (HTTP 404); fluentcart.module_inactive (HTTP 412); fluentcart.licensing_unavailable (HTTP 412); fluentcart.query_failed (HTTP 500).

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart license ID (fct_licenses.id)."
    },
    "include_license_key": {
      "description": "Opt-in: include the full unredacted license key in the response. Requires confirm_secret_handling: true. Default: redacted-only.",
      "type": "boolean"
    },
    "confirm_secret_handling": {
      "description": "Required alongside include_license_key: true. Acknowledges that full license keys must not be pasted into reports, PRs, issues, or external chat surfaces.",
      "type": "boolean"
    }
  },
  "required": [
    "id"
  ],
  "additionalProperties": false
}
diviops_fc_license_listList FluentCart Pro licenses (Pro tier; V3.1; requires FluentCart Pro + Licensing module).Pro

List FluentCart Pro licenses (Pro tier; V3.1; requires FluentCart Pro + Licensing module). Read-only. Filterable by product_id, variation_id, order_id, customer_id, status (active/inactive/disabled/expired/in_trial). License keys are NEVER returned in full — every row carries `redacted_key` only (first 4 + last 4 with ellipsis); use diviops_fc_license_get with explicit secret-handling opt-in if a full key is required for an authorized integration test. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; the success payload is { licenses: LicenseSummary[], pagination: { page, per_page, total, total_pages }, filters: { ... } }. LicenseSummary includes id, status, product_id, variation_id, order_id, customer_id, subscription_id, limit (0 = unlimited per License::getActivationLimit), activation_count, expiration_date, created_at, updated_at, redacted_key. Error codes: invalid_input (HTTP 400) when status is out of range; fluentcart.module_inactive (HTTP 412); fluentcart.licensing_unavailable (HTTP 412) when FluentCart Pro's Licensing module is absent; fluentcart.query_failed (HTTP 500).

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page": {
      "default": 1,
      "description": "Page number, 1-indexed. Default 1.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "per_page": {
      "default": 20,
      "description": "Page size. Default 20, clamped to a max of 100.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "product_id": {
      "description": "Filter to licenses for this FluentCart product ID.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "variation_id": {
      "description": "Filter to licenses for this FluentCart variation ID.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "order_id": {
      "description": "Filter to licenses issued by this order ID.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "customer_id": {
      "description": "Filter to licenses owned by this customer ID.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "status": {
      "description": "License status (fct_licenses.status). 'active' is the healthy default.",
      "type": "string",
      "enum": [
        "active",
        "inactive",
        "disabled",
        "expired",
        "in_trial"
      ]
    }
  },
  "required": [
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
diviops_fc_license_settings_getRead the per-product FluentCart Pro license-settings projection (Pro tier; V3/V3.3; requires FluentCart Pro installed + activated).Pro

Read the per-product FluentCart Pro license-settings projection (Pro tier; V3/V3.3; requires FluentCart Pro installed + activated). FluentCart Pro stores license settings in `ProductMeta` under meta_key='license_settings'; this tool reads that meta row and joins it against the product's variations so each variation surfaces with its current activation_limit + validity. Read-only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { product_id, enabled: boolean, version, prefix, variations: [ { variation_id, title, activation_limit, validity: { unit, value } | null } ], update_file: { configured_id: string|null, resolved: DownloadRow|null }, downloads: DownloadRow[], update_file_readiness: { applicable: boolean, ready: boolean|null, problems: [ { code, message } ] } }. DownloadRow is { id, title, file_name, driver, file_size, type } — metadata only, never file paths or signed URLs. `update_file.configured_id` is the raw `global_update_file` pointer (the download-row ID FluentCart Pro's licensed-update path resolves); `resolved` is the matching download row or null. `update_file_readiness` is the updater-pointer verdict: applicable only when licensing is enabled (ready: null otherwise); problem codes are downloads_missing (no download rows at all), update_file_pointer_missing (downloads exist but no pointer persisted — fails even for single-download products because FCP Pro's signed-package-URL path resolves the pointer with no fallback), update_file_pointer_unresolved (pointer matches no download row on the product). The verdict does NOT judge whether the resolved file is the intended updater package — check resolved.file_name/title yourself (e.g. a plugin update ZIP vs a bundle/suite ZIP). The update_file/downloads/update_file_readiness fields require plugin capability `fluentcart_license_update_file_get`; older plugin builds omit them. Storage semantics: `enabled` is stored as 'yes'/'no' in FCP and projected to boolean here. `activation_limit` is null/'' (unconfigured), 0 (unlimited per FluentCart Pro License::getActivationLimit), or a positive integer. `validity.unit` is one of lifetime/day/week/month/year. Variations the product has but license_settings doesn't mention surface with `activation_limit: null` and `validity: null`. Variations license_settings mentions that no longer exist on the product are filtered out — only the live variation set is returned. Error codes: invalid_input (400) when id is not a positive integer; not_found (404) when the product does not exist; fluentcart.module_inactive (412); fluentcart.query_failed (500). Idempotency: read-only.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    }
  },
  "required": [
    "product_id"
  ],
  "additionalProperties": false
}
diviops_fc_license_settings_updateWrite the per-product FluentCart Pro license-settings ProductMeta row (Pro tier; V3/V3.3; requires FluentCart Pro installed + activated).Pro

Write the per-product FluentCart Pro license-settings ProductMeta row (Pro tier; V3/V3.3; requires FluentCart Pro installed + activated). Authors `enabled`, `version`, `prefix`, per-variation `activation_limit` + `validity`, and (V3.3) the `global_update_file` updater pointer — the storage shape FluentCart Pro reads via LicenseGenerationHandler when an order is placed and via the licensed-update path when an installed plugin checks for updates. Still out of scope: `wp` readme/banner/icon config, download-asset CRUD/upload, and the license-activation API; the `wp` field is preserved when present but not authored. Refuses bundle products with `fluentcart.unsupported_product_shape` (HTTP 422). Inputs (all optional except product_id; partial updates supported): `enabled` (boolean — projected to FCP's 'yes'/'no' on write), `version` (required when enabling; max 50 chars), `prefix` (max 20 chars), `variations` (array of { variation_id (required), activation_limit (integer ≥ 0 or null; 0 = unlimited per FluentCart Pro License::getActivationLimit), validity (optional { unit: lifetime/day/week/month/year, value: positive integer } or null to auto-derive) }), `global_update_file` (positive integer download-row ID to point licensed updates at, or null to clear the pointer; the ID must match one of the product's download rows — read diviops_fc_license_settings_get's `downloads` array for valid IDs — and is rejected with invalid_input otherwise, never silently coerced; stored as a string to match FluentCart Pro's UI-authored shape; requires plugin capability `fluentcart_license_update_file_set`, otherwise this tool returns capability_missing without calling the plugin). Omitting `global_update_file` preserves the stored pointer — unlike FluentCart Pro's own UI save path, partial updates here never wipe it. When `validity` is omitted on a variation, the validity is derived from the variation's payment_type: subscription+yearly → { unit: 'year', value: 1 }; onetime → { unit: 'lifetime', value: 1 }. When `enabled: true` and the product carries variations, every variation must end up with a non-empty validity.unit. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; apply-mode success payload is { product_id, changed_fields[], license_settings: <same shape as diviops_fc_license_settings_get> } (or { noop: true, product_id, license_settings } on no-op). Error codes: invalid_input (400) when any field violates the constraints (unknown variation_id, negative activation_limit, missing version when enabling, missing validity.unit when enabling, bad enum value, global_update_file not matching a download row); not_found (404) when the product does not exist; fluentcart.unsupported_product_shape (422) on bundle products; fluentcart.module_inactive (412); fluentcart.command_failed (500); capability_missing when global_update_file is passed against a plugin build without the capability. Idempotency: conditional — identical repeat is a no-op. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    },
    "enabled": {
      "description": "Toggle FCP license-settings enablement. Stored as 'yes'/'no' in FCP. When true, version is required (use '1.0.0-beta' for the dogfood catalog).",
      "type": "boolean"
    },
    "version": {
      "description": "License-settings version string (max 50 chars). Required when enabling. Recommended: '1.0.0-beta' for a beta-cohort catalog.",
      "type": "string",
      "maxLength": 50
    },
    "prefix": {
      "description": "License-key prefix (max 20 chars). Recommended: 'DOP' for DiviOps products.",
      "type": "string",
      "maxLength": 20
    },
    "variations": {
      "description": "Per-variation license configuration. Each entry's variation_id must belong to the product. Omitted variations preserve their existing license_settings.",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "variation_id": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "Target variation ID; must belong to this product."
          },
          "activation_limit": {
            "description": "Activation limit. 0 = unlimited (per FluentCart Pro License::getActivationLimit). null clears the configured limit.",
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              {
                "type": "null"
              }
            ]
          },
          "validity": {
            "description": "Validity period. When omitted, derived from the variation's payment_type (subscription+yearly → year/1; onetime → lifetime/1). When null, force-rederived from current variation state.",
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "unit": {
                    "type": "string",
                    "enum": [
                      "lifetime",
                      "day",
                      "week",
                      "month",
                      "year"
                    ]
                  },
                  "value": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "unit",
                  "value"
                ],
                "additionalProperties": false
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "variation_id"
        ],
        "additionalProperties": false
      }
    },
    "global_update_file": {
      "description": "Download-row ID to point licensed updates at (must match one of the product's download rows — see diviops_fc_license_settings_get's downloads array), or null to clear the pointer. Omit to preserve the stored pointer.",
      "anyOf": [
        {
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        },
        {
          "type": "null"
        }
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "product_id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_order_getFetch a single FluentCart order with line items, transactions, and related license IDs (Pro tier; V3.1; requires FluentCart installed + activated).Pro

Fetch a single FluentCart order with line items, transactions, and related license IDs (Pro tier; V3.1; requires FluentCart installed + activated). Read-only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; the success payload is { order: OrderSummary, items: OrderItem[], transactions: Transaction[], license_ids: number[] }. OrderItem includes id, post_id (product CPT post_id), object_id (variation_id), title, quantity, unit_price, line_total, payment_type, fulfillment_type. Transaction includes id, status, payment_method, payment_mode, transaction_type, total, currency, created_at. license_ids carries the IDs of any fct_licenses rows tied to this order (use diviops_fc_license_get to fetch each row's redacted shape). Does NOT expose payment credentials, gateway secrets, or full license keys. Error codes: invalid_input (HTTP 400) when id is not a positive integer; not_found (HTTP 404) when no order matches; fluentcart.module_inactive (HTTP 412); fluentcart.query_failed (HTTP 500).

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart order ID (fct_orders.id; for the local smoke runbook this is the order receipt anchor)."
    }
  },
  "required": [
    "id"
  ],
  "additionalProperties": false
}
diviops_fc_order_listList FluentCart orders.Pro

List FluentCart orders for commerce dogfooding / smoke baselines (Pro tier; V3.1; requires FluentCart installed + activated). Returns a paginated summary with order identity (id, status, payment_status), gateway info (payment_method + payment_method_title, mode), totals (currency, total_amount, total_paid), fulfillment_type, type (payment/subscription), customer (customer_id + customer_email), item_count, license_count, and timestamps (created_at, updated_at, completed_at). Filterable by status, payment_status, payment_method, product_id, customer_email, and mode (test/live). Read-only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; the success payload is { orders: OrderSummary[], pagination: { page, per_page, total, total_pages }, filters: { ... } }. Error codes: invalid_input (HTTP 400) when status/payment_status/mode is out of range; fluentcart.module_inactive (HTTP 412); fluentcart.query_failed (HTTP 500). Use this alongside diviops_fc_order_get / diviops_fc_license_list to verify a smoke run without raw SQL probes.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page": {
      "default": 1,
      "description": "Page number, 1-indexed. Default 1.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "per_page": {
      "default": 20,
      "description": "Page size. Default 20, clamped to a max of 100.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "status": {
      "description": "Order status filter (fct_orders.status). Match exact values such as 'completed' or 'on-hold'.",
      "type": "string",
      "enum": [
        "on-hold",
        "pending",
        "processing",
        "completed",
        "canceled",
        "refunded",
        "failed",
        "draft"
      ]
    },
    "payment_status": {
      "description": "Payment status filter (fct_orders.payment_status).",
      "type": "string",
      "enum": [
        "pending",
        "paid",
        "partially_paid",
        "partially_refunded",
        "refunded",
        "failed"
      ]
    },
    "payment_method": {
      "description": "Exact-match payment_method (e.g. 'offline_payment', 'stripe'). Case-sensitive — FluentCart stores gateway slugs verbatim.",
      "type": "string"
    },
    "product_id": {
      "description": "FluentCart product ID (post_id of the fluent_products CPT entry). Filters to orders with at least one matching order item.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "customer_email": {
      "description": "Filter to orders whose customer record has this email (exact match).",
      "type": "string"
    },
    "mode": {
      "description": "Filter to test-mode or live-mode orders. Useful for smoke runs to isolate the test gateway corpus.",
      "type": "string",
      "enum": [
        "test",
        "live"
      ]
    }
  },
  "required": [
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
diviops_fc_order_mark_paidMark an eligible local or offline order as paid, subject to strict checks.Pro

Guarded local/offline mark-paid for a FluentCart order (Pro tier; V3.1; exact audited FluentCart 1.6.0 contract). DiviOps serializes apply on the FluentCart order row, creates or updates one canonical succeeded `transaction_type=charge` transaction, then delegates the atomic paid transition and every derived cart/event/subscription/license/fulfillment effect to `FluentCart\App\Helpers\StatusHelper::syncOrderStatuses`; it never dispatches vendor events or mutates subscriptions/licenses directly. Initial payment/subscription orders use FluentCart's `order_paid` and initial-activation family; renewal invoices use `renewal_paid` and store-managed subscription advancement without replaying new-order effects. Exact Free/installed-Pro version, transaction-lock, and StatusHelper shapes are checked before querying or mutation; older, newer, mixed, and unsupported shapes fail closed with component evidence. Refuses real gateways, canceled orders, missing subscription context, non-manual/system subscription collection, and conflicting legacy/duplicate transaction candidates. Already-paid and concurrent retries are no-ops after locked readback, while interrupted retries reuse the single matching succeeded charge before synchronization. **dry_run defaults to TRUE**; apply requires `dry_run:false` plus matching `confirm_order_id`, `confirm_payment_method`, and `confirm_due_amount`. Dry-run returns the transaction action plus canonical sync effect scope. Apply returns exact order/charge readback, initial-vs-renewal transition evidence, redacted license readback, and subscription before/after summaries. Exceptions after transaction mutation starts return `fluentcart.mutation_uncertain` with best-effort readback and explicitly require manual inspection instead of a blind retry. Error codes include invalid_input (400), not_found (404), fluentcart.unsupported_version (412), fluentcart.order_canceled / fluentcart.unsupported_payment_method / fluentcart.unsupported_order_shape / fluentcart.missing_subscription_context / fluentcart.unsupported_subscription_shape (422), fluentcart.transaction_conflict / fluentcart.concurrent_state_changed (409), fluentcart.readback_failed / fluentcart.mutation_uncertain (500), fluentcart.module_inactive (412), and fluentcart.command_failed (500). Idempotency is conditional and retry-safe only when the response says so. Pass dry_run: false plus the confirm_* fields to apply.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart order ID (fct_orders.id) to mark paid."
    },
    "dry_run": {
      "default": true,
      "description": "When true (default), return the change plan without mutating state. Apply requires explicit dry_run: false + the confirm_* fields.",
      "type": "boolean"
    },
    "confirm_order_id": {
      "description": "Apply-mode confirmation: must equal `id`. Prevents accidentally marking the wrong order paid.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "confirm_payment_method": {
      "description": "Apply-mode confirmation: must equal the order's current payment_method (e.g. 'offline_payment').",
      "type": "string"
    },
    "confirm_due_amount": {
      "description": "Apply-mode confirmation: must equal (total_amount - total_paid) in stored units (cents). Inspect via diviops_fc_order_get.",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "mark_paid_note": {
      "description": "Optional sanitize_text_field note to attach to the order's `note` column. Mirrors the admin mark-paid form field.",
      "type": "string"
    }
  },
  "required": [
    "id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_product_createCreate a simple FluentCart Pro product (Pro tier; requires FluentCart Pro installed + activated).Pro

Create a simple FluentCart Pro product (Pro tier; requires FluentCart Pro installed + activated). V2 scope: simple onetime products only — one exact default variant, `detail.variation_type="simple"`, `payment_type="onetime"`, `fulfillment_type="digital"|"physical"`. Creation writes FluentCart's current finite simple-product detail/variation other_info defaults and persists an exact nonzero pointer to the sole variant. Multi-variation, subscriptions, downloadables, gallery, taxonomies, activation_limit, and license-flow fields ship in later verticals and are refused here. Required: `title` (1-200 chars). Optional: `status` (`draft`|`publish`|`pending`|`private`; default `draft`), `content`, `excerpt`, `fulfillment_type` (default `digital`), `price` (≥0; default 0), `compare_price` (≥0; must be ≥ `price` when provided), `sku` (optional; must be unique across FluentCart variations and at most 30 characters because FluentCart stores `fct_product_variations.sku` as `VARCHAR(30)` — overlong values are rejected before mutation rather than silently truncated). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; apply-mode success payload is { product, detail, default_variation: { id, sku, item_price, compare_price } | null, storefront_links: { view_url, checkout_url, checkout_variation_id, ready, problems, draft_preview_available }, shape_readiness: { profile, ready, problems }, variation_ids, variations_count, product_id, detail_id, default_variation_id } (HTTP 201). The default_variation block mirrors the diviops_fc_product_get read-back shape so callers don't need a follow-up read to confirm sku / compare_price / item_price after a write; storefront_links and shape_readiness mirror its buyer-safety and value-free readiness projections. Unit asymmetry: write inputs (price, compare_price) are in currency units (e.g. 29.99); the default_variation block returns item_price + compare_price in stored cents (e.g. 2999), matching detail.min_price / max_price. default_variation.compare_price is null when no compare price is stored (FCP persists "no compare" as 0, normalized to null on read); default_variation.sku is null when the SKU column is SQL NULL or an empty string (the create path stores omitted SKU as NULL). Error codes: invalid_input (400) when any input violates the constraints above (including SKU > 30 chars — error.data carries { field: "sku", max_length: 30, actual_length }); fluentcart.sku_conflict (409) when the provided SKU is already in use; fluentcart.module_inactive (412); fluentcart.command_failed (500) when wp_insert_post/ProductDetail/ProductVariation creation raises. Idempotency: NOT idempotent — repeat calls create distinct products. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200,
      "description": "Product title (post_title). 1-200 chars. Used verbatim as the default variation's variation_title."
    },
    "slug": {
      "description": "Create-only requested product slug, normalized by WordPress; must normalize nonempty and not to \"0\". Requires Pro capability fluentcart_product_create_slug. Omit to derive from title. Dry-run reports intent, not a reservation; WordPress owns collision handling and product.slug returns the stored result. Later product_update title changes regenerate the slug; no slug update or redirect support.",
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "status": {
      "description": "Post status. Defaults to 'draft'.",
      "type": "string",
      "enum": [
        "draft",
        "publish",
        "pending",
        "private"
      ]
    },
    "content": {
      "description": "Long product description (post_content). Optional.",
      "type": "string"
    },
    "excerpt": {
      "description": "Short product summary (post_excerpt). Optional.",
      "type": "string"
    },
    "fulfillment_type": {
      "description": "Fulfillment shape — digital downloads vs physical shipping. Defaults to 'digital'.",
      "type": "string",
      "enum": [
        "digital",
        "physical"
      ]
    },
    "price": {
      "description": "Default variation's item_price (currency units, e.g. dollars — converted to cents server-side). Non-negative. Defaults to 0.",
      "type": "number",
      "minimum": 0
    },
    "compare_price": {
      "description": "Default variation's compare-at price (strike-through). Must be ≥ `price` when both provided. Non-negative.",
      "type": "number",
      "minimum": 0
    },
    "sku": {
      "description": "Default variation's SKU. Optional. Must be unique across all FluentCart variations and at most 30 characters (FluentCart stores fct_product_variations.sku as VARCHAR(30)). Omit to skip SKU assignment.",
      "type": "string"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "title",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_product_deleteTrash a FluentCart Pro product (Pro tier; requires FluentCart Pro installed + activated).Pro

Trash a FluentCart Pro product (Pro tier; requires FluentCart Pro installed + activated). V2 semantics: trash, NOT hard-delete. Uses `wp_trash_post` (not FluentCart's `ProductResource::delete`, which permanently destroys detail / variation rows) so the trash bin remains recoverable from the FluentCart admin UI. Repeat-safe: trashing an already-trashed product returns `ok:true` with `data.already_trashed: true` (no error). Permanent delete is intentionally NOT in V2 — surfaces in a later vertical with explicit policy. Pending-order protection: a product with at least one on-hold or processing order returns `fluentcart.pending_orders` (HTTP 409) and is not bypassable in V2. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; apply-mode success payload is { trashed: true, product_id } or { already_trashed: true, product_id }. Error codes: invalid_input (400) when id is not a positive integer; not_found (404) when no product matches; fluentcart.pending_orders (409) when the product has on-hold/processing orders; fluentcart.module_inactive (412); fluentcart.command_failed (500). Idempotency: conditional — repeat trash is a no-op. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_product_getFetch a single FluentCart Pro product by ID, including the ProductDetail row, default-variation read-back fields, a compact value-free shape-readiness verdict, buyer-safe storefront links, and a list of variation IDs (Pro tier; requires FluentCart Pro installed + activated).Pro

Fetch a single FluentCart Pro product by ID, including the ProductDetail row, default-variation read-back fields, a compact value-free shape-readiness verdict, buyer-safe storefront links, and a list of variation IDs (Pro tier; requires FluentCart Pro installed + activated). Read-only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; the success payload is { product: { id, title, slug, status, created_at, modified_at, variation_type, variants_count, min_price, max_price, stock_availability, excerpt, content, author_id, view_url, edit_url }, detail: { fulfillment_type, variation_type, min_price, max_price, manage_stock, manage_downloadable, stock_availability, default_variation_id, ... } | null, default_variation: { id, sku, item_price, compare_price } | null, storefront_links: { view_url: string|null, checkout_url: string|null, checkout_variation_id: number|null, ready: boolean, problems: string[], draft_preview_available: false }, shape_readiness: { profile: "simple_onetime"|"simple_annual_subscription"|"unsupported", ready: boolean, problems: string[] }, variation_ids: number[], variations_count }. storefront_links is ready only for a published, simple product with exactly one resolvable variation that passes FluentCart's native canPurchase(1) check. Native simple products may use the bounded sole-variation fallback when their default pointer is empty. Missing or drifted DiviOps-authored defaults remain visible in shape_readiness and every mutation remains strict. storefront_links.checkout_url comes from FluentCart's native getPurchaseUrl() query-string route; DiviOps does not invent add-to-cart URLs. Draft, pending, and private products return both buyer URLs as null. storefront_links.problems uses finite codes: product_not_published, product_shape_not_ready, default_variation_missing, variation_not_purchasable, checkout_url_unavailable. product_shape_not_ready is limited to non-simple products or products without exactly one variation. product.view_url remains unchanged for backward-compatible administrative readback and is not a buyer-safety verdict. shape_readiness never returns raw other_info; problems contains only finite codes: detail_missing, variation_type_unsupported, variation_count_not_one, default_variation_pointer_missing, default_variation_pointer_dangling, detail_defaults_drift, payment_profile_unsupported, payment_type_drift, variation_defaults_drift. An intentionally independent variation_title is supported and does not affect readiness. The default_variation block closes the read-after-write loop for the V2 simple-product write tools — sku and compare_price round-trip cleanly without a FluentCart admin fallback. Unit asymmetry: product_create / product_update accept price and compare_price in currency units (e.g. 29.99); product_get returns min_price, max_price, default_variation.item_price, and default_variation.compare_price in stored cents (e.g. 2999). default_variation.sku is null when the stored SKU is SQL NULL; clearing a SKU with sku: "" on update reads back as null. default_variation itself is null when the product has no default variation row. Apply/no-op product_create and product_update responses include the same storefront_links projection. Use the variation_ids list to follow up with diviops_fc_variation_list. Error codes: invalid_input (HTTP 400) when id is not a positive integer; not_found (HTTP 404) when no product matches the ID (or it's filtered out by the FluentCart auto-draft global scope); fluentcart.module_inactive (HTTP 412) when FluentCart is uninstalled or the module toggle is off; fluentcart.query_failed (HTTP 500) when the FluentCart model query raises an exception.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    }
  },
  "required": [
    "id"
  ],
  "additionalProperties": false
}
diviops_fc_product_listList FluentCart Pro products (Pro tier; requires FluentCart Pro installed + activated).Pro

List FluentCart Pro products (Pro tier; requires FluentCart Pro installed + activated). Returns a paginated summary list with product identity (id, title, slug, status), variation_type, variants_count, and min/max price. Filterable by `search` (LIKE post_title), `type` (one of physical/digital/subscription/onetime/simple/variations), and `status` (one of publish/draft/pending/private/trash; default returns publish+draft+pending+private). Read-only. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; the success payload is { products: ProductSummary[], pagination: { page, per_page, total, total_pages }, filters: { search, type, status } }. Error codes: invalid_input (HTTP 400) when type/status filter is out of range; fluentcart.module_inactive (HTTP 412) when FluentCart is uninstalled or the diviops-agent-pro module toggle is off; fluentcart.query_failed (HTTP 500) when the underlying FluentCart model query raises an exception (message field carries the upstream exception). Use this before authoring a Divi commerce page to identify which product IDs / types to render.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page": {
      "default": 1,
      "description": "Page number, 1-indexed. Default 1.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "per_page": {
      "default": 20,
      "description": "Page size. Default 20, clamped to a max of 100 per call.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "search": {
      "description": "Search term — matches against product post_title via SQL LIKE %term%. Case-insensitive on most MySQL collations.",
      "type": "string"
    },
    "type": {
      "description": "Product type filter. physical/digital filter by fulfillment_type on variations; subscription/onetime filter by payment_type on variations; simple filters detail.variation_type='simple'; variations filters detail.variation_type in {simple_variations, advanced_variations}.",
      "type": "string",
      "enum": [
        "physical",
        "digital",
        "subscription",
        "onetime",
        "simple",
        "variations"
      ]
    },
    "status": {
      "description": "Post status filter. Defaults to all visible-to-admin statuses (publish+draft+pending+private). Pass 'trash' explicitly to inspect trashed products.",
      "type": "string",
      "enum": [
        "publish",
        "draft",
        "pending",
        "private",
        "trash"
      ]
    }
  },
  "required": [
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
diviops_fc_product_updateUpdate a simple FluentCart Pro product (Pro tier; requires FluentCart Pro installed + activated).Pro

Update a simple FluentCart Pro product (Pro tier; requires FluentCart Pro installed + activated). Product-level title, status, content, and excerpt updates are supported for both onetime and subscription products; changing title also keeps the default variation's variation_title coherent. On simple onetime products, fulfillment_type, price, compare_price, and sku remain supported. On subscription products those variation-level fields are refused with `fluentcart.unsupported_product_shape` (HTTP 422): pricing and SKU must use diviops_fc_variation_update, while subscription fulfillment changes remain out of scope. This ensures subscription pricing never flows through the V2 product path. Multi-variation products remain refused. Supported updates preserve initialized detail/variation defaults and unrelated existing other_info keys; they report but do not auto-repair legacy drift. SKU constraint on onetime products: unique across FluentCart variations and at most 30 characters; `sku: ""` clears it and reads back as `null`. Required: `id` (positive integer; the post ID of the fluent_products CPT entry). All other fields optional; only changed fields are applied. When no field actually changes, returns `ok:true` with `data.noop: true` (apply mode) or an empty-plan dry-run summary. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; apply-mode success payload is { product, detail, default_variation: { id, sku, item_price, compare_price } | null, storefront_links: { view_url, checkout_url, checkout_variation_id, ready, problems, draft_preview_available }, shape_readiness: { profile, ready, problems }, variation_ids, variations_count, changed_fields[] } (or { noop: true, product, detail, default_variation, storefront_links, shape_readiness, ... } on a no-op). The default_variation, storefront_links, and value-free shape_readiness blocks reflect the post-update state. Unit asymmetry for onetime pricing: write inputs are currency units; readback prices are stored cents. Error codes: invalid_input (400); not_found (404); fluentcart.unsupported_product_shape (422) for non-simple products, unsupported payment types, or subscription variation fields; fluentcart.sku_conflict (409); fluentcart.module_inactive (412); fluentcart.command_failed (500). Idempotency: conditional — repeating an identical update is a no-op. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    },
    "title": {
      "description": "New product title. 1-200 chars. Also updates the default variation title for both onetime and subscription products.",
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "status": {
      "description": "New post status.",
      "type": "string",
      "enum": [
        "draft",
        "publish",
        "pending",
        "private"
      ]
    },
    "content": {
      "description": "New long description.",
      "type": "string"
    },
    "excerpt": {
      "description": "New short summary.",
      "type": "string"
    },
    "fulfillment_type": {
      "description": "New fulfillment shape. Simple onetime products only.",
      "type": "string",
      "enum": [
        "digital",
        "physical"
      ]
    },
    "price": {
      "description": "New default-variation item_price (currency units). Non-negative. Simple onetime products only; use diviops_fc_variation_update for subscriptions.",
      "type": "number",
      "minimum": 0
    },
    "compare_price": {
      "description": "New compare-at price. Must be ≥ `price` when both provided. Simple onetime products only.",
      "type": "number",
      "minimum": 0
    },
    "sku": {
      "description": "New SKU for the default variation. Simple onetime products only. Must be unique across all FluentCart variations and at most 30 characters. Empty string clears the SKU (reads back as null).",
      "type": "string"
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_fc_statusInspect FluentCart checkout/license readiness (Pro tier; V3.2).Pro

Inspect FluentCart checkout/license readiness (Pro tier; V3.2). Read-only. Returns a structured snapshot covering: site (wp_url, host, is_local_hint, wp_version), plugins (fluent_cart, fluent_cart_pro, diviops_agent_pro — { active, version } each), store (order_mode, currency, currency_symbol, currency_position, store_country, store_state, checkout/cart/receipt/shop page IDs), modules (license.active, stock_management.active+advanced_inventory), tables (core / licensing / advanced_inventory groups with count/expected/ok and gated_by hints — `ok: null` means the group is optional and module is off), gateways (registered_count, enabled_count, enabled_methods, registered_methods, local_safe_methods — slug-only summary; use diviops_fc_gateway_list/get for details), counts (orders, licenses, license_activations), and readiness (verdict: green|yellow|red, checkout_writable, license_writable, local_no_money_smoke_ready, public_launch_ready, warnings[], blockers[]). Distinguishes "fluentcart inactive" from "core schema missing" from "license module on but tables missing" — the same gaps that drove earlier local checkout/license smokes into WP-CLI and eval-file probes. No secrets are returned at any layer; gateway settings are summarized through diviops_fc_gateway_* tools. Pass include_table_lists=true to receive the full present[]/missing[] table arrays (default: count/expected/ok only, to keep the response compact). Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Error codes: fluentcart.module_inactive (412); fluentcart.command_failed (500).

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "include_table_lists": {
      "default": false,
      "description": "When true, include the full present[] and missing[] arrays in each `tables.*` group. Default false to keep the response compact.",
      "type": "boolean"
    }
  },
  "required": [
    "include_table_lists"
  ],
  "additionalProperties": false
}
diviops_fc_variation_listList FluentCart Pro variations for a product (Pro tier; V3; requires FluentCart Pro installed + activated).Pro

List FluentCart Pro variations for a product (Pro tier; V3; requires FluentCart Pro installed + activated). Read-only. Returns every variation row attached to the product with its subscription shape (payment_type, other_info.repeat_interval/times/trial_days/manage_setup_fee) and a license-settings projection when ProductMeta.license_settings is configured. For FluentCart 1.5 advanced_variations products, also resolves attribute relation metadata into VariationRow.attributes[] while preserving raw other_info.variant term IDs; each attribute row carries { group_id, group_title, group_slug, group_type, term_id, term_title, term_slug, term_settings }. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { product_id, variation_type, default_variation_id, variations: VariationRow[], variations_count }. Each VariationRow carries { id, post_id, variation_title, sku, payment_type, item_price, compare_price, fulfillment_type, stock_status, manage_stock, available, other_info: { ...all stored keys... }, attributes?: AttributeRow[], license: { activation_limit, validity: { unit, value } } | null }. Unit convention: item_price and compare_price are stored cents (e.g. 1900 = $19.00). compare_price is null when FCP stores the no-compare sentinel 0; sku is null when the column is SQL NULL OR an empty string. license is null when the product has no license_settings; otherwise activation_limit is null/'' (unset), 0 (unlimited per FluentCart Pro License::getActivationLimit), or a positive integer (max activations). validity.unit is one of: lifetime/day/week/month/year. Advanced Variations authoring remains out of scope; write tools still refuse non-simple shapes with fluentcart.unsupported_product_shape. Error codes: invalid_input (400) when id is not a positive integer; not_found (404) when the product does not exist; fluentcart.module_inactive (412); fluentcart.query_failed (500). Idempotency: read-only.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    }
  },
  "required": [
    "product_id"
  ],
  "additionalProperties": false
}
diviops_fc_variation_updateUpdate the default variation of a simple FluentCart Pro product (Pro tier; V3; requires FluentCart Pro installed + activated).Pro

Update the default variation of a simple FluentCart Pro product (Pro tier; V3; requires FluentCart Pro installed + activated). V3 scope: writes the product's default variation only; refuses non-simple products and non-default variations with `fluentcart.unsupported_product_shape` (HTTP 422). Multi-variation create/delete remains out of scope. Accepts partial updates on variation_title (non-empty, 1-200 chars), price, compare_price, sku, payment_type, and the subscription shape (repeat_interval, times, trial_days, manage_setup_fee). variation_title changes only the default variation label; use diviops_fc_product_update.title when the product title and default variation label should stay aligned. Switching `payment_type: "subscription"` requires `repeat_interval` (yearly/half_yearly/quarterly/monthly/weekly/daily) — either supplied in the same call or already stored. Switching to `onetime` restores FluentCart's initialized one-time values for the finite subscription-related keys while preserving unrelated other_info. `manage_setup_fee: "yes"` remains out of scope. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; apply-mode success payload is { product_id, variation_id, changed_fields[], variation: VariationRow, product_price_range: { min_price, max_price } | null } (or { noop: true, product_id, variation_id, variation } when nothing changes). VariationRow provides direct readback including variation_title. Error codes: invalid_input (400); not_found (404); fluentcart.unsupported_product_shape (422); fluentcart.sku_conflict (409); fluentcart.module_inactive (412); fluentcart.command_failed (500). Idempotency: conditional — identical repeat is a no-op. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "product_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart product ID (the post ID of the fluent_products CPT entry)."
    },
    "variation_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "FluentCart variation ID. Must be the product's default variation (V3 constraint)."
    },
    "variation_title": {
      "description": "Default variation label. 1-200 chars. This does not change the product title.",
      "type": "string",
      "minLength": 1,
      "maxLength": 200
    },
    "price": {
      "description": "Variation item_price in currency units (e.g. 19.00). Non-negative.",
      "type": "number",
      "minimum": 0
    },
    "compare_price": {
      "description": "Variation compare-at price in currency units. Must be ≥ price when both provided.",
      "type": "number",
      "minimum": 0
    },
    "sku": {
      "description": "Variation SKU. Must be unique across all FluentCart variations and at most 30 characters. Empty string clears the SKU (reads back as null).",
      "type": "string"
    },
    "payment_type": {
      "description": "Variation payment_type. Switching to 'subscription' requires repeat_interval. Switching to 'onetime' restores initialized one-time values for the finite subscription-related keys and preserves unrelated other_info.",
      "type": "string",
      "enum": [
        "onetime",
        "subscription"
      ]
    },
    "repeat_interval": {
      "description": "Subscription billing interval. Required when switching to payment_type='subscription' unless already stored. For ADR-005 annual rows use 'yearly'.",
      "type": "string",
      "enum": [
        "yearly",
        "half_yearly",
        "quarterly",
        "monthly",
        "weekly",
        "daily"
      ]
    },
    "times": {
      "description": "Number of subscription billing cycles. 0 = indefinite (default for V3 subscription rows).",
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "trial_days": {
      "description": "Trial-period length in days (0-365).",
      "type": "integer",
      "minimum": 0,
      "maximum": 365
    },
    "manage_setup_fee": {
      "description": "Setup-fee mode. V3 only accepts 'no' — manage_setup_fee='yes' requires signup_fee + signup_fee_name which are out of scope for V3.",
      "type": "string",
      "enum": [
        "no"
      ]
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "product_id",
    "variation_id",
    "dry_run"
  ],
  "additionalProperties": false
}

Cross-environment workflows

diviops_cross_env_header_applyApply a reviewed cross-environment Theme Builder header payload into an existing target header layout (Pro tier; requires the cross_env Pro module).Pro

Apply a reviewed cross-environment Theme Builder header payload into an existing target header layout (Pro tier; requires the cross_env Pro module). This first MVP is intentionally narrow: it requires `confirm_apply: true`, either an inline source export payload or a bounded `source_payload_ref` returned by diviops_cross_env_source_export_get, an existing target `destination_id`, and the reviewed `confirmation_binding.fingerprint` from `diviops-cross-env-preflight`. Large real headers should use `source_payload_ref`; inline `source_payload` remains supported for small/disposable tests. The server loads referenced payload bytes from its own `.diviops-tmp/cross-env-source-payloads/` artifact store, verifies checksum, re-exports current target context, reruns the TypeScript preflight engine, refuses fingerprint mismatch, unsafe verdicts, destination checksum drift, missing/ambiguous attachment remaps, missing global-color value evidence, missing target module preset definitions, and off-canvas/canvas references, then calls the Pro route with the verified plan. The Pro route re-loads the destination post, verifies the current checksum again, builds content only from source-origin upload URL rewrites and proven attachment-ID remaps, writes with readback/rollback evidence, and runs Divi static-resource cleanup plus explicit _divi_dynamic_assets_cached_feature_used cleanup. No media upload/import, global-color creation/import, preset import/clone, new layout creation, off-canvas reconcile, public/store/license change, or live-site smoke is performed by this tool. Returns the standardized envelope { ok, data?, error: { code, message, hint?, data? } }. Error codes include cross_env.confirmation_required, cross_env.source_payload_ref_invalid, cross_env.fingerprint_mismatch, cross_env.preflight_not_safe, cross_env.destination_checksum_drift, cross_env.source_checksum_mismatch, cross_env.content_write_corruption, invalid_input, not_found, forbidden, and wp_error.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "source_payload": {
      "description": "The `data` object returned by diviops_cross_env_source_export_get on the source site. Use source_payload_ref instead for large real headers.",
      "type": "object",
      "properties": {
        "origin": {
          "type": "string",
          "description": "Source site origin, e.g. https://source.example."
        },
        "object_kind": {
          "type": "string",
          "const": "tb_header_layout"
        },
        "object_id": {
          "type": [
            "number",
            "string"
          ]
        },
        "object_title": {
          "type": "string"
        },
        "object_post_type": {
          "type": "string",
          "enum": [
            "et_header_layout",
            "et_footer_layout"
          ]
        },
        "markup": {
          "type": "string",
          "description": "Sanitized source Theme Builder layout block markup."
        },
        "checksum": {
          "type": "string",
          "pattern": "^(sha256:)?[a-fA-F0-9]{64}$",
          "description": "sha256 checksum of source_payload.markup from source export."
        },
        "attachments": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "url": {
                "type": "string"
              },
              "path": {
                "type": "string"
              },
              "filename": {
                "type": "string"
              },
              "mime": {
                "type": "string"
              }
            },
            "additionalProperties": {}
          }
        },
        "module_preset_ids": {
          "description": "Referenced attrs.modulePreset IDs from source export; definitions are not included.",
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "origin",
        "object_kind",
        "markup",
        "checksum"
      ],
      "additionalProperties": {}
    },
    "source_payload_ref": {
      "description": "Bounded server-local artifact reference returned as data.source_payload_ref by diviops_cross_env_source_export_get. Preferred for large real headers because it avoids inlining full markup through the model.",
      "type": "object",
      "properties": {
        "handle": {
          "type": "string",
          "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
          "description": "Server-created source payload artifact handle returned by diviops_cross_env_source_export_get."
        },
        "checksum": {
          "type": "string",
          "pattern": "^(sha256:)?[a-fA-F0-9]{64}$",
          "description": "sha256 checksum of the referenced source payload markup."
        },
        "algorithm": {
          "type": "string",
          "const": "sha256"
        },
        "storage": {
          "type": "string",
          "const": "server_local_artifact"
        },
        "expires_at": {
          "type": "string"
        }
      },
      "required": [
        "handle",
        "checksum"
      ],
      "additionalProperties": {}
    },
    "destination_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Existing target Theme Builder header layout post ID."
    },
    "destination_kind": {
      "default": "tb_header_layout",
      "description": "Destination kind. MVP supports tb_header_layout only.",
      "type": "string",
      "enum": [
        "tb_header_layout"
      ]
    },
    "reviewed_fingerprint": {
      "type": "string",
      "pattern": "^(sha256:)?[a-fA-F0-9]{64}$",
      "description": "Reviewed confirmation_binding.fingerprint from the safe preflight report."
    },
    "confirm_apply": {
      "type": "boolean",
      "description": "Must be true. Missing/false refuses before any target mutation."
    }
  },
  "required": [
    "destination_id",
    "destination_kind",
    "reviewed_fingerprint",
    "confirm_apply"
  ],
  "additionalProperties": false
}
diviops_cross_env_layout_applyApply one reviewed Theme Builder header or footer payload to one existing same-kind target layout (Pro tier; cross_env module).Pro

Apply one reviewed Theme Builder header or footer payload to one existing same-kind target layout (Pro tier; cross_env module). Requires fresh Free source/target evidence, the generic versioned confirmation fingerprint, and confirm_apply: true. Independently refuses kind/post-type mismatch, checksum or template-linkage drift, unsafe dependency evidence, off-canvas wiring, foreign CSS variables, invalid serialization, and readback mismatch before claiming success. A converged target returns already_converged without a write or cache mutation; successful mutation returns rollout_applied with readback, checksums, rollback, supported-meta, and cache evidence. Never creates layouts, mutates template assignment, or reconciles dependencies. Also supports the exact current-post native diviops_staff body recipe with same-selector text role, raw HTML off, and an existing isolated body assignment. Body-only dry_run validates current proof without mutation; real body writes retain a recovery snapshot.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "dry_run": {
      "description": "Body only: validate the reviewed staff proof without writing. True refuses header/footer requests.",
      "type": "boolean"
    },
    "source_payload": {
      "description": "Free source export payload. Use source_payload_ref for large layouts.",
      "type": "object",
      "properties": {
        "origin": {
          "type": "string",
          "description": "Source site origin, e.g. https://source.example."
        },
        "object_kind": {
          "type": "string",
          "enum": [
            "tb_header_layout",
            "tb_footer_layout",
            "tb_body_layout"
          ]
        },
        "object_id": {
          "type": [
            "number",
            "string"
          ]
        },
        "object_title": {
          "type": "string"
        },
        "object_post_type": {
          "type": "string",
          "enum": [
            "et_header_layout",
            "et_footer_layout",
            "et_body_layout"
          ]
        },
        "markup": {
          "type": "string",
          "description": "Sanitized source Theme Builder layout block markup."
        },
        "checksum": {
          "type": "string",
          "pattern": "^(sha256:)?[a-fA-F0-9]{64}$",
          "description": "sha256 checksum of source_payload.markup from source export."
        },
        "attachments": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "url": {
                "type": "string"
              },
              "path": {
                "type": "string"
              },
              "filename": {
                "type": "string"
              },
              "mime": {
                "type": "string"
              }
            },
            "additionalProperties": {}
          }
        },
        "module_preset_ids": {
          "description": "Referenced attrs.modulePreset IDs from source export; definitions are not included.",
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "origin",
        "object_kind",
        "markup",
        "checksum"
      ],
      "additionalProperties": {}
    },
    "source_payload_ref": {
      "description": "Bounded server-local artifact reference from diviops_cross_env_source_export_get.",
      "type": "object",
      "properties": {
        "handle": {
          "type": "string",
          "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
          "description": "Server-created source payload artifact handle returned by diviops_cross_env_source_export_get."
        },
        "checksum": {
          "type": "string",
          "pattern": "^(sha256:)?[a-fA-F0-9]{64}$",
          "description": "sha256 checksum of the referenced source payload markup."
        },
        "algorithm": {
          "type": "string",
          "const": "sha256"
        },
        "storage": {
          "type": "string",
          "const": "server_local_artifact"
        },
        "expires_at": {
          "type": "string"
        }
      },
      "required": [
        "handle",
        "checksum"
      ],
      "additionalProperties": {}
    },
    "destination_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Existing target Theme Builder layout post ID."
    },
    "destination_kind": {
      "type": "string",
      "enum": [
        "tb_header_layout",
        "tb_footer_layout",
        "tb_body_layout"
      ],
      "description": "Exact target kind; must match source_payload.object_kind."
    },
    "reviewed_fingerprint": {
      "type": "string",
      "pattern": "^(sha256:)?[a-fA-F0-9]{64}$",
      "description": "Reviewed generic confirmation_binding fingerprint."
    },
    "confirm_apply": {
      "type": "boolean",
      "description": "Must be true. Missing/false refuses before any target mutation."
    }
  },
  "required": [
    "destination_id",
    "destination_kind",
    "reviewed_fingerprint",
    "confirm_apply"
  ],
  "additionalProperties": false
}
diviops_cross_env_source_export_getExport read-only, secret-free source-site payload for an offline cross-environment Theme Builder header/footer preflight.Free

Export read-only, secret-free source-site payload for an offline cross-environment Theme Builder header or footer or bounded staff body preflight. Returns exact kind/post-type identity, sanitized markup and checksum, dependency inventories, and a bounded source_payload_ref. Free/core and read-only: no WordPress content, assignment, dependency, or cache mutation. Staff body promotion requires the native current-post recipe, existing role field, and an isolated target body assignment.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "source_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Existing source Theme Builder header or footer or bounded staff body layout post ID."
    },
    "source_kind": {
      "default": "tb_header_layout",
      "description": "Source kind. Existing header or footer or bounded staff body layout evidence is supported. Staff body promotion requires the native current-post recipe, existing role field, and an isolated target body assignment.",
      "type": "string",
      "enum": [
        "tb_header_layout",
        "tb_footer_layout",
        "tb_body_layout"
      ]
    },
    "dry_run": {
      "default": true,
      "description": "Accepted for workflow symmetry; the tool is always read-only and never mutates state.",
      "type": "boolean"
    }
  },
  "required": [
    "source_id",
    "source_kind",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_cross_env_target_context_getExport read-only, secret-free target-site context for an offline cross-environment Theme Builder header/footer preflight.Free

Export read-only, secret-free target-site context for an offline cross-environment Theme Builder header or footer or bounded staff body preflight. Returns exact kind/post-type identity, the current post_content checksum without content exposure, canonical template-linkage evidence/digest, dependency evidence, and cache scope. Free/core and read-only: no content, assignment, dependency, or cache mutation. Staff body promotion requires the native current-post recipe, existing role field, and an isolated target body assignment.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "destination_id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Existing target Theme Builder header or footer or bounded staff body layout post ID."
    },
    "destination_kind": {
      "default": "tb_header_layout",
      "description": "Destination kind. Existing header or footer or bounded staff body layout evidence is supported. Staff body promotion requires the native current-post recipe, existing role field, and an isolated target body assignment.",
      "type": "string",
      "enum": [
        "tb_header_layout",
        "tb_footer_layout",
        "tb_body_layout"
      ]
    },
    "source_asset_hints": {
      "description": "Optional source upload paths, asset URLs, or basenames used to search target media candidates. Query strings, fragments, and credentials are stripped from output.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "source_upload_paths": {
      "description": "Optional source-export attachment paths with exact-path provenance, including root-level filenames.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "source_attachment_ids": {
      "description": "Optional numeric source attachment IDs found in source markup. A remap is emitted only when exactly one source ID and one exact target candidate are present.",
      "type": "array",
      "items": {
        "type": "number"
      }
    },
    "dry_run": {
      "default": true,
      "description": "Accepted for workflow symmetry; the tool is always read-only and never mutates state.",
      "type": "boolean"
    }
  },
  "required": [
    "destination_id",
    "destination_kind",
    "dry_run"
  ],
  "additionalProperties": false
}

Snapshots and recovery

diviops_managed_recovery_audit_listList immutable checksummed metadata-only managed recovery policy/prune audit events (Pro Phase 1A), newest first with bounded pagination.Pro

List immutable checksummed metadata-only managed recovery policy/prune audit events (Pro Phase 1A), newest first with bounded pagination. Corrupt events are reported as redacted corruption evidence. Never returns snapshot payload/content, raw post-meta, credentials, signing material, confirmation tokens, or unnecessary URLs/logins.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "page": {
      "default": 1,
      "type": "integer",
      "minimum": 1,
      "maximum": 1000
    },
    "per_page": {
      "default": 20,
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
diviops_managed_recovery_plan_checkPure-read managed recovery plan for one existing rollback snapshot (Pro Phase 1B).Pro

Pure-read managed recovery plan for one existing rollback snapshot (Pro Phase 1B). Requires manage_options and current target edit permission. Returns value-free intended before-state and supported metadata actions, checksums, limits/exclusions, cache/readback expectations, and capture-on-apply readiness, not an already-created recovery point. Uses Free-owned protected dry-run validation and issues a maximum-15-minute site/actor/request/snapshot/state/policy/inventory-bound confirmation for restore_apply. Writes no options, snapshots, content, cache, or audit state and returns no raw content or metadata.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "snapshot_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9_-]{2,127}$",
      "description": "Existing rollback snapshot ID to restore to its original supported page or layout target."
    },
    "request_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{2,127}$",
      "description": "Caller-stable request ID used for confirmation binding and exact replay/conflict detection."
    }
  },
  "required": [
    "snapshot_id",
    "request_id"
  ],
  "additionalProperties": false
}
diviops_managed_recovery_policy_getInspect the effective/default one-site managed recovery policy and complete metadata-only rollback snapshot inventory (Pro Phase 1A; managed_recovery module).Pro

Inspect the effective/default one-site managed recovery policy and complete metadata-only rollback snapshot inventory (Pro Phase 1A; managed_recovery module). Returns policy checksum/version, inventory checksum/count/bytes, corruption/readiness warnings, and the entitlement-independent Free recovery-data promise. Never returns snapshot payload content, raw historical post-meta, credentials, or confirmation material and never mutates state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_managed_recovery_policy_previewPure-read preview of a complete managed-recovery-policy-v1 proposal (Pro Phase 1A).Pro

Pure-read preview of a complete managed-recovery-policy-v1 proposal (Pro Phase 1A). Validates hard limits, canonicalizes types/ID ordering, recomputes complete inventory, returns deterministic keep/prune/refuse effects with stable reasons and exact byte/count deltas, and issues a maximum-15-minute actor/site/policy/inventory/body-bound confirmation for policy_update. Preview writes no policy, snapshot, cache, or audit state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "request_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{2,127}$",
      "description": "Caller-stable request ID used for confirmation binding and exact replay/conflict detection."
    },
    "policy": {
      "type": "object",
      "properties": {
        "version": {
          "type": "number",
          "const": 1
        },
        "enabled": {
          "type": "boolean"
        },
        "max_age_days": {
          "type": "integer",
          "minimum": 1,
          "maximum": 365
        },
        "max_snapshots_per_target": {
          "type": "integer",
          "minimum": 1,
          "maximum": 100
        },
        "max_site_snapshots": {
          "type": "integer",
          "minimum": 1,
          "maximum": 1000
        },
        "max_site_bytes": {
          "type": "integer",
          "minimum": 1048576,
          "maximum": 536870912
        },
        "preserve_newest_viable_per_target": {
          "type": "boolean",
          "const": true
        },
        "protected_snapshot_ids": {
          "maxItems": 50,
          "type": "array",
          "items": {
            "type": "string",
            "pattern": "^[A-Za-z0-9][A-Za-z0-9_-]{2,127}$"
          }
        },
        "audit_retention_days": {
          "type": "integer",
          "minimum": 30,
          "maximum": 2555
        }
      },
      "required": [
        "version",
        "enabled",
        "max_age_days",
        "max_snapshots_per_target",
        "max_site_snapshots",
        "max_site_bytes",
        "preserve_newest_viable_per_target",
        "protected_snapshot_ids",
        "audit_retention_days"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "request_id",
    "policy"
  ],
  "additionalProperties": false
}
diviops_managed_recovery_policy_updateApply exactly the one-site managed recovery policy reviewed by policy_preview (Pro Phase 1A).Pro

Apply exactly the one-site managed recovery policy reviewed by policy_preview (Pro Phase 1A). Recomputes current policy and complete inventory, verifies the short-lived actor/site/body/policy/inventory binding, rechecks manage_options immediately before mutation, stores the versioned policy with autoload=no, verifies readback, and appends metadata-only immutable audit evidence. It never prunes snapshots. Exact request replay returns the prior redacted result; conflicting request_id reuse refuses. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "request_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{2,127}$",
      "description": "Caller-stable request ID used for confirmation binding and exact replay/conflict detection."
    },
    "policy": {
      "type": "object",
      "properties": {
        "version": {
          "type": "number",
          "const": 1
        },
        "enabled": {
          "type": "boolean"
        },
        "max_age_days": {
          "type": "integer",
          "minimum": 1,
          "maximum": 365
        },
        "max_snapshots_per_target": {
          "type": "integer",
          "minimum": 1,
          "maximum": 100
        },
        "max_site_snapshots": {
          "type": "integer",
          "minimum": 1,
          "maximum": 1000
        },
        "max_site_bytes": {
          "type": "integer",
          "minimum": 1048576,
          "maximum": 536870912
        },
        "preserve_newest_viable_per_target": {
          "type": "boolean",
          "const": true
        },
        "protected_snapshot_ids": {
          "maxItems": 50,
          "type": "array",
          "items": {
            "type": "string",
            "pattern": "^[A-Za-z0-9][A-Za-z0-9_-]{2,127}$"
          }
        },
        "audit_retention_days": {
          "type": "integer",
          "minimum": 30,
          "maximum": 2555
        }
      },
      "required": [
        "version",
        "enabled",
        "max_age_days",
        "max_snapshots_per_target",
        "max_site_snapshots",
        "max_site_bytes",
        "preserve_newest_viable_per_target",
        "protected_snapshot_ids",
        "audit_retention_days"
      ],
      "additionalProperties": false
    },
    "confirmation_fingerprint": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$",
      "description": "Exact fingerprint returned by the matching preview operation."
    },
    "confirmation_token": {
      "type": "string",
      "minLength": 32,
      "description": "Short-lived signed token returned by the matching preview operation."
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "request_id",
    "policy",
    "confirmation_fingerprint",
    "confirmation_token",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_managed_recovery_restore_applyApply exactly the snapshot restore reviewed by managed_recovery_plan_check (Pro Phase 1B).Pro

Apply exactly the snapshot restore reviewed by managed_recovery_plan_check (Pro Phase 1B). Rechecks live permissions, compatibility, current plan, and signed confirmation binding before any target write. Non-dry apply durably reserves the request and delegates once to the Free protected restore service, which captures the current state before restoring. No force, target override, raw payload, automatic retry, or second apply. Exact completed request replay returns the prior redacted success or failure without further capture, restore, or audit; conflicting or incomplete requests refuse. Reports verified success, recovery after failure, partial failure, and audit persistence failure distinctly. dry_run performs zero option, snapshot, content, cache, or audit writes and no capture. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "snapshot_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9_-]{2,127}$",
      "description": "Existing rollback snapshot ID to restore to its original supported page or layout target."
    },
    "request_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{2,127}$",
      "description": "Caller-stable request ID used for confirmation binding and exact replay/conflict detection."
    },
    "confirmation_fingerprint": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$",
      "description": "Exact fingerprint returned by the matching managed_recovery_plan_check operation."
    },
    "confirmation_token": {
      "type": "string",
      "minLength": 32,
      "description": "Short-lived signed token returned by the matching managed_recovery_plan_check operation."
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "snapshot_id",
    "request_id",
    "confirmation_fingerprint",
    "confirmation_token",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_managed_recovery_retention_applyDelete only the exact ordered snapshot IDs reviewed by retention_preview (Pro Phase 1A).Pro

Delete only the exact ordered snapshot IDs reviewed by retention_preview (Pro Phase 1A). Rechecks manage_options, policy, complete inventory, protections, viability, signature, actor/site/body binding, and plan before the first delete, then delegates exact-ID deletion to Free/core. Stops on first failure and reports exact deleted/failed/unattempted byte/count evidence without claiming transaction rollback. Exact request replay is non-mutating; conflicting reuse refuses. Pass dry_run: true to preview the change plan without mutating state.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "request_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{2,127}$",
      "description": "Caller-stable request ID used for confirmation binding and exact replay/conflict detection."
    },
    "confirmation_fingerprint": {
      "type": "string",
      "pattern": "^sha256:[a-f0-9]{64}$",
      "description": "Exact fingerprint returned by the matching preview operation."
    },
    "confirmation_token": {
      "type": "string",
      "minLength": 32,
      "description": "Short-lived signed token returned by the matching preview operation."
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    }
  },
  "required": [
    "request_id",
    "confirmation_fingerprint",
    "confirmation_token",
    "dry_run"
  ],
  "additionalProperties": false
}
diviops_managed_recovery_retention_previewPure-read deterministic retention plan for the active one-site managed recovery policy (Pro Phase 1A).Pro

Pure-read deterministic retention plan for the active one-site managed recovery policy (Pro Phase 1A). Requires complete non-truncated Free-owned inventory; preserves explicit protections and the newest viable recovery point per target; returns ordered keep/prune/refuse rows, stable reasons, exact IDs and byte/count deltas, and a short-lived retention-only confirmation. Snapshot expiry is advisory evidence, and preview performs zero writes.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "request_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{2,127}$",
      "description": "Caller-stable request ID used for confirmation binding and exact replay/conflict detection."
    }
  },
  "required": [
    "request_id"
  ],
  "additionalProperties": false
}
diviops_rollback_snapshot_deleteHard-delete one rollback snapshot option after operator acceptance.Free

Hard-delete one rollback snapshot option after operator acceptance. Free/core cleanup surface; normally requires target-level permission, with a missing-target cleanup path for site admins or the snapshot creator. Does not expose before.value and does not restore content. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "snapshot_id": {
      "type": "string",
      "minLength": 1,
      "description": "Snapshot id to delete."
    }
  },
  "required": [
    "snapshot_id"
  ],
  "additionalProperties": false
}
diviops_rollback_snapshot_getInspect one rollback snapshot.Free

Inspect one rollback snapshot. Free/core storage management read surface. include_value defaults false; true returns the stored before.value and captured side-effect payload only when the referenced target still exists and the caller passes the target-level permission gate. Missing-target snapshots are metadata-only for admins/creators. No restore path in this tool. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "snapshot_id": {
      "type": "string",
      "minLength": 1,
      "description": "Snapshot id returned by diviops_rollback_snapshot_list."
    },
    "include_value": {
      "default": false,
      "description": "Include stored before.value and side-effect payload when target access allows it.",
      "type": "boolean"
    }
  },
  "required": [
    "snapshot_id",
    "include_value"
  ],
  "additionalProperties": false
}
diviops_rollback_snapshot_listList DiviOps rollback snapshots from the option-backed store.Free

List DiviOps rollback snapshots from the option-backed store. Free/core storage management read surface; returns metadata only, never stored before.value payloads. Supports target_kind, target_id, status, and limit filters. Results are target-permission filtered; missing-target snapshots are shown only to site admins or the snapshot creator and are payload-redacted. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "target_kind": {
      "description": "Optional target kind filter, usually post.",
      "type": "string"
    },
    "target_id": {
      "description": "Optional target post/layout ID filter.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "status": {
      "description": "Optional snapshot status filter, such as created or write_applied.",
      "type": "string"
    },
    "limit": {
      "default": 20,
      "description": "Maximum snapshots to return.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "limit"
  ],
  "additionalProperties": false
}
diviops_rollback_snapshot_restoreRestore one guarded rollback snapshot to its original post/page or Theme Builder layout target.Free

Restore one guarded rollback snapshot to its original post/page or Theme Builder layout target. Requires target edit permission, refuses content or captured Divi post-meta checksum drift with conflict before mutation, has no force override, writes through the shared full-content integrity/readback guard, restores captured supported post meta, invalidates Divi cache, and marks restore_applied only after verified readback. dry_run previews without writing. This MVP does not create a second pre-restore snapshot. Returns the standardized envelope.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "snapshot_id": {
      "type": "string",
      "minLength": 1,
      "description": "Snapshot id to restore."
    },
    "dry_run": {
      "default": false,
      "description": "Preview the checksum-bound restore without mutation.",
      "type": "boolean"
    }
  },
  "required": [
    "snapshot_id",
    "dry_run"
  ],
  "additionalProperties": false
}

Connection and utilities

diviops_meta_find_iconSearch for icons by keyword.Free

Search for icons by keyword. Returns matching icons with unicode, type (fa/divi), and weight. Use the returned unicode/type/weight in Blurb icon or Icon module attributes. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "query": {
      "type": "string",
      "description": "Search keyword (e.g. \"rocket\", \"heart\", \"chart\", \"user\")"
    },
    "type": {
      "default": "all",
      "description": "Filter by icon type: \"all\", \"fa\" (Font Awesome), or \"divi\" (ETmodules)",
      "type": "string",
      "enum": [
        "all",
        "fa",
        "divi"
      ]
    },
    "limit": {
      "default": 10,
      "description": "Max results (default 10, max 50)",
      "type": "number"
    }
  },
  "required": [
    "query",
    "type",
    "limit"
  ],
  "additionalProperties": false
}
diviops_meta_flush_cacheFlush Divi's compiled static CSS cache under wp-content/et-cache/. wp cache flush does NOT touch these files - the frontend can keep serving stale CSS after a preset/variable/module mutation until the cache is cleared.Free

Flush Divi's compiled static CSS cache under wp-content/et-cache/. wp cache flush does NOT touch these files — the frontend can keep serving stale CSS after a preset/variable/module mutation until the cache is cleared. Delegates to Divi's native ET_Core_PageResource::remove_static_resources when available (response backend: "divi_native"), which additionally clears Theme Builder CSS scattered across other post dirs, archive/taxonomy/home/notfound CSS, the object cache, module features cache, post features cache, Google Fonts cache, dynamic assets cache, and post meta caches. In post_id native mode, DiviOps also performs a targeted WP_Filesystem sweep of wp-content/et-cache/{post_id}/ and reports post_dir_sweep evidence because Divi's native invalidation can leave that directory on disk. Falls back to a targeted filesystem walk of numeric-named et-cache subdirs when the Divi class is absent (backend: "fs_fallback"). Provide exactly one selector — no site-wide default to prevent accidental full flush. Optional cleanup_dynamic_assets=true explicitly deletes and reports _divi_dynamic_assets_cached_feature_used postmeta for the selected target IDs; cleanup_canvas_refs=true also deletes _divi_dynamic_assets_canvases_used and is only appropriate when canvas/off-canvas references are affected. Dynamic-assets postmeta cleanup is supported with post_id or all (bounded to posts that already carry the selected meta keys), not after. Idempotent: missing cache root returns 200 with empty list and repeat postmeta cleanup reports absent keys. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; namespace-specific error codes: meta_flush_cache.unwritable (filesystem refused), meta_flush_cache.fs_init_failed (WP_Filesystem could not authenticate). Pass dry_run: true to preview the change plan without mutating state. Note: in `after` mode the dry-run plan reports the cutoff only — accurate file count requires the live mtime walk.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "post_id": {
      "description": "Flush cache for one post. Native backend clears matching Theme Builder CSS in other post dirs and then physically sweeps wp-content/et-cache/{post_id}/; fs_fallback only clears wp-content/et-cache/{post_id}/.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "all": {
      "default": false,
      "description": "Flush every cached file. Native backend clears archive/taxonomy/home/notfound CSS + multi-layer WP caches; fs_fallback only clears numeric-named subdirs (siblings like .cache-cleared-at, global/, en_US/, notfound/, *.data are preserved in either mode).",
      "type": "boolean"
    },
    "after": {
      "description": "Unix timestamp — flush Divi CSS files (et-*.css) with mtime strictly greater than this value. Useful for flushing entries touched since a known deployment or mutation batch. Native backend does a single-pass filesystem sweep covering numeric post dirs AND archive/taxonomy/home/notfound/global subtrees in one walk (Visual Builder -vb-* runtime CSS preserved); fs_fallback iterates numeric post dirs whose latest file mtime > after. `flushed` lists numeric post_ids whose files were actually deleted; `skipped` lists numeric post_ids that exist but had no files pass the filter.",
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "dry_run": {
      "default": false,
      "description": "When true, return the change plan { summary, changes[, warnings] } without mutating state.",
      "type": "boolean"
    },
    "cleanup_dynamic_assets": {
      "default": false,
      "description": "Explicitly delete and report Divi's _divi_dynamic_assets_cached_feature_used postmeta for the selected post_id, or for all posts that already carry selected dynamic-assets postmeta when all=true. Supported with post_id or all only.",
      "type": "boolean"
    },
    "cleanup_canvas_refs": {
      "default": false,
      "description": "Opt-in canvas/off-canvas cleanup. Requires cleanup_dynamic_assets=true and also deletes _divi_dynamic_assets_canvases_used. Use only when canvas/off-canvas references are affected.",
      "type": "boolean"
    }
  },
  "required": [
    "all",
    "dry_run",
    "cleanup_dynamic_assets",
    "cleanup_canvas_refs"
  ],
  "additionalProperties": false
}
diviops_meta_infoInspect the server, registered tools and connected-site capabilities.Free

Returns DiviOps MCP server identity, server_version, license type, numeric tool_count, registered tool catalog summary, active plugin version summary, WP-CLI allowlist, and plugin handshake/slice state including Pro and FluentCart target readiness. In regular stdio mode, a successful plugin, module, capability, and registered-tool observation is the immutable startup snapshot; failed startup observation is explicitly unavailable and claims no target coverage. Reconnect or restart MCP after supported target changes. Launcher health mode continues to observe target evidence per call. Use as the S0 preflight before dogfooding or product work. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_meta_pingTest the connection to the WordPress site and verify the Divi MCP plugin is active.Free

Test the connection to the WordPress site and verify the Divi MCP plugin is active. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }; success payload is { connected: true, message: "Connected to Divi <version>" } and connection failure surfaces as { ok: false, error: { code: 'wp_error', message } } with the underlying transport message preserved.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
diviops_meta_wp_cliRun a WP-CLI command on the WordPress site.Free

Run a WP-CLI command on the WordPress site. Requires WP_PATH env var (LOCAL_SITE_ID auto-detected from Local by Flywheel), or WP_CLI_CMD for containerized wrappers. Commands validated against a safety allowlist. Default tier covers read ops across options/posts/post-types/taxonomies/users/info/core/db (including targeted `option pluck` and `term meta get/list` reads), non-destructive writes (post/term create+update, post meta read/write, cache/rewrite/transient flush, `plugin update` from authenticated sources), ACF/SCF schema ops (`acf export/import/field-group list/get` plus SCF 6.8.4+ `scf json {status,sync,import,export}` and the `acf json …` aliases), and WXR export. Extended tier (requires DIVIOPS_WP_CLI_ALLOW env var) adds destructive or bulk-modifying ops: option update, post/post meta/term delete, term meta set/update, post term add/set/remove, search-replace, import, plugin activate/deactivate, eval-file. This passthrough has no dry_run, checksum protection or automatic backup/rollback; read back state before retrying a timed-out write. Filesystem-touching commands (`wp export`, `acf export/import`, `scf|acf json export/import`) are additionally constrained: path arguments must resolve under a safe root (defaults to `<WP_PATH>/.diviops-tmp/`, overridable via DIVIOPS_WP_CLI_SAFE_FS_ROOT, disable via DIVIOPS_WP_CLI_UNSAFE_FS=1); `wp export` and `scf json export` require an explicit `--dir=<path>` (or `--stdout`). In WP_CLI_CMD wrapper mode, DIVIOPS_WP_CLI_SAFE_FS_ROOT is required for FS-sensitive commands. Prefer the typed `diviops_scf_*` wrappers for SCF round-trips — they're easier to invoke and accept the same safe-root scoping. Use --format=json for structured output. Full allowlist + tier rationale + filesystem semantics in the MCP server README. Returns the standardized envelope { ok, data?, error: { code, message, hint? } }. Success payload: { stdout: string, stderr: string, exit_code: 0 }. Four failure modes converge on 'meta_wp_cli.command_failed' with error.data = { exit_code: number | null, stdout: string, stderr: string }: (a) numeric exit_code — wp-cli ran and exited non-zero; stdout/stderr are raw streams verbatim. (b) exit_code=null and message starts with 'wp-cli command terminated:' — execFile launched the child but it was killed (timeout or signal); stdout/stderr carry whatever streamed before the kill. (c) exit_code=null and message starts with 'wp-cli could not spawn:' — the OS refused to start the child (ENOENT/EACCES/EPERM); child never ran, stdout/stderr are empty. (d) exit_code=null and message is the rejection reason — pre-execution rejection by the allowlist / FS validator; rejection reason synthesized into error.data.stderr because the child never ran. A missing wp-cli configuration surfaces as 'meta_wp_cli.not_configured'. stdout is always passed through as a string (no server-side JSON parse) — pass --format=json and parse on the caller side when you want structured output.

Input parameters (JSON Schema)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "command": {
      "type": "string",
      "description": "WP-CLI command without the \"wp\" prefix. E.g. \"option get blogname\", \"post list --format=json\", \"export --dir=$DIVIOPS_WP_CLI_SAFE_FS_ROOT --filename_format={site}.{date}.xml\""
    }
  },
  "required": [
    "command"
  ],
  "additionalProperties": false
}

Connect your site and try one focused change

Start on a staging site, give your agent the project context and review the result before publication.