SDKsReact Native
Create an emoji message
OpenIM React Native SDK guide for create an emoji message.
Use createFaceMessage() to create an emoji message defined by your application.
const message = await OpenIMSDK.createFaceMessage({
index: 12,
data: JSON.stringify({
url: 'https://www.example.com/emoji.png',
}),
});index is an emoji index agreed by both clients. data is a custom-format string agreed by the sending and receiving clients. Use it to provide emoji identification or rendering information, such as an image URL, a fixed key, or other business data. The call returns a MessageItem ready to send.
Was this page helpful?