"errcode":40037,"errmsg":"invalid template_id rid: 656943f0-2540cb75-20fa0d78"}
url = "https://api.weixin.qq.com/cgi-bin/message/subscribe/bizsend?access_token=" + ACCESS_TOKEN
post_json = {
"touser": "obMk16foTLae8GpS15JhHQePG0CM",
"template_id": "bmaVdMQGEgOHWgglvbS09jSPGKqeDROyG1ERIP3aUJU",
"data": {
"thing2": {
"value": "companyname"
},
"time6": {
"value": "2023/11/30"
},
"character_string5": {
"value": "66688888"
},
"amount23": {
"value": "1234"
},
"thing27": {
"value": "汉字-dif2.8"
}
}
}
你是发【模板消息】还是【订阅通知】呢?你上面发的文档是【模板消息】的,你接口调用的是【订阅通知】的。
如果是发【模板消息】,那报错是正常的,更换【模板消息】发送接口重试即可:https://developers.weixin.qq.com/doc/offiaccount/Message_Management/Template_Message_Interface.html#5
如果是发【订阅通知】,建议仔细检查模板ID是否是【订阅通知】里面的。
知道了,要发的是模板消息,看错文档了,多谢啦!!