Builders/parsers for encrypted message participant nodes.
Summary
Functions
Applies the stanza options shared by encrypted direct and group messages.
Builds a participant node containing one encrypted payload.
Converts an internal Signal encryption type to its WhatsApp wire value.
Extracts non-empty participant JIDs from encrypted participant nodes.
Generates WhatsApp's version 2 participant hash for a recipient list.
Converts a JID string to ADString format matching whatsmeow/whatsapp-rust.
Adds a message attribute only when its value is present.
Functions
@spec apply_outbound_options( ExWapp.Binary.Node.t(), keyword() ) :: ExWapp.Binary.Node.t()
Applies the stanza options shared by encrypted direct and group messages.
Message type remains a stanza attribute. Media type is attached to each encrypted payload, and additional metadata nodes are appended after the encrypted content.
@spec build_participant_encrypted_node(String.t(), binary(), atom() | String.t()) :: ExWapp.Binary.Node.t()
Builds a participant node containing one encrypted payload.
Converts an internal Signal encryption type to its WhatsApp wire value.
Extracts non-empty participant JIDs from encrypted participant nodes.
Generates WhatsApp's version 2 participant hash for a recipient list.
Converts a JID string to ADString format matching whatsmeow/whatsapp-rust.
Format: user.agent:device@server
Example: 1234567890@s.whatsapp.net → 1234567890.0:0@s.whatsapp.net
Example: 1234567890:37@s.whatsapp.net → 1234567890.0:37@s.whatsapp.net
Adds a message attribute only when its value is present.