LinuxCommandLibrary

audtool

Control and query the Audacious music player

TLDR

Play/pause audio playback

$ audtool playback-playpause
copy

Print artist, album, and song name of currently playing song
$ audtool current-song
copy

Set volume of audio playback
$ audtool set-volume [100]
copy

Skip to the next song
$ audtool playlist-advance
copy

Print the bitrate of the current song in kilobits
$ audtool current-song-bitrate-kbps
copy

Open Audacious in full-screen if hidden
$ audtool mainwin-show
copy

Display help
$ audtool help
copy

Display settings
$ audtool preferences-show
copy

SYNOPSIS

audtool [--host=HOST] [--port=PORT] [--password=PASS] [--quiet] [--show-output] command [arguments]

PARAMETERS

--help
    Display usage summary and exit

--version
    Show audtool version information

--host=HOST
    Connect to Audacious on specified host (default: localhost)

--port=PORT
    Use specified TCP port (default: 45679)

--password=PASS
    Authenticate with password if required

--quiet
    Suppress non-essential error messages

--show-output
    Display stdout/stderr from executed commands

DESCRIPTION

Audtool is a versatile command-line tool designed to remotely control the Audacious audio player. It enables users to manage playback, adjust volume and balance, manipulate playlists, query track information, and more, all from the terminal. Audtool communicates with a running Audacious instance over a TCP socket, requiring the "Audacious Control Socket" plugin to be enabled in Audacious preferences.

This makes it perfect for scripting, desktop shortcuts, status bars (e.g., in i3 or polybar), or automation tasks. Commands are straightforward, with global options for connection customization. Output is concise, often just status values or confirmations, supporting easy parsing in scripts. Audtool supports querying detailed metadata like artist, title, bitrate, and equalizer settings, providing a lightweight alternative to full GUI interaction.

CAVEATS

Audacious must be running with the control socket plugin enabled; default port 45679 must be accessible. No direct file playback—controls existing instance only.

COMMON COMMANDS

playback-status
play
pause
playpause
stop
next
prev
volume up|down|NUM|toggle
current [title|artist|album]
playlist-length
playlist-add URL

PLAYLIST MANAGEMENT

playlist-clear
playlist-jump POS
playlist-insert POS URL
playlist-shuffle
playlist-save FILE

EXAMPLES

audtool play
audtool volume 80
audtool current title
audtool --host=192.168.1.100 playlist-add https://example.com/track.mp3

HISTORY

Developed as part of Audacious (forked from XMMS in 2000; modern Audacious since 2008). Audtool introduced in Audacious 3.x (2010s) to replace legacy tools like xmmsctrl, emphasizing scriptability amid rise of lightweight audio players.

SEE ALSO

audacious(1), mpc(1), ncmpc(1)

Copied to clipboard