Create post
wp_create_postCreate a post, page or item of another post type. post_title is required. post_content accepts HTML, blocks or Markdown. The status is draft unless post_status says otherwise, and the type is post unless post_type says otherwise. meta_input sets custom fields.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| post_name | No | ||
| post_type | No | ||
| meta_input | No | Custom fields as key/value pairs. Keys starting with an underscore (WordPress internals) are refused, except the Yoast SEO title, description and focus keyphrase. | |
| post_title | Yes | ||
| post_status | No | ||
| post_content | No | ||
| post_excerpt | No |