This is the full developer documentation for StreamElements Docs
# StreamElements Documentation
> Everything you need to set up, customize, and build on StreamElements.
## Explore the docs
[Section titled “Explore the docs”](#explore-the-docs)
[Chatbot](/chatbot)Commands, variables, timers, spam filters, and interactive modules for your chat.
[SE.Live](/selive)Set up SE.Live in OBS Studio and find guides for your stream.
[Overlays & Alerts](/overlays)Build stream overlays — from your first AlertBox to fully custom-coded widgets.
[Developers](/developers)Build integrations with WebSockets, the HTTP API, and custom widgets.
[Changelog](/changelog)New updates and improvements at StreamElements, with RSS feeds per product.
[Discord Community](https://discord.gg/se)Get help from the community and the StreamElements team.
# StreamElements Chatbot
> Documentation for the StreamElements Chatbot for Twitch and YouTube Live: commands, variables, timers, modules, spam filters, quotes, and counters.
The StreamElements Chatbot is a chatbot for Twitch and YouTube Live. It provides custom commands, automated timers, spam filters, and interactive modules, all configured from your StreamElements dashboard.
[Getting Started](/chatbot/getting-started)Create your first custom command and timer.
[Guides](/chatbot/guides)Build useful commands for counters, lurk replies, countdowns, and viewer input.
[Commands](/chatbot/commands)Default and custom chatbot commands.
[Variables](/chatbot/variables)Dynamic values for command and timer responses.
[Modules](/chatbot/modules)Interactive features for your chat.
[Spam Filters](/chatbot/filters)Keep your chat clean and safe.
[Timers](/chatbot/timers)Automated messages at regular intervals.
[Quotes](/chatbot/quotes)Save and share memorable moments from your stream.
[Counters](/chatbot/counters)Keep track of deaths, misses, or any other event.
[Troubleshooting](/chatbot/troubleshooting)Resolve common chatbot issues.
# Commands
> Default and custom chat commands for the StreamElements Chatbot, and the variables available in command responses.
The StreamElements Chatbot supports two kinds of chat commands. Default commands are pre-configured and ready to use immediately, covering moderation, viewer engagement, and stream information. Custom commands are commands you create yourself, with responses that can include [variables](/chatbot/variables) for dynamic content.
[Custom Commands](/chatbot/commands/custom)Create commands tailored to your channel and community.
[Default Commands](/chatbot/commands/default)Pre-configured commands that are ready to use immediately.
[Variables](/chatbot/variables)Dynamic values for command and timer responses.
# Custom Commands
> Create and manage custom StreamElements Chatbot commands from the dashboard or directly in chat, with example commands using variables.
In addition to the default commands, you can also create your own custom commands. Custom commands allow you to create commands that are tailored to your channel and your community. You can use custom commands to create unique interactions and functionalities that are not possible with the default commands.
## Managing Custom Commands
[Section titled “Managing Custom Commands”](#managing-custom-commands)
There are two ways to manage custom commands:
1. Through the creator dashboard
2. Directly in chat with the [!command](/chatbot/commands/default/command) command
### Using the dashboard
[Section titled “Using the dashboard”](#using-the-dashboard)
See [Getting Started](/chatbot/getting-started) for a step-by-step walkthrough of creating a command in the dashboard.
### Using chat
[Section titled “Using chat”](#using-chat)
| Action | Syntax | Example |
| ------- | ------------------------------------------- | -------------------------------------------------------------- |
| Add | `!command add ! ` | `!command add !socials Follow me on Twitter @MyHandle!` |
| Edit | `!command edit ! ` | `!command edit !socials Check out my links: example.com/links` |
| Remove | `!command remove !` | `!command remove !socials` |
| Show | `!command show !` | `!command show !socials` |
| Options | `!command options ! ` | `!command options !socials -cd 10 -level 500` |
Note
`!command` is aliased as `!cmd`, so `!cmd add !socials ...` works the same way.
For the full subcommand reference, including all available options, permissions, and aliases, read the documentation for the [!command](/chatbot/commands/default/command) command.
## Examples
[Section titled “Examples”](#examples)
### Dynamic Greeting Command
[Section titled “Dynamic Greeting Command”](#dynamic-greeting-command)
This command greets the user and tells them when they last visited the stream.
```streamelements
!cmd add !hello $(user), welcome to the stream! You last visited $(user.lastseen) ago.
```
Example chat
Viewer123:!hello
StreamElements:Viewer123, welcome to the stream! You last visited 2 days 5 hours ago.
Variables used:
* [$(user)](/chatbot/variables/user#available-variables) - The name of the viewer
* [$(user.lastseen)](/chatbot/variables/user#available-variables) - The time the viewer last visited the stream
### Stream Uptime Command
[Section titled “Stream Uptime Command”](#stream-uptime-command)
This command shows how long the stream has been live, the current game, and viewer count.
```streamelements
!cmd add !stream The stream has been live for $(uptime). We're currently playing $(channel.game) for $(channel.viewers) viewers!
```
Example chat
Viewer123:!stream
StreamElements:The stream has been live for 2 days 5 hours. We're currently playing Fortnite for 1234 viewers!
Variables used:
* [$(uptime)](/chatbot/variables/uptime) - The time the stream has been live
* [$(channel.game)](/chatbot/variables/channel#available-variables) - The game the stream is currently playing
* [$(channel.viewers)](/chatbot/variables/channel#available-variables) - The number of viewers currently watching the stream
### Weather Command
[Section titled “Weather Command”](#weather-command)
This command checks the weather for a location specified by the viewer.
```streamelements
!cmd add !weather $(sender), weather in: $(weather ${1:})
```
Example chat
Viewer123:!weather Tokyo
StreamElements:Viewer123, weather in: Tokyo, Japan: 🌜 17.7 °C (63.9 °F). Feels like 17.7 °C (63.9 °F). Patchy rain nearby. Wind is blowing from the South at 9.7 km/h (6.0 mp/h). 89% humidity. Visibility: 10 km (6 miles). Air pressure: 1008 hPa.
Variables used:
* [$(sender)](/chatbot/variables/sender) - The viewer who triggered the command
* [${1:}](/chatbot/variables/args) - The arguments passed to the command, here the location to look up
* [$(weather)](/chatbot/variables/weather) - The current weather in a specified location
### Shoutout Command
[Section titled “Shoutout Command”](#shoutout-command)
This command sends a simple shoutout to a specified user.
```streamelements
!cmd add !shoutout Check out ${1}, they are playing $(game ${1}) at https://twitch.tv/${1}
```
Example chat
Viewer123:!shoutout Styler
StreamElements:Check out Styler, they are playing Counter-Strike at https\://twitch.tv/Styler
Variables used:
* [${1}](/chatbot/variables/args) - The first argument passed to the command, here the name of the user to shout out
* [$(game)](/chatbot/variables/game) - The game the user is currently playing
# Default Commands
> Reference of all default StreamElements Chatbot commands, grouped by category, with usage and configuration links.
Default commands are pre-configured chat commands available in the StreamElements Chatbot. These commands provide essential functionality for streamers, moderators, and viewers to interact with the chat and manage the stream.
Below is the full list of default commands, grouped by what they do. The **Access** column shows the default permission level required; you can adjust it per command in your dashboard. Click any command for its usage, parameters, and configuration.
## Points & Loyalty
[Section titled “Points & Loyalty”](#points--loyalty)
| Command | Access | Description |
| ------------------------------------------------------- | --------------- | --------------------------------------------------------- |
| [`!addpoints`](/chatbot/commands/default/addpoints) | Super Moderator | Add loyalty points to a viewer's balance. |
| [`!givepoints`](/chatbot/commands/default/givepoints) | Everyone | Transfer your loyalty points to another user. |
| [`!leaderboard`](/chatbot/commands/default/leaderboard) | Everyone | Get a link to the points or watch time leaderboard page. |
| [`!points`](/chatbot/commands/default/points) | Everyone | Check your own or another user's points balance and rank. |
| [`!setpoints`](/chatbot/commands/default/setpoints) | Super Moderator | Set a user's loyalty points balance. |
| [`!top`](/chatbot/commands/default/top) | Everyone | Display the top users by loyalty points or watch time. |
| [`!watchtime`](/chatbot/commands/default/watchtime) | Everyone | Check your own or another user's accumulated watch time. |
## Games & Betting
[Section titled “Games & Betting”](#games--betting)
| Command | Access | Description |
| ----------------------------------------------------- | --------- | ------------------------------------------------------------- |
| [`!accept`](/chatbot/commands/default/accept) | Everyone | Accept a pending duel challenge. |
| [`!bet`](/chatbot/commands/default/bet) | Everyone | Place loyalty points on an active betting contest. |
| [`!bingo`](/chatbot/commands/default/bingo) | Moderator | Emote bingo game; viewers guess emotes to win loyalty points. |
| [`!cancelduel`](/chatbot/commands/default/cancelduel) | Everyone | Cancel an outgoing duel request you initiated. |
| [`!contest`](/chatbot/commands/default/contest) | Everyone | Check the status of the currently active betting contest. |
| [`!deny`](/chatbot/commands/default/deny) | Everyone | Reject an incoming duel request. |
| [`!duel`](/chatbot/commands/default/duel) | Everyone | Challenge another user to a points duel. |
| [`!roulette`](/chatbot/commands/default/roulette) | Everyone | Gamble loyalty points for a chance to win or lose. |
| [`!slots`](/chatbot/commands/default/slots) | Everyone | Play a slot machine game with loyalty points. |
## Giveaways & Raffles
[Section titled “Giveaways & Raffles”](#giveaways--raffles)
| Command | Access | Description |
| --------------------------------------------------------- | --------- | -------------------------------------------------------------------------- |
| [`!cancelraffle`](/chatbot/commands/default/cancelraffle) | Moderator | Immediately cancel an active raffle. |
| [`!giveaway`](/chatbot/commands/default/giveaway) | Everyone | Check the status and link of the active channel giveaway. |
| [`!join`](/chatbot/commands/default/join) | Everyone | Enter an active raffle started with !sraffle or !raffle. |
| [`!raffle`](/chatbot/commands/default/raffle) | Moderator | Start a multi-winner raffle that splits the pot; viewers enter with !join. |
| [`!sraffle`](/chatbot/commands/default/sraffle) | Moderator | Start a single-winner raffle; viewers enter with !join. |
| [`!ticket`](/chatbot/commands/default/ticket) | Everyone | Purchase tickets for giveaways and raffles. |
## Song Requests
[Section titled “Song Requests”](#song-requests)
| Command | Access | Description |
| ------------------------------------------------------- | --------- | -------------------------------------------------------- |
| [`!next`](/chatbot/commands/default/next) | Everyone | Show the next song in the media request queue. |
| [`!pause`](/chatbot/commands/default/pause) | Moderator | Pause media request playback without clearing the queue. |
| [`!play`](/chatbot/commands/default/play) | Moderator | Resume paused media request playback. |
| [`!removesong`](/chatbot/commands/default/removesong) | Moderator | Remove a song by URL, or all of a user's songs. |
| [`!skip`](/chatbot/commands/default/skip) | Moderator | Moderators skip the current song in the queue. |
| [`!song`](/chatbot/commands/default/song) | Everyone | Show the currently playing song. |
| [`!songqueue`](/chatbot/commands/default/songqueue) | Moderator | Get a link to the current media request queue page. |
| [`!songrequest`](/chatbot/commands/default/songrequest) | Everyone | Add YouTube songs or videos to the media request queue. |
| [`!srclear`](/chatbot/commands/default/srclear) | Moderator | Clear the entire media request queue. |
| [`!volume`](/chatbot/commands/default/volume) | Everyone | Check or set the media request player volume. |
| [`!voteskip`](/chatbot/commands/default/voteskip) | Everyone | Let viewers vote to skip the current media request. |
| [`!when`](/chatbot/commands/default/when) | Everyone | Check the queue position of your latest song request. |
| [`!wrongsong`](/chatbot/commands/default/wrongsong) | Everyone | Remove the last song you added to the queue. |
## Viewer Queue
[Section titled “Viewer Queue”](#viewer-queue)
| Command | Access | Description |
| ------------------------------------------- | -------- | ------------------------------------------------------------------- |
| [`!queue`](/chatbot/commands/default/queue) | Everyone | Manage viewer queues for activities like playing with the streamer. |
## Store
[Section titled “Store”](#store)
| Command | Access | Description |
| ----------------------------------------------------- | --------- | ------------------------------------------------------------ |
| [`!closestore`](/chatbot/commands/default/closestore) | Moderator | Disable all regular (non-SFX) items in the loyalty store. |
| [`!disablesfx`](/chatbot/commands/default/disablesfx) | Moderator | Disable all sound effect (SFX) items in the loyalty store. |
| [`!enablesfx`](/chatbot/commands/default/enablesfx) | Moderator | Re-enable all sound effect (SFX) items in the loyalty store. |
| [`!items`](/chatbot/commands/default/items) | Everyone | Get a link to the channel's loyalty store page. |
| [`!openstore`](/chatbot/commands/default/openstore) | Moderator | Re-enable all regular (non-SFX) items in the loyalty store. |
| [`!redeem`](/chatbot/commands/default/redeem) | Everyone | Redeem loyalty store items using points. |
## Stream Management
[Section titled “Stream Management”](#stream-management)
| Command | Access | Description |
| ------------------------------------------------------- | --------------- | ------------------------------------------------------------- |
| [`!alerts`](/chatbot/commands/default/alerts) | Moderator | Mute, skip, or pause overlay alerts from chat. |
| [`!editcounter`](/chatbot/commands/default/editcounter) | Moderator | Set, increment, or decrement custom counter values from chat. |
| [`!hypecup`](/chatbot/commands/default/hypecup) | Super Moderator | Clear the HypeCup overlay contribution list. |
| [`!setgame`](/chatbot/commands/default/setgame) | Super Moderator | Update the stream's game category on Twitch. |
| [`!settitle`](/chatbot/commands/default/settitle) | Super Moderator | Moderators change the Twitch stream title. |
| [`!timer`](/chatbot/commands/default/timer) | Moderator | Enable or disable specific chat timers. |
## Moderation
[Section titled “Moderation”](#moderation)
| Command | Access | Description |
| --------------------------------------------------------- | --------------- | --------------------------------------------------------------- |
| [`!filesay`](/chatbot/commands/default/filesay) | Super Moderator | Send multiple lines of text from a URL to chat. |
| [`!level`](/chatbot/commands/default/level) | Super Moderator | View and manually override user permission levels. |
| [`!nuke`](/chatbot/commands/default/nuke) | Super Moderator | Timeout, ban, or delete recent messages matching text or regex. |
| [`!nukeusername`](/chatbot/commands/default/nukeusername) | Super Moderator | Timeout or ban users whose usernames match text or regex. |
| [`!permit`](/chatbot/commands/default/permit) | Moderator | Temporarily allow a user to post links without being timed out. |
| [`!vanish`](/chatbot/commands/default/vanish) | Everyone | Time yourself out for 1 second to clear your messages. |
| [`!votekick`](/chatbot/commands/default/votekick) | Moderator | Start a community vote to temporarily kick a user. |
## Bot & Command Management
[Section titled “Bot & Command Management”](#bot--command-management)
| Command | Access | Description |
| ------------------------------------------------- | --------------- | ------------------------------------------------------ |
| [`!bot`](/chatbot/commands/default/bot) | Super Moderator | Mute, unmute, or remove the bot from chat. |
| [`!command`](/chatbot/commands/default/command) | Moderator | Add, remove, edit, or alias custom commands from chat. |
| [`!commands`](/chatbot/commands/default/commands) | Everyone | Get a link to the channel's public commands list. |
| [`!module`](/chatbot/commands/default/module) | Super Moderator | Enable or disable chatbot modules from chat. |
## Fun & Emotes
[Section titled “Fun & Emotes”](#fun--emotes)
| Command | Access | Description |
| ----------------------------------------------------- | --------- | ----------------------------------------------------------- |
| [`!8ball`](/chatbot/commands/default/8ball) | Everyone | Receive a random magic 8-ball style answer to a question. |
| [`!emotecount`](/chatbot/commands/default/emotecount) | Everyone | Display the usage frequency of a specific emote. |
| [`!emotes`](/chatbot/commands/default/emotes) | Everyone | List Twitch, BTTV, FFZ, or 7TV emotes, or reload the cache. |
| [`!kappagen`](/chatbot/commands/default/kappagen) | Moderator | Trigger an emote explosion via the Kappagen overlay widget. |
| [`!quote`](/chatbot/commands/default/quote) | Everyone | Display random saved quotes or manage the quote list. |
## Stream Info & Utility
[Section titled “Stream Info & Utility”](#stream-info--utility)
| Command | Access | Description |
| ----------------------------------------------------- | -------- | ----------------------------------------------------- |
| [`!accountage`](/chatbot/commands/default/accountage) | Everyone | Check the creation date of any Twitch account. |
| [`!chatstats`](/chatbot/commands/default/chatstats) | Everyone | Get a link to the channel's chat statistics page. |
| [`!followage`](/chatbot/commands/default/followage) | Everyone | Check how long a user has been following the channel. |
| [`!tip`](/chatbot/commands/default/tip) | Everyone | Get a link to the channel's tipping page. |
| [`!uptime`](/chatbot/commands/default/uptime) | Everyone | Check the current stream's duration. |
# !8ball
> Ask the StreamElements chatbot a question with the !8ball command and receive a random, magic 8-ball style answer.
The `!8ball` command simulates a magic 8-ball toy: ask it a question and it answers with a random verdict.
## Usage
[Section titled “Usage”](#usage)
To use the command, type `!8ball` followed by an optional question in the chat. The chatbot will respond with a random fortune-like answer.
```streamelements
!8ball [question]
```
The `[question]` part is entirely optional and does not influence the random outcome.
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!8ball Will I win my next game?
StreamElements:It is decidedly so.
Example chat
ViewerName:!8ball What should I have for dinner?
StreamElements:Cannot predict now.
## Configuration
[Section titled “Configuration”](#configuration)
Enable the 8ball module under `Chatbot` -> `Modules`, where you can also customize the list of possible responses the command draws from.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!roulette`](/chatbot/commands/default/roulette): Gamble loyalty points for a chance to win or lose.
* [`!slots`](/chatbot/commands/default/slots): Play a slot machine game with loyalty points.
# !accept
> Use the !accept command to accept pending duel challenges initiated with the !duel command in StreamElements chatbot.
The `!accept` command allows users to accept pending duel requests initiated by the [`!duel`](/chatbot/commands/default/duel) command. A duel request must be accepted within **2 minutes**, otherwise it expires. Once accepted, the duel resolves immediately: the winner is decided by a 50/50 coin flip, gaining the wagered points while the loser loses them.
## Usage
[Section titled “Usage”](#usage)
To use the `!accept` command, simply type it in the chat when you have a pending duel request.
```streamelements
!accept
```
## Examples
[Section titled “Examples”](#examples)
Example chat
Challenger:!duel TargetUser 100
StreamElements:@TargetUser, @Challenger wants to duel you for 100 points, you can !accept or !deny within 2 minutes
TargetUser:!accept
StreamElements:TargetUser won the Duel vs Challenger PogChamp
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!duel`](/chatbot/commands/default/duel): Initiate a duel with another user.
* [`!cancelduel`](/chatbot/commands/default/cancelduel): Cancel an outgoing duel request.
* [`!deny`](/chatbot/commands/default/deny): Deny an incoming duel request.
# !accountage
> Check the creation date (age) of any Twitch account using the StreamElements chatbot !accountage command. Useful for moderation and verification.
The `!accountage` command shows how old a Twitch account is — a quick way for moderators to spot freshly created accounts.
## Usage
[Section titled “Usage”](#usage)
To use the command, type `!accountage` followed by an optional username. If no username is provided, it checks the account age of the user running the command.
```streamelements
!accountage [username]
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!accountage StreamElements
StreamElements:@ModUser, StreamElements was created 10 years 2 months 28 days 7 hours ago.
Example chat
ViewerBob:!accountage
StreamElements:@ViewerBob, your account was created 3 years 5 months 12 days 4 hours ago.
## Parameters
[Section titled “Parameters”](#parameters)
* `[username]` (Optional): The Twitch username of the account you want to check. If omitted, the command checks the account age of the user who issued the command.
## Configuration
[Section titled “Configuration”](#configuration)
This command requires a connection to Twitch to fetch the account creation date. Ensure your StreamElements bot account is properly linked to Twitch.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!followage`](/chatbot/commands/default/followage): Checks how long a user has been following the channel.
# !addpoints
> Moderators can manually add loyalty points to a viewer's balance using the StreamElements !addpoints chatbot command.
The `!addpoints` command manually adds loyalty points to a viewer’s balance — for one-off rewards or for correcting a balance.
## Usage
[Section titled “Usage”](#usage)
To add points to a viewer, use the following syntax in your chat:
```streamelements
!addpoints
```
## Examples
[Section titled “Examples”](#examples)
Example chat
BroadcasterName:!addpoints StreamFan123 1000
StreamElements:@BroadcasterName, added 1000 points to StreamFan123. They now have 5961 points.
Example chat
ModUser99:!addpoints LoyalViewer 50
StreamElements:@ModUser99, added 50 points to LoyalViewer. They now have 1280 points.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact username of the viewer receiving points.
* `` (Required): The number of points (positive integer) to award.
## Configuration
[Section titled “Configuration”](#configuration)
* Enable the **Loyalty system** in your **StreamElements Dashboard** under **Loyalty** -> **Loyalty Settings**.
* The command’s permission level can be adjusted under **Chatbot** -> **Chat Commands** -> **Default Commands**.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!setpoints`](/chatbot/commands/default/setpoints): Set a user’s points to a specific value.
* [`!givepoints`](/chatbot/commands/default/givepoints): Allow users to give points to each other.
* [`!points`](/chatbot/commands/default/points): Check a user’s current point balance.
# !alerts
> Control StreamElements overlay alerts (mute, skip, pause) in real-time directly from chat using the !alerts command. Essential for stream management.
The `!alerts` command allows streamers and moderators to dynamically manage StreamElements overlay alerts during a live broadcast. This tool helps control alert playback directly from chat for actions like muting, skipping, or pausing.
Note
The `!alerts` command is **disabled by default**. Enable it under `Chatbot` -> `Chat Commands` -> `Default Commands` before using it.
## Usage
[Section titled “Usage”](#usage)
To manage overlay alerts, use the `!alerts` command followed by the desired action.
```streamelements
!alerts
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!alerts mute
StreamElements:Successfully muted alerts
Example chat
BroadcasterName:!alerts skip
StreamElements:Successfully skipped alerts
Example chat
ModUser:!alerts pause
StreamElements:Successfully paused alerts
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The action to perform on the alerts. Valid actions are:
* `mute`: Turns off alert sounds.
* `unmute`: Turns alert sounds back on.
* `skip`: Skips the currently playing alert.
* `pause`: Pauses the alert queue; currently playing alerts will finish.
* `unpause`: Resumes the alert queue.
## Configuration
[Section titled “Configuration”](#configuration)
* This command controls alerts within your StreamElements overlays. Ensure your overlays are active.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [Chat Alerts module](/chatbot/modules/chatalerts): Not to be confused with `!alerts` — it posts chat *messages* for events like follows and subscriptions, and does not control overlay alerts.
# !bet
> Allow viewers to participate in stream betting contests using their loyalty points with the StreamElements chatbot !bet command.
The `!bet` command allows viewers to use their loyalty points to bet on the outcome of a contest or event defined by the streamer. This command is used **while a bet is active**, which is initiated through the StreamElements Dashboard. Viewers can check the active contest with [`!contest`](/chatbot/commands/default/contest).
## Usage
[Section titled “Usage”](#usage)
To place a bet while a betting contest is open, viewers use the following syntax:
```streamelements
!bet
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!bet win 100
StreamElements:@ViewerName, you have bet 100 points on Win.
Example chat
HighRoller:!bet lose 5k
StreamElements:@HighRoller, you have bet 5000 points on Lose.
Example chat
PercentBetta:!bet optionA 25%
StreamElements:@PercentBetta, you have bet 750 points on optionA.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The specific betting option the viewer wants to choose (defined by the streamer when starting the bet).
* `` (Required): The number of loyalty points to wager. This can be a specific number, a percentage (`50%`), or use `k` for thousands (`5k`), `m` for millions (`1m`). The amount must stay within the minimum and maximum bet configured for the contest.
## Configuration
[Section titled “Configuration”](#configuration)
* Betting contests can only be **started from the StreamElements Dashboard** — there is no chat command to create one. Streamers define the options, duration, minimum/maximum bet, and other settings there.
* Viewers need sufficient loyalty points to place a bet.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!contest`](/chatbot/commands/default/contest): Checks the status and details of the currently active betting contest.
* [`!points`](/chatbot/commands/default/points): Checks a user’s current loyalty point balance.
# !bingo
> Engage viewers with an interactive emote bingo game using the !bingo command in StreamElements chatbot. Award loyalty points for guessing emotes.
The `!bingo` command starts an interactive emote bingo game in your chat. It randomly selects an emote from a specified platform (Twitch, BTTV, FFZ, 7TV), and viewers try to guess the correct emote to win loyalty points.
## Usage
[Section titled “Usage”](#usage)
Use this command to start a new bingo game.
```streamelements
!bingo
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!bingo twitch 100
StreamElements:Bingo started! Guess the Twitch emote to win 100 points!
viewer1:Kappa
viewer2:LUL
viewer3:PogChamp
StreamElements:Congratulations viewer3! You guessed the correct emote PogChamp and won 100 points!
Example chat
BroadcasterName:!bingo all 250
StreamElements:Bingo started! Guess the emote (Twitch, BTTV, FFZ, 7TV) to win 250 points!
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The platform(s) to use for emotes. Valid options:
* `twitch`: Twitch global and channel emotes.
* `bttv`: BetterTTV emotes.
* `ffz`: FrankerFaceZ emotes.
* `7tv`: 7TV emotes.
* `all`: Includes emotes from all supported platforms.
* `` (Required): The number of loyalty points to reward the winner.
## Configuration
[Section titled “Configuration”](#configuration)
* A **Loyalty system** must be active. Enable it under `Loyalty` -> `Loyalty Settings`.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* You can customize the bingo game by adjusting the reward amount and using different emote platforms to vary the game’s difficulty.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Check a user’s current loyalty points balance.
* [`!top`](/chatbot/commands/default/top): See the leaderboard for points or watch time.
# !bot
> Manage your StreamElements chatbot with the !bot command. Control bot behavior, including muting, unmuting, and removing the bot from chat.
The `!bot` command allows streamers and moderators to control the behavior of the StreamElements chatbot during a stream. This command provides essential functions for managing the bot’s presence and activity in the chat via several subcommands.
## Usage
[Section titled “Usage”](#usage)
The `!bot` command uses the following general structure:
```streamelements
!bot
```
## Subcommands
[Section titled “Subcommands”](#subcommands)
This section details the available subcommands for `!bot`.
### mute
[Section titled “mute”](#mute)
Temporarily prevents the bot from sending *any* messages (including commands and timers) in the chat.
**Syntax**
```streamelements
!bot mute
```
**Example**
Example chat
ModUser:!bot mute
StreamElements:@Moderator, I have been muted.
### unmute
[Section titled “unmute”](#unmute)
Allows the bot to resume sending messages in the chat after being muted.
**Syntax**
```streamelements
!bot unmute
```
**Example**
Example chat
BroadcasterName:!bot unmute
StreamElements:@Broadcaster, I have been unmuted.
### part
[Section titled “part”](#part)
Makes the bot leave the chat channel entirely. The bot will need to be invited back manually via the StreamElements dashboard if you wish for it to return.
**Syntax**
```streamelements
!bot part
```
**Example**
Example chat
BroadcasterName:!bot part
StreamElements has left the channel.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!commands`](/chatbot/commands/default/commands): Lists all available bot commands.
* [`!command`](/chatbot/commands/default/command): Manages custom commands.
* [`!module`](/chatbot/commands/default/module): Enables or disables chatbot modules.
## FAQ
[Section titled “FAQ”](#faq)
* **How do I get the bot back after using `!bot part`?** You need to go to your StreamElements dashboard, navigate to the Chatbot settings, and click the button to make the bot join your channel again.
* **Does `!bot mute` stop timers?** Yes, muting the bot prevents it from sending timer messages as well as command responses.
# !cancelduel
> Use the !cancelduel command in StreamElements chatbot to stop an outgoing duel request you initiated.
The `!cancelduel` command allows a user to cancel an **outgoing** duel request they initiated with the [`!duel`](/chatbot/commands/default/duel) command *before* the challenged user accepts or denies it. If a request is never answered, it expires on its own after **2 minutes**.
## Usage
[Section titled “Usage”](#usage)
To cancel your pending outgoing duel request, simply type the command in chat:
```streamelements
!cancelduel
```
## Examples
[Section titled “Examples”](#examples)
Example chat
Challenger:!duel TargetUser 100
StreamElements:@TargetUser, @Challenger wants to duel you for 100 points, you can !accept or !deny within 2 minutes
Challenger:!cancelduel
StreamElements:@Challenger, Duel request cancelled.
Example chat
ViewerName:!cancelduel
StreamElements:@UserName, You do not have any pending outgoing duel requests.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!duel`](/chatbot/commands/default/duel): Initiate a duel with another user.
* [`!accept`](/chatbot/commands/default/accept): Accept an incoming duel request.
* [`!deny`](/chatbot/commands/default/deny): Deny an incoming duel request.
# !cancelraffle
> Immediately cancel an active raffle on your channel using the StreamElements chatbot !cancelraffle command.
The `!cancelraffle` command allows streamers and moderators to immediately halt any active raffle or giveaway initiated by [`!raffle`](/chatbot/commands/default/raffle) or [`!sraffle`](/chatbot/commands/default/sraffle) on their channel.
## Usage
[Section titled “Usage”](#usage)
To cancel an ongoing raffle, use the following command in chat:
```streamelements
!cancelraffle
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!cancelraffle
StreamElements:The raffle was canceled!
Example chat
BroadcasterName:!cancelraffle
StreamElements:There is no active raffle to cancel.
## Configuration
[Section titled “Configuration”](#configuration)
* The `!cancelraffle` command requires the **Raffle module** to be active. Enable it in your **StreamElements Dashboard** under `Chatbot` -> `Modules`.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!raffle`](/chatbot/commands/default/raffle): Starts a multi-winner raffle that splits the points pot among the winners.
* [`!sraffle`](/chatbot/commands/default/sraffle): Starts a single-winner raffle where one winner takes the full pot.
# !chatstats
> Use the !chatstats command in StreamElements chatbot to view a link to the channel's detailed chat statistics page.
The `!chatstats` command provides a direct link to the streamer’s detailed chat statistics page on StreamElements. This allows anyone in chat to easily access information about chat activity, top chatters, command usage, and more.
## Usage
[Section titled “Usage”](#usage)
To get the link to the chat statistics page, simply type the command in chat:
```streamelements
!chatstats
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!chatstats
StreamElements:Chat stats can be found here: https\://stats.streamelements.com/c/YOUR\_CHANNEL\_NAME PogChamp
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!top`](/chatbot/commands/default/top): Displays the top chatters or point leaders directly in chat.
* [`!emotecount`](/chatbot/commands/default/emotecount): Checks how many times a specific emote has been used in chat.
* [`!uptime`](/chatbot/commands/default/uptime): Shows how long the current stream has been live.
* [`!followage`](/chatbot/commands/default/followage): Tells a user how long they’ve been following the channel (Twitch only).
* [`!watchtime`](/chatbot/commands/default/watchtime): Shows how long a user has been watching the stream (requires Loyalty module).
# !closestore
> Use the !closestore command in StreamElements chatbot to quickly disable all regular (non-SFX) items in your loyalty store.
The `!closestore` command allows streamers and moderators to quickly disable all **regular** (non-sound effect) items in the StreamElements loyalty store. This is useful for temporarily preventing viewers from redeeming items while making updates or during specific stream segments.
## Usage
[Section titled “Usage”](#usage)
To disable all regular store items, use the following command in chat:
```streamelements
!closestore
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!closestore
StreamElements:@Moderator, successfully updated 15 items.
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!openstore`](/chatbot/commands/default/openstore): Re-enables all regular items in the loyalty store.
* [`!disablesfx`](/chatbot/commands/default/disablesfx): Disables only sound effect (SFX) items in the loyalty store.
* [`!enablesfx`](/chatbot/commands/default/enablesfx): Enables only sound effect (SFX) items in the loyalty store.
* [`!redeem`](/chatbot/commands/default/redeem): Allows viewers to redeem store items.
# !command
> Manage StreamElements chatbot custom commands directly from chat using the !command (!cmd) functions: add, remove, edit, alias, show, options.
The `!command` (aliased as `!cmd`) command suite allows streamers and moderators with the appropriate permissions to manage custom chat commands directly from the chat interface. It provides subcommands to add, remove, edit, view aliases, show details, and configure advanced options for any custom command.
## Usage
[Section titled “Usage”](#usage)
The general syntax follows this pattern:
```streamelements
!command [arguments...]
```
Or using the alias:
```streamelements
!cmd [arguments...]
```
Replace `` with one of the functions listed below and `[arguments...]` with the required parameters for that specific subcommand.
## Subcommands
[Section titled “Subcommands”](#subcommands)
Here are the available subcommands for `!command`:
### add
[Section titled “add”](#add)
Creates a new custom command.
**Syntax:**
```streamelements
!command add !
```
**Example:**
Example chat
ModUser:!command add !socials Follow me on Twitter @MyHandle!
StreamElements:@Moderator, successfully added command !socials.
### remove
[Section titled “remove”](#remove)
Deletes an existing custom command.
**Syntax:**
```streamelements
!command remove !
```
**Example:**
Example chat
ModUser:!command remove !socials
StreamElements:@Moderator, successfully removed command !socials.
### edit
[Section titled “edit”](#edit)
Changes the response text of an existing custom command.
**Syntax:**
```streamelements
!command edit !
```
**Example:**
Example chat
ModUser:!command edit !socials Check out my links: example.com/links
StreamElements:@Moderator, successfully updated command !socials.
### alias
[Section titled “alias”](#alias)
Shows the aliases associated with a specific command, or adds/removes an alias.
**Syntax:**
```streamelements
!command alias !
!command alias add ! !
!command alias remove ! !
```
Note
Listing aliases only works with the original command name, not with one of its aliases.
**Example (listing aliases):**
Example chat
ModUser:!command alias !socials
StreamElements:@Moderator, Command !socials has aliases: !links, !connect
**Example (adding an alias):**
Example chat
ModUser:!command alias add !socials !links
StreamElements:@Moderator, successfully added alias !links to command !socials.
**Example (removing an alias):**
Example chat
ModUser:!command alias remove !socials !links
StreamElements:@Moderator, successfully removed alias !links from command !socials.
### show
[Section titled “show”](#show)
Displays the full response text and configuration details (level, cost, cooldowns) of a command.
**Syntax:**
```streamelements
!command show !
```
**Example:**
Example chat
ModUser:!command show !socials
StreamElements:@Moderator, Command !socials: Check out my links: example.com/links (Level: Everyone, Cost: 0, Cooldown: 5s, User Cooldown: 15s)
### options
[Section titled “options”](#options)
Configures advanced settings like cooldowns, cost, permission level, response type, trigger name, enabled status, and usage count for a command. See the [Parameters](#parameters-for-options-subcommand) section below for details on the available options.
**Syntax:**
```streamelements
!command options ! [option2] [value2] ...
```
Note
Replace `option1`, `value1`, etc., with the specific parameter flags and values listed in the Parameters section below. You can specify multiple options.
**Example (setting multiple options):**
Example chat
ModUser:!command options !socials -cd 10 -usercd 30 -cost 50 -level 500
StreamElements:@Moderator, successfully updated command !socials.
## Parameters (for `options` subcommand)
[Section titled “Parameters (for options subcommand)”](#parameters-for-options-subcommand)
When using the `!command options` subcommand, you specify settings using flags followed by their values. You can set multiple options in a single message. These parameters allow fine-grained control over a command’s behavior:
| Parameter | Description | Accepted Values | Example Usage |
| ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------- | ----------------- |
| `-cd` | Sets the **global command cooldown** (minimum time between *any* use of the command). | `` (e.g., `10`) | `-cd 10` |
| `-usercd` | Sets the **user-specific cooldown** (minimum time the *same user* must wait before using the command again). | `` (e.g., `30`) | `-usercd 30` |
| `-cost` | Sets the **loyalty points cost** charged each time the command is used. If a user doesn’t have enough points, the command silently does nothing (no error message is sent). Requires the StreamElements [Loyalty System](https://support.streamelements.com/hc/en-us/articles/10474478470290-Loyalty-System-Overview) (enabled in the dashboard under **Loyalty** → **Loyalty Settings**). | `` (e.g., `50`) | `-cost 50` |
| `-level` | Sets the **minimum user permission level** required. Takes a **number**: `100` (Everyone), `250` (Subscriber), `300` (Regular), `400` (VIP), `500` (Moderator), `1000` (Super Moderator). No other values are accepted. | `` (e.g., `500`) | `-level 500` |
| `-type` | Sets **how the bot responds**. Platform support for `reply`, `mention`, and `whisper` may vary. | `say` (default), `reply`, `mention`, `whisper` | `-type whisper` |
| `-trigger` | **Renames the command**, changing the trigger word used to invoke it. | `` (e.g., `!links`) | `-trigger !links` |
| `-enable` | Enables the command. | N/A | `-enable` |
| `-disable` | Disables the command, preventing anyone from using it. | N/A | `-disable` |
| `-count` | **Manually sets the command’s usage counter**, useful for resetting or adjusting the value used by [`$(count)`](/chatbot/variables/count). | `` (e.g., `0`) | `-count 0` |
## Subcommand aliases
[Section titled “Subcommand aliases”](#subcommand-aliases)
Each subcommand also accepts its own shorthand aliases:
* **`remove`:** `delete`, `del`, `rem`
* **`edit`:** `update`
* **`alias`:** `aliases`
* **`show`:** `debug`
* **`options`:** `option`, `opt`, `opts`, `o`, `🔧`
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!commands`](/chatbot/commands/default/commands): Lists available commands.
* [`$(count)`](/chatbot/variables/count): Variable to display the usage count of a command.
* [`$(user)`](/chatbot/variables/user): Variable representing the user executing the command.
* [`$(channel)`](/chatbot/variables/channel): Variable representing the channel name.
* See the full list of [Chatbot Variables](/chatbot/variables).
## FAQ
[Section titled “FAQ”](#faq)
* **What’s the difference between global cooldown (`-cd`) and user cooldown (`-usercd`)?** Global cooldown (`-cd`) applies to *everyone* – once the command is used, no one can use it again until the cooldown expires. User cooldown (`-usercd`) applies only to the *individual user* – they have to wait, but other users can still use the command if the global cooldown has passed.
* **How do I reset a command’s usage counter?** Use the `options` subcommand with the `-count` parameter: `!command options ! -count 0`
* **Can I make a command respond with a whisper instead of a public message?** Yes, use the `options` subcommand with the `-type` parameter: `!command options ! -type whisper`. Note that whisper functionality depends on the chat platform.
* **How do I add or remove a command alias via chat?** Use the `alias` subcommand with `add` or `remove`: `!command alias add ! !` or `!command alias remove ! !`.
* **I’m a moderator, but `!command add` isn’t working. Why?** Double-check that the `!command` default command itself hasn’t been disabled or had its permission level changed from the default (Moderator). You can check its settings in the `Default Commands` section of your StreamElements Dashboard.
# !commands
> Use the !commands command in StreamElements chatbot to display a link to the creator's public commands list page.
The `!commands` command provides viewers with a link to the streamer’s public StreamElements commands page. This page lists all enabled default and custom commands for the channel, making it easy for viewers to discover available interactions.
## Usage
[Section titled “Usage”](#usage)
To get the link to the commands page, simply type the command in chat:
```streamelements
!commands
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!commands
StreamElements:You can find a list of all Commands here https\://streamelements.com/styler/commands
## Configuration
[Section titled “Configuration”](#configuration)
* This command is enabled by default.
* The public commands page only shows commands that are currently enabled.
* The list updates automatically based on your command settings in the StreamElements dashboard.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!command`](/chatbot/commands/default/command): Used by moderators/streamers to manage custom commands directly via chat.
# !contest
> Use the !contest command in StreamElements chatbot to check the status and details of the currently active betting contest.
The `!contest` command allows anyone in chat to quickly check the status and details of the currently active **betting contest**. It displays the contest question, the available betting options, and the remaining time to place bets.
Note
This command *checks* the status of an active contest. To *start* a new betting contest, moderators must use the **StreamElements Dashboard**.
## Usage
[Section titled “Usage”](#usage)
To check the active contest details, simply type the command in chat:
```streamelements
!contest
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!contest
StreamElements:@User, the current contest is "Will I clutch this round?". You can !bet for yes, no. Betting ends in 3 mins 15 secs
Example chat
ViewerName:!contest
StreamElements:@User, there is no active contest.
## Configuration
[Section titled “Configuration”](#configuration)
* The command response reflects the settings of the currently active contest (question, options, duration) configured by the streamer/moderator via the dashboard.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!bet`](/chatbot/commands/default/bet): Used by viewers to place bets on the active contest.
# !deny
> Use the !deny command in StreamElements chatbot to reject incoming duel requests initiated with the !duel command.
The `!deny` command allows a user to reject an **incoming** duel request initiated by another user with the [`!duel`](/chatbot/commands/default/duel) command. Duel requests expire on their own after **2 minutes** if neither accepted nor denied.
## Usage
[Section titled “Usage”](#usage)
To reject a pending incoming duel request, type the command in chat:
```streamelements
!deny
```
## Examples
[Section titled “Examples”](#examples)
Example chat
Challenger:!duel TargetUser 100
StreamElements:@TargetUser, @Challenger wants to duel you for 100 points, you can !accept or !deny within 2 minutes
TargetUser:!deny
StreamElements:@TargetUser denied the duel request from @Challenger.
Example chat
ViewerName:!deny
StreamElements:@UserName, You do not have any pending incoming duel requests to deny.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!duel`](/chatbot/commands/default/duel): Initiate a duel with another user.
* [`!accept`](/chatbot/commands/default/accept): Accept an incoming duel request.
* [`!cancelduel`](/chatbot/commands/default/cancelduel): Cancel an *outgoing* duel request you initiated.
# !disablesfx
> Use the !disablesfx command in StreamElements chatbot to quickly disable all sound effect (SFX) items in your loyalty store.
The `!disablesfx` command allows streamers and moderators to quickly disable all **sound effect** (SFX) items in the StreamElements loyalty store. This is useful for temporarily preventing viewers from redeeming SFX during specific stream segments or when managing audio.
## Usage
[Section titled “Usage”](#usage)
To disable all SFX store items, use the following command in chat:
```streamelements
!disablesfx
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!disablesfx
StreamElements:@Moderator, successfully updated 5 items.
## Configuration
[Section titled “Configuration”](#configuration)
* Manage your store’s SFX items in your **StreamElements Dashboard** under `Loyalty` -> `Stream Store`.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!enablesfx`](/chatbot/commands/default/enablesfx): Re-enables all sound effect (SFX) items in the loyalty store.
* [`!closestore`](/chatbot/commands/default/closestore): Disables all *regular* (non-SFX) items in the loyalty store.
* [`!openstore`](/chatbot/commands/default/openstore): Enables all *regular* (non-SFX) items in the loyalty store.
* [`!redeem`](/chatbot/commands/default/redeem): Allows viewers to redeem store items.
# !duel
> Use the !duel command in StreamElements chatbot to challenge other users to a points duel in Twitch chat.
The `!duel` command allows users to challenge another user in chat to a duel, optionally wagering their loyalty points. The challenged user then has **2 minutes** to respond using [`!accept`](/chatbot/commands/default/accept) or [`!deny`](/chatbot/commands/default/deny). If the duel is accepted, the winner is decided by a 50/50 coin flip — the winner gains the wagered points and the loser loses them.
## Usage
[Section titled “Usage”](#usage)
To initiate a duel challenge, use the following syntax:
```streamelements
!duel [points]
```
## Examples
[Section titled “Examples”](#examples)
Example chat
Challenger:!duel TargetUser 100
StreamElements:@TargetUser, @Challenger wants to duel you for 100 points, you can !accept or !deny within 2 minutes
Example chat
ViewerName:!duel SelfUser 50
StreamElements:@SelfUser, you cannot duel yourself Kappa
Example chat
ViewerName:!duel AnotherUser 10000
StreamElements:@User, you do not have enough points to duel for 10000.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact username of the user you want to challenge.
* `[points]` (Optional): The number of loyalty points you want to wager. There is no minimum and no default — if you leave it out, the duel is played for 0 points. Shorthand values are supported: `k` for thousands (`5k`), `m` for millions (`1m`), a percentage of your balance (`50%`), or `all`. The wager cannot exceed either participant’s current balance, and wagers above the module’s **Maximum amount** setting are automatically capped to that maximum.
## Configuration
[Section titled “Configuration”](#configuration)
Within the Duel module settings, you can customize:
* **Maximum amount**: The highest number of points users can wager in a single duel.
* **User cooldown**: How long (in seconds) an individual user must wait before initiating another duel after participating in one.
* **Global cooldown**: How long (in seconds) everyone must wait after a duel finishes before *anyone* can start a new one.
* **Win message**: The chat message displayed when a user wins the duel.
* Available variables: `{winner}`, `{loser}`
* **Points won message**: The chat message displayed when points are awarded after a duel.
* Available variables: `{winner}`, `{loser}`, `{points}`, `{pointsname}`
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!accept`](/chatbot/commands/default/accept): Used by the challenged user to accept a duel.
* [`!deny`](/chatbot/commands/default/deny): Used by the challenged user to decline a duel.
* [`!cancelduel`](/chatbot/commands/default/cancelduel): Used by the challenger to cancel their *outgoing* duel request.
* [`!points`](/chatbot/commands/default/points): Check your current loyalty points balance.
# !editcounter
> Use the !editcounter command in StreamElements chatbot to set, increment, or decrement custom counter values directly from chat.
The `!editcounter` command allows streamers and moderators to modify the value of a pre-defined custom counter directly from chat. Counters are useful for tracking things like deaths in a game, wins, specific events, or any other metric you want to display or reference.
Note
Counters must first be created in the StreamElements Dashboard under `Chatbot` -> `Counters`.
## Usage
[Section titled “Usage”](#usage)
To modify a counter, use the following syntax:
```streamelements
!editcounter
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!editcounter deaths +1
StreamElements:@Moderator, changed the deaths counter from 5 to 6.
Example chat
BroadcasterName:!editcounter wins 10
StreamElements:@Broadcaster, changed the wins counter from 9 to 10.
Example chat
ModUser:!editcounter donations -5
StreamElements:@Moderator, changed the donations counter from 100 to 95.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact name of the counter you created in the Dashboard (case-sensitive).
* `` (Required): The value to apply. It can be:
* A number (e.g., `15`): Sets the counter to this exact value.
* `+number` (e.g., `+1`): Increments the counter by this amount.
* `-number` (e.g., `-3`): Decrements the counter by this amount.
## Configuration
[Section titled “Configuration”](#configuration)
* Counters must be created in the **StreamElements Dashboard** under `Chatbot` -> `Counters` before they can be edited via this command.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* `$(count )`: This variable displays the current value of the specified counter. It can be used in other commands or titles. Example: `!deathcount - Current deaths: $(count deaths)`
# !emotecount
> Use the !emotecount command in StreamElements chatbot to display the usage frequency of a specific emote in your chat.
The `!emotecount` command allows anyone in chat to check how many times a specific emote has been used in the channel’s chat history (since tracking began).
Note
The `!emotecount` command is **disabled by default**. Enable it under `Chatbot` -> `Chat Commands` -> `Default Commands` before using it.
## Usage
[Section titled “Usage”](#usage)
To check the count for a specific emote, use the following syntax:
```streamelements
!emotecount
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!emotecount Kappa
StreamElements:@User, The emote Kappa has been used 15731 times! PogChamp
Example chat
ViewerName:!emotecount channelCoolEmote
StreamElements:@User, The emote channelCoolEmote has been used 452 times! PogChamp
Example chat
ViewerName:!emotecount NonExistentEmote
StreamElements:@User, The emote NonExistentEmote was not found. NotLikeThis
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact name of the emote you want to check (case-sensitive). This can be a global emote, channel emote, or third-party emote (BTTV, FFZ, 7TV) if enabled.
## Configuration
[Section titled “Configuration”](#configuration)
* Emote usage tracking is handled automatically by StreamElements when the bot is active in the channel.
* The accuracy depends on when the bot joined and started tracking messages.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!emotes`](/chatbot/commands/default/emotes): Provides a link to view the channel’s available third-party emotes (BTTV, FFZ, 7TV).
## FAQ
[Section titled “FAQ”](#faq)
* **Why is the count different from what I expected?** The count reflects usage only since StreamElements started tracking messages in this channel. It might not include historical usage before the bot was added or if there were periods the bot was inactive.
# !emotes
> Use the !emotes command in StreamElements chatbot to list available emotes from Twitch, BTTV, FFZ, or 7TV, or to reload the entire emote cache.
The `!emotes` command serves two primary functions:
1. **List Platform Emotes:** When followed by a platform name (`twitch`, `bttv`, `ffz`, `7tv`), it lists the active emotes from that specific provider directly in chat.
2. **Reload Emote Cache (Moderator+):** Using the `reload` keyword, moderators can refresh the bot’s internal cache of emotes for **all** platforms (Twitch, BTTV, FFZ, 7TV) simultaneously.
## Usage
[Section titled “Usage”](#usage)
**To list active emotes for a specific platform:**
```streamelements
!emotes
```
* ``: Required. The platform whose emotes you want to list. Valid options: `twitch`, `bttv`, `ffz`, `7tv`.
**To reload the emote cache:**
```streamelements
!emotes reload
```
* This refreshes the bot’s internal cache of available emotes for **all** platforms (Twitch, BTTV, FFZ, 7TV).
* It is useful if new emotes have been added or changed and aren’t showing up correctly.
Permissions
Using `!emotes reload` requires **Moderator** permission level or higher by default. This can be adjusted in the StreamElements Dashboard under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Examples
[Section titled “Examples”](#examples)
**Listing active FFZ emotes:**
Example chat
ViewerName:!emotes ffz
StreamElements:Active FrankerFaceZ emotes in chat: monkaS FeelsOkayMan PepeHands ZULUL
**Listing active BTTV emotes:**
Example chat
ViewerName:!emotes bttv
StreamElements:Active BetterTTV emotes in chat: Pog LULW monkaW Clap
**Reloading all emote caches (Moderator+):**
Example chat
ModUser:!emotes reload
StreamElements:@Moderator, successfully updated emotes :)
## Configuration
[Section titled “Configuration”](#configuration)
* The `reload` function will refresh caches for Twitch and any enabled third-party integrations.
* The bot needs appropriate permissions (usually just being present in chat) to fetch Twitch emotes.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!emotecount`](/chatbot/commands/default/emotecount): Checks how many times a specific emote has been used in chat.
# !enablesfx
> Use the !enablesfx command in StreamElements chatbot to quickly re-enable all sound effect (SFX) items in your loyalty store.
The `!enablesfx` command allows streamers and moderators to quickly re-enable all **sound effect** (SFX) items in the StreamElements loyalty store that were previously disabled (e.g., using `!disablesfx`).
## Usage
[Section titled “Usage”](#usage)
To enable all SFX store items, use the following command in chat:
```streamelements
!enablesfx
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!enablesfx
StreamElements:@Moderator, successfully updated 5 items. (SFX store opened)
Example chat
BroadcasterName:!enablesfx
StreamElements:@Broadcaster, No disabled SFX store items found.
## Configuration
[Section titled “Configuration”](#configuration)
* Manage your store’s SFX items in your **StreamElements Dashboard** under `Loyalty` -> `Stream Store`.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!disablesfx`](/chatbot/commands/default/disablesfx): Disables all sound effect (SFX) items in the loyalty store.
* [`!closestore`](/chatbot/commands/default/closestore): Disables all *regular* (non-SFX) items in the loyalty store.
* [`!openstore`](/chatbot/commands/default/openstore): Enables all *regular* (non-SFX) items in the loyalty store.
* [`!redeem`](/chatbot/commands/default/redeem): Allows viewers to redeem store items.
# !filesay
> Use the !filesay command in StreamElements chatbot to send multiple lines of text from a URL to chat, ideal for bulk commands like bans.
The `!filesay` command allows streamers and moderators to execute multiple commands or messages stored in a text file hosted at a public URL. Each line in the text file is sent as a separate command/message to the chat. This is extremely useful for performing bulk actions, such as banning multiple users listed in a file.
## Usage
[Section titled “Usage”](#usage)
To execute the commands/messages from a file URL:
```streamelements
!filesay
```
Important
* The URL must point to a **raw text file** (e.g., a Pastebin raw link, a GitHub raw file link).
* Each line in the file will be executed as if typed directly into chat. Ensure the commands are valid (e.g., `!ban username`).
* There might be rate limits on how many lines can be processed quickly.
## Examples
[Section titled “Examples”](#examples)
**Example File (`https://pastebin.com/raw/examplebans`):**
```text
/ban BotUser1 Spamming
/ban TrollAccount2 Being disruptive
/timeout AnotherUser 600 Repeat offences
```
**Using the command:**
Example chat
BroadcasterName:!filesay https\://pastebin.com/raw/examplebans
StreamElements:Executing 3 lines from URL...
StreamElements:BotUser1 has been permanently banned from the chat.
StreamElements:TrollAccount2 has been permanently banned from the chat.
StreamElements:AnotherUser has been timed out for 600 seconds.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The direct URL to a plain text file where each line contains a command or message to be sent.
## Configuration
[Section titled “Configuration”](#configuration)
* No specific module needs to be enabled, but the command relies on the bot having the necessary permissions to execute the commands listed within the file (e.g., ban permissions).
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!nuke`](/chatbot/commands/default/nuke): Times out all users who recently chatted based on a specific phrase.
* [`!nukeusername`](/chatbot/commands/default/nukeusername): Times out all users whose usernames match a pattern.
# !followage
> Check how long you — or anyone — have been following a Twitch channel with the free !followage chat command in StreamElements Chatbot.
The `!followage` command allows anyone in chat to check how long a specified Twitch user has been following a specified Twitch channel. If no user or channel is specified, it defaults to checking the command user’s follow duration for the current channel.
## Usage
[Section titled “Usage”](#usage)
Use the command with optional parameters:
```streamelements
!followage [username] [channel_name]
```
## Examples
[Section titled “Examples”](#examples)
**Check your own follow age:**
Example chat
Viewer1:!followage
StreamElements:@Viewer1, You have been following CurrentChannel for 1 year 3 months 5 days 2 hours.
**Check another user’s follow age in the current channel:**
Example chat
ViewerName:!followage StreamElements
StreamElements:@User, StreamElements has been following CurrentChannel for 6 years 1 month 10 days 4 hours.
**Check another user’s follow age for a different channel:**
Example chat
ViewerName:!followage StreamElements AnotherChannel
StreamElements:@User, StreamElements is not following AnotherChannel.
## Parameters
[Section titled “Parameters”](#parameters)
* `[username]` (Optional): The Twitch username to check the follow age for. Defaults to the user running the command.
* `[channel_name]` (Optional): The Twitch channel name to check the follow relationship against. Defaults to the current channel where the command is used.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!accountage`](/chatbot/commands/default/accountage): Checks when a Twitch account was created.
* [`!uptime`](/chatbot/commands/default/uptime): Shows how long the current stream has been live.
* [`!watchtime`](/chatbot/commands/default/watchtime): Shows how long a user has watched the current channel (requires Loyalty module).
# !giveaway
> Use the !giveaway command in StreamElements chatbot to check the status and link for the currently active channel giveaway.
The `!giveaway` command allows anyone in chat to check the status of the currently active channel giveaway. If a giveaway is running, the command provides its name and a direct link for viewers to enter.
Note
This command *checks* the status of an active giveaway. To *start* or manage giveaways, use the StreamElements Dashboard Giveaway Module.
## Usage
[Section titled “Usage”](#usage)
To check the active giveaway details, simply type the command in chat:
```streamelements
!giveaway
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!giveaway
StreamElements:@User, Current giveaway: "Epic New Game Key!" https\://streamelements.com/YOUR\_CHANNEL/giveaway/GIVEAWAY\_ID
Example chat
ViewerName:!giveaway
StreamElements:@User, There is currently no giveaway running!
## Configuration
[Section titled “Configuration”](#configuration)
* The `!giveaway` command requires a giveaway to be running. Manage giveaways in your **StreamElements Dashboard** under `Loyalty` -> `Giveaways`.
* The command response reflects the settings of the currently active giveaway (name, entry requirements) configured by the streamer/moderator.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!ticket`](/chatbot/commands/default/ticket): Used by viewers to enter the active giveaway (if it requires loyalty points).
* [`!raffle`](/chatbot/commands/default/raffle) / [`!sraffle`](/chatbot/commands/default/sraffle): Commands for different types of raffle/giveaway systems.
# !givepoints
> Viewers can use the !givepoints command in StreamElements chatbot to transfer their loyalty points to another user.
The `!givepoints` command allows viewers to transfer their loyalty points to another user in the chat. This enables community interactions like gifting points or pooling resources.
Note
The `!givepoints` command is **disabled by default**. Enable it under `Chatbot` -> `Chat Commands` -> `Default Commands` before using it.
## Usage
[Section titled “Usage”](#usage)
To transfer points to another user:
```streamelements
!givepoints
```
## Examples
[Section titled “Examples”](#examples)
Example chat
GenerousViewer:!givepoints LuckyFriend 500
StreamElements:@GenerousViewer -> gave 500 points to @LuckyFriend
Example chat
PoorViewer:!givepoints RichPal 10000
StreamElements:@PoorViewer, You only have 500 points.
Example chat
Viewer:!givepoints NonExistentUser 10
StreamElements:@Viewer, I couldn't find that user in the database :/
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact username of the recipient.
* `` (Required): The number of points to transfer. Must be a positive integer, and the sender must have sufficient points.
## Configuration
[Section titled “Configuration”](#configuration)
* Enable the **Loyalty system** in your **StreamElements Dashboard** under `Loyalty` -> `Loyalty Settings`.
* The ability for users to give points can be enabled/disabled within the Loyalty Settings.
* Streamers can set a minimum user level required to use the command and a cooldown period in the command’s settings under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Check your own or another user’s point balance.
* [`!addpoints`](/chatbot/commands/default/addpoints): (Moderator+) Manually add points to a user.
* [`!setpoints`](/chatbot/commands/default/setpoints): (Moderator+) Set a user’s points to a specific value.
* [`!top`](/chatbot/commands/default/top): View the leaderboard for points.
# !hypecup
> Use the !hypecup command in StreamElements chatbot to clear the HypeCup overlay contribution list on your Twitch stream.
The `!hypecup` command allows streamers and moderators to clear the list of contributors displayed in the StreamElements HypeCup overlay widget.
## Usage
[Section titled “Usage”](#usage)
To clear the HypeCup overlay, use the following command in chat:
```streamelements
!hypecup clear
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!hypecup clear
StreamElements:@Moderator, Successfully cleared HypeCup.
Example chat
BroadcasterName:!hypecup
StreamElements:@Broadcaster, Usage: !hypecup clear
## Parameters
[Section titled “Parameters”](#parameters)
* `clear` (Required): This is the only valid parameter and triggers the action to clear the HypeCup overlay list.
## Configuration
[Section titled “Configuration”](#configuration)
* This command interacts with the **HypeCup widget** in your StreamElements overlays. Ensure the widget is added to an active overlay.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
# !items
> Use the !items command in StreamElements chatbot to get a link to the channel's loyalty store page, listing redeemable items.
The `!items` command provides viewers with a direct link to the channel’s StreamElements loyalty store page. This page displays all currently available items that can be redeemed using loyalty points.
## Usage
[Section titled “Usage”](#usage)
To get the link to the store page, simply type the command in chat:
```streamelements
!items
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!items
StreamElements:Check out the available items here: https\://streamelements.com/YOUR\_CHANNEL\_NAME/store
## Configuration
[Section titled “Configuration”](#configuration)
* The linked store page only shows items that are currently enabled and redeemable.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Check your current loyalty point balance.
* [`!redeem`](/chatbot/commands/default/redeem): Allows viewers to redeem a specific store item directly via chat.
* [`!closestore`](/chatbot/commands/default/closestore) / [`!openstore`](/chatbot/commands/default/openstore): (Moderator+) Commands to enable/disable regular store items.
* [`!disablesfx`](/chatbot/commands/default/disablesfx) / [`!enablesfx`](/chatbot/commands/default/enablesfx): (Moderator+) Commands to enable/disable sound effect store items.
# !join
> Use the !join command in the StreamElements chatbot to enter active raffles started with !sraffle or !raffle.
The `!join` command allows viewers to enter an **active raffle** in the chat. Viewers use this command to participate in raffles started by moderators using either [`!sraffle`](/chatbot/commands/default/sraffle) or [`!raffle`](/chatbot/commands/default/raffle). Entry is **free** — joining a raffle never costs points (points are the prize, not the entry fee) — and each viewer can only enter once per raffle; repeat `!join` messages are ignored.
The command only does something while a raffle is running. If no raffle is active, `!join` does nothing.
Note
`!join` does **not** add you to the viewer queue. To enter the viewer queue, use [`!queue join`](/chatbot/commands/default/queue) instead.
## Usage
[Section titled “Usage”](#usage)
To enter the currently active raffle, simply type:
```streamelements
!join
```
There are **no parameters** for this command.
## Examples
[Section titled “Examples”](#examples)
**Entering a raffle (`!sraffle`):**
Example chat
ModUser:!sraffle
StreamElements:A raffle has begun! Enter by typing "!join". It will end in 60 seconds.
ViewerName:!join
## Configuration
[Section titled “Configuration”](#configuration)
* The **Raffle module** must be enabled in your StreamElements dashboard (`Chatbot` -> `Modules` -> `Raffle`).
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!sraffle`](/chatbot/commands/default/sraffle): Starts a single-winner raffle where one entrant wins the full points prize.
* [`!raffle`](/chatbot/commands/default/raffle): Starts a multi-winner raffle where the points prize is split between the winners.
* [`!cancelraffle`](/chatbot/commands/default/cancelraffle): Cancels the active raffle.
* [`!queue join`](/chatbot/commands/default/queue): Enters the viewer queue (not related to raffles).
# !kappagen
> Use the !kappagen command in StreamElements chatbot to trigger a visual emote explosion on the stream overlay via the Kappagen widget.
The `!kappagen` command triggers a visual explosion of emotes on the stream overlay using the **StreamElements Kappagen widget**. This adds a fun, dynamic visual effect to the broadcast.
## Usage
[Section titled “Usage”](#usage)
To trigger the emote explosion:
```streamelements
!kappagen
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!kappagen
## Configuration
[Section titled “Configuration”](#configuration)
* The **Kappagen widget** must be added to an active StreamElements overlay.
* The `!kappagen` command must be enabled in your StreamElements Dashboard under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* You can customize the Kappagen widget settings (emotes used, intensity, duration, cooldown, cost, permissions) within the overlay editor and the command settings.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!emotes`](/chatbot/commands/default/emotes): Provides a link to the channel’s available emotes.
* [`!alerts`](/chatbot/commands/default/alerts): Manages other overlay alert functions.
# !leaderboard
> Use the !leaderboard command in StreamElements chatbot to get a link to the channel's loyalty points or watch time leaderboard page.
The `!leaderboard` command provides viewers with a direct link to the channel’s public StreamElements leaderboard page. This page ranks viewers based on loyalty points or watch time, depending on the channel’s configuration.
## Usage
[Section titled “Usage”](#usage)
To get the link to the leaderboard page, simply type the command in chat:
```streamelements
!leaderboard
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!leaderboard
StreamElements:Check out the channel Leaderboard here: https\://streamelements.com/YOUR\_CHANNEL\_NAME/leaderboard
## Configuration
[Section titled “Configuration”](#configuration)
* Enable the **Loyalty system** in your **StreamElements Dashboard** under `Loyalty` -> `Loyalty Settings`.
* The leaderboard page displays rankings based on the settings configured in the Loyalty module (points or watch time).
* The command itself is typically enabled by default.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Check your current loyalty point balance.
* [`!watchtime`](/chatbot/commands/default/watchtime): Check your accumulated watch time.
* [`!top`](/chatbot/commands/default/top): Shows the top users (points or time) directly in chat.
# !level
> Moderators can use the !level command in StreamElements chatbot to view and manually override user permission levels.
The `!level` command allows streamers and moderators to view or manually set the permission level of a specific user within the StreamElements system. User levels determine access to commands and other features.
While levels like subscriber, VIP, and moderator are often assigned automatically based on platform roles, this command allows manual overrides or assigning custom levels like `Regular` or `Super Moderator`.
## Usage
[Section titled “Usage”](#usage)
**To check a user’s level:**
```streamelements
!level
```
**To set a user’s level:**
```streamelements
!level
```
**To reset a user’s level to default (based on their platform role):**
```streamelements
!level reset
```
## Examples
[Section titled “Examples”](#examples)
**Checking a level:**
Example chat
ModUser:!level RegularViewer
StreamElements:@Moderator, The level of RegularViewer is 100.
**Setting a user to Regular:**
Example chat
ModUser:!level RegularViewer 300
StreamElements:@Moderator, Successfully set RegularViewer's level to 300 (Regular).
**Resetting a user’s level:**
Example chat
ModUser:!level RegularViewer reset
StreamElements:@Moderator, Successfully reset RegularViewer's level to 100 (Everyone).
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact username of the target user.
* ` or reset` (Optional):
* Provide a numeric level value to manually set the user’s level.
* Use the keyword `reset` to remove any manual override and revert to the level determined by their platform role (or default 100 if none).
## User Level Values
[Section titled “User Level Values”](#user-level-values)
StreamElements uses the following numeric values for permission levels:
* `100`: Everyone (Default for non-sub/VIP/mod users)
* `250`: Subscriber
* `300`: Regular (Manually assigned via Dashboard or `!level`)
* `400`: VIP (Twitch only)
* `500`: Moderator
* `1000`: Super Moderator (Manually assigned via Dashboard or `!level`)
These six values are the only ones the bot accepts — commands like `!level` and `!command options -level` reject anything else.
Note
The dashboard’s custom-command **User level** dropdown additionally offers **Broadcaster**, a level above Super Moderator. It can only be assigned from the dashboard, not from chat.
Note
Manually setting a level (e.g., setting a non-sub to `250`) grants them the permissions of that level within StreamElements (e.g., access to sub-only commands) but does *not* grant them platform-specific benefits like sub badges or emotes.
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* User levels are fundamental to command permissions configured in the **Chat Commands** section of the Dashboard.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!permit`](/chatbot/commands/default/permit): Temporarily grants link permission to a user, often used for users below a certain level.
## FAQ
[Section titled “FAQ”](#faq)
* **What happens if I use the command incorrectly?** The bot will guide you. You might see messages like:
`@User, usage !level USER 500/reset`
`@User, valid levels are: 100 (Everyone), 250 (Subscriber), 300 (Regular), 400 (VIP), 500 (Moderator), 1000 (Super Moderator)`
# !module
> Use the !module command in StreamElements chatbot to enable or disable specific chatbot modules (like games, points, etc.) directly from chat.
The `!module` command allows streamers and moderators to enable or disable specific StreamElements chatbot modules directly from the chat. This provides real-time control over features like games, loyalty systems, or other functionalities without needing to access the dashboard.
## Usage
[Section titled “Usage”](#usage)
To enable or disable a module:
```streamelements
!module
```
## Examples
[Section titled “Examples”](#examples)
**Disabling the Roulette game module:**
Example chat
ModUser:!module roulette disable
StreamElements:@Moderator, Module Roulette was disabled.
**Enabling the Quotes module:**
Example chat
BroadcasterName:!module quotes enable
StreamElements:@Broadcaster, Module Quotes was enabled.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The name of the module to modify (e.g., `roulette`, `duel`, `giveaway`, `quotes`, `loyalty`). Refer to the StreamElements Dashboard (`Chatbot` -> `Modules`) for a list of available module names.
* `` (Required): Specify `enable` to turn the module on or `disable` to turn it off.
## Configuration
[Section titled “Configuration”](#configuration)
* Available modules and their current status can be viewed in the **StreamElements Dashboard** under `Chatbot` -> `Modules`.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!bot`](/chatbot/commands/default/bot): Controls the bot’s overall presence (mute/unmute/part).
* [`!commands`](/chatbot/commands/default/commands): Provides a link to the list of commands (which are often tied to modules).
# !next
> Use the !next (!nextsong) command in StreamElements chatbot to see details about the next song in the media request queue.
The `!next` command (aliased as `!nextsong`) allows anyone in chat to view details about the upcoming song in the StreamElements media request queue. It shows the channel, song title, requester, and a link. It only **displays** the next queued song — it does not skip anything; skipping is done by moderators with [`!skip`](/chatbot/commands/default/skip).
## Usage
[Section titled “Usage”](#usage)
To see the next song in the queue:
```streamelements
!next
```
Or using the alias:
```streamelements
!nextsong
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!next
StreamElements:@User, next song: SaxChannel - Epic Sax Guy 10 Hours, requested by SaxLover https\://youtu.be/kxopViU98Xo
Example chat
ViewerName:!nextsong
StreamElements:@User, there are no songs in the queue!
## Configuration
[Section titled “Configuration”](#configuration)
* The information displayed depends on the data available from YouTube for the requested track.
* Default cooldown: 10 seconds per user.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!song`](/chatbot/commands/default/song): Shows details about the *currently playing* song.
* [`!songqueue`](/chatbot/commands/default/songqueue): Provides a link to the full media request queue.
* [`!songrequest`](/chatbot/commands/default/songrequest): Allows users to request songs to add to the queue.
* [`!skip`](/chatbot/commands/default/skip): (Moderator+) Skips the currently playing song.
* [`!removesong`](/chatbot/commands/default/removesong): (Moderator+) Removes a specific song from the queue.
# !nuke
> Use the !nuke command in StreamElements chatbot to moderate chat by timing out, banning, or deleting recent messages matching specific text or regex.
The `!nuke` command is a powerful moderation tool allowing moderators to perform bulk actions (timeout, ban, delete) on users whose recent messages contain specific text or match a regular expression.
Caution
This is a powerful command. Use it with caution, especially with broad match strings or regex.
## Usage
[Section titled “Usage”](#usage)
```streamelements
!nuke
```
## Examples
[Section titled “Examples”](#examples)
**Timeout users saying “spam spam” in the last 60 seconds for 120 seconds:**
Example chat
ModUser:!nuke 60 120 spam spam
StreamElements:@Moderator, Nuked 3 messages matching "spam spam".
**Ban users whose messages matched a regex pattern in the last 5 minutes:**
Example chat
BroadcasterName:!nuke 300 ban /badsite.(com|net)/i
StreamElements:@Broadcaster, Nuked 1 messages matching "/badsite.(com|net)/i".
**Delete messages containing “selling stuff” in the last 30 seconds (Twitch only):**
Example chat
ModUser:!nuke 30 delete selling stuff
StreamElements:@Moderator, Nuked 2 messages matching "selling stuff".
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The duration (in seconds, max 300) to scan previous messages.
* `` (Required): The moderation action:
* Number (e.g., `60`): Timeout duration in seconds.
* `ban`: Permanently ban the users.
* `delete`: Delete the matching messages (Twitch only, requires Mod status for the bot).
* `` (Required): The text to search for.
* For plain text matching: `some bad phrase`
* For regular expression matching: Wrap the pattern in forward slashes, e.g., `/badword\d+/i` (the `i` makes it case-insensitive).
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`. It’s highly recommended to keep this restricted.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!nukeusername`](/chatbot/commands/default/nukeusername): Performs similar actions but matches against usernames instead of message content.
* [`!filesay`](/chatbot/commands/default/filesay): Executes commands line-by-line from a text file URL, useful for banning specific lists of users.
# !nukeusername
> Use the !nukeusername command in StreamElements chatbot to moderate chat by timing out or banning users whose usernames match specific text or regex.
The `!nukeusername` command is a moderation tool allowing moderators to perform bulk actions (timeout or ban) on users whose **usernames** contain specific text or match a regular expression and have chatted within a specified lookback period.
Caution
This is a powerful command. Use it with caution, especially with broad match strings or regex, to avoid unintended actions against legitimate users.
## Usage
[Section titled “Usage”](#usage)
```streamelements
!nukeusername
```
## Examples
[Section titled “Examples”](#examples)
**Timeout users for 300s whose username contains “bot123” and chatted in the last 60s:**
Example chat
ModUser:!nukeusername 60 300 bot123
StreamElements:@Moderator, Nuked 2 users matching "bot123".
**Ban users whose usernames match a regex pattern (e.g., starts with “troll\_”) and chatted in the last 5 mins:**
Example chat
BroadcasterName:!nukeusername 300 ban /^troll\_/i
StreamElements:@Broadcaster, Nuked 1 users matching "/^troll\_/i".
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The duration (in seconds, max 300) to scan previous chat messages to find users who chatted.
* `` (Required): The moderation action:
* Number (e.g., `60`): Timeout duration in seconds.
* `ban`: Permanently ban the users.
* **Note:** Unlike `!nuke`, `delete` is generally not applicable here as it targets message content, not usernames.
* `` (Required): The text or pattern to match against usernames.
* For plain text matching: `badnamepart`
* For regular expression matching: Wrap the pattern in forward slashes, e.g., `/botaccount\d+/i` (the `i` makes it case-insensitive).
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`. It’s highly recommended to keep this restricted.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!nuke`](/chatbot/commands/default/nuke): Performs similar actions but matches against message content instead of usernames.
* [`!filesay`](/chatbot/commands/default/filesay): Executes commands line-by-line from a text file URL, useful for banning specific lists of users.
# !openstore
> Use the !openstore command in StreamElements chatbot to re-enable all regular (non-SFX) items in your loyalty store.
The `!openstore` command allows streamers and moderators to quickly re-enable all **regular** (non-sound effect) items in the StreamElements loyalty store that were previously disabled (e.g., using `!closestore`).
## Usage
[Section titled “Usage”](#usage)
To enable all regular store items, use the following command in chat:
```streamelements
!openstore
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!openstore
StreamElements:@Moderator, successfully updated 15 items. (Store opened)
Example chat
BroadcasterName:!openstore
StreamElements:@Broadcaster, No disabled regular store items found.
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!closestore`](/chatbot/commands/default/closestore): Disables all *regular* (non-SFX) items in the loyalty store.
* [`!disablesfx`](/chatbot/commands/default/disablesfx): Disables only sound effect (SFX) items in the loyalty store.
* [`!enablesfx`](/chatbot/commands/default/enablesfx): Enables only sound effect (SFX) items in the loyalty store.
* [`!redeem`](/chatbot/commands/default/redeem): Allows viewers to redeem store items.
* [`!items`](/chatbot/commands/default/items): Provides a link to the store page.
# !pause
> Use the !pause command in StreamElements chatbot to temporarily stop the media request playback without clearing the queue.
The `!pause` command temporarily stops the playback of the current item in the StreamElements media request queue. The queue itself remains intact, and playback can be resumed later.
## Usage
[Section titled “Usage”](#usage)
To pause the currently playing media:
```streamelements
!pause
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!pause
StreamElements:@Moderator, Media request playback paused!
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!play`](/chatbot/commands/default/play): Resumes media playback after it has been paused.
* [`!skip`](/chatbot/commands/default/skip): Skips the currently playing media item.
* [`!volume`](/chatbot/commands/default/volume): Adjusts the volume of the media player.
* [`!songrequest`](/chatbot/commands/default/songrequest): Adds a song/video to the queue.
* [`!songqueue`](/chatbot/commands/default/songqueue): Provides a link to the media queue page.
# !permit
> Use the !permit command in StreamElements chatbot to temporarily allow a specific user to post links in chat without being timed out.
The `!permit` command temporarily exempts a specified user from the bot’s automatic link filtering/timeout system. This allows them to post links for a short duration without being punished.
## Usage
[Section titled “Usage”](#usage)
To grant temporary link permission:
```streamelements
!permit [duration_seconds]
```
## Examples
[Section titled “Examples”](#examples)
**Permit a user for the default 60 seconds:**
Example chat
ModUser:!permit HelpfulViewer
StreamElements:@HelpfulViewer, you have been permitted to post links for 60 seconds.
**Permit a user for 120 seconds:**
Example chat
BroadcasterName:!permit TrustedFriend 120
StreamElements:@TrustedFriend, you have been permitted to post links for 120 seconds.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact username of the viewer to permit.
* `[duration_seconds]` (Optional): The duration (in seconds) the permit should last. Defaults to 60 seconds if not specified.
## Configuration
[Section titled “Configuration”](#configuration)
* This command relies on the **Link Protection** filter being enabled within the `Chatbot` -> `Spam Filters` section of the StreamElements Dashboard.
* The default permit duration (if not specified in the command) can be configured in the Link Protection filter settings.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!level`](/chatbot/commands/default/level): Used to view or set a user’s permanent permission level, which can also control link permissions.
# !play
> Use the !play (!resume) command in StreamElements chatbot to resume paused media request playback.
The `!play` command (aliased as `!resume`) resumes the playback of the StreamElements media request queue after it has been stopped by the [`!pause`](/chatbot/commands/default/pause) command.
## Usage
[Section titled “Usage”](#usage)
To resume playback:
```streamelements
!play
```
Or using the alias:
```streamelements
!resume
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!play
StreamElements:@Moderator, Media request playback resumed!
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!pause`](/chatbot/commands/default/pause): Pauses the current media playback.
* [`!skip`](/chatbot/commands/default/skip): Skips the currently playing media item.
* [`!volume`](/chatbot/commands/default/volume): Adjusts the volume of the media player.
* [`!songrequest`](/chatbot/commands/default/songrequest): Adds a song/video to the queue.
* [`!songqueue`](/chatbot/commands/default/songqueue): Provides a link to the media queue page.
# !points
> Use the !points command in StreamElements chatbot to check your own or another user's loyalty points balance and leaderboard rank.
The `!points` command allows anyone in chat to check the loyalty point balance and leaderboard rank of themselves or another specified user.
## Usage
[Section titled “Usage”](#usage)
To check points and rank:
```streamelements
!points [username]
```
Note
The command also triggers on your channel’s custom points name. For example, if your loyalty currency is named “ChannelPoints”, typing `!channelpoints` works as well.
## Examples
[Section titled “Examples”](#examples)
**Checking your own points:**
Example chat
Viewer1:!points
StreamElements:@Viewer1, you have 5280 ChannelPoints and are rank #15 on the leaderboard.
**Checking another user’s points:**
Example chat
ViewerName:!points StreamElements
StreamElements:@StreamElements has 99999 ChannelPoints and is rank #1 on the leaderboard.
## Parameters
[Section titled “Parameters”](#parameters)
* `[username]` (Optional): The exact username of the user whose points you want to check. If omitted, it defaults to the user running the command.
## Configuration
[Section titled “Configuration”](#configuration)
* Enable and configure the Loyalty system under `Loyalty` -> `Loyalty Settings` in your StreamElements Dashboard.
* The loyalty currency name (e.g., “ChannelPoints” in the examples) is customizable in the Loyalty Settings.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!top`](/chatbot/commands/default/top): Shows the top users on the leaderboard directly in chat.
* [`!leaderboard`](/chatbot/commands/default/leaderboard): Provides a link to the full leaderboard page.
* [`!givepoints`](/chatbot/commands/default/givepoints): Allows users to transfer points to each other.
* [`!addpoints`](/chatbot/commands/default/addpoints) / [`!setpoints`](/chatbot/commands/default/setpoints): (Moderator+) Commands to modify user points.
# !queue
> Use the !queue command in StreamElements chatbot to manage viewer queues for activities like playing games with the streamer.
The `!queue` command suite helps manage a viewer queue, often used for activities like playing games with the streamer. It allows viewers to join, check their position, and moderators to manage the queue (open, close, pick, remove).
## Usage
[Section titled “Usage”](#usage)
The general syntax follows this pattern:
```streamelements
!queue [arguments...]
```
A subcommand is always required — typing `!queue` on its own does nothing.
Permissions
The management subcommands (`open`, `close`, `pause`, `unpause`, `pick`, `remove`) require **Moderator** permission level or higher. The viewer subcommands (`join`, `position`, `list`) are available to everyone.
## Subcommands
[Section titled “Subcommands”](#subcommands)
Here’s a breakdown of the available subcommands:
### `join`
[Section titled “join”](#join)
Allows a viewer to enter the open queue.
Note
You must type the full `!queue join` to enter the viewer queue. The standalone [`!join`](/chatbot/commands/default/join) command is unrelated — it enters an active raffle instead.
* **Syntax:** `!queue join`
* **Example:**
Example chat
ViewerName:!queue join
StreamElements:@User, you have been added to the queue in position #5.
### `position`
[Section titled “position”](#position)
Checks the command user’s current position in the queue.
* **Syntax:** `!queue position`
* **Example:**
Example chat
ViewerName:!queue position
StreamElements:@User, you are currently position #3 in the queue.
### `list`
[Section titled “list”](#list)
Lists who is currently waiting in the queue. The bot posts up to 5 names in chat, followed by a count of how many other viewers are also waiting.
* **Syntax:** `!queue list`
* **Example:**
Example chat
ViewerName:!queue list
StreamElements:Currently waiting in the Viewer Games queue: UserOne, UserTwo, UserThree, UserFour, UserFive and 7 others.
### `open ` (Moderator+)
[Section titled “open \ (Moderator+)”](#open-title-moderator)
Opens the queue, allowing viewers to join. A title for the queue is **required**.
* **Syntax:** `!queue open `
* **Example:**
Example chat
ModUser:!queue open Viewer Games
StreamElements:@Moderator, The Viewer Games queue is now open! Viewers can type !queue join to enter.
### `close` (Moderator+)
[Section titled “close (Moderator+)”](#close-moderator)
Closes the queue, preventing new viewers from joining.
* **Syntax:** `!queue close`
* **Example:**
Example chat
ModUser:!queue close
StreamElements:@Moderator, The queue is now closed.
### `pause` (Moderator+)
[Section titled “pause (Moderator+)”](#pause-moderator)
Temporarily stops viewers from joining the queue (similar to close, but implies temporary).
* **Syntax:** `!queue pause`
* **Example:**
Example chat
ModUser:!queue pause
StreamElements:@Moderator, The queue is paused.
### `unpause` (Moderator+)
[Section titled “unpause (Moderator+)”](#unpause-moderator)
Resumes allowing viewers to join the paused queue.
* **Syntax:** `!queue unpause`
* **Example:**
Example chat
ModUser:!queue unpause
StreamElements:@Moderator, The queue is no longer paused.
### `pick ` (Moderator+)
[Section titled “pick \ (Moderator+)”](#pick-random--username-moderator)
Selects a participant from the queue. You must specify either a username or the keyword `random` — there is no option to pick the next person in line.
* **Syntax:**
* `!queue pick random` (Selects randomly)
* `!queue pick ` (Selects a specific user)
* **Example (random):**
Example chat
ModUser:!queue pick random
StreamElements:@LuckyViewer has been randomly selected from the queue!
* **Example (specific):**
Example chat
ModUser:!queue pick SpecificUser
StreamElements:@SpecificUser has been picked from the queue!
### `remove ` (Moderator+)
[Section titled “remove \ (Moderator+)”](#remove-username-moderator)
Removes a specific user from the queue.
* **Syntax:** `!queue remove `
* **Example:**
Example chat
ModUser:!queue remove ProblemUser
StreamElements:@Moderator, ProblemUser has been removed from the queue.
## Configuration
[Section titled “Configuration”](#configuration)
* The **Queue module** must be enabled in your StreamElements Dashboard under `Chatbot` -> `Modules`.
* Restrictions on the queue, such as the maximum queue size and which viewers are eligible to join (for example followers or subscribers only), are configured in the module settings on the Dashboard.
* Permission levels for subcommands can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [Viewer Queue Module](/chatbot/modules/viewerqueue): Enable the queue and configure its settings (size limits, messages, and behavior) in the StreamElements Dashboard.
# !quote
> Use the !quote command in StreamElements chatbot to display random saved quotes or manage the quote list (add/remove) via subcommands.
The `!quote` command interacts with the channel’s quote system. Viewers can use it to display a random saved quote. Moderators and the broadcaster can use subcommands to add new quotes or remove existing ones.
## Usage
[Section titled “Usage”](#usage)
**To display a random quote:**
```streamelements
!quote
```
**To display a specific quote by ID:**
```streamelements
!quote
```
The ID can also be prefixed with `#`, e.g. `!quote #42`.
**To add a quote (Moderator+):**
```streamelements
!quote add
```
**To remove a quote (Moderator+):**
```streamelements
!quote remove
```
Permissions
Adding (`add`) and removing (`remove`) quotes requires **Moderator** permission level or higher. Viewing quotes is available to everyone.
Note
Quotes cannot be **edited** from chat — only added and removed. To edit the text of an existing quote, use the StreamElements Dashboard.
## Examples
[Section titled “Examples”](#examples)
**Displaying a random quote:**
Example chat
ViewerName:!quote
StreamElements:@User, #42: This is peak gameplay!
**Displaying a specific quote:**
Example chat
ViewerName:!quote 10
StreamElements:@User, #10: I can't believe that worked!
**Adding a new quote (Moderator+):**
Example chat
ModUser:!quote add Never give up!
StreamElements:@Moderator, added quote #51
**Removing a quote (Moderator+):**
Example chat
ModUser:!quote remove 51
StreamElements:@Moderator, removed quote #51
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Optional): The specific ID number of the quote to display or remove, with or without a `#` prefix.
* `add ` (Moderator+): The subcommand `add` followed by the text of the quote to save.
* `remove ` (Moderator+): The subcommand `remove` followed by the ID of the quote to delete.
## Configuration
[Section titled “Configuration”](#configuration)
* The permission levels for adding and removing quotes can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* Editing the text of existing quotes is only possible from the StreamElements Dashboard.
## Subcommand aliases
[Section titled “Subcommand aliases”](#subcommand-aliases)
* `!quote add`: `!quote +`
* `!quote remove`: `!quote rem`, `!quote delete`, `!quote del`, `!quote -`
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(quote )`](/chatbot/variables/quote): Variable to display a specific quote by ID.
# !raffle
> Use the !raffle command in StreamElements chatbot to start a raffle with multiple winners that splits a points pot among them.
The `!raffle` command allows streamers and moderators to create interactive raffles with multiple winners. This feature engages viewers by giving them a chance to win prizes or recognition during the stream.
## Usage
[Section titled “Usage”](#usage)
```streamelements
!raffle [amount] [duration]
```
* `[amount]`: Optional. The total reward (pot) for the raffle, distributed among winners. Defaults to 5000 points when omitted.
* `[duration]`: Optional. The duration of the raffle in whole seconds. Defaults to the Duration configured in the module settings. Because the arguments are positional, you can only set a duration if you also give an amount.
## Examples
[Section titled “Examples”](#examples)
**Start a raffle with a 100 point reward lasting 60 seconds:**
Example chat
ModUser:!raffle 100 60
StreamElements:The Multi-Raffle for 100 points will end in 60 Seconds. Enter by typing "!join"
**Create a longer raffle with a larger reward:**
Example chat
ModUser:!raffle 500 180
StreamElements:The Multi-Raffle for 500 points will end in 180 Seconds. Enter by typing "!join"
## Parameters
[Section titled “Parameters”](#parameters)
* `[amount]` (optional): The total reward (pot) for the raffle, which will be distributed among the winners. Accepts plain numbers and the `k` (thousands) / `m` (millions) suffixes — `5k` starts a 5000-point raffle. Percentages and `all` don’t work here. Defaults to 5000 when omitted, and is capped by the module’s Max Amount setting (and an absolute 1,000,000-point cap).
* `[duration]` (optional): The duration of the raffle in whole seconds (minimum 5). Defaults to the module’s Duration setting when omitted.
## Configuration
[Section titled “Configuration”](#configuration)
The default duration and the maximum pot are configured in the raffle module settings in the StreamElements dashboard. The number of winners is not configurable — it scales automatically with the number of entrants (see the [Raffle module](/chatbot/modules/raffle) for the exact brackets).
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!join`](/chatbot/commands/default/join): Used by viewers to enter an active raffle.
* [`!cancelraffle`](/chatbot/commands/default/cancelraffle): Allows moderators to cancel an ongoing raffle.
# !redeem
> Use the !redeem command in StreamElements chatbot to allow viewers to redeem items from your loyalty store using their points.
The `!redeem` command allows viewers to exchange their loyalty points for items listed in the channel’s StreamElements **Stream Store**.
## Usage
[Section titled “Usage”](#usage)
To redeem an item:
```streamelements
!redeem
```
## Examples
[Section titled “Examples”](#examples)
**Redeeming a sound effect named “Air Horn”:**
Example chat
ViewerName:!redeem Air Horn
StreamElements:@User successfully redeemed Air Horn for 100 points!
**Trying to redeem an item the user can’t afford:**
Example chat
ViewerName:!redeem Expensive Item
StreamElements:@User, you do not have enough points to redeem Expensive Item (Cost: 5000).
**Trying to redeem a disabled or non-existent item:**
Example chat
ViewerName:!redeem Old Item
StreamElements:@User, item "Old Item" not found or is not available.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact name of the store item to redeem (case-sensitive). Find item names on the store page (link via `!items` command).
## Configuration
[Section titled “Configuration”](#configuration)
* Configure the **Stream Store** and **Loyalty System** under `Chatbot` -> `Modules` and `Loyalty` -> `Loyalty Settings` / `Stream Store`.
* Items must be created in the Stream Store with names, costs, cooldowns, etc.
* Items must be enabled to be redeemable.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!items`](/chatbot/commands/default/items): Provides a link to the store page listing available items.
* [`!points`](/chatbot/commands/default/points): Checks the user’s current point balance.
* [`!closestore`](/chatbot/commands/default/closestore) / [`!openstore`](/chatbot/commands/default/openstore): (Moderator+) Enable/disable regular store items.
* [`!disablesfx`](/chatbot/commands/default/disablesfx) / [`!enablesfx`](/chatbot/commands/default/enablesfx): (Moderator+) Enable/disable SFX store items.
# !removesong
> Use the !removesong command in StreamElements chatbot to remove a specific song (by URL) or all songs requested by a user from the media queue.
The `!removesong` command allows streamers and moderators to remove entries from the StreamElements media request queue. It can target either a specific song via its URL or all songs requested by a particular user.
## Usage
[Section titled “Usage”](#usage)
To remove a specific song by its URL:
```streamelements
!removesong
```
To remove all songs requested by a specific user:
```streamelements
!removesong
```
## Examples
[Section titled “Examples”](#examples)
**Removing a specific song by URL:**
Example chat
ModUser:!removesong https\://youtu.be/dQw4w9WgXcQ
StreamElements:@Moderator, Rick Astley - Never Gonna Give You Up was removed from the queue.
**Removing all songs requested by a user:**
Example chat
BroadcasterName:!removesong SpamRequester
StreamElements:@Broadcaster, skipped all songs from SpamRequester
## Parameters
[Section titled “Parameters”](#parameters)
* `` OR `` (Required): You must provide *either* the direct YouTube URL of the song/video to remove *or* the exact username of the person whose requests should all be removed.
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* Default cooldown: 10 seconds global.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songrequest`](/chatbot/commands/default/songrequest): Adds a song/video to the queue.
* [`!songqueue`](/chatbot/commands/default/songqueue): Provides a link to the media queue page.
* [`!skip`](/chatbot/commands/default/skip): Skips the *currently playing* song.
* [`!play`](/chatbot/commands/default/play) / [`!pause`](/chatbot/commands/default/pause): Controls playback.
# !roulette
> Use the !roulette command in StreamElements chatbot for viewers to gamble their loyalty points for a chance to win or lose.
The `!roulette` command allows viewers to gamble a specified amount of their loyalty points. They have a chance to double their bet or lose it all.
## Usage
[Section titled “Usage”](#usage)
To play roulette:
```streamelements
!roulette
```
## Examples
[Section titled “Examples”](#examples)
**Betting 100 points:**
Example chat
ViewerName:!roulette 100
StreamElements:@User spins the wheel... and wins 100 points! You now have 1100 points. PogChamp
**Betting 50% of points:**
Example chat
ViewerName:!roulette 50%
StreamElements:@User spins the wheel... and lost 500 points! You now have 500 points. FeelsBadMan
**Betting all points:**
Example chat
ViewerName:!roulette all
StreamElements:@User spins the wheel... and lost 1000 points! You now have 0 points. FeelsBadMan
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The number of points to bet. This can be:
* A specific number (e.g., `100`).
* A percentage of the user’s current points (e.g., `50%`).
* A number with `k` for thousands (e.g., `5k`).
* A number with `m` for millions (e.g., `1m`).
* The keyword `all` to bet all points.
## Configuration
[Section titled “Configuration”](#configuration)
* Requires the **Loyalty system** (points) to be active, since roulette gambles loyalty points.
* Configure settings in the **Roulette module** on the Dashboard (`Chatbot` -> `Modules`). Available options include:
* **Enable/Disable Module:** Toggle the roulette game on or off.
* **Rig Percentage:** Adjust the win chance using a slider (0% = Never lose, 100% = Always lose).
* **Minimum Amount:** Set the minimum number of points required to play (Default: 1).
* **User Cooldown:** Set the minimum time (in seconds) a specific user must wait before playing again (Default: 60).
* **Global Cooldown:** Set the minimum time (in seconds) everyone must wait after a roulette spin before anyone can play again (Default: 0).
* **Win Message:** Customize the message shown when a user wins.
* *Available variables:* `{user}`, `{bet}`, `{points}`, `{pointsname}`
* *Default:* `/me {user} won {bet} ${pointsname} in roulette and now has {points} ${pointsname}! FeelsGoodMan`
* **Lose Message:** Customize the message shown when a user loses.
* *Available variables:* `{user}`, `{bet}`, `{points}`, `{pointsname}`
* *Default:* `/me {user} lost {bet} ${pointsname} in roulette and now has {points} ${pointsname}! FeelsBadMan`
* **All-in Win Message:** Customize the message shown when a user bets `all` and wins.
* *Available variables:* `{user}`, `{bet}`, `{points}`, `{pointsname}`
* *Default:* `/me PogChamp {user} went all in and won {bet} ${pointsname} PogChamp they now have {points} ${pointsname} FeelsGoodMan`
* **All-in Lose Message:** Customize the message shown when a user bets `all` and loses.
* *Available variables:* `{user}`, `{bet}`, `{points}`, `{pointsname}`
* *Default:* `/me {user} went all in and lost every single one of their {bet} ${pointsname} LUL`
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Check current point balance.
* [`!duel`](/chatbot/commands/default/duel) / [`!slots`](/chatbot/commands/default/slots) / [`!bet`](/chatbot/commands/default/bet): Other points-based games (if enabled).
# !setgame
> Use the !setgame command in StreamElements chatbot to update your stream's game category on Twitch or Kick from chat.
The `!setgame` command allows streamers and moderators to update the stream’s current game category directly from chat. It works on Twitch and Kick; YouTube is not supported.
## Usage
[Section titled “Usage”](#usage)
To set the game category for the stream:
```streamelements
!setgame
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!setgame Fortnite
StreamElements:@Moderator changed the game to "Fortnite"!
Example chat
BroadcasterName:!setgame OSRS
StreamElements:@Broadcaster changed the game to "Old School RuneScape"!
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The title of the game you want to set for your stream. This parameter supports fuzzy searching, allowing for slight misspellings or common abbreviations.
## Configuration
[Section titled “Configuration”](#configuration)
* This command requires the StreamElements bot to have permission to modify channel information (typically granted during initial bot setup).
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!settitle`](/chatbot/commands/default/settitle): Updates the stream title.
* [`!uptime`](/chatbot/commands/default/uptime): Displays how long the stream has been live.
# !setpoints
> Use the !setpoints command in StreamElements chatbot to set a user's loyalty points balance to a specific amount.
The `!setpoints` command allows streamers and moderators to set a specific number of loyalty points for a user in the chat. This command is useful for managing loyalty programs, rewarding viewers, or correcting point balances.
Caution
Using this command will **overwrite** the user’s current point balance. Use [`!addpoints`](/chatbot/commands/default/addpoints) if you want to add to their balance instead.
## Usage
[Section titled “Usage”](#usage)
To set a user’s point balance:
```streamelements
!setpoints
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!setpoints darkoe 1000
StreamElements:@Moderator, set darkoe's points to 1000!
Example chat
BroadcasterName:!setpoints viewer123 0
StreamElements:@Broadcaster, set viewer123's points to 0!
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The username of the viewer whose points you want to set.
* `` (Required): The new amount of points to assign to the user.
## Configuration
[Section titled “Configuration”](#configuration)
* Enable the **Loyalty system** under `Loyalty` -> `Loyalty Settings`.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!addpoints`](/chatbot/commands/default/addpoints): Adds points to a user’s balance without overwriting.
* [`!givepoints`](/chatbot/commands/default/givepoints): Allows users to transfer points.
* [`!points`](/chatbot/commands/default/points): Checks a user’s current point balance.
* [`!top`](/chatbot/commands/default/top): View the leaderboard for points.
# !settitle
> Use the !settitle command in StreamElements chatbot to change your Twitch or Kick stream title from chat.
The `!settitle` command allows streamers and moderators to change the stream title directly from chat, without switching to the dashboard or streaming software. It works on Twitch and Kick; YouTube is not supported.
## Usage
[Section titled “Usage”](#usage)
To set the stream title:
```streamelements
!settitle
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!settitle Playing Overwatch 2 with viewers!
StreamElements:@Moderator changed the title to "Playing Overwatch 2 with viewers!"
Example chat
BroadcasterName:!settitle Monday Variety: Minecraft, Fall Guys, and more!
StreamElements:@Broadcaster changed the title to "Monday Variety: Minecraft, Fall Guys, and more!"
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The new title for the stream. This can be any text up to Twitch’s character limit for stream titles.
## Configuration
[Section titled “Configuration”](#configuration)
* This command requires the StreamElements bot to have permission to modify channel information (typically granted during initial bot setup).
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!setgame`](/chatbot/commands/default/setgame): Changes the current game/category of the stream.
* [`!uptime`](/chatbot/commands/default/uptime): Displays how long the stream has been live.
# !skip
> Use the !skip command in StreamElements chatbot to skip the current song in the media request queue.
The `!skip` command is used to skip the currently playing song in the StreamElements media request queue. This command is useful for streamers and moderators who want to quickly move to the next song in the queue.
!skip vs !next
`!skip` is a moderator action that **skips the currently playing song**. It is different from [`!next`](/chatbot/commands/default/next), which simply **shows** the next queued song and is available to everyone.
## Usage
[Section titled “Usage”](#usage)
To use the `!skip` command, simply type it in the chat:
```streamelements
!skip
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!skip
StreamElements:@Moderator, skipped song: Drake, 21 Savage - Rich Flex (Audio)
Example chat
ViewerName:!skip
StreamElements:@User, you do not have permission to use that command.
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* Default cooldown: 10 seconds global.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!song`](/chatbot/commands/default/song): Displays information about the currently playing song.
* [`!next`](/chatbot/commands/default/next): Displays information about the next song in the queue.
* [`!songqueue`](/chatbot/commands/default/songqueue): Shows the current media request queue.
* [`!songrequest`](/chatbot/commands/default/songrequest): Adds a song to the media request queue.
* [`!removesong`](/chatbot/commands/default/removesong): Removes a song from the queue.
* [`!play`](/chatbot/commands/default/play) / [`!pause`](/chatbot/commands/default/pause): Controls playback.
# !slots
> Use the !slots command in StreamElements chatbot for viewers to play a slot machine game with their loyalty points.
The `!slots` command allows viewers to play a simple slot machine game in your chat. Users bet loyalty points on a spin of three emotes: only three matching emotes win (two of a kind pays nothing), and a losing spin costs the full bet. The payout scales with the number of configured emotes and the module’s Return Amount setting — see the [Slotmachine module](/chatbot/modules/slotmachine) for the exact formula.
## Usage
[Section titled “Usage”](#usage)
To play the slot machine:
```streamelements
!slots
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!slots 100
StreamElements:@User you got Kappa | Kappa | 4Head and lost your 100 points LUL
Example chat
ViewerName:!slots 500
StreamElements:@User you got Kappa | Kappa | Kappa and won 12500 points PogChamp
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The amount of loyalty points the user wants to bet. This must be a positive integer and within the configured minimum/maximum bet limits.
## Configuration
[Section titled “Configuration”](#configuration)
Streamers can customize the `!slots` game through the **Slots module** settings on the StreamElements dashboard (`Chatbot` -> `Modules`):
* **Module Toggle:** Enable or disable the entire `!slots` game.
* **Return Amount:** The “How rigged should the system be?” slider. At 100% the game pays out fair odds; lower than 100% means viewers lose points over time.
* **Minimum Amount:** The minimum (and default) number of loyalty points that can be wagered.
* **Emotes:** Choose which emotes act as the symbols on the slot machine reels. *(Defaults: Kappa, PogChamp, BibleThump, OpieOP, 4Head)*
* **Cooldowns:**
* **User Cooldown:** The minimum time (in seconds) a specific user must wait before playing again. *(Default: `10` seconds)*
* **Global Cooldown:** The minimum time (in seconds) before *anyone* can use the `!slots` command again after it’s been used.
* **Win Message:** Customize the message displayed when a viewer wins. Available arguments: `{user}`, `{points}`, `{emotes}`, `{pointsname}`. *(Example: `@{user} you got {emotes} and won {points} ${pointsname} PogChamp //`)*
* **Lose Message:** Customize the message displayed when a viewer loses. Available arguments: `{user}`, `{points}`, `{emotes}`, `{pointsname}`. *(Example: `@{user} you got {emotes} and lost your {points} ${pointsname} LUL`)*
Caution
The **Loyalty system** must also be active for the `!slots` command to function, as it relies on loyalty points.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Check your current loyalty points balance.
* [`!roulette`](/chatbot/commands/default/roulette) / [`!duel`](/chatbot/commands/default/duel) / [`!bet`](/chatbot/commands/default/bet): Other points-based games (if enabled).
# !song
> Use the !song command in StreamElements chatbot to get information about the currently playing song from the media request queue.
The `!song` command allows viewers to retrieve information about the currently playing song in the StreamElements media request queue. This command is useful for viewers who want to know the title, artist, and requester of the current song.
## Usage
[Section titled “Usage”](#usage)
To use the `!song` command, simply type it in the chat:
```streamelements
!song
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!song
StreamElements:@User, current song: DrakeVEVO - Drake, 21 Savage - Rich Flex (Audio), requested by styler https\://youtu.be/I4DjHHVHWAE
Example chat
ViewerName:!song
StreamElements:@User, No song is currently playing.
## Configuration
[Section titled “Configuration”](#configuration)
* The information displayed depends on the media source (e.g., YouTube, Spotify) and the data available for the requested track.
* Default cooldown: 15 seconds global.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songrequest`](/chatbot/commands/default/songrequest): Used to add songs to the media request queue.
* [`!skip`](/chatbot/commands/default/skip): (Moderator+) Used to skip the current song.
* [`!next`](/chatbot/commands/default/next): Shows details about the *next* song in the queue.
* [`!songqueue`](/chatbot/commands/default/songqueue): Shows the upcoming songs in the media request queue.
* [`!play`](/chatbot/commands/default/play) / [`!pause`](/chatbot/commands/default/pause): (Moderator+) Controls playback.
# !songqueue
> Use the !songqueue command in StreamElements chatbot to get a link to the current media request queue page.
The `!songqueue` command replies with a direct link to the channel’s StreamElements Media Request queue page. It does **not** print the queue contents in chat — the linked page shows the upcoming songs or videos.
## Usage
[Section titled “Usage”](#usage)
Type `!songqueue` in the chat to receive a link to the media request queue page:
```streamelements
!songqueue
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!songqueue
StreamElements:You can see the songrequest queue here https\://StreamElements.com/YOUR\_CHANNEL/mediarequest
## Configuration
[Section titled “Configuration”](#configuration)
* The linked page shows requests that are currently in the queue.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* Default cooldown: 10 seconds global.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songrequest`](/chatbot/commands/default/songrequest) / `!sr`: Used to request a song or media to be added to the queue.
* [`!wrongsong`](/chatbot/commands/default/wrongsong): Allows users to remove their most recent song request from the queue.
* [`!song`](/chatbot/commands/default/song): Displays information about the currently playing song or media.
* [`!next`](/chatbot/commands/default/next): Displays information about the next song in the queue.
# !songrequest
> Use the !songrequest (!sr) command in StreamElements chatbot to allow viewers to add YouTube songs/videos to the media request queue.
The `!songrequest` command (aliased as `!sr`) allows viewers to add songs or videos to the streamer’s media request queue. This command primarily integrates with YouTube, enabling users to request media using search terms or direct URLs.
## Usage
[Section titled “Usage”](#usage)
To request media:
```streamelements
!songrequest
```
Or using the alias:
```streamelements
!sr
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!songrequest epic sax guy
StreamElements:@User, added Epic Sax Guy - "Epic Sax Guy 10 Hours" to the queue at #2 (playing \~in 3 mins 5 secs) https\://youtu.be/kxopViU98Xo
Example chat
ViewerName:!sr https\://www\.youtube.com/watch?v=dQw4w9WgXcQ
StreamElements:@User, added Rick Astley - "Never Gonna Give You Up" to the queue at #3 (playing \~in 7 mins 15 secs) https\://youtu.be/dQw4w9WgXcQ
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The media to request. This can be:
* A YouTube video URL.
* A YouTube playlist URL (if enabled in settings).
* A search term (the bot will typically pick the first result).
## Configuration
[Section titled “Configuration”](#configuration)
* Streamers can configure various settings in the Media Request module:
* Enable/disable the feature.
* Link a Spotify account (optional, for different functionality).
* Set request limits (per user, per stream).
* Set a **minimum user level** required to request songs.
* Set maximum song/video duration.
* Enable/disable playlist requests.
* Set up a song blacklist (by keyword or specific URL).
* Loyalty point costs:
* A **per-song cost** can be set, charged in loyalty points each time a viewer requests a song.
* A **subscriber discount** (percentage) reduces the cost for subscribers.
* Users at or above the configured **exempt level** (Moderators and above by default) pay nothing and bypass request filters.
* If **moderation** is enabled, requests from non-exempt users are sent to a pending queue for approval instead of being added directly.
* Default cooldown: 15 seconds per user, 3 seconds global.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songqueue`](/chatbot/commands/default/songqueue): View the current media request queue.
* [`!song`](/chatbot/commands/default/song): Displays information about the currently playing song.
* [`!next`](/chatbot/commands/default/next): Displays information about the next song in the queue.
* [`!wrongsong`](/chatbot/commands/default/wrongsong): Allows users to remove their most recent song request.
* [`!skip`](/chatbot/commands/default/skip): (Moderator+) Skips the currently playing song.
* [`!volume`](/chatbot/commands/default/volume): Checks or adjusts the volume of the media player.
* [`!removesong`](/chatbot/commands/default/removesong): (Moderator+) Removes a specific song or all songs by a user.
# !sraffle
> Use the !sraffle command in StreamElements chatbot to start a single-winner raffle that awards the full points prize to one viewer. Viewers enter using !join.
The `!sraffle` command allows streamers and moderators to start a **single-winner raffle**. The command randomly selects **one winner** from all the viewers who entered using the [`!join`](/chatbot/commands/default/join) command (entry is free, one entry per viewer), and that winner receives the **full points prize**. For a raffle with multiple winners that split the prize, use [`!raffle`](/chatbot/commands/default/raffle) instead.
## Usage
[Section titled “Usage”](#usage)
To start a single-winner raffle:
```streamelements
!sraffle [win_points] [duration_seconds]
```
## Examples
[Section titled “Examples”](#examples)
**Start a raffle awarding 10 points, lasting 10 seconds:**
Example chat
ModUser:!sraffle 10 10
StreamElements:a Raffle has begun for 10 points PogChamp it will end in 10 Seconds. Enter by typing "!join" OpieOP
**Start a raffle using the default prize (1000 points) and the default duration from the module settings:**
Example chat
ModUser:!sraffle
StreamElements:a Raffle has begun for 1000 points PogChamp it will end in 60 Seconds. Enter by typing "!join" OpieOP
## Parameters
[Section titled “Parameters”](#parameters)
* `[win_points]` (Optional): The amount of loyalty points awarded to the winner. Defaults to `1000` if not specified. The amount is capped at the maximum configured in the Raffle module settings. Requires the Loyalty module to be active.
* `[duration_seconds]` (Optional): How long the raffle entry period lasts (in **seconds**). If not specified, the default duration from the Raffle module settings on the Dashboard is used. The minimum duration is 5 seconds.
## Configuration
[Section titled “Configuration”](#configuration)
* Requires the **Raffle module** to be active (`Chatbot` -> `Modules`).
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* Other settings like the default duration (in seconds), the maximum points amount, and the raffle messages can be configured in the Raffle module settings on the Dashboard. The entry command is fixed to `!join`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!join`](/chatbot/commands/default/join): The command viewers use to enter an active `!sraffle`.
* [`!raffle`](/chatbot/commands/default/raffle): (Moderator+) Starts a multi-winner raffle where the points prize is split between the winners.
* [`!cancelraffle`](/chatbot/commands/default/cancelraffle): (Moderator+) Cancels the currently active raffle (`!raffle` or `!sraffle`).
* [`!giveaway`](/chatbot/commands/default/giveaway): Checks the status of the main channel giveaway.
# !srclear
> Use the !srclear command in StreamElements chatbot to clear the entire song/media request queue. Useful for moderation.
The `!srclear` command is used to clear the **entire** media request queue in your StreamElements chatbot. This command is particularly useful for streamers and moderators who want to reset the list of requested songs or videos during a stream.
## Usage
[Section titled “Usage”](#usage)
To clear the queue, simply type the command in chat:
```streamelements
!srclear
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!srclear
StreamElements:@Moderator, Songrequest queue has been cleared!
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* Default cooldown: 10 seconds global and 10 seconds per user.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songrequest`](/chatbot/commands/default/songrequest): Used to request a song.
* [`!removesong`](/chatbot/commands/default/removesong): Removes a specific song or all songs by a user.
* [`!wrongsong`](/chatbot/commands/default/wrongsong): Allows users to remove their most recent song request.
* [`!skip`](/chatbot/commands/default/skip): Skips the currently playing song in the queue.
# !ticket
> Use the !ticket command in StreamElements chatbot to purchase giveaway tickets with loyalty points.
The `!ticket` command allows viewers to purchase tickets for ongoing giveaways using their loyalty points. This command enables participation in raffles hosted through the StreamElements loyalty system.
Important Note
By default, the `!ticket` command does **not** reply to the user to prevent chat spam during active giveaways. Streamers can enable confirmation messages by checking the “Send confirmation when buying tickets in chat” option in the giveaway settings on the StreamElements dashboard.
## Usage
[Section titled “Usage”](#usage)
To purchase tickets, type `!ticket` in the chat, optionally followed by the number of tickets you wish to buy. If no number is specified, it defaults to purchasing one ticket.
**Syntax:**
```streamelements
!ticket [number_of_tickets]
```
## Examples
[Section titled “Examples”](#examples)
1. **Buying a single ticket:**
Example chat
ViewerName:!ticket
StreamElements:@viewer, you successfully bought 1 ticket!
2. **Buying multiple tickets:**
Example chat
ViewerName:!ticket 5
StreamElements:@viewer, you successfully bought 5 tickets!
*(Note: The reply is only sent if enabled by the streamer)*
## Parameters
[Section titled “Parameters”](#parameters)
| Parameter | Type | Description |
| ------------------- | -------- | ----------------------------------------------------------------------------------------------- |
| `number_of_tickets` | Optional | The number of tickets to purchase. Defaults to `1` if omitted. Must be a positive whole number. |
## Configuration
[Section titled “Configuration”](#configuration)
Streamers configure giveaway settings, including ticket cost and the maximum number of tickets a viewer can purchase per giveaway, through the StreamElements dashboard under **Loyalty -> Giveaways**.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!giveaway`](/chatbot/commands/default/giveaway): Checks the status of the currently active giveaway.
* [`!points`](/chatbot/commands/default/points): Allows users to check their current loyalty points balance.
## FAQ
[Section titled “FAQ”](#faq)
* **What happens if I try to buy more tickets than I have points for?** The command will fail, and you won’t purchase any tickets. You might receive an error message depending on the bot’s configuration, or the command might silently fail.
* **Can I buy tickets if there’s no giveaway running?** No, the `!ticket` command only works when a giveaway is active.
* **Is there a maximum number of tickets I can buy?** Yes, the streamer sets a maximum number of tickets per user for each giveaway in the StreamElements dashboard.
# !timer
> Use the !timer command in StreamElements chatbot to enable or disable specific chat timers directly from chat.
The `!timer` command allows moderators to enable or disable specific chat timers directly from the chat interface. Timers are messages automatically posted by the bot at set intervals.
## Usage
[Section titled “Usage”](#usage)
To enable or disable a timer:
```streamelements
!timer
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ModUser:!timer enable socialMediaTimer
StreamElements:@Moderator, timer socialMediaTimer has been enabled.
Example chat
BroadcasterName:!timer disable upcomingEvent
StreamElements:@Broadcaster, timer upcomingEvent has been disabled.
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The action to perform. `enable` turns the timer on, `disable` turns it off.
* `` (Required): The ID or exact Name of the timer as configured in the StreamElements Dashboard.
## Configuration
[Section titled “Configuration”](#configuration)
* Timers must be created and configured in the **StreamElements Dashboard** under `Chatbot` -> `Timers`.
* You can find the Timer ID or set a specific Name in the timer’s settings on the Dashboard.
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!command`](/chatbot/commands/default/command): Manages custom commands, which can sometimes serve similar purposes to simple timers.
# !tip
> Use the !tip command in StreamElements chatbot to provide viewers with a link to your StreamElements tipping page.
The `!tip` command provides a convenient way for viewers to access the streamer’s tipping link directly in chat. When used, it generates a message containing a URL where viewers can make monetary contributions to support the streamer via StreamElements.
## Usage
[Section titled “Usage”](#usage)
To display the tipping link, simply type the command in chat:
```streamelements
!tip
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!tip
StreamElements:You can Tip to StreamerName using this link https\://streamelements.com/StreamerName/tip
## Configuration
[Section titled “Configuration”](#configuration)
* The tipping page must be set up in your **StreamElements Dashboard** under `Revenue` → `Tipping Settings`.
* The command is usually enabled by default.
* You can customize the command’s response message under `Chatbot` → `Chat Commands` → `Default Commands` → `!tip`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* While not a direct command, setting up `Alerts` for tips in your overlays complements this command.
# !top
> Use the !top command in StreamElements chatbot to display the top users based on loyalty points or watch time directly in chat.
The `!top` command displays the top users in chat based on either loyalty points or watch time, depending on the parameter provided. It provides a quick glimpse of the leaderboard directly within the chat interface.
## Usage
[Section titled “Usage”](#usage)
To view a specific leaderboard:
```streamelements
!top [type]
```
If `[type]` is omitted, the points leaderboard is shown. The command displays the top 5 users for the chosen leaderboard.
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!top points
StreamElements:Top 5 ChannelPoints: 1. UserA (15000), 2. UserB (12500), 3. UserC (11000), 4. UserD (9800), 5. UserE (9500)
Example chat
ViewerName:!top online
StreamElements:Top 5 Online Watchtime: 1. UserC (50h 10m), 2. UserA (45h 30m), 3. UserE (42h 5m), 4. UserB (40h 15m), 5. UserF (38h 0m)
Example chat
ViewerName:!top
StreamElements:Top 5 ChannelPoints: 1. UserA (15000), 2. UserB (12500), 3. UserC (11000), 4. UserD (9800), 5. UserE (9500)
## Parameters
[Section titled “Parameters”](#parameters)
* `[type]` (Optional): The type of leaderboard to display. Valid options are:
* `points` (default): Shows the top users based on loyalty points. Used when `[type]` is omitted.
* `alltime`: Displays the leaderboard based on total watch time.
* `online`: Shows the top users based on watch time while the stream was live.
* `offline`: Displays the top users based on watch time while the stream was offline.
## Configuration
[Section titled “Configuration”](#configuration)
* Enable the **Loyalty system** under `Loyalty` -> `Loyalty Settings`.
* The leaderboards displayed depend on the Loyalty module configuration (points tracking, watch time tracking enabled).
* The name of the points currency (e.g., “ChannelPoints”) is set in Loyalty Settings.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Checks an individual user’s points and rank.
* [`!watchtime`](/chatbot/commands/default/watchtime): Checks an individual user’s watch time.
* [`!leaderboard`](/chatbot/commands/default/leaderboard): Provides a link to the full web-based leaderboard.
# !uptime
> Use the !uptime command in StreamElements chatbot to check the current stream's duration.
The `!uptime` command allows viewers and moderators to check how long the current stream has been live. It’s a simple yet useful tool for tracking stream duration.
## Usage
[Section titled “Usage”](#usage)
To check the stream duration, simply type the command in the chat:
```streamelements
!uptime
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!uptime
StreamElements:@StreamerName has been live for 2 hours 35 minutes and 10 seconds
## Configuration
[Section titled “Configuration”](#configuration)
* This command relies on the bot having access to the stream’s start time information.
* The response format can often be customized in the default command settings (`Chatbot` -> `Chat Commands` -> `Default Commands` -> `!uptime`).
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!followage`](/chatbot/commands/default/followage): Checks how long a user has followed (Twitch).
* [`!watchtime`](/chatbot/commands/default/watchtime): Checks a user’s accumulated watch time.
* [`!accountage`](/chatbot/commands/default/accountage): Checks when a user account was created.
# !vanish
> Use the !vanish command in StreamElements chatbot to time yourself out for 1 second, effectively clearing your visible messages.
The `!vanish` command allows chatters to temporarily time themselves out for 1 second. On platforms like Twitch, this has the effect of clearing their recent messages from the chat window for other users.
## Usage
[Section titled “Usage”](#usage)
To use the `!vanish` command, simply type it in the chat:
```streamelements
!vanish
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!vanish
StreamElements:StreamElements timed out \[User] for 1 second.
## Configuration
[Section titled “Configuration”](#configuration)
* This command is typically enabled by default.
* Its functionality relies on the bot having timeout permissions (usually inherent).
* The command can be enabled/disabled or have its permissions changed in the `Chatbot` → `Chat Commands` → `Default Commands` section of the StreamElements dashboard.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!nuke`](/chatbot/commands/default/nuke): (Moderator+) Bulk timeout, ban, or delete recent messages matching specific text or regex.
* [`!permit`](/chatbot/commands/default/permit): (Moderator+) Temporarily allows a user to post links without being timed out.
# !volume
> Use the !volume command in StreamElements chatbot to check or set the volume for the media request player.
The `!volume` command allows users to check or adjust the volume level of the StreamElements media request player.
## Usage
[Section titled “Usage”](#usage)
**To check the current volume:**
```streamelements
!volume
```
**To set an absolute volume level:**
```streamelements
!volume
```
**To adjust the volume relative to its current level:**
```streamelements
!volume +
!volume -
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!volume
StreamElements:Current volume is 50%
Example chat
ViewerName:!volume 75
StreamElements:@User set the songrequest volume to 75%
Example chat
ViewerName:!volume +10
StreamElements:@User set the songrequest volume to 85%
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Optional): A number between `0` and `100` representing the desired volume percentage, or a relative adjustment prefixed with `+` or `-` (e.g. `!volume +10`, `!volume -10`). The resulting value is always clamped to the `0`–`100` range. If omitted, the command displays the current volume.
## Configuration
[Section titled “Configuration”](#configuration)
* The command’s permission level can be adjusted under `Chatbot` -> `Chat Commands` -> `Default Commands`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songrequest`](/chatbot/commands/default/songrequest): Used to request songs or media content.
* [`!skip`](/chatbot/commands/default/skip): Skips the currently playing media request.
* [`!play`](/chatbot/commands/default/play) / [`!pause`](/chatbot/commands/default/pause): Controls media playback.
# !votekick
> Use the !votekick command in StreamElements chatbot to initiate a community vote to temporarily kick a user from chat.
The `!votekick` command initiates a community vote to temporarily remove (timeout) a user from the chat. This allows viewers to participate in moderation by collectively deciding if a user should be kicked for a period.
## Usage
[Section titled “Usage”](#usage)
To start a vote to kick a user:
```streamelements
!votekick [duration]
```
## Examples
[Section titled “Examples”](#examples)
**Start a votekick for “DisruptiveUser” with the default vote duration:**
Example chat
ModUser:!votekick DisruptiveUser
StreamElements:Vote started to kick DisruptiveUser! Type !yes or !no to vote. (Vote ends in 60s)
**Start a votekick for “RuleBreaker” with a 2-minute vote duration:**
Example chat
ModUser:!votekick RuleBreaker 2m
StreamElements:Vote started to kick RuleBreaker! Type !yes or !no to vote. (Vote ends in 120s)
## Parameters
[Section titled “Parameters”](#parameters)
* `` (Required): The exact username of the user to potentially kick.
* `[duration]` (Optional): The length of time the *voting period* should last.
* If not specified, uses the default duration set in the module configuration.
* Can be specified in seconds (`s`), minutes (`m`), or hours (`h`) (e.g., `90s`, `3m`).
* Note: This is the duration for voting, *not* the kick/timeout duration if the vote passes.
## Configuration
[Section titled “Configuration”](#configuration)
* Requires the **Votekick module** to be enabled (`Chatbot` -> `Modules`).
* Moderators configure settings in the **Votekick module** on the Dashboard:
* Enable/disable the module.
* Set the default **Vote Duration**.
* Set the required **Minimum Votes** for the vote to be considered valid.
* Define the **Vote Threshold** (percentage of `!yes` votes needed to pass).
* Set the **Timeout Duration** (how long the user is kicked if the vote passes).
* Establish **Cooldowns** (global and per-user for starting votes).
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!nuke`](/chatbot/commands/default/nuke): (Moderator+) Bulk timeout, ban, or delete recent messages matching specific text or regex.
* [Votekick Module](/chatbot/modules/votekick): Configure the votekick settings (vote duration, thresholds, timeout duration, and cooldowns).
# !voteskip
> Use the !voteskip command in StreamElements chatbot to allow viewers to vote for skipping the current media request (song/video).
The `!voteskip` command allows viewers to vote towards skipping the currently playing song or video in the StreamElements media request queue. Each user gets one vote; once the configured number of votes is reached, the current item is skipped.
## Usage
[Section titled “Usage”](#usage)
To cast a vote to skip the current media:
```streamelements
!voteskip
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!voteskip
StreamElements:Current song will be skipped in 4 more votes!
Example chat
ViewerName:!voteskip
StreamElements:The people have spoken.. skipping the current song!
## Configuration
[Section titled “Configuration”](#configuration)
* The **Vote Skip** feature must be enabled within the Media Request module settings on the StreamElements Dashboard — if it is disabled, the command does nothing.
* Streamers configure the **Number of votes required to skip** in the module settings; the song is skipped once the vote count reaches that threshold.
* Each user can vote only once per song.
* Default cooldown: 10 seconds per user.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!song`](/chatbot/commands/default/song): Displays information about the currently playing song or media.
* [`!next`](/chatbot/commands/default/next): Displays information about the next song in the queue.
* [`!wrongsong`](/chatbot/commands/default/wrongsong): Allows users to remove their own song request from the queue.
* [`!songrequest`](/chatbot/commands/default/songrequest): Lets viewers request songs or media to be played.
* [`!skip`](/chatbot/commands/default/skip): (Moderator+) Immediately skips the current media.
# !watchtime
> Use the !watchtime command in StreamElements chatbot to check your own or another user's accumulated watch time for the channel.
The `!watchtime` command allows viewers to check how long they’ve accumulated watching the current channel. This feature requires the Loyalty system to be active and configured to track watch time.
## Usage
[Section titled “Usage”](#usage)
To check watch time:
```streamelements
!watchtime [username]
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!watchtime
StreamElements:@User has spent 2 hours and 15 minutes watching StreamerName!
Example chat
ViewerName:!watchtime LoyalViewer
StreamElements:LoyalViewer has spent 1 day 5 hours and 30 minutes watching StreamerName!
## Parameters
[Section titled “Parameters”](#parameters)
* `[username]` (Optional): The username of the viewer whose watch time you want to check. If omitted, it defaults to the user issuing the command.
## Configuration
[Section titled “Configuration”](#configuration)
* Enable the **Loyalty system** under `Loyalty` -> `Loyalty Settings`.
* **Watch time tracking** must be enabled within the Loyalty Settings.
* The command itself (`!watchtime`) is usually enabled by default when Loyalty is active.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!points`](/chatbot/commands/default/points): Checks the loyalty points balance.
* [`!top`](/chatbot/commands/default/top): Shows the top viewers by watch time or points.
* [`!leaderboard`](/chatbot/commands/default/leaderboard): Provides a link to the full leaderboard.
* [`!uptime`](/chatbot/commands/default/uptime): Shows the duration of the *current* stream session.
# !when
> Use the !when (!mysong) command in StreamElements chatbot to check the queue position and estimated play time of your song request.
The `!when` command allows viewers to check the status of **their own song request** in the media request queue. It provides the song’s position in the queue and an estimated time until it plays. You can also pass a YouTube URL or video ID to check where a specific song sits in the queue.
## Usage
[Section titled “Usage”](#usage)
To check the status of your own song request:
```streamelements
!when
```
To check the queue position of a specific song:
```streamelements
!when
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!when
StreamElements:@User, "The Best Song Ever" is at #4 in the queue and is playing in 12 mins
Example chat
ViewerName:!when
StreamElements:@User, "Currently Playing" is at #1 in the queue and is playing right now
Example chat
ViewerName:!when
StreamElements:@User, you do not have a song in the queue.
## Configuration
[Section titled “Configuration”](#configuration)
* Without an argument, the command checks the queue for a request made by the user issuing the command. With a YouTube URL or video ID, it looks up that song’s position instead.
* Default cooldown: 15 seconds global.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songrequest`](/chatbot/commands/default/songrequest): Used to request a song.
* [`!wrongsong`](/chatbot/commands/default/wrongsong): Removes your last song request.
* [`!songqueue`](/chatbot/commands/default/songqueue): Provides a link to the full queue.
* [`!song`](/chatbot/commands/default/song): Shows the currently playing song.
* [`!next`](/chatbot/commands/default/next): Shows the next song in the queue.
# !wrongsong
> Remove the last song you added to the StreamElements media request queue using the !wrongsong command.
The `!wrongsong` command allows viewers to remove the **last song they added** to the StreamElements media request queue. This is useful if you accidentally requested the wrong song or simply changed your mind.
## Usage
[Section titled “Usage”](#usage)
To remove your last song request, simply type the command in chat:
```streamelements
!wrongsong
```
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!wrongsong
StreamElements:@ViewerName Removed your last song from the queue: Bohemian Rhapsody by Queen
Example chat
ViewerName:!wrongsong
StreamElements:@ViewerName You haven't requested any songs recently.
## Configuration
[Section titled “Configuration”](#configuration)
* The command affects only the song requested by the user issuing the command.
* Streamers can customize the response messages in the StreamElements dashboard under `Chatbot` -> `Chat Commands` -> `Default Commands`.
* Default cooldown: 10 seconds per user.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!songrequest`](/chatbot/commands/default/songrequest): Used to add a song to the request queue.
* [`!when`](/chatbot/commands/default/when): Checks the status of your last requested song.
* [`!songqueue`](/chatbot/commands/default/songqueue): Provides a link to the full queue.
* [`!song`](/chatbot/commands/default/song): Displays information about the currently playing song.
* [`!next`](/chatbot/commands/default/next): Shows the next song in the queue.
# Counters
> Track game deaths, missed shots, or any other event in your stream with chatbot counters and the count and getcount variables.
Counters are an easy way to keep track of certain things in your stream. They can be used to keep track of how many times you’ve died in a game, or how many times you’ve missed a cannon minion in League of Legends.
You can manage your counters in the [StreamElements Dashboard](https://streamelements.com/dashboard/bot/counters) or use the variable directly from chat listed below.
## Variables
[Section titled “Variables”](#variables)
* `getcount` - Retrieves the current count of the counter. For more information, refer to the [getcount documentation](/chatbot/variables/getcount).
* `count` - Increments or decrements the counter. For more information, refer to the [count documentation](/chatbot/variables/count).
## Examples
[Section titled “Examples”](#examples)
### Add counter command
[Section titled “Add counter command”](#add-counter-command)
Let’s start by adding a new counter command for missed cannons in League of Legends:
1. Create a new command by typing `!cmd add !cannon $(count cannon)`
2. Now when you type `!cannon` in chat, it will increment the counter by 1.

### Get the current count
[Section titled “Get the current count”](#get-the-current-count)
Let’s create another command to see how many cannons you’ve missed (without incrementing the counter):
1. Create a new command by typing `!cmd add !missedcannons $(getcount cannon)`
2. Now when you type `!missedcannons` in chat, it will show you the current count of the cannon counter.

## Related
[Section titled “Related”](#related)
* [!editcounter](/chatbot/commands/default/editcounter) - Set, increment, or decrement a counter’s value from chat
* [$(count)](/chatbot/variables/count) - Increments or decrements a counter
* [$(getcount)](/chatbot/variables/getcount) - Retrieves the current count without changing it
# Spam Filters
> StreamElements Chatbot spam filters automatically moderate unwanted chat messages: banned words, caps, emotes, links, spam, and more.
Spam filters automatically moderate chat messages so you don’t have to catch everything yourself. Each filter targets one kind of unwanted message — caps, links, banned words, spam — and takes a configurable action when a message matches.
## Usage
[Section titled “Usage”](#usage)
To use spam filters, you need to enable and configure them in your StreamElements dashboard. Once set up, the filters will automatically scan incoming messages and take action based on your settings.
## Configuration
[Section titled “Configuration”](#configuration)
Filters live in the dashboard under **Chatbot → Spam filters**. The quickest way to start is the protection-level slider at the top of the page — **Filters off**, **Minimum**, **Medium**, or **Maximum** — which applies a preset configuration across the filters. From there, expand any individual filter to toggle it and fine-tune its settings.
1. In the dashboard, go to **Chatbot → Spam filters**
2. Pick a protection level as your starting point
3. Expand a filter to adjust its penalty, thresholds, announcements, and probation
4. Toggle the filter on
## Settings shared by all filters
[Section titled “Settings shared by all filters”](#settings-shared-by-all-filters)
In addition to its own thresholds, every filter supports these common settings:
| Setting | Description |
| --------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Enabled | Turns the filter on or off. |
| Penalty | The action taken when the filter is triggered: **Timeout user**, **Ban user**, **Delete message**, or **Warn and delete message** — see [What happens on a violation](#what-happens-on-a-violation). |
| Duration | How long (in seconds) a user is timed out for, when the penalty is a timeout. |
| Exclude user group | Users in the selected group or above — Regulars, Subscribers, or VIPs — are immune to the filter. Choose “No One” to apply it to everyone. |
| Custom message | A custom violation message. It doubles as the moderation reason attached to the timeout or ban, and as the announcement text. |
| Announcement settings | When enabled, the bot also sends a public warning in chat — `@username, ` — when the filter is triggered. Each filter has its own announcement cooldown (in seconds) so chat isn’t flooded with repeated announcements. |
| Probation settings | Escalates punishments for repeat offenders: when a user violates the same filter again within the probation window, the timeout becomes the base timeout × the configured multiplier × the user’s number of violations. Probation only escalates timeouts — it never applies to deletions, bans, or warnings. |
The moderation reason sent to the platform is your custom message with “ - automated by StreamElements” appended; the chat announcement uses the message as-is.
Filters never apply to the channel owner or to platform staff. Moderators can also use the [!permit](/chatbot/commands/default/permit) command to give a user a 30-second pass that bypasses all filters.
## What happens on a violation
[Section titled “What happens on a violation”](#what-happens-on-a-violation)
The **Penalty** setting controls what the bot does when a message violates a filter:
* **Timeout user** — time the user out for the configured Duration and remove the message.
* **Delete message** — remove the message without timing the user out.
* **Ban user** — permanently ban the user.
* **Warn and delete message** — issue a Twitch Warning and delete the message.
Note
Warnings are a Twitch feature. On other platforms the warn action is unavailable, so pick a timeout, deletion, or ban instead.
When one message violates several filters at once, only the harshest action is taken: a ban outranks a timeout, a timeout outranks a warning, and a warning outranks a plain deletion. If two filters both call for a timeout, the longer one wins.
## Available Filters
[Section titled “Available Filters”](#available-filters)
[Banned Words](/chatbot/filters/bannedwords)Remove messages containing banned phrases and regular expression patterns.
[Caps](/chatbot/filters/caps)Limit excessive use of capital letters in chat messages.
[Emotes](/chatbot/filters/emotes)Limit the number of emotes allowed in a single message.
[Language](/chatbot/filters/language)Remove messages written in languages you haven't allowed.
[Links](/chatbot/filters/links)Control link posting in chat with allowlists and blocklists.
[One-Man Spam](/chatbot/filters/one-man-spam)Stop a single user from flooding chat with repeated messages.
[Paragraph](/chatbot/filters/paragraph)Limit the maximum length of chat messages.
[Repetition](/chatbot/filters/repetition)Limit excessive repetition of characters and sequences.
[Symbol](/chatbot/filters/symbol)Limit the number and percentage of symbols in chat messages.
[Zalgo](/chatbot/filters/zalgo)Remove zalgo and other combining-character text.
# Banned Words Filter
> Remove messages containing banned phrases or regular expression patterns with the StreamElements Chatbot Banned Words filter.
The Banned Words filter is a tool that helps maintain the chat environment by removing messages that contain banned phrases and patterns. This filter is highly customizable and supports the creation of multiple groups, each with its own set of banned phrases.
These phrases can be simple text or they can be regular expressions (regexp), providing a high degree of flexibility in defining what constitutes a banned phrase. For example, you could ban a specific word, or use a regular expression to ban any word that contains a certain sequence of characters.
To use this filter, simply define your groups and their associated banned phrases or patterns. Any incoming message that matches a banned phrase or pattern in any group is automatically moderated according to that group’s settings.
## Settings
[Section titled “Settings”](#settings)
Banned phrases are organized into groups. Click the **Add Group** button to create a new group (named **Group 1** by default). Each group has its own settings:
| Setting | Description |
| ------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Timeout length | Controls the action taken when a phrase in this group matches — a timeout for the configured number of seconds, message deletion only (timeout of 0), a permanent ban, or a warning plus deletion (Twitch only). This per-group value takes precedence over the filter-wide timeout. See [What happens on a violation](/chatbot/filters#what-happens-on-a-violation). |
| Scan section | Which parts of a chat message the group checks: the message text, the sender’s username, or both. |
| Exclude user group | A user-level threshold. Users at or above the selected level (for example, Moderators and above) are not checked against this group. |
| Ban reason | The moderation reason attached to the timeout or ban. |
| Banned phrases | The phrases the group matches messages against. Each entry is either plain text or a regular expression. |
When phrases from several groups match the same message, the harshest action wins: a ban beats any timeout, and between timeouts the longest one is applied.
## Phrase matching
[Section titled “Phrase matching”](#phrase-matching)
**Text phrases** are matched case-insensitively and only against whole words — `bad` matches “bad” but not “badge”. Text phrases also support the `*` wildcard, which matches any run of non-space characters.
**Regular expressions** use Go’s RE2 syntax, which does not support backreferences or lookaround. Patterns are case-insensitive by default; to take full control of the flags, start your pattern with an inline flag group such as `(?s)` — the default case-insensitivity then no longer applies. Enter patterns bare, without surrounding slashes: in `/b[aá]dword/` the slashes would be treated as literal characters and the pattern would never match.
## Examples
[Section titled “Examples”](#examples)
* Plain phrase: `badword` — removes any message containing the word “badword”, in any capitalization.
* Regular expression: `b[aá]dword` — also catches spelling variants such as “bádword”.

# Caps Filter
> Limit the number and percentage of capital letters in chat messages with the StreamElements Chatbot Caps filter.
The Caps filter helps manage the use of capital letters in chat messages. It checks the number and percentage of capital letters in a message and compares them with the set limits. If a message violates these limits, the filter takes action according to the configured settings.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| ------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Maximum amount | The maximum number of capital letters allowed in a message. If a message contains more capital letters than this limit, it will be flagged by the filter. |
| Minimum characters | The minimum number of characters a message must have before the filter checks for a violation. If a message contains fewer characters than this limit, it will not be checked by the filter. |
| Maximum percent | The maximum percentage of a message that can be capital letters. If the percentage of capital letters in a message exceeds this limit, it will be flagged by the filter. |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
# Emote Filter
> Limit the number of emotes allowed in a single chat message with the StreamElements Chatbot Emote filter.
The Emote filter helps manage the use of emotes in chat messages. It checks the number of emotes in a message and compares them with the set limit. If a message violates this limit, the filter takes action according to the configured settings.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| -------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| Maximum amount | The maximum number of emotes allowed in a message. If a message contains more emotes than this limit, it will be flagged by the filter. |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
# Language Filter
> Remove chat messages written in languages you haven't allowed with the StreamElements Chatbot Language filter.
The Language filter moderates messages based on the language they are written in. A message is flagged when the detector is confident about its language and that language is not on your allowed list. When no allowed languages are configured, the filter is off.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| ---------------------------- | ----------------------------------------------------------------------------------------------------------------------------- |
| Allowed languages | The languages permitted in chat. An empty list disables the filter. |
| Minimum detection confidence | How sure the detector must be before the filter may act, as a percentage. Messages below this are left alone. Defaults to 40. |
| Ignored words | Words and phrases stripped from a message before its language is detected, such as emote names and channel slang. |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
## How a message is checked
[Section titled “How a message is checked”](#how-a-message-is-checked)
1. Your ignored words are removed from the message, wherever they appear and whatever their casing.
2. Everything that is not a letter or a space is dropped, so numbers, punctuation, and emoji never sway the result. If nothing is left, the message is skipped.
3. What remains goes to the language detector, which returns one language and a confidence score.
4. If that score is below your **Minimum detection confidence**, the message is skipped.
5. Otherwise the detected language is compared against your allowed list. A match means the message passes; anything else is flagged.
The filter never punishes on doubt. A message it cannot read confidently is left alone, and so is one the detector fails to answer for in time.
## Choosing a confidence value
[Section titled “Choosing a confidence value”](#choosing-a-confidence-value)
The detector picks between 75 languages, so its confidence is spread thin on short messages. A two-word message rarely carries enough signal to identify, and the top guess is often nonsense:
| Message | Top guess | Confidence |
| ------------------------------------------- | ---------- | ---------- |
| `ok` | Zulu | 6.4% |
| `hi` | Maori | 6.1% |
| `gg` | Indonesian | 14.4% |
| `lets gooo` | Tswana | 21.7% |
| `KEKW PogChamp LULW` | Zulu | 23.1% |
| `how are you doing today` | English | 45.6% |
| `hola amigos como estan todos hoy` | Spanish | 47.8% |
| `ich finde diesen stream richtig gut heute` | German | 86.8% |
Real sentences land around 45% and up. Chat noise sits well below 25%. The default of 40 falls in the gap, which is why short English messages survive in an English-only channel while genuine foreign sentences are caught.
Lower the value and the filter reaches further, at the cost of acting on messages it is guessing about. Raise it and only unmistakable foreign text is flagged.
Tip
Add your channel’s emote names and catchphrases to **Ignored words**. They are the most common reason an otherwise ordinary message gets read as another language.
# Link Filter
> Control link posting in chat with allowlists, blocklists, and timeout settings using the StreamElements Chatbot Link filter.
The Link filter helps manage the posting of links in chat messages. It checks if a message contains any links and compares them with the set allowlist and blocklist. If a message contains a link that is not in the allowlist or is in the blocklist, the filter takes action according to the configured settings.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Allowlist | A list of links or link patterns that are allowed in messages. Links matching the allowlist are never flagged by the filter. |
| Blocklist | A list of links or link patterns that are never allowed in messages. Any link that matches a pattern in this list is treated as harmful and punished more harshly. |
Both lists support the `*` wildcard character for flexible rules, and patterns are matched case-insensitively.
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
Links matching the blocklist receive a harsher punishment: when the action is a timeout, the user is timed out for **double** the configured duration. With any other action (delete only, ban, or warning), the configured action applies as-is.
# One-Man Spam Filter
> Stop a single user from flooding chat with repeated or spammy messages using the StreamElements Chatbot One-Man Spam filter.
The One-Man Spam filter targets spam coming from a single user. Instead of judging each message in isolation, it compares a user’s recent messages against each other and triggers when too many of them are the same or nearly the same.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| ------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Minimum characters | The number of characters a message must have to count towards the filter. Shorter messages are ignored. (Default: 4) |
| Minimum messages | The number of messages the user must have sent within the lookback window before the filter can trigger. (Default: 5) |
| Lookback | How many seconds of the user’s message history are inspected. (Default: 30) |
| Threshold | The message similarity score (0–100, decimals allowed) that causes the user to be timed out. Messages at or above this similarity count as spam. (Default: 75) |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
# Paragraph Filter
> Limit the maximum length of chat messages with the StreamElements Chatbot Paragraph filter's character limit, timeout duration, and exclusions.
The Paragraph filter helps manage the length of chat messages. It checks the number of characters in a message and compares them with the set limit. If a message violates this limit, the filter takes action according to the configured settings.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| -------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |
| Maximum amount | The maximum number of characters allowed in a message. If a message contains more characters than this limit, it will be flagged by the filter. |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
# Repetition Filter
> Limit excessive repetition of characters and sequences in chat messages with the StreamElements Chatbot Repetition filter.
The Repetition filter limits how often the same word may be repeated within a single chat message (for example “spam spam spam spam spam”). A message is flagged when any word occurs more times than the configured maximum.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| ------------------------ | ------------------------------------------------------------------------------- |
| Maximum word repetitions | The maximum number of times a word can occur in a single message. (Default: 15) |
| Minimum characters | Words shorter than this are ignored when counting repetitions. (Default: 3) |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
# Symbol Filter
> Limit the number and percentage of symbols in chat messages with the StreamElements Chatbot Symbol filter's thresholds and timeout settings.
The Symbol filter flags messages that contain too many symbols — either more than an absolute number, or making up too large a share of the message.
## What counts as a symbol
[Section titled “What counts as a symbol”](#what-counts-as-a-symbol)
Any character that is not a letter, a number, or a space. This includes:
* Punctuation: `!` `?` `.` `,` `"` `'` `@` `#` `&` `(` `)`
* Math and currency signs: `+` `=` `<` `>` `$` `€` `^` `~`
* Unicode emoji such as 🎉
Letters and digits from any alphabet, spaces, and accents on letters are never counted. Platform emotes (Twitch, YouTube) are sent as ordinary words like `Kappa`, so they don’t count either — only Unicode emoji do.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| Maximum amount | The most symbols a message may contain. A message with more symbols than this is flagged. |
| Minimum amount | The minimum message length, in characters, before the filter applies. Messages shorter than this are never flagged, whatever they contain. |
| Maximum percent | The largest share of a message that may be symbols. The percentage is measured against all characters in the message, spaces included. |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
# Zalgo Filter
> Remove zalgo and other combining-character text from chat messages with the StreamElements Chatbot Zalgo filter.
The Zalgo filter removes “zalgo” text — messages distorted with stacked combining characters that bleed over surrounding lines and make chat hard to read. A message is flagged when it contains more combining characters than the configured maximum.
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| -------------- | -------------------------------------------------------------------------------------------- |
| Maximum amount | The maximum number of zalgo (combining) characters allowed in a single message. (Default: 1) |
The filter also supports the [settings shared by all filters](/chatbot/filters#settings-shared-by-all-filters) — timeout length, custom timeout message, excluded user level — which also determine [what happens on a violation](/chatbot/filters#what-happens-on-a-violation).
# Getting Started with the Chatbot
> Get started with the StreamElements Chatbot: create your first custom command and set up your first automated timer.
This guide walks you through the two most common ways to put the StreamElements Chatbot to work: creating your first custom command and setting up your first timer.
## Your first command
[Section titled “Your first command”](#your-first-command)
Commands are the main way users will interact with the bot in your chat. They can be used to trigger actions, or to display information to your users. In this example we will create a command that shows how long it has been since a user was last seen in chat.
1. From the [bot command dashboard](https://streamelements.com/dashboard/bot/commands), navigate to the “Custom commands” tab.
2. Click the “Add new command” button to open the command creation tool.

3. Enter the desired name for your new command in the “Command name” field. For this example we will name the command “lastseen”.
4. Optional: In the “Response type” dropdown, select the method you would like the bot to use to send the response.
* “Say” will send the response as a chat message as it is entered in the basic settings.
* “Mention” will send the response as a chat message, but will prefix the message with [`@$(user),`](/chatbot/variables/sender).
* “Reply” will send the response as a native reply to the user who triggered the command.
* NOTE: If the platform does not support native replies, the response will be sent as a “Mention” instead.
* “Whisper” will send the response as a whisper to the user who triggered the command.
5. Add the response in the “Reply” field. For our example, enter:
```streamelements
$(user) was last seen $(user.lastseen) ago
```
[`$(user)`](/chatbot/variables/user) and its sub-variables target the name typed after the command — or the person who used the command, when no name is given. For a list of all available variables, see the [variables documentation](/chatbot/variables).

6. Optional: Switch to the “Advanced settings” tab to add command aliases (alternate trigger words), cooldowns, a loyalty-point cost, or conditions such as only running while the stream is live.

7. Click the “Activate command” button to save your new command.

That’s it — the command is live in your chat:
Example chat
ViewerName:!lastseen SomeViewer
StreamElements:SomeViewer was last seen 5 mins 30 secs ago
## Your first timer
[Section titled “Your first timer”](#your-first-timer)
Timers allow you to automatically post announcements, social links, schedules, or any other messages at regular intervals in your chat.
1. From the [bot timers dashboard](https://streamelements.com/dashboard/bot/timers), click the “Add new timer” button in the top right corner.

2. In the expanded timer settings, enter a name for your timer in the “Timer Name” field.
3. Enter the message you want the timer to post under “Response messages”.
4. Set the “Online interval (minutes)”. This is how often the timer will post while your stream is live.

5. Click the “Activate Timer” button at the bottom of the timer settings.
6. The timer will now appear in your list of timers, where you can enable/disable it using the toggle switch.
For the remaining settings — offline interval, chat lines, multiple messages, and stream title or category conditions — see the [Timers](/chatbot/timers) reference.
## Next steps
[Section titled “Next steps”](#next-steps)
* Learn more about creating and managing [custom commands](/chatbot/commands/custom).
* Browse all available [variables](/chatbot/variables) you can use in responses.
* Read the [Timers](/chatbot/timers) reference for a full overview of timer settings.
* Explore [Modules](/chatbot/modules) and [Spam Filters](/chatbot/filters) to take your chatbot further.
# Chatbot Guides
> Step-by-step StreamElements Chatbot guides for building useful custom commands with counters, countdowns, viewer input, and more.
These guides combine chatbot commands, variables, and settings into complete features you can use in your channel. For individual syntax and configuration options, use the [Commands](/chatbot/commands) and [Variables](/chatbot/variables) reference sections.
[Death Counter](/chatbot/guides/death-counter)Count deaths, show the current score, correct mistakes, and reset between games.
[Lurk Command](/chatbot/guides/lurk-command)Give viewers a friendly way to say they are watching while away from chat.
[Countdown Command](/chatbot/guides/countdown-command)Count down to a daily stream time or a one-time event.
[Commands with Viewer Input](/chatbot/guides/viewer-input)Capture words from chat, add fallbacks and validation, and encode input for URLs.
# Create a Countdown Command
> Create a StreamElements countdown command for a daily stream time or a one-time event, with UTC and RFC 3339 examples.
A countdown command tells viewers how long remains until your next stream, tournament, community night, or other event. StreamElements provides two countdown formats: a recurring time of day and a fixed date and time.
## Choose a countdown type
[Section titled “Choose a countdown type”](#choose-a-countdown-type)
| Countdown | Use it for | Target format |
| --------- | -------------------------------------------------------- | ------------------------------------------------------------------ |
| Daily | A stream or event that starts at the same time every day | A 24-hour UTC time, such as `19:00` |
| One-time | An event on a specific date | A complete RFC 3339 timestamp, such as `2027-09-20T19:00:00-03:00` |
Check the timezone
A bare time is always interpreted as UTC, not your local timezone. For a one-time event, include its UTC offset in the timestamp. For example, `+02:00` means two hours ahead of UTC and `-03:00` means three hours behind UTC.
## Create a daily countdown
[Section titled “Create a daily countdown”](#create-a-daily-countdown)
This example counts down to the next occurrence of 19:00 UTC. If 19:00 has already passed today, the countdown automatically targets 19:00 tomorrow.
1. Open the [bot command dashboard](https://streamelements.com/dashboard/bot/commands), select **Custom commands**, and click **Add new command**.
2. Name the command `nextstream` and enter this reply:
```streamelements
The next stream starts in $(time.until 19:00)
```
3. Replace `19:00` with your start time converted to UTC.
4. Click **Activate command**.
Example chat
ViewerName:!nextstream
StreamElements:The next stream starts in 2 hours 30 mins
## Create a one-time event countdown
[Section titled “Create a one-time event countdown”](#create-a-one-time-event-countdown)
For an event on a particular date, use a complete RFC 3339 timestamp:
```streamelements
The community tournament starts in $(time.until 2027-09-20T19:00:00-03:00)
```
The timestamp has four parts:
```text
2027-09-20 T 19:00:00 -03:00
date time UTC offset
```
Replace the example with the event’s actual date, local start time, and UTC offset. After the fixed time passes, the output ends in `ago`; update or disable the command when the event is over.
## Troubleshooting
[Section titled “Troubleshooting”](#troubleshooting)
* **The time is several hours wrong:** a daily `HH:MM` target uses UTC. Convert the intended start time to UTC.
* **The bot prints a parsing error:** use either a bare `HH:MM` time or a complete RFC 3339 timestamp. Formats such as `September 20 at 7 PM` are not accepted.
* **The response says the event was “ago”:** the fixed timestamp is in the past. Update the target or disable the command.
* **The variable appears as text:** check the spelling and keep the target inside `$(time.until ...)`.
See the [`$(time)` reference](/chatbot/variables/time#timeuntil) for the precise input and output rules.
## Related
[Section titled “Related”](#related)
* [`$(time)`](/chatbot/variables/time): Current-time and countdown syntax.
* [Custom Commands](/chatbot/commands/custom): Manage the command from the dashboard or chat.
* [Timers](/chatbot/timers): Post messages automatically instead of waiting for a viewer command.
# Set Up a Death Counter
> Build a Twitch death counter with StreamElements: a !death command that counts up, a !deaths command to check the score, and a reset — step by step.
A death counter is three small commands: one that counts a death, one that shows the score without changing it, and one that resets it for the next game. It’s built on the chatbot’s [counters](/chatbot/counters), so the count survives stream restarts.
## The counting command
[Section titled “The counting command”](#the-counting-command)
1. From the [bot command dashboard](https://streamelements.com/dashboard/bot/commands), open the “Custom commands” tab and click “Add new command”.
2. Name the command `death`, set the “User level” to **Moderator** so random chatters can’t inflate your death count, and enter this reply:
```streamelements
Deaths: $(count deaths)
```

3. Click “Activate command”.
Every use of [`$(count deaths)`](/chatbot/variables/count) adds 1 to the counter and prints the new total — so each `!death` in chat is one more death:
Example chat
ModUser:!death
StreamElements:Deaths: 4
## Checking the score without counting
[Section titled “Checking the score without counting”](#checking-the-score-without-counting)
For a command everyone can use, read the counter with [`$(getcount)`](/chatbot/variables/getcount) — it outputs the value without adding to it. Create a second command named `deaths` (User level: Everyone) with the reply:
```streamelements
We have died $(getcount deaths) times so far
```
Example chat
ViewerName:!deaths
StreamElements:We have died 4 times so far
## Corrections and resets
[Section titled “Corrections and resets”](#corrections-and-resets)
The counter takes modifiers: `+n` adds, `-n` subtracts, and a bare number sets it. A moderator-level reset command with the reply below puts the counter back to zero between games:
```streamelements
Death counter reset ($(count deaths 0))
```
You can also fix miscounts on the fly — `$(count deaths -1)` in any moderator command takes one back.
Caution
Modifiers only work in the space-separated form: `$(count deaths +5)`. In the dot form, `$(count.deaths +5)` treats `+5` itself as the counter name — see the [`$(count)` reference](/chatbot/variables/count).
## Managing counters
[Section titled “Managing counters”](#managing-counters)
Counters are created automatically the first time they’re used and persist until you change them. You can view and edit every counter — including `deaths` — in the dashboard under **Chatbot → Counters**, and moderators can use the [`!editcounter`](/chatbot/commands/default/editcounter) default command from chat.
## Related
[Section titled “Related”](#related)
* [Counters](/chatbot/counters): How counters work, with the full syntax.
* [`$(count)`](/chatbot/variables/count) and [`$(getcount)`](/chatbot/variables/getcount): The two variables this guide is built on.
* [Custom Commands](/chatbot/commands/custom): Everything else you can do with custom commands.
# Set Up a Lurk Command
> Create a !lurk command with the StreamElements Chatbot, personalize its reply, add a cooldown, and test it in Twitch chat.
A lurk command gives viewers a quick way to say they are still watching even when they are stepping away from chat. It posts a friendly reply; it does not change the viewer’s Twitch status or how their view is counted.
## Create the command
[Section titled “Create the command”](#create-the-command)
1. Open the [bot command dashboard](https://streamelements.com/dashboard/bot/commands), select the **Custom commands** tab, and click **Add new command**.
2. Enter `lurk` in the **Command name** field and leave **User level** set to **Everyone**.
3. Enter this in the **Reply** field:
```streamelements
$(sender) is lurking. Thanks for keeping the stream company! $(random.emote)
```
[`$(sender)`](/chatbot/variables/sender) is always the viewer who used the command. [`$(random.emote)`](/chatbot/variables/random#randomemote) adds a random emote available in the channel and can be removed if you want a consistent reply.
4. Open **Advanced settings** and set a **User cooldown**. This limits how often the same viewer can trigger the reply without preventing other viewers from using it.
5. Optional: add `brb` or `afk` under **Command aliases** if you want those triggers to use the same response.
6. Click **Activate command**.
## Test it
[Section titled “Test it”](#test-it)
Use the command from a viewer account or ask someone in chat to try it:
Example chat
ViewerName:!lurk
StreamElements:ViewerName is lurking. Thanks for keeping the stream company! Kappa
If the bot does not reply, check that it has joined the channel, the command is enabled, and the command is not on cooldown. See [Chatbot troubleshooting](/chatbot/troubleshooting) for the full checklist.
## Customize the reply
[Section titled “Customize the reply”](#customize-the-reply)
You can change all of the text around the variables without changing how the command works. For example:
```streamelements
Thanks for lurking, $(sender)! Enjoy the stream and come back whenever you're ready. $(random.emote)
```
Keep `$(sender)` if you want the reply to name the person who used the command. The bot replaces it with their display name each time.
## Related
[Section titled “Related”](#related)
* [Custom Commands](/chatbot/commands/custom): Manage command replies, permissions, aliases, and cooldowns.
* [`$(sender)`](/chatbot/variables/sender): Information about the viewer who triggered a command.
* [`$(random)`](/chatbot/variables/random): Random emotes, numbers, chatters, and list choices.
# Create Commands That Use Viewer Input
> Use viewer input in StreamElements commands with argument tokens, fallbacks, validation, and URL encoding for dynamic replies.
Argument tokens let a custom command reuse what a viewer types after its trigger. You can capture one word, the rest of the message, or a range of words, then place that input in a reply or encode it for a URL.
## Create a command that captures a message
[Section titled “Create a command that captures a message”](#create-a-command-that-captures-a-message)
This command turns `!doing making pasta` into `ViewerName is currently making pasta`.
1. Open the [bot command dashboard](https://streamelements.com/dashboard/bot/commands), select **Custom commands**, and click **Add new command**.
2. Name the command `doing` and enter this reply:
```streamelements
$(sender) is currently $(1:)
```
3. Click **Activate command**.
4. Test it with several words after the trigger:
Example chat
ViewerName:!doing making pasta and dancing
StreamElements:ViewerName is currently making pasta and dancing
[`$(sender)`](/chatbot/variables/sender) identifies the viewer who used the command. `$(1:)` means every word from the first argument through the end of the message.
## Choose the input you need
[Section titled “Choose the input you need”](#choose-the-input-you-need)
In `!introduce Alice 25 from Copenhagen`, the trigger itself is word 0:
| Token | Output |
| -------- | ----------------- |
| `$(1)` | `Alice` |
| `$(2)` | `25` |
| `$(3:)` | `from Copenhagen` |
| `$(1:2)` | `Alice 25` |
If a requested word is missing, the token outputs nothing. Add a pipe fallback when a default makes sense:
```streamelements
$(sender) hugs $(1|everyone)!
```
That command targets the first word after `!hug`, or `everyone` when no name was provided.
## Validate a username
[Section titled “Validate a username”](#validate-a-username)
Use the `username` validator when an input must look like a Twitch-style username:
```streamelements
Check out $(1 username)'s channel at https://twitch.tv/$(1 username)
```
The validator accepts letters, digits, and underscores, optionally prefixed by `@`, up to 30 characters. It outputs nothing when the argument does not match that shape. See [Argument tokens](/chatbot/variables/args#validators) for the complete behavior.
## Put viewer input in a URL
[Section titled “Put viewer input in a URL”](#put-viewer-input-in-a-url)
Do not insert arbitrary multi-word input directly into a URL. Encode it for the part of the URL where it will be used.
### Query parameters
[Section titled “Query parameters”](#query-parameters)
Use [`$(queryescape)`](/chatbot/variables/queryescape) for values after `?`:
```streamelements
Search results: https://google.com/search?q=$(queryescape $(1:))
```
`!google StreamElements chatbot` produces a URL ending in `?q=StreamElements+chatbot`.
### URL paths
[Section titled “URL paths”](#url-paths)
Use [`$(pathescape)`](/chatbot/variables/pathescape) for a path segment:
```streamelements
Read more: https://en.wikipedia.org/wiki/$(pathescape $(1:))
```
`!wiki rocket league` produces a path ending in `/rocket%20league`.
Chat-command protection
Argument tokens remove a leading `/` or `.` from viewer input. This prevents a viewer from making the bot send a chat command such as `/timeout` through your custom command. URL encoding is still required when the input becomes part of a URL.
## Use input with a public API
[Section titled “Use input with a public API”](#use-input-with-a-public-api)
You can pass encoded input to [`$(customapi)`](/chatbot/variables/customapi), which makes a GET request and prints the response. The following is a pattern, not a working endpoint—replace `api.example.com` with a public endpoint you trust:
```streamelements
$(customapi https://api.example.com/define?word=$(queryescape $(1)))
```
Use an API designed to return short plain text. `$(customapi)` cannot set headers, truncates responses after 400 bytes, and does not parse JSON. Do not put private API credentials in the command URL.
## Related
[Section titled “Related”](#related)
* [Argument tokens](/chatbot/variables/args): Complete syntax for words, ranges, fallbacks, and validators.
* [`$(sender)`](/chatbot/variables/sender): Data about the viewer who triggered the command.
* [`$(queryescape)`](/chatbot/variables/queryescape) and [`$(pathescape)`](/chatbot/variables/pathescape): Encode dynamic URL values.
* [`$(customapi)`](/chatbot/variables/customapi): Request limits, errors, and examples.
# Modules
> StreamElements Chatbot modules: chat games like bingo, duel, raffle, and roulette, plus automatic tools for chat alerts and live announcements.
Chatbot modules are optional features you can switch on per channel — chat games like roulette and bingo, automated chat alerts, raffles, and moderation helpers like votekick.
## Usage
[Section titled “Usage”](#usage)
Enable and configure each module in your StreamElements dashboard. Once enabled, modules work in one of two ways:
* **Command-triggered** modules start when someone types a command in chat (for example, `!bingo`, `!duel`, or `!queue join`). Emote Combo and Emote Pyramid are the exception among the chat games: they react automatically to emotes posted in chat.
* **Dashboard-started** events — Giveaways and Contests — are created from the dashboard, and viewers take part from chat with `!ticket` or `!bet`.
* **Automatic** modules post messages on their own when something happens on your stream, such as a new follower (Chat Alerts) or the stream going live (Live Announcement). No commands are required.
## Available Modules
[Section titled “Available Modules”](#available-modules)
### Chat games
[Section titled “Chat games”](#chat-games)
[Emote Bingo](/chatbot/modules/bingo)An interactive chat game where players compete to identify the correct emote from a bingo card.
[Duel](/chatbot/modules/duel)Let viewers challenge each other to a duel, wagering points for a chance to win.
[8ball](/chatbot/modules/eightball)A Magic 8 Ball simulator that answers viewer questions with random responses.
[Emote Combo](/chatbot/modules/emotecombo)Encourage viewers to build chains of consecutive emotes in chat.
[Emote Pyramid](/chatbot/modules/emotepyramid)A collaborative chat game where viewers build pyramids of emotes.
[Raffle](/chatbot/modules/raffle)Run raffles that viewers can join for a chance to win points.
[Roulette](/chatbot/modules/roulette)A roulette-style gamble where viewers wager their points on a spin.
[Slotmachine](/chatbot/modules/slotmachine)A virtual slot machine game where viewers wager points on matching emotes.
[Viewer Queue](/chatbot/modules/viewerqueue)Create and manage a queue where viewers can join and be selected.
[Votekick](/chatbot/modules/votekick)Let viewers vote on temporarily removing a user from chat.
### Loyalty events
[Section titled “Loyalty events”](#loyalty-events)
[Giveaways](/chatbot/modules/giveaways)Viewers buy tickets with loyalty points for a chance to win a prize you define.
[Contests](/chatbot/modules/contests)Prediction-style betting where viewers back an outcome with points and winners split the pool.
### Media
[Section titled “Media”](#media)
[Song Request](/chatbot/modules/songrequest)Let viewers request YouTube songs and videos with !sr, with a moderated queue and playback controls.
### Automation
[Section titled “Automation”](#automation)
[Chat Alerts](/chatbot/modules/chatalerts)Automatically post messages in chat when stream events like follows, subscriptions, and raids occur.
[Live Announcement](/chatbot/modules/liveannouncement)Automatically post a message in chat when your stream goes live.
[Fourthwall Giveaways](/chatbot/modules/fourthwall)Turn gifted Fourthwall merch into instant chat giveaways with a join keyword.
# Bingo Module
> Run the Emote Bingo chat game with the StreamElements Chatbot using emotes from Twitch, BTTV, FFZ, and 7TV.
The Emote Bingo module is an interactive chat game that generates a bingo card with various emotes. Players compete to identify the correct emote.
## Usage
[Section titled “Usage”](#usage)
To start a Bingo game, a moderator must use the `!bingo` command with specific parameters. The winner is the first chatter to post the secret emote in chat, and they are awarded the prize points.
## Examples
[Section titled “Examples”](#examples)
1. Start a game using only Twitch emotes with a 100 point reward:
```streamelements
!bingo twitch 100
```
2. Start a game using all available emote providers with a 500 point reward:
```streamelements
!bingo all 500
```
## Parameters
[Section titled “Parameters”](#parameters)
* ``: Specifies the source of emotes for the game. Options include:
* `twitch`: Twitch emotes only
* `bttv`: BetterTTV emotes only
* `ffz`: FrankerFaceZ emotes only (alias: `frankerz`)
* `7tv`: 7TV emotes only (aliases: `seventv`, `thirdpartything`, `yeahbut7tv`)
* `all`: Includes emotes from all providers
* `[points]`: The number of points awarded to the winner. Optional — if omitted, the prize defaults to half of the configured maximum points. The prize is capped at the configured maximum, and can never exceed 1,000,000 points.
A running game can be cancelled with `!bingo cancel` (aliases: `end`, `stop`, `exit`).
## Configuration
[Section titled “Configuration”](#configuration)
The Emote Bingo module has the following settings in the StreamElements dashboard:
| Setting | Description |
| -------------- | -------------------------------------------------------- |
| Enabled | Whether the module is enabled |
| Maximum points | The maximum prize a bingo game can award (default: 4000) |
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!bingo`](/chatbot/commands/default/bingo): Starts an Emote Bingo game.
# Chat Alerts Module
> Configure the StreamElements Chat Alerts module to automatically post chat messages for follows, subscriptions, raids, and other stream events.
The Chat Alerts module automatically posts a chat message when something happens on your channel — a follow, a subscription, a raid, and so on — so events get acknowledged even when you’re mid-game.
## Usage
[Section titled “Usage”](#usage)
Chat Alerts are triggered automatically when configured events happen during your stream. No manual commands are required to activate them.
## Examples
[Section titled “Examples”](#examples)
1. Follower Alert:
```plaintext
New follower hype! Welcome to the stream, @NewFollower123! Thanks for joining our community!
```
2. Subscription Alert:
```plaintext
@Subscriber456 just subscribed for 3 months! Thank you for your continued support!
```
## Event Types
[Section titled “Event Types”](#event-types)
The available event types depend on the platform:
| Platform | Supported events |
| -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Twitch | Follows, tips, subscriptions, cheers (bits), raids, channel point redemptions, merch purchases, ad breaks, polls, predictions, hype trains, sponsorships |
| YouTube | Tips, sponsors, subscribers, redemptions, merch purchases |
| Kick | Follows, subscriptions, tips |
Each event type can have its own customized messages and trigger conditions.
### Tiered Messages
[Section titled “Tiered Messages”](#tiered-messages)
For events with an amount — tips, subscriptions, cheers, and raids, depending on the platform — you can configure multiple messages, each with its own minimum amount. When the event fires, the bot uses the message with the highest minimum amount that the event reaches:
* **Twitch**: tips, subscriptions, cheers, raids
* **YouTube**: tips, sponsors
* **Kick**: tips, subscriptions
For follow alerts, the bot picks a random message from your configured list.
## Configuration
[Section titled “Configuration”](#configuration)
To set up Chat Alerts:
1. Access your StreamElements dashboard
2. Navigate to the Chatbot section
3. Find the Chat Alerts module
4. Enable the alerts you want to use
5. Customize the message and parameters for each alert type
Each alert can be customized with the following settings:
| Setting | Description |
| -------------- | ------------------------------------------------------------------------------ |
| Event Type | The specific action that triggers the alert (e.g., follow, subscription, raid) |
| Message | The text that appears in chat when the event occurs |
| Minimum Amount | Optional minimum value for tiered events like tips or cheers |
The module also has a **Delay** setting, which postpones posting alerts by the configured number of seconds.
## Template Variables
[Section titled “Template Variables”](#template-variables)
Alert messages for activity events (follows, tips, subscriptions, cheers, raids, redemptions, merch, and sponsorships) support the following placeholders:
| Placeholder | Description |
| ------------ | ---------------------------------------------------------------------------- |
| `{user}` | The display name of the user who triggered the event |
| `{amount}` | The event’s amount (tip amount, months subscribed, bits, raid viewers, etc.) |
| `{currency}` | The currency symbol (tips) |
| `{item}` | The redeemed item or purchased merch item name(s) |
| `{msg}` | The message attached to the event, if any |
| `{tier}` | The subscription tier, e.g. “Tier 1” (subscriptions only) |
### Twitch Event Placeholders
[Section titled “Twitch Event Placeholders”](#twitch-event-placeholders)
The Twitch poll, prediction, ad break, and hype train alerts have their own placeholders:
| Event | Placeholders |
| ----------------------------------- | ------------------------------------------------------------------------------- |
| Poll started | `{title}`, `{choices}` |
| Poll ended | `{title}`, `{choice}`, `{votes}`, `{total_votes}` |
| Prediction started | `{title}`, `{outcomes}` |
| Prediction locked | `{title}`, `{highest_voted}`, `{highest_voted_count}`, `{total_votes}` |
| Prediction resolved | `{title}`, `{winner}`, `{winner_percentage}`, `{winner_votes}`, `{total_votes}` |
| Prediction canceled | `{title}` |
| Ad break | `{requester}`, `{automatic}`, `{duration}` |
| Hype train (started/progress/ended) | `{level}`, `{level_percent}`, `{next_level}` |
Note
Poll ended alerts only fire when the poll runs to completion, not when it is dismissed early. Ad break alerts are skipped when the ad break duration is zero.
# Contests Module
> Run StreamElements betting contests where viewers wager loyalty points on an outcome with !bet, and winners split the losing pool proportionally.
Contests are prediction-style bets: you define an outcome with two or more options, viewers back an option with loyalty points, and when you pick the winning option the losing bets are paid out to the winners.
## How It Works
[Section titled “How It Works”](#how-it-works)
1. Create the contest in the dashboard under **Loyalty → Contests**: a title, the options (each with a display title and the command viewers type), how many minutes betting stays open, and the minimum and maximum bet.
2. The bot announces the contest with its options. Viewers bet with [`!bet`](/chatbot/commands/default/bet) — points are deducted immediately, and each viewer can bet once per contest.
3. When the timer runs out (or you close it early), betting stops and the bot posts a per-option breakdown.
4. You pick the winning option in the dashboard. Winners get their stake back plus a share of the losing pool; everyone else loses their bet. You can also refund the contest instead, returning every stake.
Example chat
ViewerName:!bet win 100
StreamElements:@User, you have bet 100 points on Win.
Cautious:!contest
StreamElements:@Cautious, the current contest is "Do we win this game?". You can !bet for win, lose. Betting ends in 12 mins
## Payouts
[Section titled “Payouts”](#payouts)
Payouts are proportional to the bet: a winner receives
```plaintext
payout = (total pool ÷ winning option's pool) × their bet
```
That’s always at least their stake back, plus their share of what the losers put in. A 10-point bet pays exactly twice what a 5-point bet pays. Losing bets are gone — they fund the winners.
## Configuration
[Section titled “Configuration”](#configuration)
| Setting | Description |
| ---------------------------------------- | ------------------------------------------------------------------------------------ |
| Options | Each option has a display title and a chat command (what viewers type after `!bet`). |
| Duration | How many minutes viewers have to bet. |
| Minimum / Maximum bet | Bounds for a single bet, in points. |
| Send confirmation when entering via chat | When on (the default), the bot confirms each bet in chat. |
## Related
[Section titled “Related”](#related)
* [`!bet`](/chatbot/commands/default/bet): Place a bet on an option.
* [`!contest`](/chatbot/commands/default/contest): Show the running contest, its options, and the time left.
* [Contests websocket topic](/websockets/topics/channel-contests): Realtime contest events for developers.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can a viewer change or add to their bet?** A: No — one bet per viewer per contest. The first `!bet` locks in both the option and the amount.
**Q: What amounts does `!bet` accept?** A: Plain numbers, `k`/`m` suffixes (`5k` = 5000), percentages of the viewer’s balance (`25%`), and `all` — as long as the result stays within the contest’s minimum and maximum bet.
# Duel Module
> Set up the StreamElements Duel module so viewers can challenge each other to point-wagering duels in chat.
The Duel module is an interactive chat game that allows users to challenge each other to a duel, wagering points for a chance to win.
## How It Works
[Section titled “How It Works”](#how-it-works)
1. A user initiates a duel using the `!duel` command.
2. The challenged user has 2 minutes to accept or decline the duel.
3. If accepted, the game randomly determines a winner — each duelist has a 50/50 chance.
4. The winner gains the wagered points, and the loser loses them.
## Usage
[Section titled “Usage”](#usage)
To initiate a duel, use the following command:
```streamelements
!duel [points]
```
Replace `` with the name of the user you want to challenge, and `[points]` with the number of points you want to wager. The wager is optional — without one, the duel is played for 0 points.
## Examples
[Section titled “Examples”](#examples)
1. Challenging a user to a duel for 100 points:
```streamelements
!duel StreamNinja 100
```
2. Accepting a duel challenge:
```streamelements
!accept
```
## Parameters
[Section titled “Parameters”](#parameters)
* ``: The name of the user you want to challenge.
* `[points]`: The number of points you want to wager in the duel. Supports shorthand like `5k`, `1m`, percentages (`50%`), and `all`. The wager cannot exceed either duelist’s current balance, and wagers above the configured maximum amount are automatically capped to it.
## Configuration
[Section titled “Configuration”](#configuration)
You can configure the following settings for the Duel module:
| Setting | Description |
| -------------- | ----------------------------------------------------------- |
| Cooldown | The cooldown period between duel challenges. |
| Maximum amount | The maximum number of points that can be wagered in a duel. |
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!duel`](/chatbot/commands/default/duel): Challenges another user to a duel.
* [`!accept`](/chatbot/commands/default/accept): Accepts a duel challenge.
* [`!deny`](/chatbot/commands/default/deny): Declines a duel challenge.
* [`!cancelduel`](/chatbot/commands/default/cancelduel): Cancels an outgoing duel request before it is accepted or denied.
## FAQ
[Section titled “FAQ”](#faq)
**Q: How is the winner determined?** A: The winner is randomly selected when the duel is accepted — both duelists have an equal 50/50 chance of winning.
**Q: Can I challenge multiple users at once?** A: No, you can only challenge one user at a time.
**Q: What happens if the challenged user doesn’t respond?** A: If the challenged user doesn’t accept or deny within 2 minutes, the duel request expires, and no points are exchanged.
# 8ball Module
> The StreamElements 8ball module answers viewer questions with random, customizable Magic 8 Ball responses via the !8ball command.
The 8ball module is an interactive chat feature that simulates the classic Magic 8 Ball toy. It allows viewers to ask questions and receive random, customizable responses, enhancing engagement and entertainment in your chat. The module is available on all platforms.
## Usage
[Section titled “Usage”](#usage)
Viewers type `!8ball` followed by their question in the chat. The chatbot then responds with a random answer from the list configured in the dashboard. The question is optional and does not affect the randomized response.
```streamelements
!8ball [question]
```
The command can be used by everyone, with a 10-second per-user cooldown and a 3-second global cooldown.
### Aliases
[Section titled “Aliases”](#aliases)
* `!eightball`
* `!69ball`
* `!420ball`
## Examples
[Section titled “Examples”](#examples)
Example chat
ViewerName:!8ball Will I win my next game?
StreamElements:The 8ball says: It is certain.
Example chat
ViewerName:!8ball Should I order pizza tonight?
StreamElements:The 8ball says: Ask again later.
## Configuration
[Section titled “Configuration”](#configuration)
The 8ball responses come entirely from the module settings: you configure the list of possible answers, plus an optional list of emotes — when emotes are configured, a random one is appended to the response. To customize them in the StreamElements dashboard:
1. Navigate to the Chatbot section
2. Find the 8ball module in the list of available modules
3. Click on “Edit” to access the module settings
4. Modify the list of possible responses and emotes
5. Save your changes
If no responses are configured, the bot falls back to a default message saying the Magic 8-ball is out of order.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!8ball`](/chatbot/commands/default/8ball): Asks the Magic 8 Ball a question.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I add my own custom responses to the 8ball?** A: Yes, you can customize the list of possible responses in the module settings of your StreamElements dashboard.
# Emote Combo Module
> Use the StreamElements Emote Combo module to track chains of consecutive identical emotes in stream chat and announce the combo count.
The Emote Combo module tracks chains of consecutive messages containing the same emote, and announces the streak when someone finally breaks it.
## How It Works
[Section titled “How It Works”](#how-it-works)
The Emote Combo feature activates automatically when viewers start sending consecutive emote messages in chat:
1. A viewer initiates the combo by sending a message containing an emote.
2. Each following message that contains the active emote extends the combo. A message counts once, no matter how many times the emote appears in it.
3. The combo does not require different viewers — the same viewer can keep a combo going on their own.
4. The combo ends when a message is sent that does not contain the active emote. If the final count reached the minimum combo count, the bot announces the combo.
## Example
[Section titled “Example”](#example)
Example chat
Viewer1:Kappa
Viewer2:Kappa
Viewer3:Kappa
Viewer4:Kappa
Viewer5:Nice stream!
StreamElements:Viewer5 just disrupted the 4-line Kappa combo DansGame

## Configuration
[Section titled “Configuration”](#configuration)
Streamers can customize the following settings in the StreamElements dashboard:
* Whether the module is enabled
* Minimum combo count before the bot responds (default: 3)
* Cooldown between bot responses (default: 30 seconds)
* Tiered messages: a list of messages, each with a minimum count — the message with the highest minimum at or below the final combo count is used
The combo messages support the following placeholders:
| Placeholder | Description |
| ----------- | ---------------------------------------------- |
| `{user}` | The login name of the user who broke the combo |
| `{count}` | The final combo count |
| `{emote}` | The combo emote |
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I use custom emotes for the Emote Combo?** A: Yes, both Twitch global emotes and channel-specific emotes work with the Emote Combo feature.
**Q: Is there a limit to how long a combo can be?** A: No
# Emote Pyramid Module
> Rules and examples for the Emote Pyramid chat game, where viewers collaboratively build pyramids of emotes in StreamElements Chatbot.
The Emote Pyramid module is a chat game where viewers build a pyramid out of a single emote — one emote, then two, up to a peak and back down — and the bot announces whoever sends the message that completes it.
## How It Works
[Section titled “How It Works”](#how-it-works)
The Emote Pyramid game doesn’t require any specific commands to start. It begins organically when viewers participate by following these steps:
1. A viewer initiates the game by sending a single emote in the chat.
2. Subsequent messages should contain the same emote, with the number of repetitions increasing by one each time.
3. After reaching its peak, the pyramid shrinks by one repetition per message until it ends back at a single emote.
4. The viewer who sends the final single-emote message completes the pyramid and gets the credit in the bot’s announcement.
Note
The pyramid must use a single identical emote and grow or shrink by exactly one repetition per message — any message that breaks this pattern interrupts the pyramid. The bot only announces pyramids with a peak width of at least 3.
## Examples
[Section titled “Examples”](#examples)
### Successful Emote Pyramid
[Section titled “Successful Emote Pyramid”](#successful-emote-pyramid)
Example chat
Viewer1:PogChamp
Viewer2:PogChamp PogChamp
Viewer3:PogChamp PogChamp PogChamp
Viewer4:PogChamp PogChamp PogChamp PogChamp
Viewer5:PogChamp PogChamp PogChamp
Viewer6:PogChamp PogChamp
Viewer7:PogChamp
StreamElements:nice 4-width PogChamp pyramid Viewer7 LUL
### Interrupted Emote Pyramid
[Section titled “Interrupted Emote Pyramid”](#interrupted-emote-pyramid)
Example chat
Viewer1:Kappa
Viewer2:Kappa Kappa
Viewer3:Kappa Kappa Kappa
Viewer4:Nice try!
Viewer5:Kappa Kappa Kappa Kappa
In this example, the pyramid was interrupted by Viewer4’s message.
## Configuration
[Section titled “Configuration”](#configuration)
The Emote Pyramid module has two settings in the StreamElements dashboard:
* Whether the module is enabled
* Tiered messages: a list of messages, each with a minimum pyramid width — the message with the highest minimum at or below the pyramid’s peak width is used
The pyramid messages support the following placeholders:
| Placeholder | Description |
| ----------- | ------------------------------------------------------ |
| `{user}` | The display name of the user who completed the pyramid |
| `{width}` | The pyramid’s peak width |
| `{emote}` | The emote used to build the pyramid |
# Fourthwall Giveaways Module
> How StreamElements chat giveaways work when someone gifts Fourthwall merch to your chat: the join keyword, entry window, and winner announcement.
When a supporter gifts merch from your connected [Fourthwall](https://fourthwall.com) shop to the chat, the chatbot turns it into an instant giveaway: it announces the gift, viewers type a keyword to enter, and the bot announces the winners when time runs out.
## How It Works
[Section titled “How It Works”](#how-it-works)
1. A supporter gifts one or more merch items to the chat through your Fourthwall shop. This is what starts the giveaway — there is no chat command to start one.
2. The bot announces the giveaway with the join keyword and a countdown:
Example chat
StreamElements:NEW GIVEAWAY - MERCH TO WIN. GenerousViewer gifted 3 Classic Tee(s) to the chat. Type MERCH in the next 300 seconds for a chance to win.
3. Viewers enter by typing the keyword — anywhere in a message, in any casing. Each viewer is entered once, no matter how many times they type it.
4. When the entry window closes, winners are drawn and announced along with how to redeem the gift. If nobody entered, the bot says so instead.
## Requirements
[Section titled “Requirements”](#requirements)
* A [Fourthwall shop connected to StreamElements](https://streamelements.com/dashboard/merch) — without it, the module has nothing to react to.
* Twitch only.
Note
Fourthwall giveaways don’t appear under **Chatbot → Modules** — they’re controlled from within the Fourthwall merch integration. The giveaway itself — items, duration, and keyword — comes from the Fourthwall gift.
## Related
[Section titled “Related”](#related)
* [Giveaways module](/chatbot/modules/giveaways): StreamElements’ own giveaways, where viewers buy tickets with loyalty points.
* [Chat Alerts module](/chatbot/modules/chatalerts): Posts chat messages for regular (non-gifted) merch purchases.
# Giveaways Module
> Run StreamElements giveaways where viewers buy tickets with loyalty points via !ticket or the giveaway page, with subscriber luck and free-ticket options.
Giveaways let viewers spend loyalty points on tickets for a chance to win a prize you define. The chatbot announces the giveaway, sells tickets in chat, and celebrates the winner; the giveaway itself is created and drawn from the dashboard.
## How It Works
[Section titled “How It Works”](#how-it-works)
1. Create the giveaway in the dashboard under **Loyalty → Giveaways** — set the title, description, preview image, ticket cost, and limits — and start it.
2. The bot announces it in chat. Viewers buy tickets with [`!ticket`](/chatbot/commands/default/ticket) (or `!enter`) or on your public giveaway page. Every ticket has an equal chance of winning.
3. When you’re ready, close the giveaway to stop ticket sales and draw a winner from the dashboard. You can draw as many winners as you like, one at a time.
4. The bot announces each winner in chat, along with the chance they had of winning.
Example chat
ViewerName:!ticket 5
BigSpender:!ticket max
StreamElements:@BigSpender won the giveaway with a 32.50% chance to win PogChamp
`!ticket max` buys as many tickets as the viewer’s points allow, up to the per-user maximum.
## Configuration
[Section titled “Configuration”](#configuration)
Settings when creating a giveaway:
| Setting | Description |
| ---------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- |
| Ticket cost | Loyalty points per ticket. A cost of 0 makes entry free. |
| Give everyone their first ticket for free | Each viewer’s first ticket costs nothing, even when a ticket cost is set. |
| Max Tickets | Caps how many tickets a single viewer can hold. |
| Subscriber luck | Multiplies subscribers’ chances, from 1× (no special treatment) up to 10× — 2× is equivalent to holding twice the tickets. |
| Only allow subscribers to enter | Non-subscribers who try to enter from chat are turned away. |
| Send confirmation when buying tickets via chat | When on, the bot confirms each chat entry. Off by default, to keep chat quiet during busy giveaways. |
If something goes wrong, you can refund the giveaway — every entrant gets their points back. Individual entries can also be refunded.
## Related
[Section titled “Related”](#related)
* [`!ticket`](/chatbot/commands/default/ticket): Buy giveaway tickets from chat.
* [`!giveaway`](/chatbot/commands/default/giveaway): Check the currently running giveaway and get the entry link.
* [Giveaways websocket topic](/websockets/topics/channel-giveaway): Realtime giveaway events for developers.
* Not to be confused with the [Raffle module](/chatbot/modules/raffle), where entry is free via `!join` and the prize is the points themselves.
## FAQ
[Section titled “FAQ”](#faq)
**Q: What can viewers win?** A: Whatever you put up — the prize is the title and description you write. StreamElements picks the winner; delivering the prize is up to you.
**Q: Do viewers get their points back if they don’t win?** A: No — tickets are spent. Points only come back if you refund the giveaway (or a specific entry).
# Live Announcement Module
> Set up the StreamElements Live Announcement module to automatically post a chat message when your stream goes live, or when the title or game changes.
The Live Announcement module is a feature of the StreamElements Chatbot that automatically posts a message in the chat when a stream goes live, when the stream title changes, or when the game or category changes. This helps notify viewers that the stream has started and keeps them informed about what is being streamed. The module is available on all platforms.
## Usage
[Section titled “Usage”](#usage)
When enabled, the Live Announcement module works automatically without any manual input required. It provides three announcements, each of which can be toggled on or off separately and has its own customizable message:
* **Stream start**: Posted when the stream goes live.
* **Title change**: Posted when the stream title changes.
* **Game change**: Posted when the game or category changes.
## Examples
[Section titled “Examples”](#examples)
1. Default stream start announcement:
```plaintext
ExampleStreamer is now live! Streaming Fortnite: Late night squad games with friends!
```
2. Custom stream start announcement:
```plaintext
🎉 ExampleStreamer just went live! They're playing Minecraft and the stream title is "Building a mega castle - Day 3". Don't miss out!
```
## Parameters
[Section titled “Parameters”](#parameters)
Each announcement message supports its own set of placeholders:
| Announcement | Placeholders |
| ------------ | ---------------------------------- |
| Stream start | `{title}`, `{game}`, `{campaigns}` |
| Title change | `{title}` |
| Game change | `{game}` |
* `{title}`: The title of the live stream
* `{game}`: The game or category being streamed
* `{campaigns}`: The number of available sponsorships (stream start message only)
Placeholders are only substituted in the announcement they belong to — for example, `{game}` is not replaced in the title change message.
In addition to these placeholders, any standard [chat variable](/chatbot/variables) also works in the announcement messages, such as `${channel.display_name}` or `${uptime}`.
## Configuration
[Section titled “Configuration”](#configuration)
To configure the Live Announcement module:
1. Go to your StreamElements dashboard
2. Navigate to the Chatbot settings
3. Find the “Live Announcement” section
4. Enable the announcements you want to use
5. Customize each announcement message using the available parameters
Example configuration for the stream start message:
```plaintext
🔴 ${channel.display_name} is now live! 🎮 Playing {game} 📌 {title}
```
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I customize the announcement messages?** A: Yes, you can customize each of the three messages in the StreamElements dashboard using the available parameters.
**Q: How often does the Live Announcement trigger?** A: The stream start announcement triggers once per stream, when the stream initially goes live. The title and game change announcements trigger whenever the title or game changes.
**Q: Can I use custom variables in the announcement?** A: Yes. Besides the predefined placeholders, any standard chat variable (e.g., `${channel.display_name}`) can be used in the announcement messages.
# Raffle Module
> Commands, usage, and multi-winner scaling for the StreamElements Raffle module, used for giveaways and selecting participants.
The Raffle module is an interactive chat game that allows streamers to engage their audience. Moderators can initiate a raffle, and viewers can join for a chance to win. This feature is great for giveaways, selecting participants for games, or simply adding fun interaction to your stream.
## How It Works
[Section titled “How It Works”](#how-it-works)
1. A moderator starts the raffle using `!raffle` (multiple winners) or `!sraffle` (single winner).
2. Viewers join the raffle by typing `!join` in chat. Joining is free — the points are the prize, not an entry fee.
3. After a set time, the raffle ends, and winner(s) are randomly selected.
4. The winner(s) are announced in chat and awarded the prize points.
## Examples
[Section titled “Examples”](#examples)
Single-winner raffle:
Example chat
ModUser:!sraffle
StreamElements:A raffle has started! Type !join to enter.
Viewer1:!join
Viewer2:!join
StreamElements:The raffle has ended. The winner is Viewer2!
Multi-winner raffle:
Example chat
ModUser:!raffle
StreamElements:A multi-winner raffle has started! Type !join to enter.
Multiple viewers join the raffle.
StreamElements:The raffle has ended. The winners are Viewer3, Viewer7, and Viewer12!
## Parameters
[Section titled “Parameters”](#parameters)
* `!raffle [points] [duration]`: Start a multi-winner raffle. The points are the prize pot (default: 5000), which is split evenly among the winners.
* `!sraffle [points] [duration]`: Start a single-winner raffle. The winner receives the full prize (default: 1000 points).
For both commands, the optional duration is given in seconds. If omitted, the duration configured in the dashboard is used; the minimum duration is 5 seconds. The prize is capped at the maximum amount configured in the dashboard, and can never exceed 1,000,000 points.
## Configuration
[Section titled “Configuration”](#configuration)
The raffle messages can be customized in the StreamElements dashboard. The start and running messages support the `{points}` and `{time}` placeholders, and the end message supports `{winner}` (the winner names) and `{points}` (the amount awarded to each winner).
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!raffle`](/chatbot/commands/default/raffle): Starts a multi-winner raffle.
* [`!sraffle`](/chatbot/commands/default/sraffle): Starts a single-winner raffle.
* [`!join`](/chatbot/commands/default/join): Used by viewers to enter an ongoing raffle for free.
* [`!cancelraffle`](/chatbot/commands/default/cancelraffle): Cancels the current raffle (moderators only).
Note
[`!ticket`](/chatbot/commands/default/ticket) is not part of the Raffle module — it is the entry command for [StreamElements Giveaways](/chatbot/commands/default/giveaway), where tickets can cost loyalty points.
## FAQ
[Section titled “FAQ”](#faq)
**Q: How are winners determined in multi-winner raffles?** A: The number of winners scales based on the number of participants:
* Over 200 participants: 1 winner per 20 entrants
* 51-200 participants: 1 winner per 8 entrants
* 21-50 participants: 1 winner per 5 entrants
* 11-20 participants: 1 winner per 4 entrants
* 2-10 participants: Half the participants win (rounded down)
* 1 participant: That participant wins
**Q: Does it cost points to enter a raffle?** A: No. Entering with `!join` is completely free, and each viewer can enter once. The points are awarded to the winner(s) when the raffle ends.
**Q: Can I customize the raffle duration?** A: Yes, you can specify the duration in seconds when starting a raffle, e.g., `!raffle 5000 120` for a 5000 point raffle that runs for 2 minutes.
**Q: How do I prevent the same person from winning multiple times?** A: The Raffle module automatically ensures that each participant can only win once per raffle.
# Roulette Module
> Set up the StreamElements Roulette module, a chat game where viewers wager loyalty points on a roulette spin to win or lose.
The Roulette module is a chat game where viewers wager loyalty points on a spin: win and you gain your wager, lose and it’s gone.
## Usage
[Section titled “Usage”](#usage)
To start a game of roulette, users type the following command in chat:
```streamelements
!roulette
```
The module then randomly determines the outcome of the roulette spin. The payout is even money: a winner gains exactly the amount they wagered, and a loser forfeits it. The chance of winning is set by the streamer with the win-chance slider (see [Configuration](#configuration)).
## Examples
[Section titled “Examples”](#examples)
1. Wager 100 points:
```streamelements
!roulette 100
```
2. Wager 50% of total points:
```streamelements
!roulette 50%
```
3. Wager all points:
```streamelements
!roulette all
```
## Parameters
[Section titled “Parameters”](#parameters)
* ``: The number of points to wager. This can be expressed in several ways:
* As a whole number (e.g., `100`)
* As a percentage of the user’s total points (e.g., `50%`)
* Using `k` to represent thousands (e.g., `5k` for 5,000 points)
* Using `m` to represent millions (e.g., `1m` for 1,000,000 points)
* The keyword `all` to wager all points
## Configuration
[Section titled “Configuration”](#configuration)
Streamers can configure the Roulette module in the StreamElements dashboard with the following settings:
| Setting | Description |
| ------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| Win Chance | The “How rigged should the system be?” slider sets the percentage chance that a bet wins: 0% means viewers always lose, 100% means they always win. |
| Minimum Amount | The minimum number of points required to play (Default: 1). |
| User Cooldown | The minimum time (in seconds) a specific user must wait before playing again (Default: 60). |
| Global Cooldown | The minimum time (in seconds) everyone must wait after a roulette spin before anyone can play again (Default: 0). |
| Win Message | The message shown when a user wins. |
| Lose Message | The message shown when a user loses. |
| All-in Win Message | The message shown when a user bets `all` and wins. |
| All-in Lose Message | The message shown when a user bets `all` and loses. |
See the [`!roulette` command reference](/chatbot/commands/default/roulette) for the default message templates and available message variables.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!roulette`](/chatbot/commands/default/roulette): Initiates the roulette game.
* [`!points`](/chatbot/commands/default/points): Check your current point balance.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can users go into negative points?** A: No, users can only wager points they currently have.
**Q: Is there a limit to how often someone can use the Roulette command?** A: Yes — the User Cooldown setting (60 seconds by default) limits how often each viewer can play, and an optional Global Cooldown limits how often anyone can.
**Q: Can moderators disable the Roulette game?** A: Yes, moderators with appropriate permissions can enable or disable the Roulette module through the StreamElements dashboard.
# Slotmachine Module
> Set up and customize the StreamElements Slotmachine module, a virtual slot machine game where viewers wager points on matching emotes.
The Slotmachine module is a chat game where viewers wager loyalty points on a spin of a virtual slot machine.
## Usage
[Section titled “Usage”](#usage)
To start a game, viewers use the `!slots` command followed by the number of points they wish to wager. The slot machine then spins and displays a combination of three emotes.
Only three matching emotes win — two of a kind pays nothing. A winning spin credits the player with `wager × (number of emotes)² × (Return Amount ÷ 100)` points; a losing spin deducts the full wager. With the default five emotes and a 100% Return Amount, the odds of a win are 1 in 25 and a winning spin pays 25× the wager.
## Examples
[Section titled “Examples”](#examples)
1. Wager 100 points:
```streamelements
!slots 100
```
2. Wager 50% of total points:
```streamelements
!slots 50%
```
## Parameters
[Section titled “Parameters”](#parameters)
* ``: The number of points to wager. This can be expressed in several ways:
* As a whole number (e.g., `100`)
* As a percentage of the user’s total points (e.g., `50%`)
* Using `k` to represent thousands (e.g., `5k` for 5,000)
* Using `m` to represent millions (e.g., `1m` for 1,000,000)
## Configuration
[Section titled “Configuration”](#configuration)
Streamers can customize the following settings for the Slotmachine module:
| Setting | Description |
| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Emotes | The reel symbols. Defaults to `Kappa`, `PogChamp`, `BibleThump`, `OpieOP`, and `4Head`. Fewer emotes mean more frequent (but smaller) wins, since the payout scales with the square of the emote count. |
| Minimum amount | The minimum (and default) number of points that can be wagered. |
| Return amount | Payout percentage — the “How rigged should the system be?” slider. At 100% the game pays out fair odds; lower than 100% means players lose points over time. |
| User cooldown | The minimum time (in seconds) a specific viewer must wait between spins (default: 10). |
| Global cooldown | The minimum time (in seconds) everyone must wait after any spin. |
| Win / Lose message | The bot’s response messages. Available placeholders: `{emotes}`, `{points}`, `{user}`. |
The command also responds to the aliases `!slotmachine`, `!slot`, `!sm`, and `!smp`.
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!slots`](/chatbot/commands/default/slots): Initiates the slot machine game.
* [`!points`](/chatbot/commands/default/points): Check your current point balance.
# Song Request Module
> Let viewers request YouTube songs and videos with !sr, moderate the queue, and control playback — the StreamElements Song Request (Media Request) module.
The Song Request module lets viewers add YouTube songs and videos to a shared queue from chat, while you (and your mods) control playback. In the dashboard it’s called **Media Request**.
## How It Works
[Section titled “How It Works”](#how-it-works)
1. A viewer requests media with [`!songrequest`](/chatbot/commands/default/songrequest) (`!sr`), passing a YouTube URL, video ID, or search terms — searches resolve to the first YouTube result. Viewers can also request from your StreamElements profile page or the tipping page.
2. The request lands in the queue — or, with **Queue moderation** enabled, in a Pending Approval list until you or a mod with dashboard access approve it.
3. Songs play through the Media Request player: on your dashboard, on the stream via the overlay widget, and on your public request page at `streamelements.com//mediarequest`.
Example chat
ViewerName:!sr epic sax guy
StreamElements:@User, added Epic Sax Guy - "Epic Sax Guy 10 Hours" to the queue at #2 (playing \~in 3 mins 5 secs) https\://youtu.be/kxopViU98Xo
Note
YouTube is the only media source — there is no Spotify or SoundCloud integration. And although StreamElements supports several chat platforms, the song request chat commands are Twitch-only.
## Commands
[Section titled “Commands”](#commands)
Viewer commands (available to everyone):
| Command | What it does |
| --------------------------------------------------------------- | ---------------------------------------------------------------- |
| [`!songrequest` / `!sr`](/chatbot/commands/default/songrequest) | Request a song by URL, video ID, or search |
| [`!song`](/chatbot/commands/default/song) | Show the currently playing song |
| [`!next`](/chatbot/commands/default/next) | Show the next song in the queue |
| [`!when`](/chatbot/commands/default/when) | Show when your requested song will play |
| [`!wrongsong`](/chatbot/commands/default/wrongsong) | Remove your own most recent request |
| [`!voteskip`](/chatbot/commands/default/voteskip) | Vote to skip the current song (only when skip voting is enabled) |
| [`!volume`](/chatbot/commands/default/volume) | Show the player volume |
Moderator commands (permission level 500+):
| Command | What it does |
| --------------------------------------------------------------------------------------- | ------------------------------------------------ |
| [`!skip`](/chatbot/commands/default/skip) | Skip the current song |
| [`!pause`](/chatbot/commands/default/pause) / [`!play`](/chatbot/commands/default/play) | Pause or resume playback |
| [`!songqueue`](/chatbot/commands/default/songqueue) | Link the public request page with the full queue |
| [`!removesong`](/chatbot/commands/default/removesong) | Remove a song by requester name or YouTube URL |
| [`!srclear`](/chatbot/commands/default/srclear) | Clear the entire queue |
## Configuration
[Section titled “Configuration”](#configuration)
Song Request doesn’t appear under **Chatbot → Modules** — it’s controlled entirely from the dashboard’s **Media Request** section. The main setting groups:
| Setting | Description |
| ----------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Viewer requests | Master toggle for requests via `!sr`, your profile page, and the tipping page. |
| Queue moderation | Requires each request to be approved from the Pending Approval section before it enters the playlist. |
| Queue limit / per-user limits | Cap the total queue size and the number of free or paid requests per viewer (0 = unlimited). |
| Maximum request duration | Reject media longer than the configured length, with separate limits for free and paid requests. |
| Backup playlist | A YouTube playlist that plays whenever the request queue is empty. |
| YouTube filters | Limit requests to music, blacklist specific videos or tags, and set an automatic filter based on video rating and view count. |
| Loyalty cost | Charge loyalty points per request, with an optional subscriber discount. Users at or above the exempt user level (Moderator by default) bypass the cost and other limitations. |
| Minimum user level | Restrict who may request at all. |
| Tipped requests | Prioritize requests attached to tips, price them per second of media, and set a minimum tip amount. |
| Skip voting | Enable `!voteskip` and set how many votes a skip requires. |
## FAQ
[Section titled “FAQ”](#faq)
**Q: Does requesting a song cost points?** A: Only if you set a loyalty cost. If a viewer can’t afford it, the bot answers with the cost and their balance, and nothing is queued. Subscribers can get a percentage discount, and anyone at or above the exempt user level requests for free.
**Q: Where do approved requests actually play?** A: In the Media Request player — on your dashboard, in the on-stream overlay widget if you’ve added one, and on your public `mediarequest` page. The chatbot only manages the queue; it doesn’t play audio itself.
## Related
[Section titled “Related”](#related)
* [Loyalty System](https://support.streamelements.com/hc/en-us/articles/10474478470290-Loyalty-System-Overview) — required if you charge points for requests.
# Viewer Queue Module
> Create and manage a viewer queue with the StreamElements Viewer Queue module: viewers join with !queue join, and moderators open, close, and pick from the queue.
The Viewer Queue module allows streamers to create and manage a queue where viewers can join and be selected. This feature is particularly useful for organizing viewer interactions, such as game participation, Q\&A sessions, or giveaways during live streams.
## Usage
[Section titled “Usage”](#usage)
Streamers and moderators manage the queue with `!queue` subcommands, while viewers join and check their place with their own set of subcommands. See the [`!queue` command reference](/chatbot/commands/default/queue) for the full syntax of every subcommand.
## Examples
[Section titled “Examples”](#examples)
1. Opening a queue for viewers to join a game:
Example chat
ModUser:!queue open Viewer games
StreamElements:The Viewer games queue is now open! Viewers can type !queue join to enter.
Viewer1:!queue join
StreamElements:@Viewer1, you have been added to the queue in position #1.
Viewer2:!queue join
StreamElements:@Viewer2, you have been added to the queue in position #2.
2. Picking a viewer from the queue:
Example chat
ModUser:!queue pick random
StreamElements:@Viewer1 has been picked from the queue!
## Related Commands
[Section titled “Related Commands”](#related-commands)
Viewer subcommands:
* [`!queue join`](/chatbot/commands/default/queue): Enter the open queue.
* [`!queue position`](/chatbot/commands/default/queue): Check your current position in the queue.
* [`!queue list`](/chatbot/commands/default/queue): List the next viewers waiting in the queue.
Moderator subcommands:
* [`!queue open `](/chatbot/commands/default/queue): Open a queue with the given title for viewers to join.
* [`!queue close`](/chatbot/commands/default/queue): Close the queue, preventing new entries.
* [`!queue pause`](/chatbot/commands/default/queue): Temporarily stop viewers from joining.
* [`!queue unpause`](/chatbot/commands/default/queue): Resume allowing viewers to join.
* [`!queue pick `](/chatbot/commands/default/queue): Select a specific user, or a random one, from the queue.
* [`!queue remove `](/chatbot/commands/default/queue): Remove a specific user from the queue.
## Configuration
[Section titled “Configuration”](#configuration)
The Viewer Queue module has two settings in the StreamElements dashboard:
* Whether the module is enabled
* The start message posted in chat when a queue opens
Queue size and eligibility limits (such as who is allowed to join) are managed by the queue service through the dashboard, not by the chatbot module settings.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can viewers join the queue multiple times?** A: Viewers can only join the queue once.
**Q: How long does a queue last?** A: The queue remains active until it’s manually closed by a moderator, or until the stream ends.
# Votekick Module
> Configure the StreamElements Votekick module to let viewers vote on temporarily removing a user from chat.
The Votekick module lets viewers vote on whether to temporarily remove a user from the chat. If the vote passes, the user is timed out for the configured duration.
## Usage
[Section titled “Usage”](#usage)
Moderators and above can initiate a votekick with the following command:
```streamelements
!votekick [duration]
```
Replace `` with the name of the user you want to start a vote against. The optional duration (in seconds) overrides the configured voting duration for this vote; in both cases the voting duration is clamped between 10 seconds and 30 minutes.
A votekick passes when the total number of votes reaches the required votes setting **and** at least 51% of the votes are “yes”. In chat-voting mode, each user gets exactly one vote.
## Examples
[Section titled “Examples”](#examples)
1. Start a votekick for user “TrollUser123”:
```streamelements
!votekick TrollUser123
```
2. Vote in an active votekick (using the keywords configured in the dashboard, for example):
```plaintext
PogChamp
```
or
```plaintext
NotLikeThis
```
## Configuration
[Section titled “Configuration”](#configuration)
The module’s values come from the dashboard settings — customize the Votekick behavior with the following:
| Setting | Description |
| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Enabled | Whether the module is enabled |
| Native Twitch Poll | Run the vote as a native Twitch poll instead of counting chat keywords. Only available to Twitch affiliates and partners — otherwise the bot replies that polls are unavailable |
| Required Votes | The number of votes needed for the votekick to pass |
| Voting Duration | The length of the voting period, in seconds (clamped between 10 seconds and 30 minutes) |
| Kick Duration | How long the user is timed out in chat, in seconds |
| Yea Keyword | The chat keyword for a “yes” vote (chat-voting mode) |
| Nay Keyword | The chat keyword for a “no” vote (chat-voting mode) |
## Related Commands
[Section titled “Related Commands”](#related-commands)
* [`!votekick`](/chatbot/commands/default/votekick): Starts a vote to temporarily remove a user from chat.
# Quotes
> Save and recall memorable stream moments with the StreamElements Quotes system, using chat commands or the dashboard.
The Quotes system allows you and your moderators to save memorable moments, funny sayings, or notable events from your streams. Viewers can then recall these quotes using chat commands, creating a fun way to relive past highlights with your community.
You can manage your quotes in the [StreamElements Dashboard](https://streamelements.com/dashboard/bot/quotes).
## Dashboard Overview
[Section titled “Dashboard Overview”](#dashboard-overview)
The Bot Quotes page provides a centralized location to manage all your saved quotes:
* **Search**: Filter quotes by text content
* **Add Quote**: Manually add new quotes via the dashboard
* **Quote List**: View all quotes with their ID, text, creation date, associated game, and who added them
* **Actions**: Edit or delete individual quotes
## Adding Quotes
[Section titled “Adding Quotes”](#adding-quotes)
### Via Chat
[Section titled “Via Chat”](#via-chat)
Moderators and the broadcaster can add quotes directly from chat using the `!quote add` command:
```streamelements
!quote add Never gonna give you up!
```
The bot will confirm the quote was added and assign it a unique ID.
### Via Dashboard
[Section titled “Via Dashboard”](#via-dashboard)
1. Navigate to [Bot Quotes](https://streamelements.com/dashboard/bot/quotes) in your dashboard
2. Click the **+ ADD QUOTE** button
3. Enter the quote text
4. Click **Save**
The quote will be saved with the current timestamp.
## Displaying Quotes
[Section titled “Displaying Quotes”](#displaying-quotes)
### Random Quote
[Section titled “Random Quote”](#random-quote)
Viewers can display a random quote from your collection:
```streamelements
!quote
```
### Specific Quote
[Section titled “Specific Quote”](#specific-quote)
To display a specific quote by its ID:
```streamelements
!quote 42
```
## Managing Quotes
[Section titled “Managing Quotes”](#managing-quotes)
### Editing Quotes
[Section titled “Editing Quotes”](#editing-quotes)
Quotes can only be edited from the dashboard — there is no chat command for editing. To edit an existing quote:
1. Go to the [Bot Quotes](https://streamelements.com/dashboard/bot/quotes) page
2. Find the quote you want to edit
3. Click the pencil icon in the Actions column
4. Update the quote text
5. Save your changes
### Removing Quotes
[Section titled “Removing Quotes”](#removing-quotes)
**Via Chat (Moderator+):**
```streamelements
!quote remove 42
```
**Via Dashboard:**
1. Find the quote in the list
2. Click the trash icon in the Actions column
3. Confirm the deletion
## Chat Command Reference
[Section titled “Chat Command Reference”](#chat-command-reference)
For the full command documentation, see the [!quote command reference](/chatbot/commands/default/quote).
| Command | Description | Permission |
| -------------------- | ----------------------------------------------- | ---------- |
| `!quote` | Display a random quote | Everyone |
| `!quote ` | Display a specific quote (also accepts `#`) | Everyone |
| `!quote add ` | Add a new quote | Moderator+ |
| `!quote remove ` | Remove a quote (also accepts `#`) | Moderator+ |
Editing quotes is dashboard-only; there is no `!quote edit` chat command.
### Command Aliases
[Section titled “Command Aliases”](#command-aliases)
* `!quote add` can also be written as `!quote +`
* `!quote remove` can also be written as `!quote rem`, `!quote delete`, `!quote del`, or `!quote -`
## Quote Variables
[Section titled “Quote Variables”](#quote-variables)
You can use quote variables in custom commands and timers. For detailed documentation, see the [$(quote) variable reference](/chatbot/variables/quote).
* `$(quote)` - Returns a random quote
* `$(quote )` - Returns a specific quote by ID
### Example Custom Command
[Section titled “Example Custom Command”](#example-custom-command)
Create a command that displays a random quote with custom formatting:
```streamelements
!cmd add !randomquote Here's a memorable moment: $(quote)
```
## Configuration
[Section titled “Configuration”](#configuration)
The permission levels for adding and removing quotes can be adjusted under **Chatbot** -> **Chat Commands** -> **Default Commands** in your [StreamElements Dashboard](https://streamelements.com/dashboard/bot/commands/default).
# Timers
> Reference for StreamElements Chatbot timer settings: messages, online interval, chat lines, and conditions, plus how to manage timers from the dashboard.
Chatbot timers are automated messages or actions that occur at specified intervals during a live stream. They serve to remind viewers about certain aspects of the stream, such as rules or upcoming events, and can also be used to automatically execute commands at regular intervals.
You can manage your timers in the [StreamElements Dashboard](https://streamelements.com/dashboard/bot/timers). For a step-by-step walkthrough of creating your first timer, see [Getting Started](/chatbot/getting-started).
## Settings
[Section titled “Settings”](#settings)
| Setting | Description |
| --------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Name | Identifies the timer in the dashboard. |
| Messages | The message(s) the timer posts. A timer can be configured with multiple messages, which are cycled through each time the timer is activated. |
| Online interval | How often the timer is activated, in minutes, while the stream is live. |
| Chat lines | The minimum number of chat messages that must have been sent in the last 5 minutes for the timer to fire. This prevents timers from spamming the chat when there is less chatroom activity. |
| Conditions | Optional conditions that must be fulfilled for the timer to be activated. For instance, a timer can be set to run exclusively when the stream is categorized under “Just Chatting”, or if the stream title includes a specific keyword. |
## Managing timers
[Section titled “Managing timers”](#managing-timers)
From the [timers dashboard](https://streamelements.com/dashboard/bot/timers):
* To edit an existing timer, click the pencil icon next to the timer in the list.
* To delete a timer, click the trash can icon.
* To enable or disable a timer, use the toggle switch next to it.
* Use the search bar at the top to quickly find specific timers.
## Tips for effective timer use
[Section titled “Tips for effective timer use”](#tips-for-effective-timer-use)
* Keep messages concise and relevant to your audience.
* Use timers sparingly to avoid spamming your chat.
* Use the chat lines setting to ensure timers only post during active periods.
# Troubleshooting
> Checklists for common StreamElements Chatbot issues: bot not responding, commands not working, timers not triggering, and messages being deleted.
This section helps you quickly resolve common issues you might encounter with the StreamElements Chatbot and answers frequently asked questions.
## Bot not responding
[Section titled “Bot not responding”](#bot-not-responding)
* Check that the bot is currently active in your channel. Go to your StreamElements dashboard and ensure the bot is turned on.
* Ensure the bot is not banned or ignored in your channel. Sometimes the bot might have been accidentally banned, which prevents it from posting messages.
* Check that the bot has not been muted with [`!bot mute`](/chatbot/commands/default/bot). A muted bot sends no command responses or timer messages; use `!bot unmute` to restore it.
## Commands not working
[Section titled “Commands not working”](#commands-not-working)
* Verify the command syntax, including the prefix (usually `!`). See [Custom Commands](/chatbot/commands/custom) for the management syntax.
* Check the command’s permission level. Some commands are restricted to moderators or the streamer; adjust this in the dashboard or with [`!command options`](/chatbot/commands/default/command).
* Check for cooldowns. If a command was recently used, it might still be on cooldown; cooldowns are configured per command with [`!command options`](/chatbot/commands/default/command) or in the dashboard.
## Timers not triggering
[Section titled “Timers not triggering”](#timers-not-triggering)
* Ensure the timer is enabled and configured with the correct interval. See [Timers](/chatbot/timers) for all settings.
* Check the chat lines threshold. A timer only fires once the minimum number of chat messages has been sent within its interval, so it stays silent in an inactive chat. Lower the [chat lines setting](/chatbot/timers) or wait for more chat activity.
* Check any conditions on the timer. A timer with stream category or title keyword [conditions](/chatbot/timers) only fires while those conditions are met.
## Messages being deleted
[Section titled “Messages being deleted”](#messages-being-deleted)
* A spam filter is likely removing the messages. Review your settings for each filter in [Spam Filters](/chatbot/filters).
* If links are being deleted, the [Link filter](/chatbot/filters/links) acts on messages containing links that are not on your allowlist. Add the link to the allowlist or exclude the affected user groups from the filter.
## FAQ
[Section titled “FAQ”](#faq)
### How do I add the StreamElements Chatbot to my channel?
[Section titled “How do I add the StreamElements Chatbot to my channel?”](#how-do-i-add-the-streamelements-chatbot-to-my-channel)
Go to the Chatbot section of your StreamElements dashboard and click the button to make the bot join your channel.
### Can I create custom commands?
[Section titled “Can I create custom commands?”](#can-i-create-custom-commands)
Yes. You can define the command name, response, cooldowns, and user level restrictions. See [Custom Commands](/chatbot/commands/custom) for managing commands from the dashboard or directly in chat, and [Getting Started](/chatbot/getting-started) for a step-by-step walkthrough.
### How do I set up moderation filters?
[Section titled “How do I set up moderation filters?”](#how-do-i-set-up-moderation-filters)
Filters for links, caps, symbols, and more can be set up in the StreamElements dashboard under the “Spam Filters” section. See [Spam Filters](/chatbot/filters) for the available filters and their settings.
### Can the chatbot respond to commands with custom messages?
[Section titled “Can the chatbot respond to commands with custom messages?”](#can-the-chatbot-respond-to-commands-with-custom-messages)
Yes. Each custom command has a response you define, and responses can include [variables](/chatbot/variables) for dynamic content. See [Custom Commands](/chatbot/commands/custom).
### How do I remove the chatbot from my channel?
[Section titled “How do I remove the chatbot from my channel?”](#how-do-i-remove-the-chatbot-from-my-channel)
Use the [`!bot part`](/chatbot/commands/default/bot) command in chat, or go to the Chatbot section in your StreamElements dashboard and select the option to part the bot from your channel.
***
If your issue isn’t listed here or if you have more questions, please visit our [Discord](https://discord.gg/se) or contact support via [streamelements.com](https://streamelements.com).
# Variables
> Reference of all StreamElements Chatbot variables for chat commands, grouped by category, with syntax and usage links.
Chat commands support variables in a dynamic way. Variables are placeholders that can be used in chat commands to represent a specific value or piece of information. When a command is triggered, these variables are replaced with the actual values they represent.
For example, in the command `$(uptime shroud)`, `shroud` is a variable representing a username. When this command is executed, the `uptime` of the user `shroud` is returned.
Variables are placeholders you put in a command response; the bot replaces them with live values — the sender’s name, the current game, a random number — when the command runs.
In a hurry?
See the [Variables cheat sheet](/chatbot/variables/cheat-sheet) — every variable with its syntax and return value on a single page.
Note
In addition to the `$()` syntax, the `${}` syntax is also supported. Both forms are interchangeable in chat commands: `$(uptime shroud)` can also be written as `${uptime shroud}`.
Note
Variables work on all platforms unless a page notes otherwise — on YouTube, `$(user)` (and its sub-variables), `$(game)`, and `$(redeem)` are not available.
## Stream Info
[Section titled “Stream Info”](#stream-info)
| Variable | Description |
| -------------------------------------------- | --------------------------------------------------------------------------- |
| [`$(channel)`](/chatbot/variables/channel) | Channel information such as name, viewer count, followers, and subscribers. |
| [`$(game)`](/chatbot/variables/game) | Display the current game on a Twitch channel. |
| [`$(provider)`](/chatbot/variables/provider) | Display the platform the channel runs on: twitch, youtube, or kick. |
| [`$(title)`](/chatbot/variables/title) | Display a channel's title. Also available as $(status). |
| [`$(uptime)`](/chatbot/variables/uptime) | Display stream uptime for any channel. |
## Stream Management
[Section titled “Stream Management”](#stream-management)
| Variable | Description |
| -------------------------------------------- | ---------------------------------- |
| [`$(setgame)`](/chatbot/variables/setgame) | Change the stream's game category. |
| [`$(settitle)`](/chatbot/variables/settitle) | Change the stream title. |
## User & Chat
[Section titled “User & Chat”](#user--chat)
| Variable | Description |
| ------------------------------------------------ | ---------------------------------------------------------------------------------- |
| [`$(msgid)`](/chatbot/variables/msgid) | Retrieve the unique message ID. |
| [`$(pointsname)`](/chatbot/variables/pointsname) | Display the channel's custom loyalty points name. |
| [`$(redeem)`](/chatbot/variables/redeem) | Redeem a loyalty store item straight from a chat command. |
| [`$(sender)`](/chatbot/variables/sender) | Information about the user who triggered the command. Also available as $(source). |
| [`$(touser)`](/chatbot/variables/touser) | Display a user's name or a specified word. |
| [`$(user)`](/chatbot/variables/user) | User information such as name, points, and rank; accepts a username argument. |
| [`Command Arguments`](/chatbot/variables/args) | Access the words of the message that triggered the command. |
## Emotes
[Section titled “Emotes”](#emotes)
| Variable | Description |
| ---------------------------------------------------- | -------------------------------------------------- |
| [`$(7tvemotes)`](/chatbot/variables/7tvemotes) | List active 7TV emotes in the channel. |
| [`$(bttvemotes)`](/chatbot/variables/bttvemotes) | Display active BetterTTV emotes in the channel. |
| [`$(ffzemotes)`](/chatbot/variables/ffzemotes) | Display active FrankerFaceZ emotes in the channel. |
| [`$(twitchemotes)`](/chatbot/variables/twitchemotes) | Display available Twitch subscriber emotes. |
## Counters & Data
[Section titled “Counters & Data”](#counters--data)
| Variable | Description |
| -------------------------------------------- | ------------------------------------------------- |
| [`$(count)`](/chatbot/variables/count) | Create and manage custom counters. |
| [`$(getcount)`](/chatbot/variables/getcount) | Retrieve a counter value without incrementing it. |
| [`$(quote)`](/chatbot/variables/quote) | Display random or specific saved quotes. |
## Games
[Section titled “Games”](#games)
| Variable | Description |
| ------------------------------------------------------------ | ----------------------------------------------------------------------- |
| [`$(leagueoflegends)`](/chatbot/variables/leagueoflegends) | Get a League of Legends player's rank and LP. |
| [`$(pubg)`](/chatbot/variables/pubg) | Display PUBG player statistics like K/D, wins, and rating. |
| [`$(teamfighttactics)`](/chatbot/variables/teamfighttactics) | Get a Teamfight Tactics player's rank and LP. Also available as $(tft). |
## Utility & Web
[Section titled “Utility & Web”](#utility--web)
| Variable | Description |
| -------------------------------------------------- | ------------------------------------------------------------------------------------ |
| [`$(customapi)`](/chatbot/variables/customapi) | Make an API request and display the response in chat. Also available as $(urlfetch). |
| [`$(if)`](/chatbot/variables/if) | Show different responses depending on a true/false condition. |
| [`$(math)`](/chatbot/variables/math) | Perform mathematical calculations in chat messages. |
| [`$(pathescape)`](/chatbot/variables/pathescape) | Escape a string for use in a URL path. Also available as $(pathencode). |
| [`$(queryescape)`](/chatbot/variables/queryescape) | Encode a string for use in a URL query. Also available as $(queryencode). |
| [`$(repeat)`](/chatbot/variables/repeat) | Repeat a phrase a specified number of times. |
| [`$(stockprice)`](/chatbot/variables/stockprice) | Display real-time stock prices. |
| [`$(time)`](/chatbot/variables/time) | Display the current time in a timezone, or a countdown. |
| [`$(weather)`](/chatbot/variables/weather) | Display current weather conditions for a location. |
## Fun
[Section titled “Fun”](#fun)
| Variable | Description |
| ---------------------------------------- | ------------------------------------------------------------ |
| [`$(ai)`](/chatbot/variables/ai) | Generate AI responses in chat. Also available as $(chatgpt). |
| [`$(random)`](/chatbot/variables/random) | Generate random numbers, emotes, or chatters. |
# $(7tvemotes)
> Display the list of active 7TV emotes in a Twitch channel with the $(7tvemotes) variable in StreamElements Chatbot commands.
The `$(7tvemotes)` variable is used to retrieve and display a list of active 7TV emotes in the current Twitch channel. This can be useful for creating commands that inform viewers about available emotes or for integrating emote information into other chatbot functionalities.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !7tv The active 7TV emotes in this channel are: $(7tvemotes)
```
Example chat
ViewerName:!7tv
StreamElements:The active 7TV emotes in this channel are: LULW KEKW 5Head DinkDonk PogU
## Usage
[Section titled “Usage”](#usage)
When the command is triggered, the variable is replaced with a list of the channel’s active 7TV emote codes, separated by single spaces. The list is unordered — the same emotes may appear in a different order each time the command runs.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [$(bttvemotes)](/chatbot/variables/bttvemotes): Lists active BetterTTV emotes in the channel
* [$(ffzemotes)](/chatbot/variables/ffzemotes): Lists active FrankerFaceZ emotes in the channel
## FAQ
[Section titled “FAQ”](#faq)
**Q: How often is the 7TV emote list updated?**
A: The 7TV emote list is cached for 48 hours. To update the list immediately, you can use the command `!emotes reload`.
**Q: Can I filter or limit the number of emotes displayed?**
A: The `$(7tvemotes)` variable doesn’t have built-in filtering or limiting options. To manipulate the output, you’ll need to use additional StreamElements variables or custom code.
**Q: What if there are no 7TV emotes in the channel?**
A: If there are no active 7TV emotes, the variable will return an empty string.
# $(ai)
> Generate AI responses in chat with the $(ai) variable in StreamElements Chatbot commands, including rate limits and default context.
The `$(ai)` variable allows you to integrate AI into your StreamElements chat commands, generating dynamic responses based on user input.
Caution
The `$(ai)` variable is currently in beta and may be subject to changes.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !askai $(ai $(1:))
```
Example chat
ViewerName:!askai what snack should I grab for the next boss fight?
StreamElements:Something one-handed, ViewerName — grab some pretzels so you can snack and dodge at the same time. Good luck with the boss!
## Usage
[Section titled “Usage”](#usage)
To use the AI variable, include it in your commands with the following syntax:
```streamelements
$(ai )
```
Replace `` with the text you want the AI to respond to. Everything you pass to the variable is joined together with spaces and sent as a single prompt.
## Examples
[Section titled “Examples”](#examples)
1. Contextual response:
```streamelements
!command add !aifact ${ai You are a knowledgeable historian. Tell me an interesting fact about ${1:}}
```
2. Roleplaying:
```streamelements
!command add !aipirate ${ai You are a friendly pirate. Greet ${user} and tell them about your latest adventure.}
```
3. Combining with other variables:
```streamelements
!command add !aiwelcome ${ai Create a warm welcome message for ${1} who was last seen $(user.lastseen ${1}) ago. Their last message was $(user.lastmessage ${1}).}
```
In these examples, `${1}` inserts only the first word the viewer types after the command, while `${1:}` inserts everything from the first word onward — see [Argument tokens](/chatbot/variables/args) for details.
## Parameters
[Section titled “Parameters”](#parameters)
The `$(ai)` variable accepts a single parameter:
* `prompt`: The input text for the AI to generate a response. This parameter is required and must be less than 512 characters.
## Aliases
[Section titled “Aliases”](#aliases)
* `$(chatgpt)`: Identical to `$(ai)` in every way.
## Default Context
[Section titled “Default Context”](#default-context)
The AI variable comes with some default context that it’s always aware of:
1. **Channel Emotes**: The AI knows about the custom emotes available in your channel. It can reference and use these emotes in its responses when appropriate.
2. **Sender’s Name**: The AI is aware of the name of the user who triggered the command. This allows for personalized responses without explicitly including the user’s name in the query.
3. **Current Date**: The AI knows the current date, allowing it to provide timely responses or reference current events when relevant.
This default context enables the AI to generate more relevant and personalized responses without requiring you to explicitly include this information in every query.
## Configuration
[Section titled “Configuration”](#configuration)
### Rate limits
[Section titled “Rate limits”](#rate-limits)
To prevent abuse, the `$(ai)` variable is rate limited per channel:
| Channel | Requests per minute |
| --------- | ------------------- |
| Regular | 10 |
| Affiliate | 20 |
| Partner | 30 |
When the limit is exceeded, the bot replies `rate limit exceeded`.
## Errors
[Section titled “Errors”](#errors)
| Bot reply | Cause |
| ---------------------------------------------- | ---------------------------------------------- |
| `rate limit exceeded` | The channel’s per-minute request limit was hit |
| `input should be less than 512 characters` | The prompt is 512 characters or longer |
| `Something went wrong during prompt execution` | The AI service request failed |
| `Failed to execute prompt` | The AI response could not be read |
Note
AI replies are sanitized before being sent to chat: leading `/` and `.` characters are stripped, and replies starting with `!` are prefixed with an invisible character — so an AI response can never trigger chat commands or other bot commands.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I customize the AI’s personality?**
A: Yes, you can provide context or instructions in your query to shape the AI’s response. For example:
```streamelements
$(ai You are a friendly pirate. Greet ${user} and share a sea shanty.)
```
**Q: Can I use the AI variable in combination with other variables?**
A: Yes, you can combine the `$(ai)` variable with other StreamElements variables to create more dynamic and personalized responses. See example 3 in the Examples section.
**Q: Are there any content restrictions for AI-generated responses?**
A: Yes, the AI is programmed to avoid generating inappropriate, offensive, or harmful content. However, it’s always a good idea to monitor and moderate AI-generated responses during your stream.
**Q: How long can my prompt be?**
A: The prompt limit is 512 characters — anything longer makes the bot reply `input should be less than 512 characters`. For optimal performance, keep your prompts concise. If you need a more extensive response, consider breaking it down into multiple separate commands.
**Q: How can I report issues or unexpected behavior with the AI variable?**
A: If you encounter any problems or unexpected responses, you can report them to StreamElements support or post in the official StreamElements Discord for assistance.
# Command Arguments
> Access the words of a chat message in StreamElements Chatbot commands with the $(1), $(1:), and $(1:3) argument tokens.
Argument tokens let your custom commands use the words of the message that triggered them. This enables dynamic responses based on user input, enhancing the interactivity of your chatbot.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !greet Hello, $(1)!
```
Example chat
ViewerName:!greet World
StreamElements:Hello, World!
## Usage
[Section titled “Usage”](#usage)
Words are numbered from the start of the message, and **word 0 is the command trigger itself**, so `$(1)` is the first argument after the command.
| Token | Output |
| -------- | -------------------------------------- |
| `$(N)` | The Nth word of the message |
| `$(N:)` | Words N through the end of the message |
| `$(N:M)` | Words N through M, inclusive |
| `$(:M)` | Words 0 (the trigger) through M |
Both bracket styles work everywhere and are fully interchangeable: `$(1)` and `${1}` are identical, as are `$(1:)` and `${1:}`. Argument tokens can also be nested freely inside other variables, e.g. `$(weather ${1:})`.
If the requested word doesn’t exist in the message, the output is blank.
Note
Argument tokens strip a leading `/` or `.` from their output. This guards against chat-command injection — a viewer can’t make the bot send chat commands like `/timeout` through your custom commands.
## Examples
[Section titled “Examples”](#examples)
**Introducing a user**
```streamelements
!cmd add !introduce $(1) is $(2) years old
```
Example chat
ViewerName:!introduce Alice 25
StreamElements:Alice is 25 years old
**Using everything after the command**
```streamelements
!cmd add !announce Attention everyone: $(1:)
```
Example chat
ViewerName:!announce the stream starts in 10 minutes
StreamElements:Attention everyone: the stream starts in 10 minutes
## Fallbacks
[Section titled “Fallbacks”](#fallbacks)
Use a pipe to provide a default value when an argument is missing:
```streamelements
!cmd add !hug $(sender) hugs $(1|everyone)!
```
Example chat
ViewerName:!hug
StreamElements:StreamFan123 hugs everyone!
## Quoting
[Section titled “Quoting”](#quoting)
Wherever a variable takes space-separated inputs, quotes group several words into a single input. Single quotes `'...'`, double quotes `"..."`, and backticks `` `...` `` all behave identically.
## Validators
[Section titled “Validators”](#validators)
A token can take an optional validator, which makes it output the word only if it passes a check:
`$(1 username)` (alias: `$(1 word)`) outputs the argument only if it looks like a username — letters, digits, and underscores, optionally prefixed with `@`, up to 30 characters.
```streamelements
!cmd add !so Check out $(1 username)'s channel!
```
Example chat
ViewerName:!so CoolStreamer
StreamElements:Check out CoolStreamer's channel!
`$(1 emote)` outputs the argument only if it is an emote in the message.
```streamelements
!cmd add !emote $(1 emote)
```
Example chat
ViewerName:!emote Kappa
StreamElements:Kappa
The dot form also works for validators, e.g. `$(1.word)` or `$(1.emote)`.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(touser)`](/chatbot/variables/touser): The first word after the command, falling back to the sender’s name
* [`$(sender)`](/chatbot/variables/sender): The name of the user who triggered the command
* [`$(user)`](/chatbot/variables/user): Information about a user, such as points and rank
## FAQ
[Section titled “FAQ”](#faq)
**Q: What happens if I try to access an argument that wasn’t provided?**
A: If you try to access an argument that wasn’t provided (e.g., `$(2)` when only one argument was given), the output will be blank. Use a pipe fallback like `$(2|default)` to output something else instead.
**Q: Can I write a range backwards, like $(3:1)?**
A: No. Reversed or negative ranges are not valid and will render as literal text.
# $(bttvemotes)
> Display the list of active BetterTTV emotes in a Twitch channel with the $(bttvemotes) variable in StreamElements Chatbot commands.
The `$(bttvemotes)` variable lists all active BetterTTV (BTTV) emotes in your Twitch channel. This feature allows streamers and viewers to easily see which custom BTTV emotes are available for use in the chat.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !bttv Our channel's BTTV emotes: $(bttvemotes)
```
Example chat
ViewerName:!bttv
StreamElements:Our channel's BTTV emotes: LULW KEKW 5Head PogU
## Usage
[Section titled “Usage”](#usage)
When the command is triggered, the variable is replaced with a list of the channel’s active BTTV emote codes, separated by single spaces. It doesn’t require any parameters. The list is unordered — the same emotes may appear in a different order each time the command runs.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [$(ffzemotes)](/chatbot/variables/ffzemotes): Lists active FrankerFaceZ (FFZ) emotes in the channel
* [$(7tvemotes)](/chatbot/variables/7tvemotes): Lists active 7TV emotes in the channel
## FAQ
[Section titled “FAQ”](#faq)
**Q: How often is the list of BTTV emotes updated?**
A: The BTTV emote list is cached for 48 hours. To update the list immediately, you can use the command `!emotes reload`.
**Q: Can I use this variable to check BTTV emotes in other channels?**
A: No, the `$(bttvemotes)` variable only shows BTTV emotes for the channel where the chatbot is active.
**Q: What if there are no BTTV emotes enabled in my channel?**
A: If no BTTV emotes are enabled, the variable will return an empty string.
# $(channel)
> Reference for the StreamElements Chatbot $(channel) variables: channel name, viewers, followers, subscribers, game, title, and uptime.
The `$(channel)` variables in StreamElements Chatbot allow you to access and display various channel-related information in your chat messages and commands. These variables provide real-time data such as channel name, viewer count, follower count, and subscriber information.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !stats $(channel.display_name) has $(channel.followers) followers and $(channel.subs) subscribers!
```
Example chat
ViewerName:!stats
StreamElements:CoolStreamer123 has 50000 followers and 500 subscribers!
## Usage
[Section titled “Usage”](#usage)
To use a channel variable, include it in your chatbot command using the `$()` syntax. The variable will be automatically replaced with the corresponding value when the message is sent.
## Available variables
[Section titled “Available variables”](#available-variables)
| Variable | Description | Notes |
| ------------------------- | -------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- |
| `$(channel)` | Name of the channel (login name) | Any unrecognized field, e.g. `$(channel.name)`, also returns the channel name |
| `$(channel.display_name)` | Channel’s display name | May differ in capitalization from `$(channel)` |
| `$(channel.alias)` | Channel’s alias | |
| `$(channel.provider)` | Channel’s streaming platform as a lowercase slug: `twitch`, `youtube`, or `kick` | |
| `$(channel.provider_id)` | Channel’s platform ID (e.g. Twitch or YouTube channel ID) | Aliases: `$(channel.twitchid)`, `$(channel.youtubeid)` |
| `$(channel.id)` | Channel’s internal StreamElements ID | |
| `$(channel.title)` | Current stream title | Alias: `$(channel.status)`. Returns `` if the lookup fails |
| `$(channel.game)` | Current game/category | Returns `` if not set, `` if the lookup fails |
| `$(channel.viewers)` | Current viewer count, as a plain number | Returns `` if offline |
| `$(channel.followers)` | Total follower count, as a plain number | Returns `0` on error |
| `$(channel.chatters)` | Current number of chatters, as a plain number | Returns `0` on error |
| `$(channel.subs)` | Total subscriber count, as a plain number | Aliases: `$(channel.subcount)`, `$(channel.subscribers)`. Own channel only — returns `0` on error or for other channels |
| `$(channel.subpoints)` | Total subscriber points, as a plain number | Own channel only — returns `0` on error or for other channels |
| `$(channel.uptime)` | Current stream uptime, e.g. `3 hours 27 mins` | Returns `` if offline |
## Checking another channel
[Section titled “Checking another channel”](#checking-another-channel)
Add a username after the field to look up a different channel:
```streamelements
$(channel.game somestreamer)
$(channel.title somestreamer)
$(channel somestreamer)
```
* This cross-channel form works on Twitch. It is not implemented on YouTube, where it falls back to your own channel’s data.
* `$(channel.subs)` and `$(channel.subpoints)` always return `0` for other channels.
* If the channel doesn’t exist, `title` and `game` return ``; other lookup failures return an `` code.
The standalone [`$(game)`](/chatbot/variables/game), [`$(title)`](/chatbot/variables/title), and [`$(uptime)`](/chatbot/variables/uptime) variables are shortcuts for the matching channel fields and accept a username the same way.
## Examples
[Section titled “Examples”](#examples)
**A stream status command combining provider, game, and title**
```streamelements
!cmd add !status We're live on $(channel.provider) playing $(channel.game) — $(channel.title)
```
Example chat
ViewerName:!status
StreamElements:We're live on twitch playing Super Mario 64 — Speedrunning Mario 64 - Day 3!
**A live stats command combining uptime, viewers, and chatters**
```streamelements
!cmd add !live We've been live for $(channel.uptime) with $(channel.viewers) viewers and $(channel.chatters) active chatters!
```
Example chat
ViewerName:!live
StreamElements:We've been live for 3 hours 27 mins with 1337 viewers and 850 active chatters!
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [$(user)](/chatbot/variables/user): Displays information about the user who triggered the command
* [$(touser)](/chatbot/variables/touser): Refers to the target user in commands that mention other users
* [$(game)](/chatbot/variables/game), [$(title)](/chatbot/variables/title), [$(uptime)](/chatbot/variables/uptime): Standalone shortcuts for the matching channel fields
## FAQ
[Section titled “FAQ”](#faq)
**Q: How often are these variables updated?**
A: Channel variables are updated in real-time, reflecting the most current information available from the platform.
**Q: What happens if a variable can’t retrieve the information?**
A: It depends on the variable:
* `$(channel.followers)`, `$(channel.chatters)`, `$(channel.subs)`, and `$(channel.subpoints)` return `0` on error
* `$(channel.title)` and `$(channel.game)` return `` on error
* `$(channel.viewers)` and `$(channel.uptime)` return `` if the channel is offline
* `$(channel.game)` returns `` if no game is set
# Variables cheat sheet
> One-page reference of every StreamElements Chatbot variable: syntax, return values, sub-variables, argument tokens, and aliases.
Every chatbot variable on one page — syntax and what it returns, at a glance. Click a variable for its full page with examples, parameters, and error cases.
## Stream info
[Section titled “Stream info”](#stream-info)
| Variable | Syntax | Returns |
| -------------------------------------------- | ------------------------------ | ---------------------------------------------------------------------------------------------------------- |
| [`$(channel)`](/chatbot/variables/channel) | `$(channel. [channel])` | A channel field (see [sub-variables](#channel-sub-variables)); bare `$(channel)` returns the channel name. |
| [`$(game)`](/chatbot/variables/game) | `$(game [channel])` | The current category, e.g. `Just Chatting`; `` when unset. |
| [`$(title)`](/chatbot/variables/title) | `$(title [channel])` | The current stream title. Alias: `$(status)`. |
| [`$(uptime)`](/chatbot/variables/uptime) | `$(uptime [channel])` | Time live, e.g. `2 hours 30 mins`; `` when offline. |
| [`$(provider)`](/chatbot/variables/provider) | `$(provider)` | The platform slug: `twitch`, `youtube`, or `kick`. |
## Stream management
[Section titled “Stream management”](#stream-management)
| Variable | Syntax | Returns |
| -------------------------------------------- | ----------------------- | ------------------------- |
| [`$(setgame)`](/chatbot/variables/setgame) | `$(setgame "")` | Sets the stream category. |
| [`$(settitle)`](/chatbot/variables/settitle) | `$(settitle "")` | Sets the stream title. |
## User & chat
[Section titled “User & chat”](#user--chat)
| Variable | Syntax | Returns |
| ------------------------------------------------ | ---------------------------- | ------------------------------------------------------------------------------------------------------------ |
| [`$(user)`](/chatbot/variables/user) | `$(user. [username])` | A user field (see [sub-variables](#user-and-sender-sub-variables)); bare `$(user)` returns the display name. |
| [`$(sender)`](/chatbot/variables/sender) | `$(sender.)` | Same fields as `$(user)`, always for the message author. Alias: `$(source)`. |
| [`$(touser)`](/chatbot/variables/touser) | `$(touser)` | The first word after the command, or the sender’s display name. |
| [`$(1)`, `$(1:)`](/chatbot/variables/args) | `$(N)` `$(N:)` `$(N:M)` | Words of the triggering message (see [argument tokens](#argument-tokens)). |
| [`$(msgid)`](/chatbot/variables/msgid) | `$(msgid)` | The platform message ID of the triggering message. |
| [`$(pointsname)`](/chatbot/variables/pointsname) | `$(pointsname)` | The channel’s loyalty points name; `points` when unset. |
| [`$(redeem)`](/chatbot/variables/redeem) | `$(redeem [item] [input])` | Redeems a loyalty store item; the bot replies with the store message. |
## Emotes
[Section titled “Emotes”](#emotes)
| Variable | Syntax | Returns |
| ---------------------------------------------------- | ----------------- | ------------------------------------------------------------- |
| [`$(twitchemotes)`](/chatbot/variables/twitchemotes) | `$(twitchemotes)` | The channel’s Twitch subscriber emote codes, space-separated. |
| [`$(bttvemotes)`](/chatbot/variables/bttvemotes) | `$(bttvemotes)` | The channel’s active BetterTTV emote codes. |
| [`$(ffzemotes)`](/chatbot/variables/ffzemotes) | `$(ffzemotes)` | The channel’s active FrankerFaceZ emote codes. |
| [`$(7tvemotes)`](/chatbot/variables/7tvemotes) | `$(7tvemotes)` | The channel’s active 7TV emote codes. |
## Counters & data
[Section titled “Counters & data”](#counters--data)
| Variable | Syntax | Returns |
| -------------------------------------------- | ---------------------------- | ----------------------------------------------------------------------------------- |
| [`$(count)`](/chatbot/variables/count) | `$(count [name] [modifier])` | Changes a counter and returns the new value; `+N`/`-N` adjusts, a bare number sets. |
| [`$(getcount)`](/chatbot/variables/getcount) | `$(getcount )` | The counter’s value without changing it. |
| [`$(quote)`](/chatbot/variables/quote) | `$(quote [id])` | A saved quote as `#12 `; random when no id; `quote not found` on a bad id. |
## Games
[Section titled “Games”](#games)
| Variable | Syntax | Returns |
| ------------------------------------------------------------ | -------------------------------------------- | ------------------------------------------------------------------------------------- |
| [`$(leagueoflegends)`](/chatbot/variables/leagueoflegends) | `$(leagueoflegends )` | The player’s LoL rank, e.g. `Gold IV (81 LP)`. |
| [`$(teamfighttactics)`](/chatbot/variables/teamfighttactics) | `$(teamfighttactics )` | The player’s TFT rank, e.g. `Gold IV (81 LP)`; `Unranked` on errors. Alias: `$(tft)`. |
| [`$(pubg)`](/chatbot/variables/pubg) | `$(pubg )` | A PUBG stat from pubgtracker.com, e.g. `248`. |
## Logic, utility & web
[Section titled “Logic, utility & web”](#logic-utility--web)
| Variable | Syntax | Returns |
| -------------------------------------------------- | --------------------------------- | ------------------------------------------------------------------------------------------------------- |
| [`$(if)`](/chatbot/variables/if) | `$(if [else])` | `` when the condition is true, otherwise `[else]`; false with no else suppresses the whole reply. |
| [`$(math)`](/chatbot/variables/math) | `$(math )` | The result of the calculation, e.g. `7.8`. |
| [`$(time)`](/chatbot/variables/time) | `$(time [timezone])` | The current time as 24-hour `HH:MM`; UTC when no IANA zone is given. |
| [`$(time.until)`](/chatbot/variables/time) | `$(time.until )` | Time until (or since) the given time, e.g. `2 hours 30 mins` (with `ago` if past). |
| [`$(repeat)`](/chatbot/variables/repeat) | `$(repeat )` | The phrase repeated, space-separated (capped at 100 repeats / \~1000 characters). |
| [`$(random)`](/chatbot/variables/random) | `$(random)` / `$(random.X-Y)` | A random integer, 1–100 by default (see [random forms](#random-forms)). |
| [`$(customapi)`](/chatbot/variables/customapi) | `$(customapi )` | The first 400 bytes of the URL’s response. Alias: `$(urlfetch)`. |
| [`$(queryescape)`](/chatbot/variables/queryescape) | `$(queryescape )` | The text URL-query-encoded (spaces become `+`). Alias: `$(queryencode)`. |
| [`$(pathescape)`](/chatbot/variables/pathescape) | `$(pathescape )` | The text URL-path-encoded (spaces become `%20`). Alias: `$(pathencode)`. |
| [`$(weather)`](/chatbot/variables/weather) | `$(weather "")` | Current conditions: temperature, wind, humidity, visibility, pressure. |
| [`$(stockprice)`](/chatbot/variables/stockprice) | `$(stockprice )` | A real-time stock price line for the symbol. |
| [`$(ai)`](/chatbot/variables/ai) | `$(ai )` | An AI-generated reply (prompt up to 512 characters). Alias: `$(chatgpt)`. |
## Argument tokens
[Section titled “Argument tokens”](#argument-tokens)
Words are numbered from the start of the triggering message; **word 0 is the command trigger itself**. See the [argument tokens page](/chatbot/variables/args) for details.
| Token | Returns |
| --------------- | -------------------------------------------------------- |
| `$(N)` | The Nth word of the message. |
| `$(N:)` | Words N through the end. |
| `$(N:M)` | Words N through M, inclusive. |
| `$(:M)` | Words 0 (the trigger) through M. |
| `$(N username)` | Word N only if it is a valid username (alias: `word`). |
| `$(N emote)` | Word N only if it is an emote in the triggering message. |
## User and sender sub-variables
[Section titled “User and sender sub-variables”](#user-and-sender-sub-variables)
Use as `$(user. [username])` or `$(sender.)` — the fields are identical; `$(user)` accepts an optional username (defaulting to the first word after the command if it looks like a name), while `$(sender)` is always the message author.
| Field | Returns |
| --------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| `name` | The login name, in lowercase. |
| `twitchid` | The platform user ID. |
| `points` | The loyalty points balance, e.g. `100`. |
| `level` | The access level: `100` everyone, `250` subscriber, `300` regular, `400` VIP, `500` moderator, `1000` super moderator, `1500` broadcaster. |
| `lastmessage` | The user’s last chat message. |
| `lastseen` | Time since last seen, e.g. `2 hours 30 mins`; `` if never recorded. |
| `lastactive` | Time since the user last typed; `` if never recorded. |
| `time_online` | Watchtime while the stream is live, e.g. `2 hours 30 mins`. |
| `time_offline` | Time accrued while the stream is offline. |
| `points_rank` | Points rank as `rank/total`, e.g. `5/283`. |
| `points_alltime_rank` | All-time points rank as `rank/total`. |
| `time_online_rank` | Watchtime rank as `rank/total`. |
| `time_offline_rank` | Offline-time rank as `rank/total`. |
## Channel sub-variables
[Section titled “Channel sub-variables”](#channel-sub-variables)
Use as `$(channel.)`. On Twitch you can also target another channel: `$(channel. )`.
| Field | Returns |
| -------------- | ----------------------------------------------------------------------------- |
| `display_name` | The channel’s display name. |
| `alias` | The channel’s alias. |
| `provider` | The platform slug, e.g. `twitch`. |
| `provider_id` | The platform channel ID (aliases: `twitchid`, `youtubeid`). |
| `id` | The StreamElements channel ID. |
| `title` | The current stream title (alias: `status`). |
| `game` | The current category; `` when unset. |
| `viewers` | The current viewer count; `` when offline. |
| `followers` | The follower count. |
| `chatters` | The current chatter count. |
| `subs` | The subscriber count — own channel only (aliases: `subcount`, `subscribers`). |
| `subpoints` | The subscriber points — own channel only. |
| `uptime` | Time live, e.g. `2 hours 30 mins`; `` when offline. |
## Random forms
[Section titled “Random forms”](#random-forms)
| Form | Returns |
| ----------------------------------------- | ----------------------------------------------------------------------------------- |
| `$(random)` | A random integer from 1 to 100. |
| `$(random.X-Y)` or `$(random.number X-Y)` | A random integer from X to Y, inclusive. |
| `$(random.pick a b c)` | One of the listed items (quote multi-word items, or pass one comma-separated list). |
| `$(random.chatter)` | A random active chatter; `` on failure. |
| `$(random.emote)` | A random emote from the channel’s BTTV/FFZ/7TV and global emotes. |
## Syntax rules
[Section titled “Syntax rules”](#syntax-rules)
* `$()` and `${}` are interchangeable: `$(uptime)` is the same as `${uptime}`.
* Variables nest freely: `$(weather ${1:})`, `$(if $(random.pick 1,0) Heads Tails)`.
* Quote multi-word values with single quotes, double quotes, or backticks: `$(random.pick 'option one' 'option two')`.
* A pipe sets a default for empty values: `$(1|everyone)` outputs `everyone` when no argument was given.
* Argument tokens `$(N)`, `$(N:)`, `$(N:M)` read words from the triggering message; word 0 is the trigger itself.
# $(count)
> Create, display, and modify custom counters in StreamElements Chatbot with the $(count) variable.
The `$(count)` variable creates, displays, and changes named counters. It’s commonly used for tracking deaths in games, counting command usage, or keeping score of any recurring event.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !deaths $(channel.display_name) has died $(count) times this stream!
```
Example chat
ViewerName:!deaths
StreamElements:CoolStreamer123 has died 13 times this stream!
## Usage
[Section titled “Usage”](#usage)
The basic syntax for using the `$(count)` variable is:
```streamelements
$(count [counter_name] [modifier])
```
Where:
* `[counter_name]` is an optional name for your counter (by default, the invoking command’s own counter is used)
* `[modifier]` can be used to set or modify the counter value
Each use changes the counter and outputs the **new** value as a plain number. Without a modifier, the counter is incremented by 1.
## Examples
[Section titled “Examples”](#examples)
**Basic usage** — increments the command’s own counter by 1 each time:
```streamelements
!cmd add !deaths $(count)
```
Example chat
ViewerName:!deaths
StreamElements:13
**Named counter with a custom modifier:**
```streamelements
!cmd add !bossfails $(count bossfails +5)
```
Example chat
ViewerName:!bossfails
StreamElements:25
## Parameters
[Section titled “Parameters”](#parameters)
* `[counter_name]`: (Optional) A unique identifier for your counter. If not specified, the invoking command’s own counter is used.
* `[modifier]`: (Optional) The second space-separated token; sets or modifies the counter value:
* `+n`: Increment the counter by n (e.g., `+1`, `+5`)
* `-n`: Decrement the counter by n (e.g., `-1`, `-3`)
* `n`: Set the counter to a specific value n (e.g., `0`, `100`) — `$(count deaths 0)` resets the counter
Note
Modifiers only work in the space-separated form. The dot form `$(count.deaths)` works for naming a counter, but in `$(count.deaths +5)` the parser treats `+5` itself as the counter name — so it increments a counter literally named “+5” by 1 and ignores `deaths` entirely. Use `$(count deaths +5)` instead.
## Configuration
[Section titled “Configuration”](#configuration)
Counters are automatically created when first used and persist across stream sessions. You can manage counters in the StreamElements dashboard under the Chatbot section.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(getcount)`](/chatbot/variables/getcount): Display the current value of a counter
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I have multiple counters?**
A: Yes, you can create multiple counters by using different names (e.g., `$(count deaths)`, `$(count wins)`).
**Q: How do I reset a counter?**
A: You can reset a counter to zero using `$(count [counter_name] 0)`.
# $(customapi)
> Make GET requests to external APIs and display the response in chat with the $(customapi) variable in StreamElements Chatbot.
The `$(customapi)` variable makes an HTTP request to an external API and displays the response directly in chat. Use it to pull real-time data — game stats, third-party services, or your own endpoints — into commands.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !latestvideo Check out our latest video: $(customapi https://decapi.me/youtube/latest_video?id=UCjerlCIbLPQwSnYlClkjDXg)
```
Example chat
ViewerName:!latestvideo
StreamElements:Check out our latest video: STREAMELEMENTS PATCH NOTES - SEPTEMBER 10, 2023 #streamelements #updates #patchnotes - https\://youtu.be/-q\_q37PoaM8
## Usage
[Section titled “Usage”](#usage)
To use the `$(customapi)` variable, include it in your chat message or command response followed by the URL you want to request:
```streamelements
$(customapi )
```
Replace `` with the actual API endpoint you want to call. If the URL doesn’t start with `http://` or `https://`, `http://` is automatically prepended.
Note
The legacy dot form is also supported: `$(customapi.https://example.com/data)` works the same as `$(customapi https://example.com/data)`. The same applies to `$(urlfetch.)`.
## How requests work
[Section titled “How requests work”](#how-requests-work)
* Requests are GET only and are routed through a StreamElements proxy with a **15-second timeout** — your API is never called directly from the bot.
* You cannot set custom request headers.
* Responses are truncated to the **first 400 bytes**; anything longer is silently cut off.
* Query parameters are percent-encoded and re-sorted alphabetically before the request is made.
* The URL must be a single token without spaces — all inputs are concatenated with no separator, so spaces are dropped. To insert dynamic values like user input into a URL, encode them first with [`$(queryescape)`](/chatbot/variables/queryescape).
* There is no caching: every evaluation makes a fresh request.
## Examples
[Section titled “Examples”](#examples)
### Getting a random joke
[Section titled “Getting a random joke”](#getting-a-random-joke)
```streamelements
$(customapi https://official-joke-api.appspot.com/random_joke)
```
Example chat
StreamElements:{"id":323,"type":"general","setup":"Why did the cookie cry?","punchline":"Because his father was a wafer so long!"}
### Passing user input safely
[Section titled “Passing user input safely”](#passing-user-input-safely)
```streamelements
!command add !define $(customapi https://api.example.com/define?word=$(queryescape $(1)))
```
## Parameters
[Section titled “Parameters”](#parameters)
The `$(customapi)` variable itself doesn’t accept parameters. However, you can include query parameters in the URL if the API requires them. For example:
```streamelements
$(customapi https://api.example.com/data?param1=value1¶m2=value2)
```
## Aliases
[Section titled “Aliases”](#aliases)
* `$(urlfetch)`: Identical to `$(customapi)` in every way — both names run the exact same code.
## Errors
[Section titled “Errors”](#errors)
| Bot reply | Cause |
| ------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `invalid url ` | The URL could not be parsed |
| `Could not connect to remote server` | The request failed (e.g. timeout, DNS failure) |
| `The remote server returned status code ` | The server responded with status 400 or higher, e.g. `The remote server returned status code 404 Not Found` |
| `The remote server did not send any data` | The response body could not be read |
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I use `$(customapi)` to make POST requests?**
A: No, `$(customapi)` only supports GET requests.
**Q: What happens if the API returns an error status?**
A: Any response with status code 400 or higher renders `The remote server returned status code ` in chat. Any status below 400 (including all 2xx and 3xx statuses) returns the response body as-is.
**Q: How can I handle JSON responses?**
A: `$(customapi)` returns the raw response. To parse JSON, you may need to use additional tools or custom integrations.
# $(ffzemotes)
> Display the list of active FrankerFaceZ emotes in a Twitch channel with the $(ffzemotes) variable in StreamElements Chatbot commands.
The `$(ffzemotes)` variable is used to display a list of active FrankerFaceZ (FFZ) emotes in your Twitch channel. This can be helpful for viewers to see which custom emotes are available for use in the chat.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !ffz Our channel's FFZ emotes: $(ffzemotes)
```
Example chat
ViewerName:!ffz
StreamElements:Our channel's FFZ emotes: LULW KEKW 5Head PogU
## Usage
[Section titled “Usage”](#usage)
When the command is triggered, the variable is replaced with a list of the channel’s active FFZ emote codes, separated by single spaces. The list is unordered — the same emotes may appear in a different order each time the command runs.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [$(bttvemotes)](/chatbot/variables/bttvemotes): Lists active BetterTTV emotes in the channel
* [$(7tvemotes)](/chatbot/variables/7tvemotes): Lists active 7TV emotes in the channel
## FAQ
[Section titled “FAQ”](#faq)
**Q: How often is the FFZ emote list updated?**
A: The FFZ emote list is cached for 48 hours. To update the list immediately, you can use the command `!emotes reload`.
**Q: Can I filter or limit the number of emotes displayed?**
A: The `$(ffzemotes)` variable doesn’t have built-in filtering or limiting options. To manipulate the output, you’ll need to use additional StreamElements variables or custom code.
**Q: What if there are no FFZ emotes in the channel?**
A: If there are no active FFZ emotes, the variable will return an empty string.
# $(game)
> Display the current game being played on a Twitch channel with the $(game) variable in StreamElements Chatbot.
The `$(game)` variable displays the game category a channel is currently playing.
Note
`$(game)` is not available on YouTube — there, it renders as literal text instead of being replaced. On YouTube, use [`$(channel.game)`](/chatbot/variables/channel) instead, which works on every platform.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !game We're currently playing $(game)!
```
Example chat
ViewerName:!game
StreamElements:We're currently playing Valorant!
## Usage
[Section titled “Usage”](#usage)
To use the `$(game)` variable, simply include it in your command or message:
```streamelements
$(game)
```
You can also check the game of a specific channel by providing a username:
```streamelements
$(game [username])
```
The variable is replaced with the name of the game or category, exactly as it appears on the platform.
## Examples
[Section titled “Examples”](#examples)
Check the game on another channel:
```streamelements
shroud is playing: $(game shroud)
```
Example chat
StreamElements:shroud is playing: Counter-Strike: Global Offensive
## Parameters
[Section titled “Parameters”](#parameters)
* `username` (optional): The Twitch username of the channel you want to check. If not provided, the variable will display the game of the current channel. Cross-channel lookups work on Twitch.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(title)`](/chatbot/variables/title): Displays the current stream title
* [`$(channel)`](/chatbot/variables/channel): Shows information about the current channel
* [`$(uptime)`](/chatbot/variables/uptime): Displays how long the current stream has been live
## FAQ
[Section titled “FAQ”](#faq)
**Q: How often does the game information update?**
A: The game is fetched live each time the variable runs, so it reflects the platform’s current data. Changes typically show up within a few seconds of updating the game on Twitch.
**Q: What happens if no game is set?**
A: If no game is set for the channel, the `$(game)` variable returns ``.
**Q: What happens if the lookup fails?**
A: If the game can’t be retrieved for your own channel, the variable returns ``. When checking another channel, a channel that doesn’t exist returns ``, and other failures return an `` code.
# $(getcount)
> Retrieve a counter's current value without incrementing it using the $(getcount) variable in StreamElements Chatbot.
The `$(getcount)` variable allows you to retrieve the current value of a counter without incrementing it. This is useful for displaying counter values in chat messages or on stream overlays.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !hugstats The !hug command has been used $(getcount hugs) times so far.
```
Example chat
ViewerName:!hugstats
StreamElements:The !hug command has been used 42 times so far.
## Usage
[Section titled “Usage”](#usage)
To use the `$(getcount)` variable, you need to provide the name of the counter as a parameter. The syntax is as follows:
```streamelements
$(getcount )
```
The variable outputs the counter’s current value as a plain number, e.g. `42`.
## Examples
[Section titled “Examples”](#examples)
Displaying the current death count without changing it:
```streamelements
!command add !deathcheck We're at $(getcount deaths) deaths so far. It could be worse!
```
Example chat
ViewerName:!deathcheck
StreamElements:We're at 13 deaths so far. It could be worse!
## Parameters
[Section titled “Parameters”](#parameters)
The `$(getcount)` variable takes one parameter:
* `counter_name`: The name of the counter you want to retrieve the value for. This is a required parameter.
Note
Unlike [`$(count)`](/chatbot/variables/count), `$(getcount)` is read-only and never modifies the counter — and it does not fall back to the invoking command’s own counter, so the counter name must always be provided.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(count)`](/chatbot/variables/count): Increments a counter and returns its new value
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I use $(getcount) to create a new counter?**
A: No, `$(getcount)` only retrieves existing counter values. To create a new counter, use the `$(count)` variable first.
**Q: What happens if I try to get the count of a non-existent counter?**
A: If the counter doesn’t exist, `$(getcount)` will return `0`.
**Q: Is there a limit to how many counters I can have?**
A: StreamElements doesn’t specify a limit, but it’s good practice to use counters judiciously to avoid performance issues.
# $(if)
> Add conditional logic to StreamElements Chatbot commands with the $(if) variable — show different responses depending on a true/false condition.
The `$(if)` variable adds simple conditional logic to your commands: it checks whether a condition is true and outputs one of two values accordingly. Combined with nested variables like `$(random.pick)`, it powers coin flips, chance-based games, and toggleable responses.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !coinflip $(sender) flips a coin... it lands on $(if $(random.pick 1,0) Heads Tails)!
```
Example chat
ViewerName:!coinflip
StreamElements:ViewerName flips a coin... it lands on Heads!
`$(random.pick 1,0)` randomly returns `1` or `0`, which `$(if)` reads as true or false — so the command answers `Heads` half the time and `Tails` the other half.
## Usage
[Section titled “Usage”](#usage)
```streamelements
$(if [else])
```
The three parts are separated by spaces. Each part can be a plain word, a quoted string (`'...'`, `"..."`, or backticks), or a nested variable.
* If `` is true, the variable outputs ``.
* If `` is false, it outputs `[else]` — or, when no `[else]` is given, the bot says nothing at all (see the caution below).
Only the branch that is taken gets evaluated — a nested variable in the branch that isn’t chosen never runs.
### How conditions work
[Section titled “How conditions work”](#how-conditions-work)
The condition is a **single value read as a boolean**. There are no comparison operators — you can’t write something like `$(if $(sender.points) > 100 ...)`.
| Condition value | Counts as |
| --------------------------------------------------------- | --------- |
| `1`, `t`, `T`, `true`, `TRUE`, `True` | true |
| `0`, `f`, `F`, `false`, `FALSE`, `False` | false |
| Anything else, including arbitrary text or an empty value | false |
A false condition with no else silences the bot
If the condition is false and you didn’t provide an `[else]` value, the bot suppresses the **entire response** — not just the `$(if)` part. For example, `Hello $(if false '4Head')` produces no message at all. Add an else branch (or a pipe default, see below) whenever the bot should always reply.
## Examples
[Section titled “Examples”](#examples)
| Variable | Output |
| -------------------------- | --------------------------------------------------- |
| `$(if true '4Head')` | `4Head` |
| `$(if 1 '4Head' "NaM")` | `4Head` |
| `$(if xd '4Head' 'Keepo')` | `Keepo` — a non-boolean condition counts as false |
| `$(if false '4Head')` | Nothing — the whole message is suppressed |
| `$(if false x\|fallback)` | `fallback` — a pipe default acts as the else branch |
A practical pattern is gating on another variable that produces a boolean-like value, such as `$(random.pick)` with `1`/`0` options:
```streamelements
!command add !chest You open the chest and find $(if $(random.pick 1,0) 'a legendary sword' 'absolutely nothing')!
```
## Parameters
[Section titled “Parameters”](#parameters)
* `` (required): A single value parsed as a boolean. `1`/`t`/`true` (any casing) are true; everything else — including `0`, `false`, and any other text — is false.
* `` (required): The output when the condition is true.
* `[else]` (optional): The output when the condition is false. If omitted and the condition is false, the bot sends no message. A pipe default on the then-value (`$(if cond then|else)`) works as an else branch too.
## Related variables
[Section titled “Related variables”](#related-variables)
* [`$(random)`](/chatbot/variables/random): `$(random.pick 1,0)` makes a 50/50 condition for `$(if)`.
* [`$(provider)`](/chatbot/variables/provider): Returns the channel’s platform slug.
* [`$(1)`, `$(1:)`](/chatbot/variables/args): Argument tokens and pipe defaults, useful inside `$(if)` branches.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I compare two values, like checking if a user typed a specific word?**
A: No. The condition is a single token read as a boolean — there are no `==`, `>`, or similar operators. Text that isn’t a recognized boolean value simply counts as false.
**Q: Why does my command sometimes not respond at all?**
A: Most likely an `$(if)` with a false condition and no else branch — that suppresses the entire message. Add an `[else]` value or a pipe default.
**Q: Can I nest variables inside $(if)?**
A: Yes — all three slots accept nested variables, and only the branch that is taken is evaluated.
# $(leagueoflegends)
> Get a League of Legends player's rank and LP using StreamElements Chatbot. Supports Riot IDs and multiple regions.
The `$(leagueoflegends)` variable allows you to retrieve and display the current rank and LP (League Points) of a specified League of Legends player using the StreamElements Chatbot.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !rank My current rank: $(leagueoflegends styler#euw euw)
```
Example chat
ViewerName:!rank
StreamElements:My current rank: Gold IV (81 LP)
## Usage
[Section titled “Usage”](#usage)
To use this variable, you need to provide two parameters: the player’s Riot ID or Summoner Name, and the region.
```streamelements
$(leagueoflegends )
```
The name comes first here — the opposite of [`$(teamfighttactics)`](/chatbot/variables/teamfighttactics), where the region comes first.
The output format is ` ( LP)`, for example `Gold IV (81 LP)` or `Challenger I (1229 LP)`.
Riot IDs
League of Legends is transitioning to Riot IDs. During the transition, you can use either Riot IDs or Summoner Names. After the transition, only Riot IDs will be supported.
Note
If the Riot ID contains spaces, wrap it in quotes. Both inputs are case-insensitive.
## Examples
[Section titled “Examples”](#examples)
```streamelements
$(leagueoflegends styler#euw euw)
$(leagueoflegends "Doublelift#na1" na)
```
Example output:
```plaintext
Challenger I (1229 LP)
```
## Parameters
[Section titled “Parameters”](#parameters)
1. **Riot ID/Summoner Name**: The player’s unique identifier, e.g. `styler#euw`
2. **Region**: The server region of the player (e.g., `euw`, `na`)
## Supported Regions
[Section titled “Supported Regions”](#supported-regions)
* `br` (Brazil)
* `eune` (Europe Nordic & East)
* `euw` (Europe West)
* `jp` (Japan)
* `kr` (Republic of Korea)
* `lan` (Latin America North)
* `las` (Latin America South)
* `na` (North America)
* `oce` (Oceania)
* `pbe` (Public Beta Environment)
* `ph` (Philippines)
* `ru` (Russia)
* `sg` (Singapore)
* `th` (Thailand)
* `tw` (Taiwan)
* `tr` (Turkey)
* `vn` (Vietnam)
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(teamfighttactics)`](/chatbot/variables/teamfighttactics): The same rank lookup for Teamfight Tactics
## FAQ
[Section titled “FAQ”](#faq)
**Q: Why isn’t the rank updating immediately?**
A: Rank data may have a slight delay due to API caching. It typically updates within a few minutes after a player’s ranked game.
**Q: What happens if the lookup fails?**
A: If the player can’t be found or the API request fails, the bot replies with the raw error message returned by the API.
# $(math)
> Perform mathematical calculations in StreamElements Chatbot messages with the $(math) variable and math.js expressions.
The `$(math)` variable allows you to perform mathematical calculations and operations directly in your StreamElements Chatbot messages. It utilizes the math.js library, providing a wide range of mathematical functions and capabilities.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !calc Result: $(math $(1:))
```
Example chat
ViewerName:!calc 2 + 2
StreamElements:Result: 4
## Usage
[Section titled “Usage”](#usage)
To use the `$(math)` variable, include it in your message followed by a valid math.js expression:
```streamelements
$(math )
```
Replace `` with the mathematical operation you want to perform. Results are plain numbers like `4`, `-1`, or `0.05` — and unit conversions return values like `5 inch`.
## Examples
[Section titled “Examples”](#examples)
**Rounding a division result**
```streamelements
10 divided by 3, rounded to the nearest integer, is $(math "round(10/3)")
```
Example chat
StreamElements:10 divided by 3, rounded to the nearest integer, is 3
**Generating a random number**
```streamelements
Your random number between 1 and 10 is $(math "random(1,10)")
```
Example chat
StreamElements:Your random number between 1 and 10 is 7.525986609745358
## Parameters
[Section titled “Parameters”](#parameters)
The `$(math)` variable takes a single parameter: a valid math.js expression. This can include:
* Basic arithmetic operations (`+`, `-`, `*`, `/`)
* Mathematical functions (e.g., `round()`, `floor()`, `ceil()`, `log()`, `sin()`, `cos()`)
* Constants (e.g., `pi`, `e`)
* Logical operators (e.g., `>`, `<`, `==`, `!=`)
For a complete list of supported operations and functions, refer to the [math.js documentation](https://mathjs.org/docs/index.html).
## Errors
[Section titled “Errors”](#errors)
| Bot reply | Cause |
| ------------------------------------------------ | -------------------------------------- |
| `Something went wrong while processing equation` | The request to the math service failed |
| `Failed to evaluate equation` | The result could not be read |
Invalid expressions return the error text produced by the math service itself.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(customapi)`](/chatbot/variables/customapi): Can be used to fetch and process numerical data from external sources
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I use variables in my math expressions?**
A: Yes, you can use other StreamElements variables within your `$(math)` expression. For example: `$(math $(user.points) * 2)` would output double the user’s points.
**Q: Is there a limit to the complexity of expressions I can use?**
A: While there’s no strict limit, very complex expressions may take longer to process, and results are truncated to the first 400 bytes. It’s best to keep expressions relatively simple for optimal performance.
# $(msgid)
> Output the unique message ID of the message that triggered a command with the $(msgid) variable in StreamElements Chatbot.
The `$(msgid)` variable outputs the unique message ID of the chat message that triggered the command — mainly useful for debugging and advanced custom integrations.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !messageid The ID of the message that triggered this command is: $(msgid)
```
Example chat
ViewerName:!messageid
StreamElements:The ID of the message that triggered this command is: bcc9b4bc-566d-4f14-a57d-a86c1c3196f8
## Usage
[Section titled “Usage”](#usage)
To use the `$(msgid)` variable, simply include it in your command response or custom script. The chatbot will automatically replace it with the actual message ID when the command is triggered.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(user)`](/chatbot/variables/user): Returns the username of the person who triggered the command
* [`$(channel)`](/chatbot/variables/channel): Returns the name of the channel where the command was triggered
## FAQ
[Section titled “FAQ”](#faq)
**Q: What format does the message ID use?**
A: The variable returns the platform’s native message ID. On Twitch this is a UUID (a string of letters and numbers separated by hyphens, such as `bcc9b4bc-566d-4f14-a57d-a86c1c3196f8`); other platforms like YouTube and Kick use their own ID formats.
# $(pathescape)
> Escape strings for safe use in URL paths with the $(pathescape) variable in StreamElements Chatbot commands.
The `$(pathescape)` variable is a utility function in the StreamElements Chatbot that escapes a string for safe use in a URL path. It converts spaces and special characters into their percent-encoded equivalents, ensuring that the resulting string can be used as part of a valid URL.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !wiki Read all about it: https://en.wikipedia.org/wiki/$(pathescape ${1:})
```
Example chat
ViewerName:!wiki rocket league
StreamElements:Read all about it: https\://en.wikipedia.org/wiki/rocket%20league
## Usage
[Section titled “Usage”](#usage)
To use `$(pathescape)`, include it in your command or message with the string you want to escape as its parameter:
```streamelements
$(pathescape )
```
Replace `` with the text you want to encode for use in a URL path.
Note
`$(pathescape)` only escapes the first value it is given, so multi-word text must arrive as a single piece: wrap it in quotes (`$(pathescape "two words")`) or nest an argument token like `${1:}`, as in the example above.
## Examples
[Section titled “Examples”](#examples)
### Basic Usage
[Section titled “Basic Usage”](#basic-usage)
Input:
```streamelements
$(pathescape "Hello World!")
```
Output:
```plaintext
Hello%20World%21
```
### Using with $(customapi)
[Section titled “Using with $(customapi)”](#using-with-customapi)
Input:
```streamelements
$(customapi "https://api.example.com/$(pathescape 'User Input & Symbols?')")
```
Fetches:
```plaintext
https://api.example.com/User%20Input%20&%20Symbols%3F
```
Note that characters which are valid inside a URL path segment (such as `&`, `:`, and `=`) are left as-is — only characters that would break the path (spaces, `?`, `/`, and similar) are encoded.
## Parameters
[Section titled “Parameters”](#parameters)
The `$(pathescape)` variable accepts a single parameter:
* **text**: The text you want to escape for use in a URL path. This parameter is required.
If no text is provided, the variable is not replaced and appears as literal text in the response.
## Aliases
[Section titled “Aliases”](#aliases)
`$(pathencode)` can also be used as an alias for `$(pathescape)`.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(queryescape)`](/chatbot/variables/queryescape): Escapes text for use in URL query parameters (encodes spaces as `+`).
* [`$(customapi)`](/chatbot/variables/customapi): Fetches content from a URL, often combined with `$(pathescape)` for dynamic requests.
## FAQ
[Section titled “FAQ”](#faq)
**Q: What characters does $(pathescape) encode?**
A: It percent-encodes spaces (as `%20`) and any characters that are not safe inside a URL path segment, such as `?` and `/`. Characters that are valid in a path segment, like `&` and `:`, are left unchanged.
**Q: What’s the difference between $(pathescape) and $(queryescape)?**
A: `$(pathescape)` is for the path portion of a URL and encodes spaces as `%20`. `$(queryescape)` is for query parameters (everything after `?`) and encodes spaces as `+`.
# $(pointsname)
> Display the name of your stream's loyalty currency with the $(pointsname) variable in StreamElements Chatbot messages and commands.
The `$(pointsname)` variable displays the name of your channel’s loyalty currency, so command responses keep working even after you rename your points.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !points $(sender) has $(sender.points) $(pointsname)!
```
Example chat
ViewerName:!points
StreamElements:ViewerName has 500 memecoins!
## Usage
[Section titled “Usage”](#usage)
Insert `$(pointsname)` into your chat messages or commands where you want the loyalty currency name to appear. The chatbot will automatically replace it with your actual loyalty points name. If you haven’t set a custom name, it displays `points`.
## Examples
[Section titled “Examples”](#examples)
Informing viewers about earning points:
```streamelements
Earn more $(pointsname) by watching the stream!
```
Example chat
StreamElements:Earn more memecoins by watching the stream!
## Related
[Section titled “Related”](#related)
* [`$(user.points)`](/chatbot/variables/user#available-variables): Displays the user’s current loyalty points balance
* [`!addpoints`](/chatbot/commands/default/addpoints): Adds points to a user’s balance (mod/broadcaster only)
* [`!setpoints`](/chatbot/commands/default/setpoints): Sets a user’s points to a specific value (mod/broadcaster only)
## FAQ
[Section titled “FAQ”](#faq)
**Q: How do I change my loyalty points name?**
A: You can change your loyalty points name in the StreamElements dashboard under the Loyalty tab. The `$(pointsname)` variable will automatically update to reflect the new name.
**Q: Can I use $(pointsname) in custom commands?**
A: Yes, you can use `$(pointsname)` in any custom command or chat message where you want to display your loyalty points name.
# $(provider)
> Display which streaming platform a channel runs on — twitch, youtube, or kick — with the $(provider) variable in StreamElements Chatbot.
The `$(provider)` variable returns the platform the channel runs on, as a lowercase slug: `twitch`, `youtube`, or `kick`. It is identical to [`$(channel.provider)`](/chatbot/variables/channel) and works on every platform.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !platform This channel streams on $(provider) — see you in chat!
```
Example chat
ViewerName:!platform
StreamElements:This channel streams on twitch — see you in chat!
## Usage
[Section titled “Usage”](#usage)
```streamelements
$(provider)
```
The variable takes no arguments and always refers to the channel the bot is running in.
| Platform | Output |
| -------- | --------- |
| Twitch | `twitch` |
| YouTube | `youtube` |
| Kick | `kick` |
Because the output is a stable lowercase slug, it is most useful **nested inside other variables** — for example to build platform-aware responses with [`$(customapi)`](/chatbot/variables/customapi):
```streamelements
$(customapi https://example.com/messages/$(provider))
```
This requests a different URL per platform (`.../messages/twitch` on Twitch, `.../messages/kick` on Kick, and so on), so your API can return a platform-specific response.
Note
[`$(if)`](/chatbot/variables/if) cannot compare text, so `$(if $(provider) ...)` does not branch by platform — a slug like `twitch` always counts as false. Use the `$(customapi)` pattern above for platform-specific responses.
## Related variables
[Section titled “Related variables”](#related-variables)
* [`$(channel)`](/chatbot/variables/channel): `$(channel.provider)` returns the same value, alongside other channel fields.
* [`$(customapi)`](/chatbot/variables/customapi): Fetch a URL — combine with `$(provider)` for platform-aware responses.
* [`$(if)`](/chatbot/variables/if): Conditional output based on a true/false condition.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Does $(provider) work on every platform?**
A: Yes — it is available on Twitch, YouTube, and Kick.
**Q: Is the output capitalized?**
A: No, it is always the lowercase slug (`twitch`, not `Twitch`).
# $(pubg)
> Display PUBG player statistics like K/D, wins, and rating in chat with the $(pubg) variable in StreamElements Chatbot.
The `$(pubg)` variable displays a PLAYERUNKNOWN’S BATTLEGROUNDS player statistic in chat — kills, K/D ratio, wins, rating, and more — for a given region and match type.
Third-party data
Stats are fetched from the third-party service pubgtracker.com, which has not been reliably available for a long time. If the service is down, the variable returns `Failed to get stats` — test your command before relying on it.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !pubgwins I have won $(pubg na shroud solo wins) solo games this season!
```
Example chat
ViewerName:!pubgwins
StreamElements:I have won 248 solo games this season!
## Usage
[Section titled “Usage”](#usage)
```streamelements
$(pubg )
```
All four parameters are required — with fewer than four, the variable renders as literal text. Inputs are case-insensitive (everything is lowercased before use).
## Parameters
[Section titled “Parameters”](#parameters)
* `` (required): The region the stats are tracked in, matched against the player’s data — for example `na`, `eu`, or `agg` (all regions aggregated).
* `` (required): The player’s PUBG (PC) name.
* `` (required): The match type, matched against the player’s data — for example `solo`, `duo`, or `squad`.
* `` (required): One of the whitelisted stat keys below.
## Available stats
[Section titled “Available stats”](#available-stats)
| Stat | Meaning |
| --------------------- | ------------------------ |
| `kd` | K/D ratio |
| `winratio`, `winrate` | Win percentage |
| `wins` | Wins |
| `losses` | Losses |
| `roundsplayed` | Rounds played |
| `rating` | Rating |
| `bestrating` | Best rating |
| `bestrank` | Best rank |
| `top10s` | Top-10 finishes |
| `top10ratio` | Top-10 rate |
| `wintop10ratio` | Win/top-10 ratio |
| `top10spg` | Top 10s per game |
| `kills` | Kills |
| `killspg` | Kills per game |
| `dailykills` | Daily kills |
| `weeklykills` | Weekly kills |
| `roundmostkills` | Most kills in a round |
| `maxkillstreaks` | Max kill streak |
| `headshotkills` | Headshot kills |
| `headshotkillspg` | Headshot kills per game |
| `headshotkillratio` | Headshot kill ratio |
| `roadkills` | Road kills |
| `teamkills` | Team kills |
| `suicides` | Suicides |
| `assists` | Assists |
| `damagepg` | Average damage per match |
| `healspg` | Heals per game |
| `revivespg` | Revives per game |
| `timesurvived` | Time survived |
| `longesttimesurvived` | Longest time survived |
| `mostsurvivaltime` | Most survival time |
| `avgsurvivaltime` | Average survival time |
Any other stat key returns an error (see below).
## Errors
[Section titled “Errors”](#errors)
| Output | Meaning |
| ---------------------------- | ------------------------------------------------------------------------------- |
| ` is not a valid stat` | The stat key isn’t in the list above — e.g. `headshots is not a valid stat`. |
| `No stats found` | No data matched the given region and match type in the player’s current season. |
| `Failed to get stats` | The pubgtracker.com API request failed. |
## Related variables
[Section titled “Related variables”](#related-variables)
* [`$(leagueoflegends)`](/chatbot/variables/leagueoflegends): Get a League of Legends player’s rank and LP.
* [`$(teamfighttactics)`](/chatbot/variables/teamfighttactics): Get a Teamfight Tactics player’s rank and LP.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Can I use it for console players?**
A: No — the lookup queries PC profiles on pubgtracker.com.
**Q: Why do I always get “Failed to get stats”?**
A: The data comes from the third-party pubgtracker.com service, which has been unreliable or unavailable for a long time. If the service is down, there is nothing to display.
# $(queryescape)
> Encode strings for use in URL query parameters with the $(queryescape) variable in StreamElements Chatbot commands.
The `$(queryescape)` variable is used to encode a string for safe use in URLs. It replaces spaces with plus signs and escapes special characters, making it ideal for creating dynamic search queries or links within chatbot commands.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !google Let me Google that for you: https://google.com/search?q=$(queryescape ${1:})
```
Example chat
ViewerName:!google StreamElements chatbot
StreamElements:Let me Google that for you: https\://google.com/search?q=StreamElements+chatbot
## Usage
[Section titled “Usage”](#usage)
To use the `$(queryescape)` variable, include it in your command with the text you want to encode as its parameter:
```streamelements
$(queryescape )
```
Replace `` with the string you want to encode for URL usage.
Note
`$(queryescape)` only escapes the first value it is given, so multi-word text must arrive as a single piece: wrap it in quotes (`$(queryescape "two words")`) or nest an argument token like `${1:}`, as in the example above.
## Examples
[Section titled “Examples”](#examples)
A YouTube search command:
```streamelements
!command add !yt https://www.youtube.com/results?search_query=$(queryescape ${1:})
```
Example chat
ViewerName:!yt funny cat videos
StreamElements:https\://www\.youtube.com/results?search\_query=funny+cat+videos
## Parameters
[Section titled “Parameters”](#parameters)
The `$(queryescape)` variable takes a single parameter:
* **text**: The string you want to encode for URL usage. This can be static text or a dynamic value from another variable or user input.
If no text is provided, the variable is not replaced and appears as literal text in the response.
## Aliases
[Section titled “Aliases”](#aliases)
`$(queryencode)` can also be used as an alias for `$(queryescape)`.
## Related Variables
[Section titled “Related Variables”](#related-variables)
* [`$(pathescape)`](/chatbot/variables/pathescape): Escapes text for use in URL paths (encodes spaces as `%20`).
* [`$(customapi)`](/chatbot/variables/customapi): Used to fetch content from a URL, often combined with `$(queryescape)` for dynamic web requests.
* [Argument tokens](/chatbot/variables/args): Represent user input in custom commands, frequently used with `$(queryescape)` to create dynamic queries.
## FAQ
[Section titled “FAQ”](#faq)
**Q: Why should I use $(queryescape) instead of just inserting text directly into a URL?**
A: Using `$(queryescape)` ensures that special characters and spaces are properly encoded, preventing errors in the URL and ensuring it works correctly across different platforms and browsers.
**Q: What’s the difference between $(queryescape) and $(pathescape)?**
A: `$(queryescape)` is for query parameters (everything after `?`) and encodes spaces as `+`. `$(pathescape)` is for the path portion of a URL and encodes spaces as `%20`.
**Q: Can I use $(queryescape) with other variables or in more complex commands?**
A: Yes, you can combine `$(queryescape)` with other variables and use it in complex commands. It’s especially useful when working with user input or dynamic data that needs to be included in URLs.
# $(quote)
> Display a random or specific saved quote in Twitch chat with the $(quote) variable in StreamElements Chatbot.
The `$(quote)` variable allows you to display a randomly saved quote or a specific quote by ID in your Twitch chat using the StreamElements Chatbot.
## Use it
[Section titled “Use it”](#use-it)
```streamelements
!command add !randomquote $(quote)
```
Example chat
ViewerName:!randomquote
StreamElements:#12 That was the play of the century!
## Usage
[Section titled “Usage”](#usage)
Embed `$(quote)` in a custom command. You can optionally specify a quote ID to display a specific quote.
1. Display a random quote:
```streamelements
$(quote)
```
2. Display a specific quote by ID:
```streamelements
$(quote 3)
```
## Output
[Section titled “Output”](#output)
The variable outputs the quote in the format `#