WordPress · JSON Structure

Wordpress Post Type Structure

A WordPress registered post type

Type: object Properties: 7
CMSContent ManagementOpen SourceWordPress

PostType is a JSON Structure definition published by WordPress, describing 7 properties. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.

Properties

capabilities description hierarchical name rest_base slug taxonomies

Meta-schema: https://json-structure.org/meta/core/v0/#

JSON Structure

Raw ↑
{
  "$schema": "https://json-structure.org/meta/core/v0/#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/wordpress/refs/heads/main/json-structure/wordpress-post-type-structure.json",
  "name": "PostType",
  "description": "A WordPress registered post type",
  "type": "object",
  "properties": {
    "capabilities": {
      "type": "object",
      "description": "All capabilities used by the post type",
      "additionalProperties": {
        "type": "string"
      }
    },
    "description": {
      "type": "string",
      "description": "A human-readable description of the post type",
      "example": ""
    },
    "hierarchical": {
      "type": "boolean",
      "description": "Whether or not the post type should have children",
      "example": false
    },
    "name": {
      "type": "string",
      "description": "Human-readable name of the post type, e.g., Posts",
      "example": "Posts"
    },
    "rest_base": {
      "type": "string",
      "description": "REST base route for the post type",
      "example": "posts"
    },
    "slug": {
      "type": "string",
      "description": "An alphanumeric identifier for the post type",
      "example": "post"
    },
    "taxonomies": {
      "type": "array",
      "description": "All taxonomies associated with the post type",
      "items": {
        "type": "string"
      },
      "example": [
        "category",
        "post_tag"
      ]
    }
  }
}