createFaceMessage static method
Object
createFaceMessage(
{ - required String userID,
- String convType = 'C2C',
- required int index,
- required dynamic data,
- String cloudCustomData = '',
- bool needReadReceipt = false,
- int priority = 0,
})
Implementation
static Object createFaceMessage(
{required String userID,
String convType = 'C2C',
required int index,
required data,
String cloudCustomData = '',
bool needReadReceipt = false,
int priority = 0}) {
final textParams = {
"to": userID,
"conversationType": convType,
"needReadReceipt": needReadReceipt,
"cloudCustomData": cloudCustomData,
"priority": MessagePriorityWeb.convertMsgPriorityToWeb(priority),
"payload": mapToJSObj({"index": index, "data": data}),
};
return mapToJSObj(textParams);
}