• 请不要在回答技术问题时复制粘贴 AI 生成的内容
tanrunhao
V2EX  ›  程序员

做个开放的微信机器人,可以通过 http 接口发送消息到个人号。

  •  4
     
  •   tanrunhao ·
    tans · Jul 20, 2021 · 6048 views
    This topic created in 1933 days ago, the information mentioned may be changed or developed.

    源代码地址 https://github.com/tans/push-bot

    使用方式很简单

    1. 加机器人好友自动通过,并发送 api 接口。
    2. 调用生成的接口,命令机器人发消息给自己。

    以下是发给我个人号的接口, 只要修改 query 的 msg 参数内容,我就能收到了。

    https://push.bot.qw360.cn/send/860f7620-e939-11eb-99b1-4de94dc0e818?msg=hello

    大家发送消息留言要健康啊。

    欢迎加机器人生成自己的推送接口。记得适度调戏机器人。

    欢迎加我交流机器人开发

    23 replies  •  2022-05-08 09:37:50 +08:00
    tanrunhao
    tanrunhao
    OP
    Jul 20, 2021
    1
    大家不要只点链接 , 发 hello 给我啊~~
    tanrunhao
    tanrunhao
    OP
    Jul 20, 2021
    3
    “可以发送图片吗?” - 暂时不支持图片发送,加上 post 的接口, 把 msg 改成对象就可以支持。
    tanrunhao
    tanrunhao
    OP
    Jul 20, 2021
    4
    ”看得到吗“ - 看到的
    yuuko
    yuuko
    Jul 20, 2021 via Android
    5
    有点意思
    upojzsb
    upojzsb
    Jul 21, 2021
    6
    感谢,东西不错,写了个爬成绩的爬虫,把成绩推到 WeChat 上。
    tanrunhao
    tanrunhao
    OP
    Jul 21, 2021
    7
    @upojzsb 额, 很适合爬虫, 后台的数据汇报
    tanrunhao
    tanrunhao
    OP
    Jul 21, 2021
    8
    GuguDan
    GuguDan
    Jul 21, 2021
    9
    不支持群聊里推送吗?
    tanrunhao
    tanrunhao
    OP
    Jul 21, 2021 via Android
    10
    @GuguDan 有空我支持一下
    nojsja
    nojsja
    Jul 21, 2021
    11
    不错!我接入我的 github pages 评论了,有人留言,直接推送微信
    kaishui00
    kaishui00
    Jul 21, 2021
    12
    这个实现了没,对象是啥,咋发送
    kaishui00
    kaishui00
    Jul 21, 2021
    13
    发送图片的
    tanrunhao
    tanrunhao
    OP
    Jul 21, 2021 via Android
    14
    @kaishui00 还没啊,发图片开放出来,会不会大家的爬虫脚本又忙起来,用来发 mm 图
    tanrunhao
    tanrunhao
    OP
    Jul 22, 2021
    15
    更新支持发送图片, 详细请看代码仓库文档 https://github.com/tans/push-bot
    gfwoc
    gfwoc
    Jul 22, 2021
    16
    很棒~ 能不能也支持一下反向的,就是我给机器人发消息,机器人帮我把这个消息发送到我指定的 webhook 地址上。
    这样可以实现我从微信分享内容到钉钉了~
    tanrunhao
    tanrunhao
    OP
    Jul 22, 2021 via Android
    17
    @gfwoc 这个想法不错。但是 webhook 的地址要解析消息才能转发吧,这不是又再搞一层,到时候用起来会很复杂吧
    tanrunhao
    tanrunhao
    OP
    Jul 22, 2021 via Android
    18
    @tanrunhao 不过逆向确实也很好玩
    hxy100
    hxy100
    Jul 22, 2021
    19
    为什么我这边发送中文就乱码,msg 无论是用 GBK 编码还是 UTF-8 编码,发过去都是乱码。
    ---
    tanrunhao
    tanrunhao
    OP
    Jul 23, 2021 via Android
    20
    @hxy100 不会啊,你浏览器直接带中文消息访问一下试试
    zzm88104
    zzm88104
    Aug 31, 2021 via iPhone
    21
    可不可以用来给指定好友定时发送提醒?
    uzfg57666
    uzfg57666
    Apr 23, 2022
    22
    市场上
    uzfg57666
    uzfg57666
    May 8, 2022
    23
    现在好像不能用了,一般用 PC 个微模拟的,2645542961 还可以二次开发
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1287 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 49ms · UTC 22:15 · PVG 06:15 · LAX 14:15 · JFK 17:15
    ♥ Do have faith in what you're doing.