WordPress
Manage posts, pages, media, users, and taxonomies on self-hosted WordPress sites via the REST API.
Overview
Manage posts, pages, media, users, and taxonomies on self-hosted WordPress sites via the REST API.
Prerequisites
- One or more self-hosted WordPress sites (WordPress.com is not supported)
- WordPress 5.6+ with Application Passwords enabled
- A stackgate.ai account
Getting credentials
For each WordPress site:
- In WordPress admin, go to Users → Profile (or the target user).
- Scroll to Application Passwords, enter a label (e.g. "stackgate.ai"), and click Add New Application Password.
- Copy the generated password immediately — it is shown only once.
- In stackgate.ai, open Integrations → WordPress.
- Click Activate and add the site URL, username, and application password.
- stackgate.ai verifies the connection before saving.
You can add multiple sites after the initial connect.
Using with AI clients
- Dedicated endpoint:
POST /mcp/wordpress - Private gateway:
wordpress__*tools (passsiteslug to target a connected site)
upload_media accepts file_id from Temp Storage (from create_file or email/gmail download with store_in_temp_storage=true) as an alternative to source_url or file_base64.
Troubleshooting
- REST API disabled — ensure permalinks are not "plain" and security plugins allow
/wp-json/. - 401 on connect — regenerate the application password; usernames are case-sensitive.
- Wrong site — use the site slug from
list_siteswhen calling other tools.
Available tools
-
create_category
Create a WordPress category.
-
create_comment
Create a WordPress comment.
-
create_page
Create a WordPress page.
-
create_post
Create a new WordPress post.
-
create_tag
Create a WordPress tag.
-
create_user
Create a WordPress user. Requires Administrator role on the connected account.
-
delete_category
Delete a WordPress category.
-
delete_comment
Delete a WordPress comment.
-
delete_media
Delete a WordPress media item.
-
delete_page
Delete a WordPress page.
-
delete_post
Delete a WordPress post (moves to trash unless force is true).
-
delete_tag
Delete a WordPress tag.
-
delete_user
Delete a WordPress user. Requires Administrator role.
-
get_category
Get a WordPress category by ID.
-
get_comment
Get a WordPress comment by ID.
-
get_current_user
Get the currently authenticated WordPress user for a site.
-
get_media
Get a WordPress media item by ID.
-
get_page
Get a WordPress page by ID.
-
get_post
Get a single WordPress post by ID.
-
get_tag
Get a WordPress tag by ID.
-
get_user
Get a WordPress user by ID.
-
list_categories
List WordPress categories.
-
list_comments
List WordPress comments.
-
list_media
List WordPress media items.
-
list_pages
List WordPress pages.
-
list_post_types
List available WordPress post types on a site.
-
list_posts
List WordPress posts with optional search and filters.
-
list_sites
List configured WordPress sites for this account (id, label, site_url).
-
list_tags
List WordPress tags.
-
list_users
List WordPress users. Requires appropriate permissions on the connected account.
-
search_content
Search WordPress content across post types using the global search endpoint.
-
update_category
Update a WordPress category.
-
update_comment
Update a WordPress comment.
-
update_media
Update WordPress media metadata.
-
update_page
Update a WordPress page.
-
update_post
Update an existing WordPress post.
-
update_tag
Update a WordPress tag.
-
update_user
Update a WordPress user.
-
upload_media
Upload media to WordPress via source URL, base64 file content, or temp storage file_id.
MCP endpoint:
https://stackgate.ai/mcp/wordpress
(HTTP) or via the
private gateway.
Related workflows
Multi-integration playbooks that use WordPress to solve concrete business outcomes.
-
Creator loop with YouTube, Search Console, and WordPress
Turn search demand and video performance into WordPress drafts that match what audiences already look for.
-
Temp Storage handoffs between AI tools
Pass files between email, WordPress, and other integrations without manual downloads or re-uploads.