placeStreamChatDefs top-level constant

Map<String, dynamic> const placeStreamChatDefs

place.stream.chat.defs

Implementation

const placeStreamChatDefs = <String, dynamic>{
  "lexicon": 1,
  "id": "place.stream.chat.defs",
  "defs": {
    "messageView": {
      "type": "object",
      "required": ["uri", "cid", "author", "record", "indexedAt"],
      "properties": {
        "cid": {"type": "string", "format": "cid"},
        "uri": {"type": "string", "format": "at-uri"},
        "author": {
          "type": "ref",
          "ref": "app.bsky.actor.defs#profileViewBasic",
        },
        "badges": {
          "type": "array",
          "description":
              "Up to 3 badge tokens to display with the message. First badge is server-controlled, remaining badges are user-settable. Tokens are looked up in badges.json for display info.",
          "items": {"type": "ref", "ref": "place.stream.badge.defs#badgeView"},
          "maxLength": 3,
        },
        "record": {"type": "unknown"},
        "deleted": {
          "type": "boolean",
          "description":
              "If true, this message has been deleted or labeled and should be cleared from the cache",
        },
        "replyTo": {
          "type": "union",
          "refs": ["#messageView"],
        },
        "indexedAt": {"type": "string", "format": "datetime"},
        "chatProfile": {"type": "ref", "ref": "place.stream.chat.profile"},
      },
    },
    "pinnedRecordView": {
      "type": "object",
      "description": "View of a pinned chat record with hydrated message data.",
      "required": ["uri", "cid", "record", "indexedAt"],
      "properties": {
        "cid": {"type": "string", "format": "cid"},
        "uri": {"type": "string", "format": "at-uri"},
        "record": {"type": "ref", "ref": "place.stream.chat.pinnedRecord"},
        "message": {"type": "ref", "ref": "#messageView"},
        "pinnedBy": {"type": "ref", "ref": "place.stream.chat.profile"},
        "indexedAt": {"type": "string", "format": "datetime"},
      },
    },
  },
};