Python Service Puppet for Wechaty
- Consume Wechaty Puppet Service
import asyncio
from wechaty import Wechaty
from wechaty_puppet_service import PuppetService
bot = Wechaty(PuppetService("your-token-here"))
bot.on('message', lambda x: print(x))
asyncio.run(bot.start())
The token set to this environment variable will become the default value of puppetOptions.token
WECHATY_PUPPET_SERVICE_TOKEN=secret python bot.py
or you can use TOKEN
or token
environment variable alias name to set token, for example:
TOKEN=secret python bot.py
# or
token=secret python bot.py
Rename from wechaty-puppet-hostie
-> wechaty-puppet-service
- Init Python version
- Published to PyPI
- @wj-Mcat - Jingjing WU (吴京京)
- @huan - (李卓桓) [email protected]
- Code & Docs © 2020-now Huan LI <[email protected]>
- Code released under the Apache-2.0 License
- Docs released under Creative Commons