Message type - Reaction
Enables reacting by using emoji to a message.
- js
// userAlice.chat.send(recipient, message)
// This section focuses on customization parameters for 'message' object
const aliceMessagesBob = await userAlice.chat.send(recipient, {
type: 'Reaction',
content: '👍', // content can be eliminated
reference: 'bafyreia2okco5ocdxmoxon72erviypaht74u3dqunf3vydu237ybju4kw4', // pass in the reference to the message hash that this reaction is intended for
});
Customization parameters
When sending a message, you can customize the following params
Param | Type | Subtype | Default | Remarks |
---|---|---|---|---|
recipient | string | - | - | Recipient supports a number of address format including wallet address, chain agnostic wallet address, NFT addresses or even chatid which is useful in groups |
message | object | - | - | Configuration for message to be sent |
- | message.type | Meta | Text | Type of message Content |
- | message.content | string | - | Emoji Symbol - 👍, 👎, ❤️, 👏, 😄, 😢 |
- | options.reference | string | - | Pass in the reference to the message hash that this reaction is intended for |
Note: Parameters
in this style
are mandatory.