{
  "lexicon": 1,
  "id": "net.bisks.catspace.profile",
  "defs": {
    "main": {
      "type": "record",
      "description": "A person's catspace profile page content — cat name, mood, bio, 'now purring to' song, a MySpace-style Top 8, theme choice, and an optional photo. Singleton per repo, written via putRecord create-or-update at rkey \"self\". Rendered at catspace.bisks.net/cat/<handle>. Written and read by catspace (https://catspace.bisks.net).",
      "key": "literal:self",
      "record": {
        "type": "object",
        "required": ["catName", "mood", "bio", "song", "theme", "top8", "updatedAt"],
        "properties": {
          "catName": {
            "type": "string",
            "maxLength": 160,
            "maxGraphemes": 40,
            "description": "The cat's name. UI input caps at 40 characters; falls back to \"Unnamed Cat\" if left blank."
          },
          "mood": {
            "type": "string",
            "maxLength": 120,
            "maxGraphemes": 40,
            "description": "Current mood, chosen from a fixed dropdown in the UI (e.g. \"Purring\", \"Zoomies\", \"Judging You\", \"Loaf Mode\", \"Feral\", \"Napping (again)\", \"Plotting\", \"Knocking Something Off A Shelf\"). Not enforced as an enum here since the dropdown options are UI-side and may grow."
          },
          "bio": {
            "type": "string",
            "maxLength": 2000,
            "maxGraphemes": 500,
            "description": "Free-text 'about me' bio. UI textarea caps at 500 characters."
          },
          "song": {
            "type": "string",
            "maxLength": 320,
            "maxGraphemes": 80,
            "description": "The 'now purring to' song field. UI input caps at 80 characters."
          },
          "theme": {
            "type": "string",
            "maxLength": 40,
            "description": "Id of the chosen page theme, one of a fixed set defined client-side (bubblegum, midnight-disco, matrix-kitten, static-tv, cosmic-cat, cheddar). Defaults to \"bubblegum\"."
          },
          "top8": {
            "type": "array",
            "maxLength": 8,
            "items": { "type": "string", "maxLength": 240, "maxGraphemes": 60 },
            "description": "Up to 8 handles for the Top 8 friends list, in order. Each entry is a handle as typed by the user (leading '@' stripped client-side, not otherwise validated against a real account)."
          },
          "photo": {
            "type": "blob",
            "accept": ["image/*"],
            "description": "Optional cover photo, uploaded via com.atproto.repo.uploadBlob before saving the profile. No client-side size cap beyond the PDS's own blob limits."
          },
          "updatedAt": {
            "type": "string",
            "format": "datetime",
            "description": "When this profile was last saved, as an ISO 8601 datetime."
          }
        }
      }
    }
  }
}
