{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cubi-estate/json-schema/cubi-estate-admin-publish-update-request-schema.json",
  "title": "AdminPublishUpdateRequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cubi-estate-admin-api-openapi.yml#/components/schemas/AdminPublishUpdateRequest",
  "properties": {
    "title": {
      "type": "string",
      "title": "Title",
      "description": "Headline. Web blog uses it as the title; Telegram gets it as a bold first line."
    },
    "body": {
      "type": "string",
      "title": "Body",
      "description": "Rich HTML body. Sent verbatim to blog/email; auto-converted to Telegram-safe HTML for the channel."
    },
    "targets": {
      "items": {
        "type": "string",
        "enum": [
          "blog",
          "channel",
          "subscribers",
          "email",
          "x"
        ]
      },
      "type": "array",
      "title": "Targets",
      "description": "Where to publish. Split automatically by renderer; 'whatsapp' is not supported here."
    },
    "lang": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Lang",
      "description": "ISO 639-1 tag (audit; body sent as-is).",
      "default": "en"
    },
    "dedup_key": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Dedup Key",
      "description": "Idempotency key; suffixed -web/-tg per send so a re-fire is a no-op."
    },
    "dry_run": {
      "type": "boolean",
      "title": "Dry Run",
      "description": "Render + validate + show the converted Telegram body, send nothing.",
      "default": false
    }
  },
  "type": "object",
  "required": [
    "title",
    "body"
  ]
}