Documentation › Local MCP Server · Updated Dec 2026

WS Commander MCP Server Setup & 30-Tool Reference

Wire Claude Code, Claude Desktop, and OpenAI Codex to safe local macOS file operations with wsc mcp. Thirty typed tools communicate strictly over an owner-only 0600 Unix domain socket with zero TCP listeners, zero API keys, three off-by-default permission switches, and full automation-audit.jsonl logging.

1. Step-by-Step Setup for Claude Code, Claude Desktop & Codex

  1. Install WS Commander (`v1.0.12 Beta`): Download WS-Commander-1.0.12-universal-notarized.zip, verify SHA-256 (fec8f3e3c1400a987ed9d77c06ce6b250053349d03a14f9efb5edc56be9e3ad1), unzip into /Applications/WS Commander.app, and launch the app.
  2. Enable your desired switches in Settings › Automation: All three switches start off. Enable Enable local automation API for read & navigation tools, and add Allow file changes only when you want queued copies, moves, renames, archive packing, or confirmed Trash operations.
  3. Register the stdio MCP bridge (wsc mcp) in your client:

Step 3A · Claude Code

Run once in Terminal, then verify inside Claude Code with /mcp:

claude mcp add --transport stdio --scope user ws-commander -- \
  "/Applications/WS Commander.app/Contents/Resources/bin/wsc" mcp

Step 3B · Claude Desktop

Add to ~/Library/Application Support/Claude/claude_desktop_config.json and restart:

{
  "mcpServers": {
    "ws-commander": {
      "command": "/Applications/WS Commander.app/Contents/Resources/bin/wsc",
      "args": [
        "mcp"
      ]
    }
  }
}

Step 3C · OpenAI Codex

Add to ~/.codex/config.toml or run codex mcp add:

codex mcp add ws-commander -- "/Applications/WS Commander.app/Contents/Resources/bin/wsc" mcp

[mcp_servers.ws-commander]
command = "/Applications/WS Commander.app/Contents/Resources/bin/wsc"
args = ["mcp"]

Step 4 (Recommended) · Block raw shell bypasses with wsc guard

# Preview changes cleanly before modifying ~/.claude/ or ~/.codex/
"/Applications/WS Commander.app/Contents/Resources/bin/wsc" guard install claude-code --dry-run
"/Applications/WS Commander.app/Contents/Resources/bin/wsc" guard install codex --dry-run

# Apply non-destructive guardrails (.bak created for ~/.claude/settings.json)
"/Applications/WS Commander.app/Contents/Resources/bin/wsc" guard install claude-code
"/Applications/WS Commander.app/Contents/Resources/bin/wsc" guard install codex

Step 5 · Verify first call

Ask your agent to call get_state or list_directory, or test the local socket directly in Terminal:

printf '%s\n' '{"jsonrpc":"2.0","id":1,"method":"app.state"}' \
  | nc -U "$HOME/Library/Application Support/Wscommander/ipc/api.sock"

2. Security

WS Commander was designed so an autonomous coding agent can never silently escalate privileges or delete directories without explicit macOS user boundaries:

  • Owner-only Unix socket: Traffic travels strictly over ~/Library/Application Support/Wscommander/ipc/api.sock (0600 file mode inside a 0700 directory). Any connection from another OS user is dropped immediately, and zero TCP or UDP ports are ever opened.
  • No API key requirement: Authentication relies on macOS filesystem ownership of api.sock rather than bearer tokens stored in plain-text env files or cloud dashboards.
  • Three off-by-default permission switches: Turning off Allow file changes immediately withdraws unstarted queued agent mutations and stops running agent transfers before their next file step (Stopped: permission revoked).
  • Human confirmation sheets & protected roots: By default, trash and delete pause in awaitingConfirmation and show WS Commander’s confirmation sheet naming the client. /, top-level OS folders, volume roots, and $HOME (resolved through symlinks) are always refused for move, rename, Trash, or delete.
  • No Keychain leakage & JSONL audit log: Remote SFTP/FTP passwords stay isolated inside the macOS Keychain; every request is recorded in ~/Library/Application Support/Wscommander/automation-audit.jsonl.

3. Typed Path Object Schema

Every file or folder tool accepts explicit typed path objects rather than ambiguous string prefixes:

Local Path

{ "type": "local", "path": "/Users/alice/Documents/Report.pdf" }

Archive Entry

{ "type": "archive", "archive": "/Users/alice/Downloads/bundle.zip", "path": "docs/notes.md" }

Connected Remote

{ "type": "remote", "profile": "prod-sftp", "path": "/var/www/releases/app.tar.gz" }

4. Complete 30-Tool Parameter Reference

Required parameters are marked with * and optional parameters with ?. File mutation tools queue into WS Commander’s Operations window and return an operationId immediately for polling via get_operation.

