InboundMessage

public class InboundMessage : CustomStringConvertible, Sendable

An inbound message (whether from another user or as a sync message from self)

  • Device that sent the message (note that this would be one of ours if it is a sync message)

    Declaration

    Swift

    public var source: SignalAddress
  • Timestamp of the sent message

    Declaration

    Swift

    public var timestamp: Date
  • Expiration of the message in seconds, if provided

    Declaration

    Swift

    public var expiration: TimeInterval?
  • How long the message was retained by the Signal server before it was received here

    Declaration

    Swift

    public var serverAge: TimeInterval
  • Timestamp for when the Signal server received the message (useful for correcting clock skew)

    Declaration

    Swift

    public var serverReceived: Date
  • Whether the end-session flag was set in the envelope

    Declaration

    Swift

    public var endSessionFlag: Bool
  • Whether the expiration-timer-update flag was set in the envelope

    Declaration

    Swift

    public var expirationTimerUpdateFlag: Bool
  • A ForstaPayloadV1 initialized with the the inbound message’s envelope body

    Declaration

    Swift

    public var payload: ForstaPayloadV1
  • Information about any associated attachments – use SignalClient.fetchAttachment() to retrieve and decrypt them

    Declaration

    Swift

    public var attachments: [AttachmentInfo]
  • Expiration start-time (if there was an expiration and this is a sync message from another of our devices)

    Declaration

    Swift

    public var expirationStart: Date?
  • The destination set in the sync message container (in Forsta, this is usually the threadId for the message)

    Declaration

    Swift

    public var destination: String?
  • The Signal envelope body you shouldn’t need to look at directly because .payload represents the same information in a nice form

    Declaration

    Swift

    public var signalBody: String