Metadata-Version: 2.1
Name: twitchirc-drgreengiant
Version: 2.0.0
Summary: A simple receive only Twitch IRC client
Author-email: Simon Howroyd <howroydlsu@gmail.com>
Project-URL: Homepage, https://github.com/howroyd/twitchirc
Project-URL: Repository, https://github.com/howroyd/twitchirc
Project-URL: Bug Tracker, https://github.com/howroyd/twitchirc/issues
Keywords: twitch,irc,chat
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: GNU General Public License v2 (GPLv2)
Classifier: Operating System :: OS Independent
Classifier: Topic :: Communications :: Chat :: Internet Relay Chat
Requires-Python: >=3.11.4
Description-Content-Type: text/markdown
License-File: LICENSE

# TwitchIRC

[![CodeQL](https://github.com/howroyd/twitchirc/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/howroyd/twitchirc/actions/workflows/codeql-analysis.yml)\
[![Python application](https://github.com/howroyd/twitchirc/actions/workflows/python-app.yml/badge.svg)](https://github.com/howroyd/twitchirc/actions/workflows/python-app.yml)\
[![Upload Python Package](https://github.com/howroyd/twitchirc/actions/workflows/python-publish.yml/badge.svg)](https://github.com/howroyd/twitchirc/actions/workflows/python-publish.yml)

This module connects to the Twitch IRC as a basic listener client.  It handles the ping pong and initial connection but otherwise does not send anything to Twitch therefore does not appear in the viewer list nor can it post to chat.  As such, no oauth is required, it just works out of the box.

It can join multiple channels at the same time and will report which channel a message was received in.

## Installation

Available on PyPi at https://pypi.org/project/twitchirc-drgreengiant/

```bash
pip install twitchirc_drgreengiant
```

## Typical Usage

```python
from twitchirc_drgreengiant import twitchirc

channels = frozenset(["drgreengiant", "hpxdreamer"])

with twitchirc.TwitchIrc(channels) as irc:
    while True:
        msg = irc.get_message(irc)

        if not msg:
            continue

        print("Received a message:")
        print(f"{msg.channel=} from {msg.username=}")
        print(f"{msg.payload=}")
        print()
```
