wechaty-puppet-macpro v0.6.0
WECHATY-PUPPET-MACPRO
Notice
- wechaty-puppet-macpro is still in Early Alpha Stage, please make sure you have the necessary engineering technics to deal with the bugs instead of just asking for support.
- You are welcome to file an issue to reproduce the problem, if it is reproducible, we will fix that as soon as possible.
- If you need a stable version, please keep waiting until we release the stable one.
Install
1. Init
1.1. Check your Node version first
node --version // v10.16.0for windows system
To make sure you could install wechaty-puppet-macpro successfully, you have to start PowerShell as Administrator and run these commands:
npm install -g windows-build-tools
npm install -g node-gyp1.2. Create your bot folder and do some init config
mkdir my-macpro-bot && cd my-macpro-bot
npm init -y
npm install ts-node typescript -g
tsc --init2. Install the bot dependency
npm install wechaty@latest
npm install wechaty-puppet-macpro@latestOr some new features developing version:
npm install wechaty@next
npm install wechaty-puppet-macpro@next3. Install other dependency
There's no need to install
wechaty-puppetin my-macpro-bot
npm install qrcode-terminal
...4. Other Tips
If step 1~3 can not help you install successfully, please try this suggestion, otherwise just skip it please.
rm -rf node_modules package-lock.json
npm installIf you want to see detail logs about your bot, just run:
BROLOG_LEVEL=silly ts-node index.tsor
BROLOG_LEVEL=silly node index.jsExample
import { Wechaty } from 'wechaty'
import { PuppetMacpro } from 'wechaty-puppet-macpro'
import { ScanStatus } from 'wechaty-puppet'
import { generate } from 'qrcode-terminal'
const token = 'your token'
const name = 'your-bot-name'
const puppet = new PuppetMacpro({
token,
})
const bot = new Wechaty({
puppet,
name, // unique for each WeChat account, will generate ${name}.memory-card.json file in current root dirctory
})
bot
.on('scan', (qrcode, status) => {
if (status === ScanStatus.Waiting) {
generate(qrcode, {
small: true
})
}
})
.on('login', (user) => {
console.log(`login user : ${JSON.stringify(user)}`)
})
.on('message', msg => {
console.log(`msg : ${JSON.stringify(msg)}`)
})
.start()Puppet Comparison
| 功能 | padpro | macpro | macpro |
|---|---|---|---|
| <消息> | |||
| 收发文本 | ✅ | ✅ | ✅ |
| 收发个人名片 | ✅ | ✅ | ✅ |
| 收发图文链接 | ✅ | ✅ | ✅ |
| 发送图片、文件 | ✅ | ✅ | ✅(对内容有大小限制,20M以下) |
| 接收图片、文件 | ✅ | ✅ | ✅(对内容有大小限制,25M以下) |
| 发送视频 | ✅ | ✅ | ✅(视频以链接形式发送) |
| 接收视频 | ✅ | ✅ | ✅ |
| 发送小程序 | ❌ | ✅ | ❌ |
| 接收动图 | ❌ | ✅ | ✅ |
| 发送动图 | ❌ | ✅ | ✅ |
| 接收语音消息 | ✅ | ✅ | ✅ |
| 发送语音消息 | ✅ | ❌ | ❌ |
| 转发文本 | ✅ | ✅ | ✅ |
| 转发图片 | ✅ | ✅ | ✅ |
| 转发图文链接 | ✅ | ✅ | ✅ |
| 转发音频 | ✅ | ✅ | ❌ |
| 转发视频 | ✅ | ✅ | ✅ |
| 转发文件 | ✅ | ✅ | ✅ |
| 转发动图 | ❌ | ❌ | ❌ |
| 转发小程序 | ❌ | ❌ | ❌ |
| <群组> | |||
| 创建群聊 | ✅ | ✅ | ✅ |
| 设置群公告 | ✅ | ✅ | ✅ |
| 获取群公告 | ❌ | ❌ | ✅ |
| 群二维码 | ✅ | ✅ | ✅ |
| 拉人进群 | ✅ | ✅ | ✅ |
| 踢人出群 | ✅ | ✅ | ✅ |
| 退出群聊 | ✅ | ✅ | ✅ |
| 改群名称 | ✅ | ✅ | ✅ |
| 入群事件 | ✅ | ✅ | ✅ |
| 离群事件 | ✅ | ✅ | ✅ |
| 群名称变更事件 | ✅ | ✅ | ✅ |
| @群成员 | ✅ | ✅ | ✅ |
| 群列表 | ✅ | ✅ | ✅ |
| 群成员列表 | ✅ | ✅ | ✅ |
| 群详情 | ✅ | ✅ | ✅ |
| <联系人> | |||
| 修改备注 | ✅ | ✅ | ✅ |
| 添加好友 | ✅ | ✅ | ✅ |
| 自动通过好友 | ✅ | ✅ | ✅ |
| 添加好友 | ✅ | ✅ | ✅ |
| 好友列表 | ✅ | ✅ | ✅ |
| 好友详情 | ✅ | ✅ | ✅ |
| <其他> | |||
| 登录微信 | ✅ | ✅ | ✅ |
| 扫码状态 | ✅ | ❌ | ✅ |
| 退出微信 | ✅ | ✅ | ✅ |
| 依赖协议 | iPad | Mac | iPad |
5 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago