wxs javascript sdk
js sdk for wxs services
$ npm install wxs-sdk --save
// Browser
<script src="node_modules/wxs.js/dist/index.js"></script>
<script>
Wechat = Wechat({
id: wxs appid,
mobile: your wxs account mobile,
token: wxs app token
});
</script>
// With import
import { WXS: Wechat } from 'wxs-sdk';
const Wechat = WXS({
id: wxs appid,
mobile: your wxs account mobile,
token: wxs app token
}); // leave the options empty the second time
// With CommonJs
const Wechat = require('wxs-sdk').Wechat({
id: wxs appid,
mobile: your wxs account mobile,
token: wxs app token
});
see wxs services