# at.upvote.comment

> Published by [upvote.at](https://lexicon.garden/identity/did:plc:b2bmihikxhdt6s2luzguhexb)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:b2bmihikxhdt6s2luzguhexb/at.upvote.comment)
- [Documentation](https://lexicon.garden/lexicon/did:plc:b2bmihikxhdt6s2luzguhexb/at.upvote.comment/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:b2bmihikxhdt6s2luzguhexb/at.upvote.comment/examples)

## Definitions

### `at.upvote.comment`

**Type**: `record`

A Markdown comment on a canonical subject or a reply to another comment.

**Key**: `tid`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `text` | `string` | Yes | Markdown source. Facet byte ranges refer to this unrendered UTF-8 text. |
| `langs` | `array` | No | BCP 47 language tags for the human-language comment text. |
| `facets` | `array` | No | Annotations over text, especially DID-backed mentions. Indices count UTF-8 bytes. |
| `labels` | `union` | No | Self-applied content labels. |
| `subject` | `string` (uri) | Yes | For a top-level comment, the canonical URI used by at.upvote.signal.subject. For a reply, the AT URI of its direct at.upvote.comment parent. |
| `createdAt` | `string` (datetime) | Yes | Client-declared timestamp when the comment was created. |
| `rootSubject` | `string` (uri) | No | Author-declared discussion resource. The subject is the immediate parent; verify ancestry before using the root for visibility or moderation. |

## Raw Schema

```json
{
  "id": "at.upvote.comment",
  "defs": {
    "main": {
      "key": "tid",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "subject",
          "text",
          "createdAt"
        ],
        "properties": {
          "text": {
            "type": "string",
            "maxLength": 50000,
            "minLength": 1,
            "description": "Markdown source. Facet byte ranges refer to this unrendered UTF-8 text.",
            "maxGraphemes": 5000,
            "minGraphemes": 1
          },
          "langs": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "language"
            },
            "maxLength": 3,
            "description": "BCP 47 language tags for the human-language comment text."
          },
          "facets": {
            "type": "array",
            "items": {
              "ref": "app.bsky.richtext.facet",
              "type": "ref"
            },
            "maxLength": 100,
            "description": "Annotations over text, especially DID-backed mentions. Indices count UTF-8 bytes."
          },
          "labels": {
            "refs": [
              "com.atproto.label.defs#selfLabels"
            ],
            "type": "union",
            "description": "Self-applied content labels."
          },
          "subject": {
            "type": "string",
            "format": "uri",
            "description": "For a top-level comment, the canonical URI used by at.upvote.signal.subject. For a reply, the AT URI of its direct at.upvote.comment parent."
          },
          "createdAt": {
            "type": "string",
            "format": "datetime",
            "description": "Client-declared timestamp when the comment was created."
          },
          "rootSubject": {
            "type": "string",
            "format": "uri",
            "description": "Author-declared discussion resource. The subject is the immediate parent; verify ancestry before using the root for visibility or moderation."
          }
        }
      },
      "description": "A Markdown comment on a canonical subject or a reply to another comment."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
