{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/frase-io/json-schema/frase-io-cms-post-schema.json",
  "title": "CmsPost",
  "x-generated": "2026-11-09",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/frase-io-openapi.json#/components/schemas/CmsPost",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "site_id": {
      "type": "string",
      "format": "uuid"
    },
    "slug": {
      "type": "string"
    },
    "type": {
      "type": "string",
      "enum": [
        "blog_post",
        "page"
      ]
    },
    "title": {
      "type": "string"
    },
    "content": {
      "type": "string",
      "description": "HTML content"
    },
    "excerpt": {
      "type": [
        "string",
        "null"
      ]
    },
    "featured_image": {
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "seo_title": {
      "type": [
        "string",
        "null"
      ]
    },
    "seo_description": {
      "type": [
        "string",
        "null"
      ]
    },
    "focus_keyword": {
      "type": [
        "string",
        "null"
      ]
    },
    "canonical_url": {
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "schema_markup": {
      "type": [
        "object",
        "null"
      ],
      "description": "JSON-LD structured data for the post. Must include `@context` and `@type`. Additional properties depend on the chosen schema type. See [schema.org](https://schema.org) for full type definitions.",
      "properties": {
        "@context": {
          "type": "string",
          "default": "https://schema.org",
          "description": "Schema.org context URL. Almost always `https://schema.org`."
        },
        "@type": {
          "type": "string",
          "description": "The schema.org type for this content.",
          "enum": [
            "Article",
            "BlogPosting",
            "NewsArticle",
            "FAQPage",
            "HowTo",
            "TechArticle",
            "WebPage"
          ]
        },
        "headline": {
          "type": "string",
          "description": "The headline of the article. Recommended for Article, BlogPosting, NewsArticle.",
          "maxLength": 110
        },
        "description": {
          "type": "string",
          "description": "A short description or summary of the content."
        },
        "author": {
          "oneOf": [
            {
              "type": "object",
              "description": "Author as a Person or Organization.",
              "properties": {
                "@type": {
                  "type": "string",
                  "enum": [
                    "Person",
                    "Organization"
                  ]
                },
                "name": {
                  "type": "string"
                },
                "url": {
                  "type": "string",
                  "format": "uri"
                }
              }
            },
            {
              "type": "array",
              "description": "Multiple authors.",
              "items": {
                "type": "object",
                "properties": {
                  "@type": {
                    "type": "string",
                    "enum": [
                      "Person",
                      "Organization"
                    ]
                  },
                  "name": {
                    "type": "string"
                  },
                  "url": {
                    "type": "string",
                    "format": "uri"
                  }
                }
              }
            }
          ]
        },
        "datePublished": {
          "type": "string",
          "format": "date",
          "description": "Original publication date in ISO 8601 format (e.g., `2026-04-16`)."
        },
        "dateModified": {
          "type": "string",
          "format": "date",
          "description": "Last modification date in ISO 8601 format."
        },
        "image": {
          "oneOf": [
            {
              "type": "string",
              "format": "uri"
            },
            {
              "type": "object",
              "properties": {
                "@type": {
                  "type": "string",
                  "enum": [
                    "ImageObject"
                  ]
                },
                "url": {
                  "type": "string",
                  "format": "uri"
                },
                "width": {
                  "type": "integer"
                },
                "height": {
                  "type": "integer"
                }
              }
            }
          ],
          "description": "Primary image. Can be a URL string or an ImageObject."
        },
        "publisher": {
          "type": "object",
          "description": "The publisher of the content.",
          "properties": {
            "@type": {
              "type": "string",
              "enum": [
                "Organization"
              ]
            },
            "name": {
              "type": "string"
            },
            "logo": {
              "type": "object",
              "properties": {
                "@type": {
                  "type": "string",
                  "enum": [
                    "ImageObject"
                  ]
                },
                "url": {
                  "type": "string",
                  "format": "uri"
                }
              }
            }
          }
        },
        "mainEntity": {
          "description": "Primary entity of the page. Used by FAQPage (array of Question) and HowTo (HowToStep array).",
          "oneOf": [
            {
              "type": "array",
              "description": "For FAQPage: array of Question objects.",
              "items": {
                "type": "object",
                "properties": {
                  "@type": {
                    "type": "string",
                    "enum": [
                      "Question"
                    ]
                  },
                  "name": {
                    "type": "string",
                    "description": "The question text."
                  },
                  "acceptedAnswer": {
                    "type": "object",
                    "properties": {
                      "@type": {
                        "type": "string",
                        "enum": [
                          "Answer"
                        ]
                      },
                      "text": {
                        "type": "string",
                        "description": "The answer text."
                      }
                    }
                  }
                }
              }
            },
            {
              "type": "object"
            }
          ]
        },
        "step": {
          "type": "array",
          "description": "For HowTo: ordered list of steps.",
          "items": {
            "type": "object",
            "properties": {
              "@type": {
                "type": "string",
                "enum": [
                  "HowToStep"
                ]
              },
              "name": {
                "type": "string",
                "description": "Step title."
              },
              "text": {
                "type": "string",
                "description": "Step instructions."
              },
              "image": {
                "type": "string",
                "format": "uri"
              }
            }
          }
        }
      },
      "additionalProperties": true
    },
    "status": {
      "type": "string",
      "enum": [
        "draft",
        "published",
        "scheduled"
      ]
    },
    "published_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "meta": {
      "type": [
        "object",
        "null"
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "primary_author": {
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "avatar_url": {
          "type": [
            "string",
            "null"
          ],
          "format": "uri"
        },
        "bio": {
          "type": [
            "string",
            "null"
          ]
        },
        "role": {
          "type": [
            "string",
            "null"
          ],
          "description": "e.g. \"Head of Content\". Set on author creation only; a re-import never overwrites an existing author's role."
        }
      },
      "required": [
        "id",
        "name",
        "slug"
      ],
      "description": "Primary/canonical author, or null."
    },
    "authors": {
      "type": "array",
      "description": "Byline authors (incl. the primary), ordered by position.",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "position": {
            "type": "integer"
          },
          "avatar_url": {
            "type": [
              "string",
              "null"
            ],
            "format": "uri"
          },
          "role": {
            "type": [
              "string",
              "null"
            ],
            "description": "e.g. \"Head of Content\". Set on author creation only; a re-import never overwrites an existing author's role."
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "position"
        ]
      }
    },
    "category": {
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "parent_id": {
          "type": [
            "string",
            "null"
          ],
          "format": "uuid"
        }
      },
      "required": [
        "id",
        "name",
        "slug"
      ],
      "description": "Single category, or null."
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "slug"
        ]
      }
    }
  }
}