Wolther47 edited this page Sep 3, 2018 · 75 revisions

OVERVIEW

Learn more about Wechaty Puppet at https://github.com/Chatie/wechaty-puppet/wiki

WHAT IS WECHATY PUPPET

The term Puppet in Wechaty is a name that we had picked up to describe part of our system: Puppet is an Abstract Class for implementing plugins, the plugins are the component that helps Wechaty to control the Wechat, that's the reason we call it puppet.

Plugins are named PuppetXXX, like PuppetPuppeteer is using the chrome puppeteer to control the WeChat Web API via a chrome browser, PuppetPadchat is using the WebSocket protocol to connect with a Protocol Server for controlling an iPad program.

For a deeper understanding of the Puppet in Wechaty, you can read its source code if you like at https://github.com/Chatie/wechaty-puppet/blob/master/src/puppet.ts

abstract puppet

Puppet

All core puppet abstract class

PuppetPuppeteer

A web solution to connect weChat, Wechaty init implement is by web weChat, which inject js code into chrome.

PuppetMock

A mock function to connect weChat, not a real implement, for testing other connectors to connect with Wechaty, in other words: a mock solution to implement puppet. This is used for further to connect other solutions, such as iPad, Xposed, iOs, windows client...

PuppetPadchat

An iPad solution to connect weChat

PuppetIos

An iOS solution to connect weChat is on the way.

RUN

  1. Using puppet-mock to run ding-dong-bot
WECHATY_PUPPET=mock npm start
  1. Using puppet-padchat to run ding-dong-bot
WECHATY_PUPPET=padchat npm start
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.