You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/api/model/message.ts
+14Lines changed: 14 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -32,6 +32,20 @@ export interface Message {
32
32
* The body of the message. If the message type is `chat` , `body` will be the text of the chat. If the message type is some sort of media, then this body will be the thumbnail of the media.
33
33
*/
34
34
body: string;
35
+
/**
36
+
* The device ID of the device that sent the message. This is only present if the message was sent from host account-linked session. This is useful for determining if a message was sent from a different mobile device (note that whenever a device) or a desktop session.
37
+
*
38
+
* Note: This will emit a number for the current controlled session also but the only way to know if the number represents the current session is by checking `local` (it will be `true` if the message was sent from the current session).
39
+
*
40
+
* If the device ID is `0` then the message was sent from the "root" host account device.
41
+
*
42
+
* This might be undefined for incoming messages.
43
+
*/
44
+
device: number;
45
+
/**
46
+
* If the message was sent from this controlled session this will be `true`. This is useful for determining if a message was sent from a different mobile device (note that whenever a device) or a desktop session.
47
+
*/
48
+
local: boolean;
35
49
/**
36
50
* a convenient way to get the main text content from a message.
0 commit comments