1.0.10 • Published 4 years ago

wechat-api2 v1.0.10

Weekly downloads
1
License
ISC
Repository
-
Last release
4 years ago

安装

npm install wechat-api2

如何使用

import { WechatAPI } from 'wechat-api2'

const api = new WechatAPI({appid , appsecret})

// 调用微信接口获取 access_token,获取成功后会回调创建 WechatAPI 对象时传入 setToken
await api.fetchToken()

// 获取用户信息
await api.getUserInfo(openid)

方法列表

  • sendTemplate 发送模板消息
  • fetchToken 获取token
  • getUserInfo 获取用户信息
  • updateRemark 更新备注
  • getFollowers 获取关注者列表
  • setAppid 设置 Appid
  • setAppsecret 设置 Appsecret
  • setTokenHanlder 设置Token相关处理函数
  • createQRCode 创建二维码
1.0.10

4 years ago

1.0.9

4 years ago

1.0.8

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago