Skip to main content
Glama

Frontman for WordPress

wp_elementor_add_element

Destructive

Adds a new Elementor subtree in one save with a private rollback. Use after_element_id: "book-demo" to insert immediately after a unique sibling, excluding any explicit parent_id or position. Alternatively use parent_id and position. Prefer wp_elementor_generate_element; do not pass element: {}.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "site_id": "<site_id>",
      "post_id": "<post_id>",
      "element": "<element>"
    },
    "name": "wp_elementor_add_element"
  }
}

Input Schema

NameRequiredDescriptionDefault
elementYesElementor subtree: elType is required, and widgets require widgetType. IDs can be omitted at every depth and are generated automatically.
post_idYes
site_idYesThe connected site's id returned by list_sites. Call list_sites first; do not use a URL or WordPress post ID.
positionNo
parent_idNo
after_element_idNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and non-idempotent, so the safety profile is known; the description adds real context beyond that with the atomic single-save plus private rollback behavior, which materially changes how risky the mutation feels. It stops short of saying how to locate or restore that rollback (siblings list_rollbacks/restore_rollback exist), which would have completed the picture.

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

Conciseness4/5

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

Three front-loaded sentences, each carrying distinct information (capability, positioning modes, sibling preference plus a validation warning). The illustrative "book-demo" value is slightly noisy but functional as an example of a unique sibling id.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 6-parameter mutation tool with nested element objects and no output schema, the description covers the modal behavior, the mutual exclusion rule, and one concrete validation failure. What remains thin is the return value and rollback retrieval, which are not stated anywhere else in the structured fields.

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

Parameters4/5

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

With schema coverage at only 33%, the description compensates well: it defines the semantics of after_element_id and its mutual exclusion with parent_id/position, and warns against passing an empty element object. post_id and the numeric position are still left to the schema, so it is not exhaustive.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ("Adds a new Elementor subtree") plus the execution model ("in one save with a private rollback"). It also names the preferred sibling wp_elementor_generate_element, so an agent can tell which of the two element-creation tools to reach for without opening either schema.

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

Usage Guidelines4/5

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

Gives explicit insertion-mode guidance: after_element_id to insert behind a unique sibling, explicitly excluding parent_id/position in that mode, and the alternative parent_id + position mode. The one gap is that "Prefer wp_elementor_generate_element" gives no condition explaining when this tool is the right choice instead.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.