通过HOOK技术导出接口,实现本地调用wxwork客户端,支持4.1.28版本,包括以下功能 :
1.登陆模块:
获取登录二维码,登录/注销
2.用户信息模块:
获取联系人信息,获取外部/内部联系人列表,获取群/群成员/标签/标签成员列表
3.好友操作模块:
搜索手机号,添加/删除好友,设置联系人备注/手机号/描述/标签
4.群操作模块:
创建群聊,退出群聊,转让群主,邀请好友进群移除群成员,修改群名,发布群公告,修改自己在群聊中的昵称,添加群成员为好友,建群通知,成员进群通知,成员退群通知
5.消息模块:
发送/接收 【文本/图片/视频/文件/链接/名片/语音/小程序/视频号消息】
6.控制台模块:
获取朋友圈首页/详情,删除/评论/发送朋友圈,消息群发
-----------------------------------------------------------------------------
//contact information
char qq[] = "773327083";
char verifyText = "csdn-wwork";
-----------------------------------------------------------------------------
源码示例:
m_longlink->PerformTask(
std::make_shared<SendMessageTask>(msgType, strtoull(recverId), msgProtobuf),
[&, syncKey](bool result, const std::string& data)
{
json_t notifySdkData;
if (result) {
WWResponse rsp;
rsp.ParseFromString(data);
if (rsp.rsp_base().error_code() == 0) {
ChatRsp rspBody;
rspBody.ParseFromString(rsp.rsp_body());
notifySdkData["is_success"] = rspBody.is_svr_fail() ? 0 : 1;
notifySdkData["msg_id"] = rspBody.msg_data().appinfo();
FNNotify(m_id, WWCmdSendCommonMessage, E_SUCCESS, syncKey, notifySdkData);
} else {
NotifyRequestError(WWCmdSendCommonMessage, rsp.rsp_base(), syncKey, notifySdkData);
}
} else {
notifySdkData["err_desc"] = data;
FNNotify(m_id, WWCmdSendCommonMessage, E_UNKNOW_ERROR, syncKey, notifySdkData);
}
});
-----------------------------------------------------------------------------
//contact information
char qq[] = "773327083";
char verifyText = "csdn-wwork";
-----------------------------------------------------------------------------