Skip to main content

OBS CLI

Project description

🎬🎥 OBS CLI

obs-cli is a command-line interface for OBS Studio.

It allows you to control OBS Studio from the command line, making it easier to automate scene switching, source toggling, and more.

This implementation of obs-cli is:

⚠️ Only the new OBS WebSocket API (v5) is supported!

💻 Installation

You can install obs-cli using pip(x):

# pipx
pipx install obs-cli

# pip
pip install --user obs-cli

🛠️ Usage

Here's the general usage of obs-cli:

obs-cli --help

This will show you the available commands and options.

🌟 Features

🎞️ Scene Management

You can manage scenes using the scene command:

obs-cli scene --help

For example, to switch to a scene named "Scene2":

obs-cli scene switch "Scene2"

To list all scenes:

obs-cli scene list

📦 Item Management

You can manage scene items using the item command:

obs-cli item --help

For example, to hide an item named "Item1" in a scene named "Scene2":

obs-cli item hide --scene "Scene2" "Item1"

And to show it:

obs-cli item show --scene "Scene2" "Item1"

To list all items in a scene:

obs-cli item list --scene "Scene2"

📂 Group Management

You can manage scene item groups using the group command:

obs-cli group --help

For example, to hide an group named "group1" in a scene named "Scene2":

obs-cli group hide --scene "Scene2" "group1"

And to show it:

obs-cli group show --scene "Scene2" "group1"

To list all groups in a scene:

obs-cli group list --scene "Scene2"

🎤 Input Management

You can manage inputs using the input command:

obs-cli input --help

For example, to get the settings of an input named "Mic/Aux":

obs-cli input get "Mic/Aux"

To set the device_id of a webcam input named "Webcam":

obs-cli input set "Webcam" device_id /dev/v4l/by-id/usb-Elgato_Elgato_Facecam_FW52K1A04919-video-index0

To list all inputs:

obs-cli input list

Mute/unmute or toggle the mute state of an input:

obs-cli input mute "Mic/Aux"
obs-cli input unmute "Mic/Aux"
obs-cli input toggle-mute "Mic/Aux"

🎨 Filter Management

You can manage filters using the filter command:

obs-cli filter --help

For example, to enable a filter named "Filter1" on an input named "Mic/Aux":

obs-cli filter enable "Mic/Aux" "Filter1"

And to disable it:

obs-cli filter disable "Mic/Aux" "Filter1"

To list all filters on an input:

obs-cli filter list "Mic/Aux"

⌨️ Hotkey Management

You can manage hotkeys using the hotkey command:

obs-cli hotkey --help

For example, to trigger a hotkey named "Hotkey1":

obs-cli hotkey trigger "Hotkey1"

To list all hotkeys:

obs-cli hotkey list

🎥 Virtual Camera Management

You can manage the virtual camera using the virtualcam command:

obs-cli virtualcam --help

For example, to start the virtual camera:

obs-cli virtualcam start

To stop the virtual camera:

obs-cli virtualcam stop

To toggle the virtual camera:

obs-cli virtualcam toggle

To get the status of the virtual camera:

obs-cli virtualcam status

📡 Stream Management

You can manage the stream using the stream command:

obs-cli stream --help

For example, to start streaming:

obs-cli stream start

To stop streaming:

obs-cli stream stop

To toggle streaming:

obs-cli stream toggle

To get the status of the stream:

obs-cli stream status

🎥 Record Management

You can manage recording using the record command:

obs-cli record --help

For example, to start recording:

obs-cli record start

To stop recording:

obs-cli record stop

To toggle recording:

obs-cli record toggle

To get the status of the recording:

obs-cli record status

📄 License

This project is licensed under the GPL-3.0 License.

See LICENSE for more information.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

obs_cli-0.8.3.tar.gz (45.4 kB view details)

Uploaded Source

Built Distribution

obs_cli-0.8.3-py3-none-any.whl (31.5 kB view details)

Uploaded Python 3

File details

Details for the file obs_cli-0.8.3.tar.gz.

File metadata

  • Download URL: obs_cli-0.8.3.tar.gz
  • Upload date:
  • Size: 45.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for obs_cli-0.8.3.tar.gz
Algorithm Hash digest
SHA256 b2b21212e3194cf55ad80d2fb9d1527bac0df39de7c1ef324b5f68912e3f63c1
MD5 e139f38f1a1bc218b226e6b9554532e8
BLAKE2b-256 b0f8ad2745f3de830ec96d79698885108e3e77721d290099d2f7735d320bf277

See more details on using hashes here.

Provenance

The following attestation bundles were made for obs_cli-0.8.3.tar.gz:

Publisher: pypi.yaml on pschmitt/obs-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file obs_cli-0.8.3-py3-none-any.whl.

File metadata

  • Download URL: obs_cli-0.8.3-py3-none-any.whl
  • Upload date:
  • Size: 31.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for obs_cli-0.8.3-py3-none-any.whl
Algorithm Hash digest
SHA256 3ac0a2fdc976a55d2839779129e7a12094bfd2bfeebb6315af73ee5c86e7aebd
MD5 67e8213558d1964b92b97154ceb66e1a
BLAKE2b-256 f99b4f969199387164d6a2b1160a41acdd4ebe2f782d5a7b3c2f866c96aa586c

See more details on using hashes here.

Provenance

The following attestation bundles were made for obs_cli-0.8.3-py3-none-any.whl:

Publisher: pypi.yaml on pschmitt/obs-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page