LinuxCommandLibrary

pw-cli

Interact with PipeWire multimedia server

TLDR

Print all nodes (sinks and sources) along with their IDs

$ pw-cli list-objects Node
copy

Print information about an object with a specific ID
$ pw-cli info [4]
copy

Print all objects' information
$ pw-cli info all
copy

SYNOPSIS

pw-cli [options] [command]

PARAMETERS

-h, --help
    Show help options

-v, --version
    Show program version

-r, --remote=NAME
    The name of the PipeWire remote to connect to. If not given, the standard socket name will be used.

list [id]
    List all the properties of an object id or all the registered objects.

info [id]
    Show information of an object id.

dump [id]
    Dump the object properties as S-expressions. If id is not given, then list all objects.

load [modulename] [args]
    Load a module with the specified arguments

create [factory] [args]
    Create an object from the factory with the specified arguments.

destroy [id]
    Destroy the object identified by id.

update [id] [args]
    Update the properties of object id.

connect [src_id] [src_port] [dst_id] [dst_port]
    Connect the src_port of object src_id with the dst_port of object dst_id.

disconnect [src_id] [src_port] [dst_id] [dst_port]
    Disconnect the src_port of object src_id with the dst_port of object dst_id.

subscribe [types]
    Subscribe to object events of the requested types. Valid types are 'core', 'node', 'port', 'link', 'stream'. Subscribe with no types for all events.

wait [id]
    Wait until the object id has a 'running' state

DESCRIPTION

The pw-cli command is a versatile tool for interacting with a PipeWire server. It provides a command-line interface to manage and inspect PipeWire objects, such as nodes, streams, ports, and links. It is primarily used for debugging, testing, and development of PipeWire applications and modules.

pw-cli allows users to list, monitor, and modify the properties of PipeWire objects. It also supports executing commands against these objects, enabling control over the audio and video processing pipelines managed by PipeWire. This tool is essential for anyone working on PipeWire-based systems and applications, offering deep insight and control over the underlying multimedia infrastructure. The command supports various types of commands allowing users to get information from the Pipewire server, create objects on the server, and modify the properties of the existing ones.

CAVEATS

The `pw-cli` tool requires a running PipeWire server to function correctly. Proper understanding of PipeWire's object model and properties is crucial for effective usage.

USAGE EXAMPLES

  • List all nodes: pw-cli list Node
  • Show info for node with id 32: pw-cli info 32
  • Create the `alsa.sink` from factory: pw-cli create alsa.sink

HISTORY

The `pw-cli` tool was developed as part of the PipeWire project, a multimedia framework designed to provide low-latency audio and video processing capabilities on Linux and other operating systems. It emerged alongside PipeWire as a debugging and management interface, providing developers with a way to interact directly with the server and inspect its state. The tool has evolved with PipeWire, gaining new features and improvements to support the growing capabilities of the multimedia framework. Initially designed as debugging tool it evolved as a must have tool for developers for managing servers.

SEE ALSO

pipewire(1), pw-mon(1)

Copied to clipboard