Simple Twitch Chat Wrapper written in Python
Project description
This is a simple twitch chat wrapper written on python that I use to build simple bots fast.
installation
pip intall twitch_chat_wrapper
fetchin Twitch oauth password token
Follow this link https://twitchapps.com/tmi/ and save the token
usage
from twitch_chat_wrapper import TwitchChatWrapper viewers_greetings = [] def message_handler(chat, username, message): print("@{}: {}".format(username, message)) if username not in viewers_greetings: chat.send_message("@{} welcome to the stream".format(username)) viewrs_greetings.append(username) twitch = TwitchChatWrapper( bot_nickname="AwesomeBot", oauth_pass="oauth:r1xxk1111111111112222222222xwd", channel="hardlydifficult") twitch.events.on_message += message_handler twitch.loop()
shout out
To https://www.twitch.tv/hardlydifficult which is building a awesome gamedev twitch community
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size twitch_chat_wrapper-0.4.2.tar.gz (3.5 kB) | File type Source | Python version None | Upload date | Hashes View |
Close
Hashes for twitch_chat_wrapper-0.4.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 01995c54740a63779e8fb9bc9e04c491ee0e69986a0c2c96a220ccae8d367399 |
|
MD5 | 3497dc6a55a8598af5100dd71df6c2e9 |
|
BLAKE2-256 | 2f8922ca775ce287da007c56ce7d032b4f17a989499d0876545c50eaeb037408 |