Import Library Section is a WordPress ability from Page Builder: Pagelayer – Drag and Drop website builder — usable via Easy MCP AI, which connects Claude, ChatGPT, and any AI assistant to your site.

Install Free Plugin →

Import Library Section

Write

Import an official PopularFX/PageLayer library section by ID and append it directly into a post or page's content.

Requires the Pagelayer plugin on WordPress 6.9+ (or another source of wp_register_ability()) for the Abilities API — registration is skipped entirely via a function_exists() guard when it isn't available, and ability categories similarly require wp_register_ability_category(). Most abilities require the 'edit_posts' capability; update-global-styles, create-menu, and delete-menu require 'manage_options'. search-images additionally needs a Pexels API key configured on the Pagelayer AI Agents settings page, and get-library-sections/import-library-section call Pagelayer's own hosted library API. Four near-duplicate abilities (get-widget, get-widgets-summary, edit-layout, navigator) are registered in source with mcp_public:false — fully callable over the REST Abilities API but intentionally left out of the advertised MCP tool list as duplicates of get-widget-schema, list-widgets, update-page, and get-page respectively — and are excluded from this listing.

What it does

Fetches a section's markup from Pagelayer's remote library API using the site's license key, sideloads any images it references into the Media Library, and appends the resulting block markup onto the target post's post_content. Requires a valid section_id (from get-library-sections) and an existing post_id, and returns an error if the section data could not be retrieved from the remote library.

See it in action

You ask your AI assistant

"Import library section "hero-42" into page 128."

Inputs

Name Type Required Description
section_id string Yes Library section ID.
post_id integer Yes Target post/page ID.

Returns

An object with success (boolean), section_id, post_id, and url (the post's permalink) on success, or a WP_Error on invalid input or a failed remote fetch.

Permission

Requires the 'edit_posts' capability.

Newsletter

The AI + WordPress space moves fast. Keep up.

New tools, workflow ideas, and product updates — be the first to know what's next.

No spam, unsubscribe anytime.