wechat_service_message
v1.0.15
Published
send service message to members
Downloads
7
Readme
Simple use
var Service_Message = require('wechat_service_message');
var sendData = {
type: type, //type can be "text", "image" or "voice"
media_id: media_id, //media_id is the response you got from https://qyapi.weixin.qq.com/cgi-bin/media/upload?access_token=ACCESS_TOKEN&type=TYPE
touser: toUser, //the user_id in wechat-qy
openid: openid, //the openid in wechat-mp
access_token: access_token //use CorpID and Secret in the qy kf service to exchange access_token
};
Service_Message.sendMessage(sendData);
- Where access_token is the access_token you got from other api.
- data is an object including type content touser openid and access_token
Installation
$ npm install wechat_service_message