Twitch Alerts

Post in Discord when the streamers a server follows go live on Twitch, keep the post up to date, and change it when the stream ends. Free for every bot.

Twitch Alerts posts in your server when a streamer goes live on Twitch. Each server has its own list of streamers. While a stream is live, your bot keeps the post up to date. When the stream ends, the post changes to show how long it ran and links the recording.

Twitch Alerts is free for every bot, with up to 100 streamers in each server. Its commands, events, variables and stored values don't count toward your free limits. One part needs Premium: Bot status, which shows a live streamer on the bot's own status.

The Twitch alerts Discord bot page gives a shorter tour.

A Twitch alert in Discord: Tom is live on Twitch, Building a bot live, Playing Software and Game Development for 128 viewers, with a picture of the stream and a Watch stream button

What your members see when a streamer goes live

Before you start

You need:

  • Your bot in your Discord server. See Invite Your Bot if it isn't yet.
  • A channel for the alerts, like #stream-alerts. Your bot needs View Channel, Send Messages and Embed Links there.
  • The streamer's Twitch name, or a link to their channel.

You don't need a Twitch account or a Twitch key. Twitch Alerts doesn't need the Message Content intent.

Setup

  1. 1

    Turn on Twitch Alerts

    Open Twitch Alerts in your bot's dashboard and press Enable at the top right. It adds the Twitch Alerts events, the /twitch command, and the custom variables that hold your streamers and settings.

    The top of the Twitch Alerts page with Enabled, the server menu set to Ghost Hangout, Reset to Default, Docs and the Get started strip
    • A Enabled shows the module is on. Before you turn it on, this says Enable.
    • B The server menu picks whose streamers and settings you're changing.
    • C Reset to Default. See Each server's own settings.
    • D Docs opens this page.
    • E The Get started strip shows your next step. Once setup is done it says You're set.
  2. 2

    Pick your server

    Use the server menu at the top of the page. Each server has its own streamers, messages and options.

  3. 3

    Pick a default channel

    Open the Options tab. Under Where alerts go and who they ping, pick a Channel. Every streamer without a channel of its own posts there.

  4. 4

    Add a streamer

    Open the Streamers tab and type a Twitch name in the box. Pick the streamer from the results. See Add a streamer.

  5. 5

    Save

    A bar pops up at the bottom of the page. Press Save Changes. Your bot watches the saved list, so a new streamer says Starts after you save until you do.

    The Unsaved changes bar with Save Changes marked
  6. 6

    See it work

    The next time that streamer goes live on Twitch, your bot posts in the channel. Until then, the streamer's row says Watching.

Each server's own settings

Twitch Alerts has no setting that covers every server. When you pick a server, you see and change that server's streamers, messages and options. To set up another server, pick it in the same menu. The page remembers the last server you picked in that browser.

Reset to Default puts the picked server's messages and options back to how a new Twitch Alerts module starts. Your streamers, each streamer's own message, and the channels and roles you picked all stay.

Disable turns Twitch Alerts off for the whole bot and keeps your streamers and settings.

Streamers

The Streamers tab lists every streamer the server follows. Each streamer is one row. Press a row to open it, and all of its settings show right there.

The Streamers tab with the search box, a count of 3 of 100, rows for NASA, GitHub and TwitchRivals with their status, channel, switch and Remove, beside a Discord preview of the live alert

The Streamers tab

  • A The three tabs: Streamers, Messages and Options.
  • B The search box and Check.
  • C How many streamers the server follows, out of 100.
  • D A streamer's row: picture, name, status, and a line saying where it posts and who it pings.
  • E The switch turns that streamer's alerts on or off.
  • F Remove takes the streamer off the list. Press it twice, then save.
  • G The preview shows the alert with sample details.

Add a streamer

Type in the box and the page searches Twitch as you type. It starts after two letters and shows up to eight streamers, each with a picture, a name and a Live mark if they're live right now. Click one to add it, or use the arrow keys and press Enter. A streamer already on your list says On the list.

