SuperAPIAI Directory

phygital-key-mcp

github.com · AI developer platforms

Phygital Key MCP is an open-source tool based on MCP (Model Context Protocol) that lets AI applications request explicit user approval via passkeys (fingerprint, face, PIN, or hardware security key) before performing sensitive operations such as deploying code, making payments, deleting, or sending messages. The approval result is signed by the user's key, and the server can verify the signature offline, ensuring the operation was authorized by a real person and that the request content has not been tampered with. It is suitable for MCP-compatible AI applications such as Claude Code and Claude Desktop, is licensed under Apache-2.0, and is free and open source.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)
PlatformsmacOS · Linux

About this tool

Phygital Key MCP is a component of the Phygital Key product line aimed at MCP (Model Context Protocol) AI applications. MCP is a common way for AI applications to connect to tools, and it can be used by Claude Code, Claude Desktop, and other MCP applications. The program is named phygital-key-mcp; it provides tools for AI applications and runs an approval page where users decide whether to approve the operation requested by the AI.

Purpose

When an AI agent is about to deploy code, make a payment, delete, or send content, it calls the request_approval tool and submits the specific operation it wants to perform. The user reads the request on the approval page and approves it using a passkey (fingerprint, face, PIN, or hardware security key). The user's key signs that exact request (WebAuthn, ES256 on P-256). The agent passes the signed approval to the service performing the operation, and the service verifies the approval offline on its own before acting. The agent has no tool with which it can approve on its own; if even a single character of the request content changes, the service rejects it with REQUEST_MISMATCH.

Key Capabilities

  • Request approval: The AI agent submits a specific operation via request_approval and waits for the user to approve, reject, cancel, or let it expire.
  • Passkey signing: The user signs the request using a fingerprint, face, PIN, or hardware security key, with the ES256 signature algorithm (ECDSA on P-256 with SHA-256).
  • Offline verification: The service performing the operation can independently verify the approval signature offline, without relying on the approving party being online.
  • Tamper resistance: The approval is bound to the request content, and any character change causes verification to fail (REQUEST_MISMATCH).
  • Approval page security: The page is built from the request itself rather than text written by the agent; it displays all fields, warns about similar-looking letters, invisible characters, and extra spaces, shows the SHA-256 fingerprint of the signed text, and checks that the displayed content matches what will be signed before requesting the key.
  • Standing Approvals: For repeated small operations, the user can approve once and set limits (such as payee, maximum amount, number of uses, and validity period), with each use generating a one-minuteValid usage tokens are checked and counted by the server.
  • Receipts and auditing: After a service executes, it can return a signed receipt (success or failure), which the agent passes along via record_receipt; the approval page only displays receipts signed by a stored service key. The audit log is a SHA-256 hash chain that records the ID, hash, and result, but not the request itself.
  • Secure installation and signed updates: Secure installation places the gateway where AI cannot reach it (macOS and Linux), and automatic updates only accept file lists signed by a built-in release key, with SHA-256 verification.

Usage

Installation options include: downloading the file for the corresponding platform from the GitHub releases page, using the container image ghcr.io/phygital-brain/phygital-key-mcp, installing via the npm package @phygital-key/mcp, or using the installation script. There are two ways to connect an AI application: stdio mode (specify the command in the Claude Code or Claude Desktop configuration) and HTTP mode (requires an access token generated by phygital-key-mcp token). On first use, run phygital-key-mcp enroll in the terminal to add a passkey and obtain a one-time link valid for 10 minutes.

Quick start: run the demo program, start the gateway (http://localhost:7468)和模拟服务(http://localhost:7469),然后让 the AI application performs the operation, the approval page opens, and after approval the simulated service executes (no real operation); if rejected, the service is rejected.

Server-side verification: you can use the Rust library phygital-key-verify, the command-line tool (exit code 0 means approved, 1 means rejected), or the dependency-free JavaScript checker.

Use cases

Suitable for high-risk AI operations that require explicit human authorization, such as code deployment, payments, data deletion, and sending messages. Suitable for AI application developers using MCP, service providers that need to add a human approval step to AI operations, and teams concerned about operation auditing and security.

Limitations

  • Approvals are signed, not encrypted; the gateway, the service, and anyone holding the approval can read the request content, so requests should not contain passwords or card numbers.
  • Gateways other than localhost should use HTTPS.
  • Secure installation is available only on macOS and Linux; it requires administrator privileges, and the AI must not be able to obtain the administrator password.
  • Long-term approvals allow at most 1000 uses and a maximum of 30 days, and always require a fingerprint, face, or PIN.
  • Requests are kept only in memory while waiting; no analytics, no accounts, no tracking.
  • This repository contains only the MCP part; the approval page, keys, long-term approvals, receipts, audit logs, secure installation, and signed updates come from the shared base repository Phygital-Brain/phygital-key.
  • Licensed under Apache-2.0; the NOTICE file must be retained.
Up/Down to navigate · Enter to open · ESC to closeBrowse all tools