python操作微信

from wxpy import *
bot = Bot(cache_path=True)
bot.file_helper.send("Hello world")
groups = bot.groups()
for group in groups:
group.send("我出来逗比一下")
# my_friend = bot.friends().search('忽而今夏', city="娄底")[0]
# my_friend1 = bot.friends().search('毒药', city="深圳")[0]
# group = bot.groups().search("开车了")[0]
# for member in group:
# print(member)
#
# group1 = bot.groups().search("吃货")[0]
# for member in group1:
# print(member.name)
# if member.name == "呵呵":
# continue
# friend = bot.friends().search(member.name)[0]
# friend.send("我在使用脚本给你发信息,看到信息,不用回复。")

groups = bot.groups()
# for group in groups:
# group.send("我继续出来逗比一下")
friends = bot.friends()
for friend in friends:
if friend.name in ["Woody 梧桐", "Smy", "lison", "李慧嫱", "枫", "春", "飞奔的鱼?", "Running", "邱凯", "毒药"]:
friend.send("Great artist always hid themselves in their work.")
friend.send("我在搞事情, 看到信息不用回复")
 

转载于:https://www.cnblogs.com/wlgo2108/p/9637794.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值