> ## Documentation Index
> Fetch the complete documentation index at: https://docs.famulor.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Twitch

> Answer Twitch chat @mentions and optional whispers

Twitch lets the assistant answer when someone @mentions the bot in a channel chat. Whispers are optional and need an extra user token.

## When to use it

Use it for a live channel where viewers already ask questions in chat. The bot account is a separate Twitch user. Each broadcaster must grant the bot **channel:bot** or make the bot a moderator.

## What the assistant hears

The assistant hears **channel.chat.message** only after you subscribe that EventSub event to the Famulor URL. Famulor does not create the EventSub subscription for you. The callback must be HTTPS on port 443.

## Where the keys come from

The linked provider guide shows the screens for these clicks. Follow the clicks below together with those pictures.

You invent the EventSub secret (10 to 100 characters) before subscribing, so it exists before the Famulor URL. Register the application at [dev.twitch.tv/console/apps](https://dev.twitch.tv/console/apps). The Client ID is on the application, and the Client Secret is shown when you generate it. The subscription clicks and the request shape are in [Handling webhook events](https://dev.twitch.tv/docs/eventsub/handling-webhook-events). Chat scopes are `user:read:chat`, `user:write:chat` and `user:bot`.

## Create it at the provider

1. Sign in at [dev.twitch.tv/console/apps](https://dev.twitch.tv/console/apps).
2. Choose **Register Your Application**. Set the OAuth redirect to `http://localhost`, choose **Confidential**, and create it.
3. Copy the **Client ID**. Generate a **Client Secret** and copy it immediately.
4. Invent an EventSub secret of 10 to 100 characters.
5. Use a separate bot account. Its login name is the value Famulor asks for. Note the numeric user ID if you have it.
6. For whispers only, also create a user access token and refresh token for that bot. Chat @mentions do not need them.

## Connect it in Famulor

Your plan includes this channel. Open **Settings → Channels**, choose the card, name the connection, pick an assistant and save. The shared conversation settings — response delay (default 5 seconds) and inactivity timeout (default 30 minutes) — are described on the [messaging channels](https://docs.famulor.io/channels/messaging.md) page.

On the **Twitch** card paste **Application Client ID**, **Application Client Secret**, **EventSub webhook secret** and **Bot account login**. **Bot numeric user ID**, **User access token for whispers** and **Refresh token for whispers** stay empty unless you use whispers.

After saving, open the connection menu and choose **Copy webhook URL**. Paste that exact address into the provider. A verified custom domain is already part of the address Famulor shows.

## Point the provider at Famulor

1. Copy the Famulor webhook URL.
2. Subscribe EventSub **channel.chat.message** to that HTTPS URL on port 443, with the same secret. Use the bot token that has `user:read:chat`, `user:write:chat` and `user:bot`.
3. On each channel, add the bot as a moderator or have the broadcaster grant **channel:bot**.
4. @mention the bot in chat. The message appears in History.

## History

Open [History](https://docs.famulor.io/monitoring/history.md) and filter by **Twitch**. The thread, the assistant reply and any analysis appear there. You can pause the assistant and answer manually.

## API, MCP and command line

The same connection can be created with the public API, the MCP tool `create_messaging_connector`, or the command line. Replace the placeholders with your own values.

```bash theme={null}
famulor create-messaging-connector --platform twitch --name "Support" \
  --assistant-id ASSISTANT_UUID --client-id CLIENT_ID --client-secret CLIENT_SECRET --webhook-secret YOUR_10_TO_100_CHAR_SECRET --bot-username my_twitch_bot
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.