The search box with twitch typed in and a list of Twitch channels under it, one with a Live mark and one marked On the list, the others with Add at the right
  • A Type a Twitch name, or paste a link like twitch.tv/tom.
  • B The results. Add puts that streamer on the list.
  • C Check looks up the exact name or link you typed.

Twitch only knows a name as it is today. If a streamer changed their name, search for the new one, or paste their channel link and press Check.

Nothing is saved or watched until you press Save Changes.

What a row's status means

Status What it means
Starts after you save The streamer is new on the page. Save, and your bot starts watching
Watching Saved, and no alert has gone out yet
Live now, 1 h 12 min They are live, and for how long
Last alert 3 days ago When your bot last posted for them
Pick a channel The streamer has no channel of its own and the server has no default channel, so nothing can post
A line in red The last alert didn't post. The line gives the reason, for example a missing permission

Its own channel and ping

An open row starts with Discord channel and Who it pings.

An open streamer row for NASA with Discord channel set to #nasa-live, Who it pings set to the Stargazers role, and Use its own message switched on with Edit message
  • A Discord channel. Leave it empty to use the server's default channel.
  • B Who it pings: roles, @everyone or @here. Leave it empty to use the server's default ping.
  • C Use its own message. See below.

Under each field, a line says what the streamer uses right now: its own pick, or the server's default.

Its own message

Turn on Use its own message to give one streamer a different live post. Edit message opens the full message builder. It starts as a copy of the server's live message.

A streamer's own message is used when they go live and while the post is kept up to date. The stream ended message is always the server's, from the Messages tab.

Filters

Open Filters in a row to choose which streams post. The line beside it sums up what's set, or says Every stream posts.

A streamer's Filters with Only these categories set to Software and Game Development, The title must have one of these set to bot, The title must have none of these set to rerun, and Their Discord member under it
  • A Only these categories. Empty posts every category. The name has to match Twitch's, like Just Chatting.
  • B The title must have one of these. Empty posts every title. Capitals don't matter.
  • C The title must have none of these. A title with any of these words never posts.
  • D Their Discord member, for the Live role.

A stream that doesn't pass the filters posts nothing and pings nobody.

Their Discord member

Paste the streamer's Discord user ID to link them to a member of your server. That member gets the Live role while they are live.

To copy a user ID in Discord, open Settings, then Advanced, and turn on Developer Mode. Then right click the member and press Copy User ID.

Messages

The Messages tab has one card for each message. Every message is fully editable: press Edit message to open the message builder, where you can change the words, the picture, the colour and the buttons.

The Messages tab with the When a streamer goes live card, its message, Edit message and its variables, beside a Discord preview of the alert for Tom
  • A The card's title, and a line saying when the message is sent.
  • B Edit message opens the message builder.
  • C The variables this message can use. Click one to copy it.
  • D The preview, with sample details.
Message When it's used
When a streamer goes live Posted in the streamer's channel when they go live, with the ping. While they are live it's kept up to date
When the stream ends What the live post becomes when the stream is over, or a new message, as picked under When a stream ends
When staff list the streamers The private answer to /twitch list

The live message starts with a Watch stream button, and the stream ended message with Watch the VOD. The VOD button is left out when Twitch has no recording.

Variables

Variable What it fills in
{tw_ping} The roles this alert pings, as mentions. Empty when it pings nobody
{event_twitch_display_name} The streamer's name as Twitch shows it
{event_twitch_user_name} The streamer's login, as in their link
{event_twitch_stream_title} The stream's title
{event_twitch_game_name} The category they are streaming in
{event_twitch_viewer_count} How many people are watching now
{event_twitch_stream_url} The link to the stream
{event_twitch_thumbnail_url} A picture of the stream
{event_twitch_profile_image} The streamer's profile picture
{event_twitch_duration} How long the stream ran
{event_twitch_peak_viewers} The most people watching at once
{event_twitch_vod_url} The link to the recording. Empty when there is none
{server} The server's name
{tw_list} Every streamer the server follows, one line each: the name, live or off, and its channel
{tw_count} How many streamers the server follows

