Custom Commands
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”There are two ways to manage custom commands:
- Through the creator dashboard
- Directly in chat with the !command command
Using the dashboard
Section titled “Using the dashboard”See Getting Started for a step-by-step walkthrough of creating a command in the dashboard.
Using chat
Section titled “Using chat”| Action | Syntax | Example |
|---|---|---|
| Add | !command add !<name> <response> |
!command add !socials Follow me on Twitter @MyHandle! |
| Edit | !command edit !<name> <new_response> |
!command edit !socials Check out my links: example.com/links |
| Remove | !command remove !<name> |
!command remove !socials |
| Show | !command show !<name> |
!command show !socials |
| Options | !command options !<name> <option> <value> |
!command options !socials -cd 10 -level 500 |
For the full subcommand reference, including all available options, permissions, and aliases, read the documentation for the !command command.
Examples
Section titled “Examples”Dynamic Greeting Command
Section titled “Dynamic Greeting Command”This command greets the user and tells them when they last visited the stream.
!cmd add !hello $(user), welcome to the stream! You last visited $(user.lastseen) ago.Variables used:
- $(user) - The name of the viewer
- $(user.lastseen) - The time the viewer last visited the stream
Stream Uptime Command
Section titled “Stream Uptime Command”This command shows how long the stream has been live, the current game, and viewer count.
!cmd add !stream The stream has been live for $(uptime). We're currently playing $(channel.game) for $(channel.viewers) viewers!Variables used:
- $(uptime) - The time the stream has been live
- $(channel.game) - The game the stream is currently playing
- $(channel.viewers) - The number of viewers currently watching the stream
Weather Command
Section titled “Weather Command”This command checks the weather for a location specified by the viewer.
!cmd add !weather $(sender), weather in: $(weather ${1:})Variables used:
- $(sender) - The viewer who triggered the command
- ${1:} - The arguments passed to the command, here the location to look up
- $(weather) - The current weather in a specified location
Shoutout Command
Section titled “Shoutout Command”This command sends a simple shoutout to a specified user.
!cmd add !shoutout Check out ${1}, they are playing $(game ${1}) at https://twitch.tv/${1}Variables used: