diff --git a/main.py b/main.py index 3fc1103..c993a53 100644 --- a/main.py +++ b/main.py @@ -45,7 +45,7 @@ async def root(): } # 网址返回wxid以及时间戳 - mag = { + msg = { "title:": '标题', "text": @@ -57,6 +57,7 @@ async def root(): "icon_url": "https://www.hackrobot.cn/wp-content/uploads/2023/05/cropped-Screenshot-2023-05-22-at-17.26.38-32x32.png" } + # link卡片链接 link = { 'event': 'SendLinkMsg', 'robot_wxid': 'wxid_haqoszjheyuz22', @@ -66,52 +67,13 @@ async def root(): 'final_from_wxid': 'wxid_haqoszjheyuz22', 'final_from_name': '', 'to_wxid': 'wxid_4413224132412', - 'msg': mag + 'msg': msg } # r = requests.post("http://192.168.31.25:8090", data=payload) # r = requests.post("http://192.168.31.25:8090", json=payload) # 获取好友列表 getinfo = {'event': 'GetFriendList', 'robot_wxid': 'wxid_haqoszjheyuz22'} - xmllink = { - 'event': - 'SendTextMsg', - 'robot_wxid': - 'wxid_haqoszjheyuz22', - 'robot_name': - '', - 'type': - 49, - 'from_wxid': - 'wxid_haqoszjheyuz22', - 'from_name': - '', - 'final_from_wxid': - 'wxid_haqoszjheyuz22', - 'final_from_name': - '', - 'to_wxid': - 'wxid_4413224132412', - 'msgid': - '894964783959555477', - 'msg': - '''\r\n wxid_haqoszjheyuz22\r\n 0\r\n \r\n \r\n \r\n 活动小助手\r\n view\r\n 5\r\n 0\r\n \r\n https://hackrobot.cn\r\n \r\n \r\n \r\n \r\n \r\n \r\n https://aiimg.hackrobot.cn/1698288150.2901459.png\r\n - \r\n \r\n \r\n - \r\n \r\n \r\n - 0\r\n \r\n \r\n - \r\n \r\n \r\n \r\n - \r\n \r\n \r\n 0\r\n \r\n \r\n \r\n \r\n - 1\r\n Window wechat\r\n \r\n\r\n''' - } - - file = { - 'event': 'SendFileMsg', - 'robot_wxid': 'wxid_haqoszjheyuz22', - 'to_wxid': 'wxid_4413224132412', - 'msg': 'C:\\Users\\Administrator\\Documents\\Applet\\static\\.mp3' - } - r = requests.post("http://192.168.31.42:8090", data=json.dumps(link)) print('item')