# org.swappulse.directMessage

> Published by [bridge.swappulse.org](https://lexicon.garden/identity/did:plc:jwoatauidzr4lollmro2gh35)

## Description

A single message in a 1:1 conversation, mirrored to AT Protocol as a real org.swappulse.directMessage record. The sender is tracked by authorDid; the recipient by recipientDid so both can read.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:jwoatauidzr4lollmro2gh35/org.swappulse.directMessage)
- [Documentation](https://lexicon.garden/lexicon/did:plc:jwoatauidzr4lollmro2gh35/org.swappulse.directMessage/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:jwoatauidzr4lollmro2gh35/org.swappulse.directMessage/examples)

## Definitions

### `org.swappulse.directMessage`

**Type**: `record`

A direct message in a conversation.

**Key**: `tid`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `body` | `string` | Yes |  |
| `read` | `boolean` | No |  |
| `authorDid` | `string` (did) | No |  |
| `createdAt` | `string` (datetime) | Yes |  |
| `authorName` | `string` | No |  |
| `authorAvatar` | `string` (uri) | No |  |
| `authorHandle` | `string` | No |  |
| `recipientDid` | `string` (did) | Yes |  |
| `conversationId` | `string` | No |  |
| `conversationRef` | `string` (at-uri) | No |  |

## Raw Schema

```json
{
  "id": "org.swappulse.directMessage",
  "defs": {
    "main": {
      "key": "tid",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "recipientDid",
          "body",
          "createdAt"
        ],
        "properties": {
          "body": {
            "type": "string",
            "maxLength": 2000
          },
          "read": {
            "type": "boolean"
          },
          "authorDid": {
            "type": "string",
            "format": "did"
          },
          "createdAt": {
            "type": "string",
            "format": "datetime"
          },
          "authorName": {
            "type": "string"
          },
          "authorAvatar": {
            "type": "string",
            "format": "uri"
          },
          "authorHandle": {
            "type": "string"
          },
          "recipientDid": {
            "type": "string",
            "format": "did"
          },
          "conversationId": {
            "type": "string"
          },
          "conversationRef": {
            "type": "string",
            "format": "at-uri"
          }
        }
      },
      "description": "A direct message in a conversation."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1,
  "revision": 1,
  "description": "A single message in a 1:1 conversation, mirrored to AT Protocol as a real org.swappulse.directMessage record. The sender is tracked by authorDid; the recipient by recipientDid so both can read."
}
```