Keep {tw_ping} in the live message if you want the ping to show. The stream ended message never pings anyone.

The BotGhost credit

On a free bot, every alert shows a small Made with BotGhost line under it. That covers the live post, each update to it, and the stream ended message. The reply to /twitch list shows the line about one time in three. Premium bots never show it.

The line sits under your message. It isn't part of your words, so editing a message doesn't remove it.

Options

The Options tab holds the defaults for every streamer in the server.

Where alerts go

The Where alerts go and who they ping card sets the server's default channel and ping.

The Options tab with Where alerts go and who they ping set to #stream-alerts and the Stream pings role, and When a stream ends set to Edit the post
  • A Channel. Every streamer without its own channel posts here. Your bot needs View Channel, Send Messages and Embed Links there.
  • B Who gets pinged: roles, @everyone or @here. Empty pings nobody.
  • C When a stream ends. See below.

Your bot needs Mention Everyone to ping @everyone, @here, or a role that not everyone can mention.

A streamer with its own channel or ping uses that. See Its own channel and ping.

When a stream ends

Choose what happens to the live post once the stream is over.

Choice What your bot does
Edit the post The live post becomes the stream ended message. This is how it starts
Delete the post The live post is taken away
Post a new message The live post stays, and the stream ended message is posted under it
Leave it The live post stays as it is

The stream ended message starts as "Tom was live on Twitch", with how long the stream ran, the most viewers it had, and a Watch the VOD button.

Your bot checks Twitch every two minutes, so the post changes a few minutes after the stream ends. If someone deleted the live post, your bot has nothing to edit and does nothing.

While a stream is live

The While a stream is live card with Keep the post fresh on and Also alert for reruns off, beside the Live role card with the Live now role picked
  • A Keep the post fresh. On to start with.
  • B Also alert for reruns. Off to start with.
  • C The Live role. See below.

Keep the post fresh edits the live post when the stream changes. A new title or category shows within a couple of minutes. The viewer count and the picture update every 10 minutes. Nobody is pinged again.

Also alert for reruns adds alerts for reruns, watch parties and premieres. While it's off, only live streams post.

If a stream drops and comes back within five minutes, your bot doesn't post or ping a second time.

Live role

Pick a Role on the Live role card. Your bot gives it to a streamer's Discord member while they are live, and takes it away when the stream ends.

The role only goes to streamers with a member set. See Their Discord member. Your bot needs Manage Roles, and its own role has to sit above the live role in your server's role list.

Leave the role empty for no live role.

Bot status

Bot status while live needs Premium, because only Premium bots can change their status. On a free bot the card still shows, with its two settings switched off. Everything else in Twitch Alerts is free.

Show one streamer on the bot's own status while they are live. The status shows as Streaming, with a link to the stream.

The Bot status while live card with a Premium tag, Which streamer set to NASA, and Status text set to the streamer's name is live on Twitch, with Shows as: Streaming NASA is live on Twitch under it
  • A Which streamer. Pick one from the server's list, or Off.
  • B Status text, up to 128 characters. It starts as {event_twitch_display_name} is live on Twitch.
  • C How the status will look.

When the stream ends, the bot's saved status comes back.

A bot has one status for every server it's in. If two servers each pick a streamer, the last one to go live shows.

Commands

Command What it does Who can use it
/twitch list Lists the server's streamers, who is live now, and each one's channel Members with Manage Server

Only the person who used the command sees the reply. You can change the reply on the Messages tab.

The Twitch Alerts commands card with /twitch opened to its list subcommand, and the Twitch Alerts events card with Went live, Stream changed and Stream ended
  • A /twitch list, with Edit and its own switch.
  • B The three events. Press one to open it in the builder.
  • C Show variable names shows each setting's variable on the page.

