isKnownMessage
isKnownMessage(
message):message is IncomingMessage
Defined in: src/resources/webhook-helpers.ts:43
Narrows a message to the IncomingMessage union. Returns false for a
message whose type this SDK version does not model, so new Meta message
types can be handled separately instead of falling into a union branch.
Parameters
Section titled “Parameters”message
Section titled “message”UnknownIncomingMessage | IncomingMessage
A message returned by extractMessages or a message event.
Returns
Section titled “Returns”message is IncomingMessage
Independent open-source project. Not affiliated with, endorsed by or sponsored by Meta or WhatsApp. Released under the MIT licence. Source on GitHub.