{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "A forum topic (thread root) on Asteri, stored in the author's own repo.",
      "key": "tid",
      "record": {
        "properties": {
          "board": {
            "description": "Board slug, e.g. sophia, astra, pleroma, terra, simulacra, sacra, umbra.",
            "maxLength": 40,
            "type": "string"
          },
          "createdAt": {
            "format": "datetime",
            "type": "string"
          },
          "media": {
            "description": "Images attached to the topic, stored as blobs in the author's repo.",
            "items": {
              "ref": "#mediaItem",
              "type": "ref"
            },
            "maxItems": 4,
            "type": "array"
          },
          "pollOptions": {
            "description": "Present (2-6 items) when the topic is a poll.",
            "items": {
              "maxLength": 80,
              "type": "string"
            },
            "maxItems": 6,
            "type": "array"
          },
          "tags": {
            "items": {
              "maxLength": 60,
              "type": "string"
            },
            "maxItems": 3,
            "type": "array"
          },
          "text": {
            "description": "Body text; may contain the site's sanitized subset of HTML.",
            "maxGraphemes": 5000,
            "maxLength": 50000,
            "type": "string"
          },
          "title": {
            "maxGraphemes": 150,
            "maxLength": 1500,
            "type": "string"
          },
          "url": {
            "format": "uri",
            "maxLength": 2000,
            "type": "string"
          }
        },
        "required": [
          "title",
          "board",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    },
    "mediaItem": {
      "properties": {
        "alt": {
          "maxGraphemes": 1000,
          "maxLength": 2000,
          "type": "string"
        },
        "image": {
          "accept": [
            "image/png",
            "image/jpeg",
            "image/webp",
            "image/gif",
            "image/avif"
          ],
          "maxSize": 5000000,
          "type": "blob"
        }
      },
      "required": [
        "image",
        "alt"
      ],
      "type": "object"
    }
  },
  "id": "ca.astronomi.boards.post",
  "lexicon": 1
}
