npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@steipete/peekaboo

v3.9.4

Published

macOS automation MCP server with screen capture, UI interaction, and AI analysis

Readme

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 background process-targeted input by default when a target is known.
  • 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 through Tachikoma, including hosted, local, and OpenAI-/Anthropic-compatible providers.
  • Claude Fable 5 support with 1M context and a 128K output ceiling; saved temperature/max-token settings are shared by the app and CLI and clamped to each model's capabilities.
  • MCP server for Codex, Claude Code, and Cursor plus a native CLI; the same tools in both.
  • Warm daemon and Peekaboo.app Bridge hosts for permission-bound automation, with distinct lease-owned sockets and local fallback.
  • 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

# Capture current UI state, then copy its snapshot and opaque element IDs exactly
peekaboo see --app Safari --json
SNAPSHOT="<snapshot-id>"
TEXT_FIELD_ID="<text-field-id>"
BUTTON_ID="<button-id>"

# Click a button by label
peekaboo click --on "Reload this page" --snapshot "$SNAPSHOT"

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

# Invoke a named accessibility action on an element
peekaboo perform-action --on "$BUTTON_ID" --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-8"
#       }
#     }
#   }
# }

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.

Background vs foreground input

click, type, press, hotkey, and paste default to background delivery when Peekaboo can resolve a target process from --app, --pid, --window-id, or snapshot metadata. Background delivery posts process-targeted input without making the target app frontmost, so scripts can interact with Safari, Notes, Terminal, etc. without stealing focus.

Use --foreground when the app only accepts input in its focused key window, when you need a real foreground mouse event, or when you are intentionally driving the current focus. Focus flags such as --space-switch and --bring-to-current-space also imply foreground delivery. Element/query clicks first use Accessibility actions; keyboard input, coordinate clicks, and synthetic click fallback require Event Synthesizing for the sending process. Run peekaboo permissions request-event-synthesizing if permissions status reports it missing.

# Background: target Safari without activating it
peekaboo click "Address and search bar" --app Safari
peekaboo type "github.com/openclaw/Peekaboo" --app Safari --return

# Foreground: focus Safari first for apps/fields that reject background input
peekaboo click "Address and search bar" --app Safari --foreground
peekaboo type "github.com/openclaw/Peekaboo" --app Safari --return --foreground

| 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, --foreground | Click by element ID, label, or coordinates | | type | --text, --clear, --profile, --delay, --foreground | 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, --foreground | Special keys and sequences | | hotkey | combos like cmd,shift,t, --foreground | Modifier combos (cmd/ctrl/alt/shift) | | paste | text/file/image payloads, --restore-delay-ms, --foreground | Paste with clipboard restore | | 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, request-screen-recording, request-event-synthesizing | 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

Peekaboo's provider list changes with Tachikoma and the tested model catalog. See docs/providers.md for the current provider reference, including OpenAI, Anthropic, xAI/Grok, Google Gemini, MiniMax, Kimi, Ollama, LM Studio, and compatible custom endpoints.

Set providers via PEEKABOO_AI_PROVIDERS or peekaboo config add. Agent generation settings live under agent.temperature and agent.maxTokens in ~/.peekaboo/config.json; the macOS Settings UI reads and writes the same values.

Learn more

Community

  • PeekabooWin — Windows-first rewrite of the Peekaboo automation loop (JavaScript + PowerShell) by @FelixKruger
  • PeekabooX — Linux-first rewrite of the Peekaboo automation loop (Rust + Python) by @nordbyte

Development basics

  • Requirements: see docs/platform-support.md. Node 22+ is only needed for the npm MCP wrapper and pnpm helper scripts.
  • Install deps: pnpm install then pnpm run build:cli or pnpm run test:safe.
  • Lint/format: pnpm run lint && pnpm run format.

License

MIT