node-red-contrib-wechatferry 1.1.2
docker安装wechatFerry,在homeassistant中安装node-red,调用该节点可将信息发送到微信
wechatferry对接homeassistant
在homeassistant中将需要的消息发送到微信
前提条件
- 你得有一个微信号
- 使用docker安装jackytj/wcf-docker 具体见
- https://registry.hub.docker.com/r/jackytj/wcf-docker/
节点设置
- 配置参数: http://x.x.x.x:8080/, 端口后面的"/"必须要加上;
- 发送节点前需要增加一个函数节点
// 假设 msg.payload 是从上一节点传来的值
let newContent = msg.payload;
let newJson = {
"type": "text", //发送字符串信息
"content": newContent,
"to": "53100431649", //群号或者是个人微信id
"isGroup": true // 是否发送给群,发送给个人需要改为flase
}
// 将新的 JSON 对象赋值给 msg.payload
msg.payload = newJson;
// 返回 msg 对象
return msg;