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

@booklib/claude-ado-confirm-hook

v1.0.0

Published

Native macOS confirmation dialog for Azure DevOps MCP write operations in Claude Code

Downloads

25

Readme

Azure DevOps Confirmation Hook for Claude Code

Native macOS dialog for reviewing Azure DevOps MCP write operations before they execute. See what's changing, approve or cancel.

| Update — word-level diff | Create — field summary | Batch update — table view | |:---:|:---:|:---:| | | | |

Why

The Azure DevOps MCP server lets Claude Code create, update, and link work items directly. But write operations execute immediately — no visual preview of what's about to change.

This hook intercepts MCP write calls and shows a native macOS dialog with:

  • Updates: side-by-side diff with word-level highlighting
  • Batch updates: table with old → new values per item
  • Creates: field summary of the new work item
  • Links, comments, PRs: formatted preview

Install

npx @booklib/claude-ado-confirm-hook

This copies the hook files to .claude/hooks/, compiles the native dialog, and prints the settings config to add.

Manual install

If you prefer not to use npm:

mkdir -p .claude/hooks
curl -sL https://raw.githubusercontent.com/ZLStas/claude-code-ado-confirm-hook/main/hooks/ado-confirm.sh -o .claude/hooks/ado-confirm.sh
curl -sL https://raw.githubusercontent.com/ZLStas/claude-code-ado-confirm-hook/main/hooks/ado-confirm-dialog.py -o .claude/hooks/ado-confirm-dialog.py
curl -sL https://raw.githubusercontent.com/ZLStas/claude-code-ado-confirm-hook/main/hooks/ado-webview.swift -o .claude/hooks/ado-webview.swift
chmod +x .claude/hooks/ado-confirm.sh .claude/hooks/ado-confirm-dialog.py
swiftc -framework Cocoa -framework WebKit -O -o .claude/hooks/ado-webview .claude/hooks/ado-webview.swift

Configure

Add to .claude/settings.local.json:

{
  "hooks": {
    "PreToolUse": [
      {
        "matcher": "mcp__azure-devops__wit_create_work_item|mcp__azure-devops__wit_update_work_item|mcp__azure-devops__wit_update_work_items_batch|mcp__azure-devops__wit_add_child_work_items|mcp__azure-devops__wit_add_work_item_comment|mcp__azure-devops__repo_create_pull_request|mcp__azure-devops__wit_work_items_link|mcp__azure-devops__wit_add_artifact_link|mcp__azure-devops__repo_create_branch",
        "hooks": [
          {
            "type": "command",
            "command": ".claude/hooks/ado-confirm.sh",
            "timeout": 30000,
            "statusMessage": "Awaiting confirmation for Azure DevOps action..."
          }
        ]
      }
    ]
  }
}

The hook reads your org name and access token from .mcp.json automatically — no hardcoded config needed.

How It Works

  1. Claude Code calls an Azure DevOps MCP tool (create, update, link, etc.)
  2. The hook intercepts the call before execution
  3. For updates: fetches current values from Azure DevOps API to show the diff
  4. Renders an HTML view in a native macOS WebView window
  5. You click Approve (or Enter) to proceed, Cancel (or Escape) to block

The dialog appears on your current screen — no desktop switching.

Requirements

  • macOS (Cocoa WebView)
  • Xcode Command Line Tools (for swiftc)
  • jq, curl (for the shell script)
  • Azure DevOps MCP server configured in .mcp.json

Files

| File | What it does | |------|-------------| | ado-confirm.sh | Hook entry point. Enriches payloads with current values for diffs. | | ado-confirm-dialog.py | Builds HTML for each operation type. Handles diff, batch fetch, name normalization. | | ado-webview.swift | Native macOS window with WKWebView. Renders HTML, handles Approve/Cancel. |

License

MIT