Peekaboo

mcp
Security Audit
Fail
Health Pass
  • License — License: MIT
  • Description — Repository has a description
  • Active repo — Last push 2 days ago
  • Community trust — 4087 GitHub stars
Code Fail
  • rm -rf — Recursive force deletion command in .github/workflows/macos-ci.yml
Permissions Pass
  • Permissions — No dangerous permissions requested
Purpose
This tool is a macOS CLI and MCP server that provides AI agents with screen capture, visual analysis, and full GUI automation capabilities (clicking, typing, scrolling).

Security Assessment
Overall risk: Medium. The tool inherently requires access to highly sensitive data because it needs macOS Screen Recording and Accessibility permissions to function. It can literally see everything on your screen and control your computer's UI. While the automated audit found no hardcoded secrets and no explicitly dangerous permissions requested in the code, the tool does make network requests to send visual data to external AI providers (like OpenAI, Anthropic, or Google) for analysis. The two failed audit checks for `rm -rf` commands are false positives; they are safely located within GitHub Actions CI/CD workflows for cleaning up build environments, not in the core application code.

Quality Assessment
Overall quality is excellent. The project is highly active, with its last code push occurring today, and boasts strong community trust with over 3,200 GitHub stars. It is properly licensed under the permissive MIT license and is widely compatible with major AI CLIs and coding environments. The documentation is clear and comprehensive. Note that the current version 3 release is in beta, so users should expect minor bugs.

Verdict
Use with caution — while the code itself is safe and well-maintained, granting screen recording and UI control access to any tool requires careful consideration of your privacy boundaries and trust in your configured AI providers.
SUMMARY

Peekaboo is a macOS CLI & optional MCP server that enables AI agents to capture screenshots of applications, or the entire system, with optional visual question answering through local or remote AI models.

README.md

Peekaboo 🫣 - Mac automation that sees the screen and does the clicks.

Peekaboo Banner

npm package
License: MIT
macOS 15.0+ (Sequoia)
Swift 6.2
node >=22
Download macOS
Homebrew
Ask DeepWiki

Peekaboo brings high-fidelity screen capture, AI analysis, and complete GUI automation to macOS. Version 3 adds native agent flows and multi-screen automation across the CLI and MCP server.

What you get

  • Pixel-accurate captures (windows, screens, menu bar) with optional Retina 2x scaling.
  • Natural-language agent that chains Peekaboo tools (see, click, type, scroll, hotkey, menu, window, app, dock, space).
  • Action-first UI automation for routine clicks/scrolls, with synthetic input fallback for apps that need it.
  • Direct accessibility tools for settable values and named actions (set-value, perform-action).
  • Menu and menubar discovery with structured JSON; no clicks required.
  • Multi-provider AI: GPT-5.1 family, Claude 4.x, Grok 4-fast (vision), Gemini 2.5, and local Ollama models.
  • MCP server for Codex, Claude Code, and Cursor plus a native CLI; the same tools in both.
  • Configurable, testable workflows with reproducible sessions and strict typing.
  • Requires macOS Screen Recording + Accessibility permissions (see docs/permissions.md).

Install

  • macOS app + CLI (Homebrew):
    brew install steipete/tap/peekaboo
    
  • MCP server (Node 22+, no global install needed):
    npx -y @steipete/peekaboo
    

Quick start

# Capture full screen at Retina scale and save to Desktop
peekaboo image --mode screen --retina --path ~/Desktop/screen.png

# Click a button by label (captures, resolves, and clicks in one go)
peekaboo see --app Safari --json | jq -r '.data.snapshot_id' | read SNAPSHOT
peekaboo click --on "Reload this page" --snapshot "$SNAPSHOT"

# Directly set a text field value when the accessibility value is settable
peekaboo set-value --on T1 --value "hello" --snapshot "$SNAPSHOT"

# Invoke a named accessibility action on an element
peekaboo perform-action --on B1 --action AXPress --snapshot "$SNAPSHOT"

