wordpress-content-manager
WordPress content management via REST API for listing, searching, viewing, creating, updating, and deleting posts (including draft/scheduled/published) with tags and categories. Use when managing WordPress blog content, especially for blog.gbase.com or other sites configured via profiles. Requires Node.js and WordPress REST API credentials.
When & Why to Use This Skill
The WordPress Content Manager skill enables seamless interaction with WordPress sites via the REST API, allowing for comprehensive post management directly through Claude. It supports the full content lifecycle—including listing, searching, creating, updating, and deleting posts—while handling complex metadata like tags, categories, and publication statuses. Designed for efficiency, it supports multiple site profiles and handles both Markdown and HTML content, making it an essential tool for automated blogging and CMS administration.
Use Cases
- Automated Publishing Workflow: Convert AI-generated drafts or research into formatted WordPress posts, automatically assigning categories and tags before scheduling or publishing.
- Bulk Content Updates: Search for specific posts across a site to perform batch updates to titles, statuses, or content, or to clean up outdated drafts using the bulk delete functionality.
- Multi-Site Management: Switch between different blog environments (e.g., production, staging, or different brands) using site-specific profiles to manage diverse content portfolios from a single interface.
- Content Auditing and Retrieval: Quickly list and retrieve existing post data to review editorial history, check SEO metadata, or repurpose old content for new marketing campaigns.
| name | wordpress-content-manager |
|---|---|
| description | WordPress content management via REST API for listing, searching, viewing, creating, updating, and deleting posts (including draft/scheduled/published) with tags and categories. Use when managing WordPress blog content, especially for blog.gbase.com or other sites configured via profiles. Requires Node.js and WordPress REST API credentials. |
| compatibility | Requires Node.js 16+ and npm. Uses WP_USERNAME and WP_APP_PASSWORD (Application Password) for authentication. |
| requires-setup | true |
| default-profile | gbase-blog |
WordPress Content Manager
Manage WordPress posts in a site-agnostic way. This skill defaults to the Gbase blog profile but supports multiple site profiles.
Stage 1: Copy Only (No Install)
Ensure these are present on the target machine/container:
- This skill folder (copied by agent-skills deploy scripts)
- The WordPress CLI tool folder from
X:\core\tools\blog-wordpress
Do not install Node or npm packages at this stage.
Stage 2: Lazy Runtime Setup (Non-Interactive)
Run the setup script the first time the skill is activated. It verifies Node, installs dependencies, and validates access.
Windows (PowerShell)
pwsh ~/.codex/skills/wordpress-content-manager/scripts/setup.ps1
Linux/macOS
bash ~/.codex/skills/wordpress-content-manager/scripts/setup.sh
If you are using Claude Code, replace ~/.codex/skills with ~/.claude/skills.
Profiles and Site Selection
Profiles live under profiles/ in this skill. Select a profile with:
--profile <name>flag- or
WP_PROFILE=<name>env var
If neither is set, the default profile gbase-blog is used.
See references/profiles.md for the profile format and overrides.
Required Environment Variables
WP_USERNAME(WordPress username)WP_APP_PASSWORD(WordPress Application Password)
Optional overrides:
WP_API_URLWP_SITE_URLWP_CLI_PATH(path toblog-wordpressCLI folder)
Commands
All commands are non-interactive and return JSON when --json is set.
Describe Connection
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs site info --json
List or Search Posts
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts list --status publish --search "guitar" --per_page 20 --page 1
View a Post
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts get 123 --json
Create a Post (HTML or Markdown)
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts create \
--title "New Post" \
--content-file ./post.md \
--status draft \
--categories 1,2 \
--tags 5,7
Schedule a Post
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts create \
--title "Scheduled Post" \
--content "<p>HTML body</p>" \
--status future \
--date "2025-01-15T15:30:00"
Update a Post
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts update 123 \
--title "Updated Title" \
--status publish
Delete a Post
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts delete 123
Bulk Delete (Dry-Run First)
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts delete-many \
--status draft \
--search "test" \
--dry-run
node ~/.codex/skills/wordpress-content-manager/scripts/wp-content.mjs posts delete-many \
--status draft \
--search "test" \
--confirm
Future Extensions (Out of Scope for v1)
- Plugin management
- YouTube automation or auto-content plugins
These can be added in a future version or by wrapping a more full-featured WordPress admin tool.