Internal
Constructor for internal use.
The type of PresenceAction the PresenceMessage is for.
The ID of the client that published the PresenceMessage.
The ID of the connection associated with the client that published the PresenceMessage.
The payload of the PresenceMessage.
This will typically be empty as all presence messages received from Ably are automatically decoded client-side using this value. However, if the message encoding cannot be processed, this attribute will contain the remaining transformations not applied to the data payload.
A JSON object of arbitrary key-value pairs that may contain metadata, and/or ancillary payloads. Valid payloads include headers.
A unique ID assigned to each PresenceMessage by Ably.
The time the PresenceMessage was received by Ably, as milliseconds since the Unix epoch.
Static fromDecodes and decrypts a deserialized PresenceMessage-like object using the cipher in ChannelOptions. Any residual transforms that cannot be decoded or decrypted will be in the encoding property. Intended for users receiving messages from a source other than a REST or Realtime channel (for example a queue) to avoid having to parse the encoding string.
The deserialized PresenceMessage-like object to decode and decrypt.
Optional channelOptions: ChannelOptions
A ChannelOptions object containing the cipher.
Static fromDecodes and decrypts an array of deserialized PresenceMessage-like object using the cipher in ChannelOptions. Any residual transforms that cannot be decoded or decrypted will be in the encoding property. Intended for users receiving messages from a source other than a REST or Realtime channel (for example a queue) to avoid having to parse the encoding string.
An array of deserialized PresenceMessage-like objects to decode and decrypt.
Optional channelOptions: ChannelOptions
A ChannelOptions object containing the cipher.
Generated using TypeDoc
Contains an individual presence update sent to, or received from, Ably.