Warning: this repo is too old that compared with the wechat official api, Please do the full test before use in production environment.
Wechat Card API for NodeJS
Just support card type: CASH, DISCOUNT, GIFT, GROUPON, GENERAL_COUPON, LUCK_MONEY in this verison
npm install wechat-card
var wxCard = require("wechat-card");
wxCard.setConfig({
appId: "YOUR APP ID",
appSecret: "YOUR APP SECRET"
// or config access token service
// accessTokenService: "http://url"
});
wxCard.card.createCard(cardinfo, function(error, cardid) {
// do something
});
MIT