<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>消息推送服务 on 施国鹏 (seth-shi)</title><link>https://sethix.com/zh-cn/tags/%E6%B6%88%E6%81%AF%E6%8E%A8%E9%80%81%E6%9C%8D%E5%8A%A1/</link><description>Recent content in 消息推送服务 on 施国鹏 (seth-shi)</description><generator>Hugo -- gohugo.io</generator><language>zh-cn</language><lastBuildDate>Sat, 30 Oct 2021 13:57:42 +0800</lastBuildDate><atom:link href="https://sethix.com/zh-cn/tags/%E6%B6%88%E6%81%AF%E6%8E%A8%E9%80%81%E6%9C%8D%E5%8A%A1/index.xml" rel="self" type="application/rss+xml"/><item><title>使用企业微信做一个消息推送服务机器人</title><link>https://sethix.com/zh-cn/posts/2021103013/</link><pubDate>Sat, 30 Oct 2021 13:57:42 +0800</pubDate><guid>https://sethix.com/zh-cn/posts/2021103013/</guid><description>Start 之前在CODING配置了所有项目部署成功后进行消息推送, 随着项目多了,再加上其他服务也有消息提醒, Server酱提供的服务就不够用了
找了一下常用的两个个服务, 但是次数都有限制, 不够用
Server酱 免费用户每天5消息 Qmsg酱 每天30次消息,不够稳定 配置 随后看到Server酱有教学一个微信机器人搭建的服务,仓库地址 https://github.com/easychen/wecomchan 参考README注册好企业微信, 创建一个企业(个人用户按需写即可,不需要企业) 拿到参数(agentid, secret, 企业ID)之后,可以直接通过企业微信的接口发送消息 Server酱用Go封装好了一个服务,可以直接部署来使用https://github.com/easychen/wecomchan/blob/main/go-wecomchan/README.md 在CODING把之前发送给Server酱的请求更换为自己搭建的服务 // Server酱 sshCommand( remote: remoteConfig, command: &amp;#34;curl -X POST -d \&amp;#34;title=`echo \$(curl -I 127.0.0.1:8199/ping)`&amp;amp;desp=消息详情\&amp;#34; https://sctapi.ftqq.com/xxxx.send&amp;#34;, sudo: true, ) // 更换后, 按实际更换成自己所需 sshCommand( remote: remoteConfig, command: &amp;#34;curl -X POST -d \&amp;#34;sendkey=xxxxxxx&amp;amp;msg_type=text&amp;amp;msg=${DOCKER_REPO_NAME}%0D%0A${SERVICE_URL}%0D%0A%0D%0A`echo \$(curl -I 127.0.0.1:8199/ping)`\&amp;#34; http://127.0.0.1:8080/wecomchan&amp;#34;, sudo: true, ) 效果图 企业微信 企业微信</description></item></channel></rss>