Interface StoredMsg

An interface representing a message that retrieved directly from JetStream.

Hierarchy

  • StoredMsg

Properties

data: Uint8Array

The payload of the message body

header: MsgHdrs

Headers for the message

seq: number

The sequence number of the message in the Stream

subject: string

The subject the message was originally received on

time: Date

The time the message was received

timestamp: string

The raw ISO formatted date returned by the server

Methods

  • Convenience method to parse the message payload as JSON. This method will throw an exception if there's a parsing error;

    Type Parameters

    • T

    Parameters

    Returns T

  • Convenience method to parse the message payload as string. This method may throw an exception if there's a conversion error

    Returns string

Generated using TypeDoc