# Run a natural-language automation
peekaboo agent "Open Notes and create a TODO list with three items"

# Run as an MCP server (Codex, Claude Code, Cursor)
npx -y @steipete/peekaboo

# Minimal MCP client config snippet:
# {
#   "mcpServers": {
#     "peekaboo": {
#       "command": "npx",
#       "args": ["-y", "@steipete/peekaboo"],
#       "env": {
#         "PEEKABOO_AI_PROVIDERS": "openai/gpt-5.5,anthropic/claude-opus-4-7"
#       }
#     }
#   }
# }

Shell completions

Peekaboo can generate shell-native completions directly from the same Commander
metadata that powers CLI help and docs:

# Current shell (recommended)
eval "$(peekaboo completions $SHELL)"

# Explicit shells
eval "$(peekaboo completions zsh)"
eval "$(peekaboo completions bash)"
peekaboo completions fish | source

For persistent setup and troubleshooting, see
docs/commands/completions.md.

Command Key flags / subcommands What it does
see --app, --mode screen/window, --retina, --json Capture and annotate UI, return snapshot + element IDs
click --on <id/query>, --snapshot, --wait-for, --coords Click by element ID, label, or coordinates
type --text, --clear, --profile, --delay Enter text with pacing options
set-value --on <id/query>, --value, --snapshot Directly set a settable accessibility value
perform-action --on <id/query>, --action, --snapshot Invoke a named accessibility action
press key names, --count, --delay, --hold Special keys and sequences
hotkey combos like cmd,shift,t Modifier combos (cmd/ctrl/alt/shift)
scroll --on <id>, --direction up/down, --amount Scroll views or elements
swipe --from/--to, --duration, --steps Smooth gesture-style drags
drag --from/--to, modifiers, Dock/Trash targets Drag-and-drop between elements/coords
move --to <id/coords>, --screen-index Position the cursor without clicking
window list, move, resize, focus, set-bounds Move/resize/focus windows and Spaces
app launch, quit, relaunch, switch, list Launch, quit, relaunch, switch apps
space list, switch, move-window List or switch macOS Spaces
menu list, list-all, click, click-extra List/click app menus and extras
menubar list, click Target status-bar items by name/index
dock launch, right-click, hide, show, list Interact with Dock items
dialog list, click, input, file, dismiss Drive system dialogs (open/save/etc.)
image --mode screen/window/menu, --retina, --analyze Screenshot screen/window/menu bar (+analyze)
list apps, windows, screens, menubar, permissions Enumerate apps, windows, screens, permissions
tools --verbose, --json, --no-sort Inspect native Peekaboo tools
completions [shell] Generate zsh/bash/fish completion scripts from Commander metadata
config init, show, add, login, models Manage credentials/providers/settings
permissions status, grant Check/grant required macOS permissions
run .peekaboo.json, --output, --no-fail-fast Execute .peekaboo.json automation scripts
sleep --duration (ms) Millisecond delays between steps
clean --all-snapshots, --older-than, --snapshot Prune snapshots and caches
agent --model, --dry-run, --resume, --max-steps, audio Natural-language multi-step automation
mcp serve (default) Run Peekaboo as an MCP server

Models and providers

  • OpenAI: GPT-5.1 (default) and GPT-4.1/4o vision
  • Anthropic: Claude 4.x
  • xAI: Grok 4-fast reasoning + vision
  • Google: Gemini 2.5 (pro/flash)
  • Local: Ollama (llama3.3, llava, etc.)

Set providers via PEEKABOO_AI_PROVIDERS or peekaboo config add.

Learn more

Community

Development basics

  • Requirements: macOS 15+, Xcode 16+/Swift 6.2. Node 22+ only if you run the pnpm docs/build helper scripts (core CLI/app/MCP are Swift-only).
  • Install deps: pnpm install then pnpm run build:cli or pnpm run test:safe.
  • Lint/format: pnpm run lint && pnpm run format.

License

MIT

Reviews (0)

No results found