Tool & RPC Method Scope & Switch Parameters (* required) Default Description
get_state
app.state
Read-only
Enable local automation API
None Off (Switch 1) Return both panes (location, tabs, cursor, selection count, view mode, sort) and active permissions.
list_directory
pane.list
Read-only
Enable local automation API
pane?, location?, offset?, limit?, includeHidden? Off (Switch 1) List paged entries of a pane or any local, archive, or connected remote folder without navigating.
get_selection
pane.selection
Read-only
Enable local automation API
pane*, offset?, limit? Off (Switch 1) Return marked entries and the focused cursor entry of left, right, active, or inactive pane.
get_file_info
file.info
Read-only
Enable local automation API
path* Off (Switch 1) Return entry kind, size, timestamps, POSIX permissions, owner/group, hidden flag, and symlink target.
read_text_file
file.readText
Read-only
Enable local automation API
path*, offset?, maxBytes?, encoding? Off (Switch 1) Read a bounded byte slice (up to 1 MiB/call) through the Lister decoder; binary files are refused.
search_start
search.start
Read-only
Enable local automation API
roots?, pane?, name?, nameRegex?, content?, contentRegex?, caseSensitive?, maxDepth?, maxResults? Off (Switch 1) Start an asynchronous file/content search below local roots or active pane folder and return searchId.
search_results
search.results
Read-only
Enable local automation API
searchId*, offset?, limit? Off (Switch 1) Poll search job state (running, finished, cancelled, failed) and paged matches.
search_stop
search.stop
Read-only
Enable local automation API
searchId* Off (Switch 1) Cancel a running background search job while keeping matches collected so far readable.
checksum
checksum.compute
Read-only
Enable local automation API
path*, algorithm? Off (Switch 1) Compute lowercase hex digest (sha256, crc32, md5, sha1, sha384, sha512, sha3-256, sha3-512, blake3).
compare_directories
compare.directories
Read-only
Enable local automation API
left*, right*, recursive?, compareContents?, dateToleranceSeconds?, include?, includeIdentical?, direction?, limit? Off (Switch 1) Diff two local folders and optionally preview sync actions without changing any files.
list_operations
operation.list
Read-only
Enable local automation API
None Off (Switch 1) List queued, running, paused, awaiting-confirmation, and recently finished queue operations.
get_operation
operation.status
Read-only
Enable local automation API
operationId* Off (Switch 1) Inspect live progress, transferred bytes, conflicts, and per-item outcomes of one queued operation.
list_commands
command.list
Read-only
Enable local automation API
None Off (Switch 1) List built-in command IDs, live availability, and whether each is allowed via run_command.
list_remote_profiles
remote.profiles
Read-only
Enable local automation API
None Off (Switch 1) List saved FTP/SFTP profiles (id, protocol, host, port, username, state); passwords are never returned.
navigate_pane
pane.navigate
View-only
Enable local automation API
pane*, location?, action?, select?, timeoutMs? Off (Switch 1) Navigate a pane to a typed location or relative action (up, home, back, forward, refresh).
activate_pane
pane.activate
View-only
Enable local automation API
pane* Off (Switch 1) Focus either the left, right, active, or inactive pane.
select_entries
pane.select
View-only
Enable local automation API
pane*, mode*, names?, pattern? Off (Switch 1) Mark or unmark pane entries (replace, add, remove, all, none, invert) via exact names or wildcards.
open_tab
tab.open
View-only
Enable local automation API
pane*, location?, timeoutMs? Off (Switch 1) Open and focus a new folder tab in the specified pane.
close_tab
tab.close
View-only
Enable local automation API
pane*, index? Off (Switch 1) Close a tab by zero-based index (or the active tab when index is omitted; never closes the last tab).
select_tab
tab.select
View-only
Enable local automation API
pane*, index*, timeoutMs? Off (Switch 1) Switch focus to an existing tab in the left or right pane.
run_command
command.run
View-only
Enable local automation API
id* Off (Switch 1) Run allow-listed non-mutating UI/navigation/sort commands; file-changing commands are always denied.
copy
operation.copy
File change
Allow file changes
sources*, destination*, name?, onConflict? Off (Switch 2) Queue a copy/extract/upload/download using APFS clonefile, fcopyfile, and live conflict sheets.
move
operation.move
File change
Allow file changes
sources*, destination*, name?, onConflict? Off (Switch 2) Queue a move within or across volumes/remotes; deletes sources only after verified transfer completion.
rename
operation.rename
File change
Allow file changes
path*, newName*, onConflict? Off (Switch 2) Queue a rename within the parent folder with conflict protection and protected-root refusal.
create_directory
operation.mkdir
File change
Allow file changes
parent*, name* Off (Switch 2) Create a folder (local, writable archive, or remote) without overwriting any existing entry.
pack
operation.pack
File change
Allow file changes
sources*, destination*, name*, format?, compression?, onConflict? Off (Switch 2) Compress local files/folders into zip, tar, tar.gz, tar.xz, tar.bz2, or 7z via parallel workers.
extract
operation.extract
File change
Allow file changes
archives*, destination*, separateSubdirectories?, fileMask?, onConflict? Off (Switch 2) Extract ZIP/TAR/7z/bsdtar archives into a local folder with path-traversal protection.
trash
operation.trash
File change
Allow file changes (+ confirmation or Switch 3)
paths* Off (Switch 2 + sheet) Move local files/folders to macOS Trash after protected-root checks; shows a sheet unless Switch 3 is on.
delete
operation.delete
File change
Allow file changes (+ confirmation or Switch 3)
paths* Off (Switch 2 + sheet) Permanently delete local, archive, or remote entries outside protected roots with confirmation sheet by default.
control_operation
operation.control
File change
Allow file changes
operationId*, action* Off (Switch 2) Pause, resume, cancel, or remove a queued or active file operation in the shared queue.

Full JSON Schema source: dev-docs/automation-api.md · Security overview: /mcp · Live REST JSON: /api/v1/tools.