Build Complete Layout is a WordPress ability from Ultimate Addons for Elementor — usable via Easy MCP AI, which connects Claude, ChatGPT, and any AI assistant to your site.
Install Free Plugin →Build Complete Layout
DestructiveBuilds a complete Elementor layout — sections, columns, and widgets — from a single JSON structure, replacing all existing content on the target post.
Requires the Ultimate Addons for Elementor (Header Footer & Elementor) plugin on WordPress 6.9+ (the WP Abilities API). No ability registers unless the plugin's 'Enable AI Tools' master switch (uae_mcp_settings.enable_abilities) is turned on in settings. Most abilities require the 'manage_options' capability; a smaller set of read/discovery abilities (template and page listing, the Elementor builder read/list/schema abilities, active-template lookup, display-rule locations, and design tokens) instead require only 'edit_posts' or 'read'. Abilities that act on a specific page, post, or template additionally check the current user's per-object 'edit_post' (or 'delete_post') capability on that item. Separately, every non-readonly (Write or Destructive) ability is gated behind a site-wide 'Allow Modifications' setting at registration time: if it is off, none of those abilities are even registered with the WP Abilities API, regardless of capability checks — this covers all template/page CRUD, widget/extension toggles, display-rule updates, theme/settings changes, and the Elementor builder writes alike, not just the builder ones. Eight of those abilities (the seven Elementor page-builder writes — build, insert-widget, update-widget, remove-element, move-element, add-section, add-column — plus pages-create) additionally re-check this same setting explicitly inside execute() as a redundant safeguard.
What it does
Given a post_id and a structure (a JSON string describing an array of section objects with columns, settings, column_settings, and children widgets), the handler decodes and validates the structure, converts each section definition into an Elementor element tree, and writes the result to the post, overwriting its existing '_elementor_data'. It works on any Elementor-enabled post (page, post, or HFE header/footer template), not just HFE templates. It is marked destructive and idempotent, and its instructions tell the calling AI to fetch design tokens, widget types, and schemas first, then call this once instead of chaining insert/add-section calls, and to call builder-regenerate-css afterward.
See it in action
You ask your AI assistant
"Build a new header for post 42 with a dark 3-column layout: logo on the left, a horizontal nav menu in the center, and a search icon on the right."
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
| post_id | integer | Yes | Any Elementor-enabled post ID (page, post, or HFE template). |
| structure | string | Yes | A minified JSON string describing an array of section objects (columns, settings, column_settings, children widgets with widget_type/settings). |
Returns
Returns success, the detected layout_mode ('container' or 'section'), the element_count created, a simplified structure tree of the new elements, and a human-readable message.
Permission
permission_callback requires current_user_can('edit_posts'); execute() also calls check_modifications_allowed() (blocks with 403 unless the 'Allow Modifications' AI Tools setting is enabled) and validate_elementor_post() (confirms the post is Elementor-editable and checks current_user_can('edit_post', ID) for that specific post).
More Ultimate Addons for Elementor abilities
Activate Widget
Enables a specific HFE widget by its slug.
Add Column to Section
Adds a new column to an existing section or container in an Elementor post, redistributing column widths automatically.
Add Section/Container
Adds a new structural layout element (a section with columns on legacy sites, or a flex container on container-mode sites) to an Elementor post.
Bulk Toggle All Widgets
Activates or deactivates every HFE widget at once.
Clear Elementor Cache
Clears the Elementor CSS cache globally to regenerate all stylesheets.
Create Page
Creates a new Elementor-ready page or post with optional page template.