There are two options to download/install the Twitch CLI for each platform.
If you are using MacOS or Linux, we recommend using Homebrew for installing the CLI as it will also manage the versioning for you.
To install via Homebrew, run brew install twitchdev/twitch/twitch-cli
and it'll be callable via twitch
.
If you are using Windows, we recommend using Scoop for installing the CLI, as it'll also manage versioning.
To install via Scoop, run:
scoop bucket add twitch https://github.com/twitchdev/scoop-bucket.git
scoop install twitch-cli
This will install it into your path, and it'll be callable via twitch
.
Alternatively on Windows you can use WinGet for installing the CLI
To install via Winget, run:
winget install Twitch.TwitchCLI
To download, go to the Releases tab of GitHub. The examples in the documentation assume you have put this into your PATH and renamed to twitch
(or symlinked as such).
Note: If using MacOS and downloading manually, you may need to adjust the permissions of the file to allow for execution.
To do so, please run: chmod 755 <filename>
where the filename is the name of the downloaded binary.
To update the Twitch CLI, run the command relevant to your installation method.
NOTE: Once a day the program will make an HTTP call to Github to check if the application is of the latest version. For information on disabling this, see Disabling release version checks and notices below.
To update using Homebrew, run:
brew upgrade twitchdev/twitch/twitch-cli
To update using Scoop, run:
scoop update twitch-cli
To update using WinGet, run:
winget update Twitch.TwitchCLI
To download, go to the Releases tab of GitHub. The examples in the documentation assume you have put this into your PATH and renamed to twitch
(or symlinked as such).
Note: If using MacOS and downloading manually, you may need to adjust the permissions of the file to allow for execution.
To do so, please run: chmod 755 <filename>
where the filename is the name of the downloaded binary.
When the Twitch CLI exits successfully, the application will automatically check the Twitch CLI's Github releases at the following URL:
https://api.github.com/repos/twitchdev/twitch-cli/releases/latest
If the version of the Twitch CLI you are running is older than the latest released version, a notice will be printed to the console.
To prevent this from happening, make one of the following changes:
- Set the environment variable
CI
totrue
- Set the environment variable
TWITCH_DISABLE_UPDATE_CHECKS
totrue
- Add
DISABLE_UPDATE_CHECKS=true
to your .twitch-cli.env configuration file - SET
LAST_UPDATE_CHECK
to3000-01-01
in your .twitch-cli.env configuration file, which will prevent it from running until the year 3000
If you're running the Twitch CLI in a CI/CD environment, most environments will have already set the CI
environment variable to true
.
The CLI largely follows a standard format:
twitch <product> <action>
The commands are described below, and any accompanying args/flags will be in the accompanying subsections.
The CLI currently supports the following products:
Check out CONTRIBUTING.md for notes on making contributions.
This library is licensed under the Apache 2.0 License.