添加新对话框时的Quickblox iOS通知

时间:2018-06-19 20:46:38

标签: ios notifications chat quickblox

是否有我们在ServiceManager(QMServicesManager)中获得的iOS通知,chatService通知应用程序为用户添加了一个新对话框。基本上是全新的聊天请求

1 个答案:

答案 0 :(得分:0)

创建对话框后,您可以使用QuickBlox的系统通知将邮件发送给收件人

let message: QBChatMessage = QBChatMessage()
    let params = NSMutableDictionary()
    params["event_type"] = "NewDialogCreated"
    params["dialogId"] = <dialogId or the information you need to pass>
    message.customParameters = params
    message.recipientID = UInt(recipientId)!

    QBChat.instance.sendSystemMessage(message) { (Error) in

    }

收件人可以在QBChatdelegate中收到此消息

#pragma mark QBChatDelegate

func chatDidReceiveSystemMessage(message: QBChatMessage!) {

}