群晖:微信通知的webhook配置

群晖:微信通知的webhook配置

·

1,SurveillanceStation监控的webhook微信通知配置:

拿到企业微信群的机器人webhook后:https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=ddddddddddddddddd

按照要求配置到后,出现BUG,原因是URL里面不能有?,有问号后,SurveillanceStation会把它放到body里面导致错误。

Sep 26 15:37:18 [16551] outgoing:1:(): {"method":"POST","payload":"key=ddddddddddddd&{\"msgtype\": \"text\",\"text\": {\"content\": \"来自 MyNas 上 Synology Surveillance Station 的测试信息----尊敬的用户,您好:\\n\\n>您已在 MyNas 上设置 Surveillance Station 的 Webhook 事件通知。\\n\\n谨上,\\nSynology Surveillance Station\"}}","response":{"body":"{\"errcode\":93000,\"errmsg\":\"Warning: wrong json format. invalid webhook url, hint: [1727336238214400526794305], from ip: 180.159.86.170, more info at https://open.work.weixin.qq.com/devtool/query?e=93000\"}","code":200},"result":{"code":0,"type":"curl"},"source":"notification test webhook","time":{"duration":144333,"end":1727336238712505,"start":1727336238568172},"url":"https://qyapi.weixin.qq.com/cgi-bin/webhook/send"}


最后想到一个方法就是在cloudflare上配置一个代理转发来完成。

参考: Cloudflare-Workers-Proxy/worker.js at main · ymyuuu/Cloudflare-Workers-Proxy · GitHub


把地址转发后面添加一个key=dddddddddddddd.