{
"id": "social.coves.community.comment.defs",
"defs": {
"postRef": {
"type": "object",
"required": [
"uri",
"cid"
],
"properties": {
"cid": {
"type": "string",
"format": "cid",
"description": "CID of the post record"
},
"uri": {
"type": "string",
"format": "at-uri",
"description": "AT-URI of the post"
}
},
"description": "Reference to a post record"
},
"commentRef": {
"type": "object",
"required": [
"uri",
"cid"
],
"properties": {
"cid": {
"type": "string",
"format": "cid",
"description": "CID of the comment record"
},
"uri": {
"type": "string",
"format": "at-uri",
"description": "AT-URI of the comment"
}
},
"description": "Reference to a comment record"
},
"commentView": {
"type": "object",
"required": [
"uri",
"cid",
"author",
"record",
"post",
"createdAt",
"indexedAt",
"stats"
],
"properties": {
"cid": {
"type": "string",
"format": "cid",
"description": "CID of the comment record"
},
"uri": {
"type": "string",
"format": "at-uri",
"description": "AT-URI of the comment record"
},
"post": {
"ref": "#postRef",
"type": "ref",
"description": "Reference to the parent post"
},
"embed": {
"refs": [
"social.coves.embed.images",
"social.coves.embed.post"
],
"type": "union",
"description": "Embedded content from the comment record (images or quoted post). The AppView may transform blob references into fetchable URLs and enrich quoted posts with a resolved view."
},
"stats": {
"ref": "#commentStats",
"type": "ref",
"description": "Comment statistics (votes, replies)"
},
"author": {
"ref": "social.coves.community.post.defs#authorView",
"type": "ref",
"description": "Comment author information"
},
"parent": {
"ref": "#commentRef",
"type": "ref",
"description": "Reference to parent comment if this is a nested reply"
},
"record": {
"type": "unknown",
"description": "The actual comment record verbatim"
},
"viewer": {
"ref": "#commentViewerState",
"type": "ref",
"description": "Viewer-specific state (vote, saved, etc.)"
},
"createdAt": {
"type": "string",
"format": "datetime",
"description": "When the comment was created"
},
"indexedAt": {
"type": "string",
"format": "datetime",
"description": "When this comment was indexed by the AppView"
}
},
"description": "Base view for a single comment with voting, stats, and viewer state"
},
"commentStats": {
"type": "object",
"required": [
"upvotes",
"downvotes",
"score",
"replyCount"
],
"properties": {
"score": {
"type": "integer",
"description": "Calculated score (upvotes - downvotes)"
},
"upvotes": {
"type": "integer",
"minimum": 0,
"description": "Number of upvotes"
},
"downvotes": {
"type": "integer",
"minimum": 0,
"description": "Number of downvotes"
},
"replyCount": {
"type": "integer",
"minimum": 0,
"description": "Number of direct replies to this comment"
}
},
"description": "Statistics for a comment"
},
"blockedComment": {
"type": "object",
"required": [
"uri",
"blocked"
],
"properties": {
"uri": {
"type": "string",
"format": "at-uri",
"description": "AT-URI of the blocked comment"
},
"blocked": {
"type": "boolean",
"const": true,
"description": "Always true for blocked comments"
},
"blockedBy": {
"type": "string",
"maxLength": 64,
"description": "What caused the block: viewer blocked author, or comment was removed by moderators",
"knownValues": [
"author",
"moderator"
]
}
},
"description": "Comment is blocked due to viewer blocking author or moderation action"
},
"notFoundComment": {
"type": "object",
"required": [
"uri",
"notFound"
],
"properties": {
"uri": {
"type": "string",
"format": "at-uri",
"description": "AT-URI of the missing comment"
},
"notFound": {
"type": "boolean",
"const": true,
"description": "Always true for not found comments"
}
},
"description": "Comment was not found (deleted, never indexed, or invalid URI)"
},
"threadViewComment": {
"type": "object",
"required": [
"comment"
],
"properties": {
"comment": {
"ref": "#commentView",
"type": "ref",
"description": "The comment itself"
},
"hasMore": {
"type": "boolean",
"description": "True if more replies exist but are not included in this response"
},
"replies": {
"type": "array",
"items": {
"refs": [
"#threadViewComment",
"#notFoundComment",
"#blockedComment"
],
"type": "union"
},
"description": "Nested replies to this comment"
}
},
"description": "Wrapper for threaded comment structure, similar to Bluesky's threadViewPost pattern"
},
"commentViewerState": {
"type": "object",
"properties": {
"vote": {
"type": "string",
"maxLength": 64,
"description": "Viewer's vote on this comment",
"knownValues": [
"up",
"down"
]
},
"voteUri": {
"type": "string",
"format": "at-uri",
"description": "AT-URI of the viewer's vote record"
}
},
"description": "Viewer-specific state for a comment"
}
},
"$type": "com.atproto.lexicon.schema",
"lexicon": 1
}