Skip to main content

The Wistia CLI

Learn about Wistia's command line tool.

Written by Caroline F

What is the Wistia CLI?

The Wistia CLI is an installable command-line tool for working with the Wistia Data API from terminals, scripts, CI jobs, or AI coding-agent workflows. It gives you a scriptable way to work with Wistia accounts, upload media, manage content, and query analytics—the same API-backed capabilities available through the Wistia MCP server, in command-line form.

Tip

If you'd like an AI client like Claude or ChatGPT to talk to Wistia in natural language, use the Wistia MCP server. If you'd like people, scripts, CI jobs, or agent runtimes to run Wistia commands directly, use the CLI. They share the same underlying capabilities, but are built for different environments.


Install the Wistia CLI

The install path for the Wistia CLI differs based on whether you're using macOS, Linux, or Windows. Check out our developer resources for a full breakdown of the Wistia CLI.

Homebrew (macOS/Linux)

brew install wistia/tap/wistia-cli

Quick install script (macOS/Linux)

curl -fsSL https://raw.githubusercontent.com/wistia/wistia-cli/main/scripts/install.sh | bash

Quick install script (Windows PowerShell)

iwr -useb https://raw.githubusercontent.com/wistia/wistia-cli/main/scripts/install.ps1 | iex

Manual download

You can also download a pre-built binary for your platform from the releases page and place it on your PATH. To confirm the CLI is installed, run wistia --version.

Connect the CLI to your Wistia account

The Wistia CLI uses a Wistia API access token. You can create one in the API Home tab of your Account Settings. If you don't see the API Home tab, ask your Account Owner.

Once you have a token, run wistia configure (or wistia auth login). The CLI stores your token securely in your computer's keychain. To check which credentials are active, run wistia auth whoami.

Tip

For CI jobs or other automated environments, set your token with the WISTIA_CLI_BEARER_AUTH environment variable instead of passing it with --bearer-auth. That way your token doesn't end up in your shell history or logs. Treat your API token like a password, and never commit it to source control.

Try a few commands

Once you're connected, try a few read-only commands:

  • wistia account get (shows your account details)

  • wistia media list (lists your media, most recent first)

  • wistia folders list (lists your folders)

Add --help to any command, like wistia media --help, to see what it can do. To get output a script can use, add --output-format json. Other options are yaml, table, and toon.

Use the CLI with AI coding agents

The CLI switches to agent mode automatically when it runs inside tools like Claude Code, Cursor, or Codex. In agent mode, it returns compact output and structured error messages that agents can act on. You can also turn it on yourself with --agent-mode. To preview a command without running it, add --dry-run.

Troubleshooting

"command not found" after installing

If the install script can't write to /usr/local/bin, it installs to ~/.local/bin instead. Make sure that folder is on your PATH, or reinstall with WISTIA_CLI_INSTALL_DIR set to a folder of your choice.

When contacting support, send us the command you ran, your wistia --version, how you installed the CLI, and the error output. Please never share your API token with our team.

Did this answer your question?