interface PresenceEvent {
    id: string;
    isContact?: boolean;
    isGroup: boolean;
    isOnline: boolean;
    isUser: boolean;
    participants?: {
        id: string;
        shortName: string;
        state:
            | "available"
            | "composing"
            | "recording"
            | "unavailable";
    }[];
    state:
        | "available"
        | "composing"
        | "recording"
        | "unavailable";
    t: number;
}

Properties

id: string

ID of contact or group

isContact?: boolean

If is an user, check is a contact

isGroup: boolean
isOnline: boolean
isUser: boolean
participants?: {
    id: string;
    shortName: string;
    state:
        | "available"
        | "composing"
        | "recording"
        | "unavailable";
}[]
state:
    | "available"
    | "composing"
    | "recording"
    | "unavailable"
t: number

Timestramp of event Date.now()