Create content
create_contentCreate WordPress posts, pages, or custom post types as drafts or publish directly. Assign taxonomy terms by name, auto-creating missing ones for your site.
Instructions
Create a post, page, or any custom post type. Content is created as a DRAFT unless you explicitly pass status: "publish" — this server never publishes to a live site implicitly. Taxonomy terms can be given by name and are created if missing.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| date | No | Publish date in site time, ISO 8601 (2026-01-31T09:00:00). With status "future" this schedules the post. | |
| meta | No | Custom fields, as key/value pairs. A key only writes if it is registered with show_in_rest — use set_content_meta for unregistered keys. | |
| slug | No | URL slug. Changing this on published content breaks existing links unless you add a redirect. | |
| type | No | Content type to create. | post |
| terms | No | Taxonomy assignments keyed by taxonomy REST base, e.g. {"categories": [3], "tags": ["news"]}. Names that do not exist yet are created. | |
| title | No | The title, as plain text. | |
| author | No | User ID of the author. | |
| format | No | Post format: standard, aside, gallery, link, image, quote, status, video, audio, chat. | |
| parent | No | Parent ID, for hierarchical types such as pages. | |
| status | No | publish | future | draft | pending | private | trash. | |
| sticky | No | Pin the post to the top of the blog. Posts only. | |
| content | No | Full content body, replacing whatever is there. For the block editor this is block markup (<!-- wp:paragraph --><p>…</p><!-- /wp:paragraph -->); classic content is plain HTML. Use `edits` instead for a small change. | |
| excerpt | No | Hand-written excerpt. | |
| site_id | No | Which configured WordPress site to act on. Optional — with a single site configured it is used automatically; with several, the default site is used unless you name one. Run list_sites for valid ids. | |
| password | No | Password-protect the content. | |
| template | No | Page template file, e.g. "templates/full-width.php". | |
| menu_order | No | Sort order for hierarchical types. | |
| ping_status | No | Whether pingbacks and trackbacks are accepted. | |
| comment_status | No | Whether comments are open on this item. | |
| featured_media | No | Attachment ID of the featured image. Upload it with create_media first. |