API

CLI reference

Every `apexdock` subcommand, flag, and exit code.

The apexdock CLI wraps the Control API and the widget wire over a single command-line surface. It's bundled at ApexDock.app/Contents/Resources/bin/apexdock.

Install

Settings → Integrations → Install CLI symlinks /usr/local/bin/apexdock to the bundled binary. macOS asks for your password to write to that location.

Manual install:

bash
sudo ln -sf /Applications/ApexDock.app/Contents/Resources/bin/apexdock /usr/local/bin/apexdock

The symlink points at the binary inside the app bundle, so updating ApexDock keeps the CLI in sync.

Top-level groups

apexdock workspace …    # workspace verbs
apexdock app …          # app verbs
apexdock action …       # bar action verbs
apexdock bar …          # bar visibility
apexdock settings …     # settings panel
apexdock palette …      # command palette
apexdock widget …       # widget wire (push)

apexdock --help and apexdock <group> --help show the full subcommand tree.

Workspace

apexdock workspace list                          # list all
apexdock workspace switch <name>                 # match by name
apexdock workspace switch --id <uuid>            # match by id
apexdock workspace current                       # active workspace

Name match: case-insensitive, exact > prefix > contains.

App

apexdock app focus <bundleId>                    # activate or launch
apexdock app list-pinned                         # global pinned list

focus activates the app if running, otherwise launches via NSWorkspace. Returns {bundleId, launched}.

Action

apexdock action toggle-dock-suppressor           # hide/show macOS Dock
apexdock action toggle-window-minder             # toggle window clamping

Mirrors the Settings → Bar toggles. Useful for binding to a hotkey via Karabiner or Keyboard Maestro.

Bar

apexdock bar toggle                              # flip visibility
apexdock bar set-visible true|false              # force a state

Affects every bar panel in multi-monitor mode.

Settings

apexdock settings open <tab>

Tabs: bar, permissions, agents, assistant, commandPalette, workspaces, about.

Palette

apexdock palette show                            # open the panel
apexdock palette run "<query>"                   # local fuzzy match + run

run skips the AI router — only local fuzzy match. Use show and type if you want AI routing.

Widget

apexdock widget upsert --id <id> [flags]         # publish or update
apexdock widget remove --id <id>                 # remove a widget
apexdock widget clear                            # remove all from this connection
apexdock widget list                             # dump the public schema info

upsert flags:

FlagNotes
--idrequired
--labeltext chip, truncated to 8 chars
--symbolSF Symbol
--iconfilesystem path or data:image/...
--tintcolor (#hex or named)
--tooltiphover text
--ordersort key
--click-shell <command>shell click action
--click-url <url>URL click action
--click-palette <query>palette click action

At most one --click-* per upsert. Run apexdock widget upsert --help for the complete reference.

Output formats

Default output is the raw JSON response. Pass --text for tab-separated human-readable output (control commands only — widget commands always speak JSON).

bash
apexdock workspace current --text   # → "id<TAB>name"
apexdock workspace list --text      # → table

Exit codes

CodeMeaning
0OK
1Invalid usage
2Server returned ok:false
3Socket missing or unreachable

Useful in shell scripts:

bash
if apexdock workspace switch "$1" --text; then
  echo "switched"
else
  echo "no match" >&2
fi

Bundled helpers

Beyond the main apexdock:

BinaryPurpose
apexdock-eventWraps the Hook API for agent telemetry + approvals
apexdock claude-hookBundled Swift Claude Code hook handler
apexdock-claude-hookLegacy compatibility wrapper

Both live in the same Contents/Resources/bin/ directory. Symlink as needed.

Uninstall

bash
sudo rm /usr/local/bin/apexdock

Or uninstall via Settings → Integrations → Uninstall CLI.