interface ChatReadState

Returned to the WebSocket route by getChatReadState and markChatRead. The route sends it in welcome and in chat_read_update, and the client shows unread on the chat's badge.

Properties

readAt: string

The created_at of the newest message the user has read.

unread: number

Counts only the messages of other users after readAt.

Usage

import { type ChatReadState } from "api/services/chat-service.ts";