sendMessageReadReceipts method

Future<V2TimCallback> sendMessageReadReceipts({
  1. required List<String> messageIDList,
})

Implementation

Future<V2TimCallback> sendMessageReadReceipts({
  required List<String> messageIDList,
}) async {
  try {
    final originalMessageList = messageIDList.map((e) => timeweb!.findMessage(e)).toList();
    final res = await wrappedPromiseToFuture(timeweb!.sendMessageReadReceipt(originalMessageList));
    if (res.code == 0) {
      return CommonUtils.returnSuccessForCb(res.data);
    }
    return CommonUtils.returnSuccessForCb([]);
  } catch (error) {
    return CommonUtils.returnError(error.toString());
  }
}