messageContent

Returns the message content cast to the specified MessageFormat subtype, or null if the entry does not contain message content of that type. Works for both standard messages and streaming tokens.

Return

The message content as T, or null if the payload does not match.

Type Parameters

T

The expected MessageFormat subtype (e.g., TextFormat, RichLinkFormat).