RockList.Live uses a shared Twitch bot account that is separate from the broadcaster account.
- the streamer signs into the app with their own Twitch account
- an admin connects the shared bot account once
- each streamer opts their own channel into bot presence from channel settings
- when the opted-in channel goes live, the app ensures the
channel.chat.messageEventSub subscription exists for that broadcaster + bot user pair - when the channel goes offline, the app removes that chat subscription
The owner settings page can show:
DisabledBot auth requiredBroadcaster auth requiredWaiting to go liveActiveSubscription error
channel_settings.bot_channel_enabled is the owner preference.
channels.botEnabled is the current active-in-chat state.
- Fill in the Twitch-related values in
.env.exampleor.env.deploy.example. - Register both Twitch redirect URIs:
${APP_URL}/auth/twitch/callback${APP_URL}/auth/twitch/bot/callback
- Apply migrations:
npm run db:migrate- Sign in with the broadcaster account.
- Open
/dashboard/adminas an admin user. - Connect the shared bot account while logged into the Twitch account named in
TWITCH_BOT_USERNAME. - Open
/dashboard/settingsfor the channel owner and enable the bot for that channel. - Go live on Twitch and confirm the bot status changes to
Active.
TWITCH_SCOPES belongs to the broadcaster app login, not the shared bot login.
The current default scope set is:
openid user:read:moderated_channels moderator:read:chatters channel:bot channel:read:subscriptions bits:read channel:manage:redemptions
Those scopes support:
- bot-badged chat replies
- chatter-aware viewer lookup
- subscription and cheer VIP token automation
- app-owned channel point rewards
If the connected broadcaster account is missing those permissions, reconnect Twitch from the app.
The app-owned channel point reward flow only works on Twitch Affiliate or Partner channels. Twitch rejects reward create or update calls on channels without channel points.
- replies are sent with the bot account token, not the broadcaster token
- Twitch
401send failures trigger one token refresh and one retry - EventSub subscriptions are reconciled from the app instead of being treated as one-time manual setup
Do not test the same broadcaster in both local and production unless that overlap is intentional.
Two cases matter:
- same broadcaster + same bot account: one environment can take over the shared
channel.chat.messagesubscription - same broadcaster + different bot accounts: both environments can receive and act on the same chat command
Safe default:
- use a dedicated test broadcaster
- use a dedicated test bot account
- keep local
TWITCH_BOT_USERNAMEaligned with that test bot account - avoid leaving both local and production subscriptions active for the same broadcaster
- one shared bot account is used across channels
- bot connection management stays on the admin page
- EventSub subscription drift still relies on save, login, and live-state reconciliation instead of a dedicated health dashboard