{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "A single diary entry: the user watched a movie or TV work at a point in time, with free-form tags. Adds the per-watch diary layer on top of the Popfeed listItem record referenced by 'subject'.",
      "key": "tid",
      "record": {
        "properties": {
          "createdAt": {
            "description": "When this record was created.",
            "format": "datetime",
            "type": "string"
          },
          "episode": {
            "description": "Episode number, for TV watches.",
            "type": "integer"
          },
          "mediaType": {
            "description": "Denormalized media type of the work.",
            "enum": [
              "movie",
              "tv"
            ],
            "type": "string"
          },
          "note": {
            "description": "Optional short note about the watch.",
            "maxGraphemes": 300,
            "maxLength": 3000,
            "type": "string"
          },
          "rewatch": {
            "description": "Whether this watch was a rewatch.",
            "type": "boolean"
          },
          "season": {
            "description": "Season number, for TV watches.",
            "type": "integer"
          },
          "subject": {
            "description": "Strong reference to the social.popfeed.feed.listItem record for this work.",
            "ref": "com.atproto.repo.strongRef",
            "type": "ref"
          },
          "tags": {
            "description": "Free-form, lowercase, trimmed tags applied to this watch.",
            "items": {
              "maxGraphemes": 64,
              "maxLength": 640,
              "type": "string"
            },
            "maxLength": 64,
            "type": "array"
          },
          "tmdbId": {
            "description": "Denormalized TMDB id of the work, for resilience if the subject cannot be resolved.",
            "type": "string"
          },
          "watchedAt": {
            "description": "When the watch happened.",
            "format": "datetime",
            "type": "string"
          }
        },
        "required": [
          "subject",
          "tmdbId",
          "mediaType",
          "watchedAt",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "id": "computer.sims.log.watch",
  "lexicon": 1
}
