# MessageRef

object type

One inbox message.

## Fields

| Field | Type | Notes |
| --- | --- | --- |
| `id` | [ID](/types/#scalars) `ID!` | No further notes. |
| `toKind` | [MessageSubjectKind](/types/MessageSubjectKind/) `MessageSubjectKind!` | The inbox — YOUR user id (USER) or a team id (TEAM). |
| `toId` | [ID](/types/#scalars) `ID!` | No further notes. |
| `fromKind` | [MessageFromKind](/types/MessageFromKind/) `MessageFromKind!` | No further notes. |
| `fromUserId` | [ID](/types/#scalars) | The sender (USER) or the attributed actor (SYSTEM — null for a pure platform notice). |
| `body` | [String](/types/#scalars) `String!` | No further notes. |
| `targetType` | [String](/types/#scalars) | The optional 'about this record' ref — both present or both null. |
| `targetId` | [ID](/types/#scalars) | No further notes. |
| `createdAt` | [String](/types/#scalars) `String!` | No further notes. |
| `readAt` | [String](/types/#scalars) | USER rows: null = unread; TEAM rows: always null (no per-member read state v1). |

## Used by

- [markMessageRead](/reference/your-own-session/markMessageRead/)
- [sendMessage](/reference/work-and-notes/sendMessage/)