Events

Twitch Alerts is made of ordinary builder blocks. You can open any event to see how it works, or add your own blocks to it.

Event When it runs What it does
Went live A streamer on the list goes live Checks the filters, works out the channel and the ping, gives the live role, then posts the live message
Stream changed A live stream's title, category or viewers change Edits the live post, when Keep the post fresh is on
Stream ended A streamer on the list goes offline Takes the live role away, then edits or deletes the live post, or posts the stream ended message

Changing a setting on the page doesn't change the events. The blocks read your settings each time they run.

BotPanel

You can put Twitch Alerts on your bot's BotPanel website. Server admins can then set it up for their own server:

  • Streamers: add a streamer by name or link, and set each one's channel, ping, own message, filters and Discord member. The website looks the name up on Twitch when the admin saves.
  • Messages: every message, with the full message builder.
  • The defaults: the default channel and ping, what happens when a stream ends, the two switches, and the live role.

Bot status while live isn't on the website, because the status belongs to the whole bot. The commands and events stay on your dashboard.

You choose which settings admins see in Modules. Your BotPanel plan decides which servers can open the server dashboard.

Moving your old Twitch alerts in

If your bot already has Twitch Stream Online events, the page shows a Move your alerts in card. Press See what moves and it tells you what can move, for example "1 Twitch alert can move." and "1 stays as your own event because it has other blocks." Nothing moves until you press the move button. Not now closes the list.

The Move your alerts in card on the Twitch Alerts page, saying 1 Twitch alert can move and 1 stays as your own event because it has other blocks, with the Move 1 alert and Not now buttons
  • A How many alerts can move.
  • B The alerts that stay as your own events, and why.
  • C The button that moves them. It says how many, like Move 1 alert.

What moves:

  • An event with only the Twitch block and one Send or Edit a Message block becomes a streamer on the list, in the server that owns the message's channel.
  • The streamer keeps the event's channel. A role, @everyone or @here in the old message becomes its ping. A message you changed becomes the streamer's own message.
  • The old event is switched off. It isn't deleted.
  • An event with other blocks stays as your own event and keeps working.

For 30 days, you can undo the move. That switches the old events back on and removes the moved streamers.

On a free bot, moved alerts stop counting toward the 3 custom event limit, because module events never count.

Limits

What Limit
Streamers 100 in each server
Search results Up to 8
Status text 128 characters
Bot status One streamer in each server, Premium bots only
Viewer count and picture updates Every 10 minutes while live

The limits are the same on free and Premium bots.

Troubleshooting

A streamer went live and nothing posted

Check these in order:

  1. You pressed Save Changes after adding the streamer. A row that says Starts after you save isn't watched yet.
  2. The streamer's switch is on, and so is Twitch Alerts.
  3. The streamer has a channel, or the server has a default channel. A row without one says Pick a channel.
  4. Your bot has View Channel, Send Messages and Embed Links in that channel. If the post failed, the row shows the reason in red.
  5. The stream passes the streamer's Filters.
  6. Your bot is online. A free bot is switched off after 7 days with no activity, and Start brings it back.
The search finds nothing

Twitch only knows a name as it is today, so an old name won't show. Try fewer letters, or paste the channel's link and press Check.

The ping shows as plain text

Your bot needs Mention Everyone to ping @everyone, @here, or a role that not everyone can mention.

The live role isn't given

Set the streamer's Discord member, and pick a role on the Live role card. Your bot needs Manage Roles, and its own role has to sit above the live role.

The post didn't change when the stream ended

Your bot checks Twitch every two minutes, so give it a few minutes. If When a stream ends is set to Leave it, the post stays as it is. If the live post was deleted, there's nothing to edit.

The bot's status doesn't change

Bot status needs Premium. Check that a streamer is picked under Which streamer, that the streamer is switched on, and that the status text isn't empty.

Every alert shows Made with BotGhost

That's how alerts work on a free bot. See The BotGhost credit.