Stripe MCP
MCP server integrating with Stripe - tools for customers, products, payments, and more.
Pre-payment safety gate for x402 agents: PII screening, spend policy, replay checks before signing.
제작자가 쓴 원문
목록은 사용 점수(100점 만점)로 정렬되며 구성은 다음과 같습니다
| 인기 | 0/80 | GitHub 별 또는 주간 다운로드: 큰 쪽 60, 작은 쪽 20 |
|---|---|---|
| 최신성 | 12/12 | 30일 안에 릴리스나 코드 변경이 있으면 만점 |
| 응답 중 | 0/8 | 마지막 점검 때 클라우드 엔드포인트가 응답 |
| 사용 점수 | 12/100 |
품질: 기본 점검 1/1개 통과(표시만, 정렬에는 안 씀) · 상승세: 데이터 없음 (급상승 탭에서만 사용)
쓰고 있는 AI 앱을 고른 다음 설정을 복사하세요.
한 문장으로 AI에게 설치 맡기기
Presidio Hardened X402 MCP 설치해 줘. https://mcp.popnx.com/i/presidio-v-presidio-hardened-x402-mcp.md 를 따라 하고, 명령을 먼저 보여 주고 내가 승인하면 실행해.내 컴퓨터에서 작업하는 AI(Claude Code, Cursor 등)에 붙여 넣으세요. 단계를 읽고 명령을 보여 준 뒤 승인을 기다립니다. 키도 가입도 필요 없습니다. · AI가 읽을 전체 내용 보기
검사 1/1 통과 · 내 컴퓨터에서 실행돼요 · ✓ 명령 확인 2026년 11월 13일
먼저: 어떤 AI를 쓰시나요?
쓰는 앱을 고르면 아래에 단계가 나옵니다.
Claude에 연결할 수 있지만 먼저 준비가 필요해요
먼저 컴퓨터에 Python (uv)를 설치하세요 (한 번만) · 컴퓨터용 Claude 앱(Windows 또는 Mac)에서만 되고 웹이나 모바일은 안 돼요
이 메시지를 Claude 채팅에 붙여 넣으세요. AI가 컴퓨터를 확인하고 어떤 파일을 바꿀지 알려 준 뒤 매번 동의를 기다립니다.
이 컴퓨터의 Claude에 MCP server Presidio Hardened X402 MCP을 설치해 주세요. 순서대로: 1) uv --version로 uv가 있는지 확인. 없으면 https://docs.astral.sh/uv/getting-started/installation/에서 설치하라고 알려 주고 직접 설치하지 마세요. 2) 이 설정만 사용하세요(PopNx MCP 확인 완료): { "mcpServers": { "presidio-hardened-x402": { "command": "uvx", "args": [ "presidio-hardened-x402-mcp" ] } } } 3) 바꿀 파일의 전체 경로나 실행할 명령을 알려 주고 제 동의를 기다리세요. 4) 키는 필요 없습니다. 5) 합의한 대로 실행한 뒤 Presidio Hardened X402 MCP의 도구가 실제로 보이는지 확인하세요.이 메시지에는 키가 없습니다. 키가 필요하면 AI가 파일이나 앱 입력란에 직접 붙여 넣으라고 안내합니다.
이미 설치했나요? 먼저 확인 · 터미널을 열고 이 명령을 입력한 뒤 Enter
uv --versionMac: ⌘ + Space를 누르고 Terminal 입력 후 Enter
Windows: 시작 메뉴를 열고 Windows PowerShell 입력 후 "열기"
아직 설치하지 않았다면: uv에는 클릭형 설치 파일이 없습니다. uv 공식 페이지에서 내 시스템(macOS 또는 Windows)용 한 줄 명령을 복사해 터미널에 붙여 넣으세요 · Python을 따로 설치할 필요 없이 uv가 필요할 때 자동으로 내려받습니다
설치가 끝나면 터미널을 닫았다가 다시 열고 같은 명령을 실행하세요. 버전 번호가 나와야 합니다: uv --version
한 번 설치하면 uv가 필요한 모든 도구에서 쓸 수 있습니다
SettingsDeveloperEdit Config
{
"mcpServers": {
"presidio-hardened-x402": {
"command": "uvx",
"args": [
"presidio-hardened-x402-mcp"
]
}
}
}Presidio Hardened X402 MCP을 써서 나에게 무엇을 해 줄 수 있는지 알려 주고, 하나 해 봐✓ Claude가 Presidio Hardened X402 MCP을 쓰고 있다고 하거나 답에 Presidio Hardened X402 MCP 도구 이름이 나오면 연결된 거예요
메뉴 이름은 2026년 11월 11일에 Anthropic 도움말에서 확인 · 앱 버전에 따라 화면이 조금 다를 수 있어요
ChatGPT는 아직 Presidio Hardened X402 MCP에 연결할 수 없어요
Presidio Hardened X402 MCP는 내 컴퓨터에 설치해서 쓰지만 ChatGPT는 웹에서 도는 서버만 연결할 수 있어요
A · Presidio Hardened X402 MCP에 연결되는 앱 쓰기
B · 온라인 쇼핑몰 및 결제에서 ChatGPT에 연결되는 다른 서버
같은 분류에서 많이 쓰는 것 중 키 없이 주소만으로 연결되는 것을 골랐어요
Claude Code에 연결할 수 있지만 먼저 준비가 필요해요
먼저 컴퓨터에 Python (uv)를 설치하세요 (한 번만)
이 메시지를 Claude Code 채팅에 붙여 넣으세요. AI가 컴퓨터를 확인하고 어떤 파일을 바꿀지 알려 준 뒤 매번 동의를 기다립니다.
이 컴퓨터의 Claude Code에 MCP server Presidio Hardened X402 MCP을 설치해 주세요. 순서대로: 1) uv --version로 uv가 있는지 확인. 없으면 https://docs.astral.sh/uv/getting-started/installation/에서 설치하라고 알려 주고 직접 설치하지 마세요. 2) 이 설정만 사용하세요(PopNx MCP 확인 완료): claude mcp add --scope user presidio-hardened-x402 -- uvx presidio-hardened-x402-mcp 3) 바꿀 파일의 전체 경로나 실행할 명령을 알려 주고 제 동의를 기다리세요. 4) 키는 필요 없습니다. 5) 합의한 대로 실행한 뒤 Presidio Hardened X402 MCP의 도구가 실제로 보이는지 확인하세요.이 메시지에는 키가 없습니다. 키가 필요하면 AI가 파일이나 앱 입력란에 직접 붙여 넣으라고 안내합니다.
이미 설치했나요? 먼저 확인 · 터미널을 열고 이 명령을 입력한 뒤 Enter
uv --versionMac: ⌘ + Space를 누르고 Terminal 입력 후 Enter
Windows: 시작 메뉴를 열고 Windows PowerShell 입력 후 "열기"
아직 설치하지 않았다면: uv에는 클릭형 설치 파일이 없습니다. uv 공식 페이지에서 내 시스템(macOS 또는 Windows)용 한 줄 명령을 복사해 터미널에 붙여 넣으세요 · Python을 따로 설치할 필요 없이 uv가 필요할 때 자동으로 내려받습니다
설치가 끝나면 터미널을 닫았다가 다시 열고 같은 명령을 실행하세요. 버전 번호가 나와야 합니다: uv --version
한 번 설치하면 uv가 필요한 모든 도구에서 쓸 수 있습니다
Mac: Command+스페이스를 누르고 Terminal 입력 · Windows: PowerShell 열기
claude mcp add --scope user presidio-hardened-x402 -- uvx presidio-hardened-x402-mcpPresidio Hardened X402 MCP이 목록에 있고 연결됨으로 보이면 돼요
Presidio Hardened X402 MCP을 써서 나에게 무엇을 해 줄 수 있는지 알려 주고, 하나 해 봐✓ Claude Code가 Presidio Hardened X402 MCP을 쓰고 있다고 하거나 답에 Presidio Hardened X402 MCP 도구 이름이 나오면 연결된 거예요
메뉴 이름은 2026년 11월 11일에 Anthropic 도움말에서 확인 · 앱 버전에 따라 화면이 조금 다를 수 있어요
Cursor에 연결할 수 있지만 먼저 준비가 필요해요
먼저 컴퓨터에 Python (uv)를 설치하세요 (한 번만)
이 메시지를 Cursor 채팅에 붙여 넣으세요. AI가 컴퓨터를 확인하고 어떤 파일을 바꿀지 알려 준 뒤 매번 동의를 기다립니다.
이 컴퓨터의 Cursor에 MCP server Presidio Hardened X402 MCP을 설치해 주세요. 순서대로: 1) uv --version로 uv가 있는지 확인. 없으면 https://docs.astral.sh/uv/getting-started/installation/에서 설치하라고 알려 주고 직접 설치하지 마세요. 2) 이 설정만 사용하세요(PopNx MCP 확인 완료): { "mcpServers": { "presidio-hardened-x402": { "command": "uvx", "args": [ "presidio-hardened-x402-mcp" ] } } } 3) 바꿀 파일의 전체 경로나 실행할 명령을 알려 주고 제 동의를 기다리세요. 4) 키는 필요 없습니다. 5) 합의한 대로 실행한 뒤 Presidio Hardened X402 MCP의 도구가 실제로 보이는지 확인하세요.이 메시지에는 키가 없습니다. 키가 필요하면 AI가 파일이나 앱 입력란에 직접 붙여 넣으라고 안내합니다.
이미 설치했나요? 먼저 확인 · 터미널을 열고 이 명령을 입력한 뒤 Enter
uv --versionMac: ⌘ + Space를 누르고 Terminal 입력 후 Enter
Windows: 시작 메뉴를 열고 Windows PowerShell 입력 후 "열기"
아직 설치하지 않았다면: uv에는 클릭형 설치 파일이 없습니다. uv 공식 페이지에서 내 시스템(macOS 또는 Windows)용 한 줄 명령을 복사해 터미널에 붙여 넣으세요 · Python을 따로 설치할 필요 없이 uv가 필요할 때 자동으로 내려받습니다
설치가 끝나면 터미널을 닫았다가 다시 열고 같은 명령을 실행하세요. 버전 번호가 나와야 합니다: uv --version
한 번 설치하면 uv가 필요한 모든 도구에서 쓸 수 있습니다
Presidio Hardened X402 MCP을 써서 나에게 무엇을 해 줄 수 있는지 알려 주고, 하나 해 봐✓ Cursor가 Presidio Hardened X402 MCP을 쓰고 있다고 하거나 답에 Presidio Hardened X402 MCP 도구 이름이 나오면 연결된 거예요
메뉴 이름은 2026년 11월 11일에 Cursor 도움말에서 확인 · 앱 버전에 따라 화면이 조금 다를 수 있어요
VS Code에 연결할 수 있지만 먼저 준비가 필요해요
먼저 컴퓨터에 Python (uv)를 설치하세요 (한 번만)
이 메시지를 VS Code 채팅에 붙여 넣으세요. AI가 컴퓨터를 확인하고 어떤 파일을 바꿀지 알려 준 뒤 매번 동의를 기다립니다.
이 컴퓨터의 VS Code에 MCP server Presidio Hardened X402 MCP을 설치해 주세요. 순서대로: 1) uv --version로 uv가 있는지 확인. 없으면 https://docs.astral.sh/uv/getting-started/installation/에서 설치하라고 알려 주고 직접 설치하지 마세요. 2) 이 설정만 사용하세요(PopNx MCP 확인 완료): { "servers": { "presidio-hardened-x402": { "type": "stdio", "command": "uvx", "args": [ "presidio-hardened-x402-mcp" ] } } } 3) 바꿀 파일의 전체 경로나 실행할 명령을 알려 주고 제 동의를 기다리세요. 4) 키는 필요 없습니다. 5) 합의한 대로 실행한 뒤 Presidio Hardened X402 MCP의 도구가 실제로 보이는지 확인하세요.이 메시지에는 키가 없습니다. 키가 필요하면 AI가 파일이나 앱 입력란에 직접 붙여 넣으라고 안내합니다.
이미 설치했나요? 먼저 확인 · 터미널을 열고 이 명령을 입력한 뒤 Enter
uv --versionMac: ⌘ + Space를 누르고 Terminal 입력 후 Enter
Windows: 시작 메뉴를 열고 Windows PowerShell 입력 후 "열기"
아직 설치하지 않았다면: uv에는 클릭형 설치 파일이 없습니다. uv 공식 페이지에서 내 시스템(macOS 또는 Windows)용 한 줄 명령을 복사해 터미널에 붙여 넣으세요 · Python을 따로 설치할 필요 없이 uv가 필요할 때 자동으로 내려받습니다
설치가 끝나면 터미널을 닫았다가 다시 열고 같은 명령을 실행하세요. 버전 번호가 나와야 합니다: uv --version
한 번 설치하면 uv가 필요한 모든 도구에서 쓸 수 있습니다
Presidio Hardened X402 MCP을 써서 나에게 무엇을 해 줄 수 있는지 알려 주고, 하나 해 봐✓ VS Code가 Presidio Hardened X402 MCP을 쓰고 있다고 하거나 답에 Presidio Hardened X402 MCP 도구 이름이 나오면 연결된 거예요
메뉴 이름은 2026년 11월 11일에 VS Code 도움말에서 확인 · 앱 버전에 따라 화면이 조금 다를 수 있어요
Windsurf, Zed, Gemini CLI 같은 다른 MCP 앱은 추가 방법이 저마다 달라요. 앱 목록에서 확인하세요
JSON 설정은 아래 “개발자용”에 있어요
Claude Code
claude mcp add --scope user presidio-hardened-x402 -- uvx presidio-hardened-x402-mcpClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"presidio-hardened-x402": {
"command": "uvx",
"args": [
"presidio-hardened-x402-mcp"
]
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"presidio-hardened-x402": {
"command": "uvx",
"args": [
"presidio-hardened-x402-mcp"
]
}
}
}VS Code (mcp.json)
{
"servers": {
"presidio-hardened-x402": {
"type": "stdio",
"command": "uvx",
"args": [
"presidio-hardened-x402-mcp"
]
}
}
}이 설정은 제작자의 레지스트리 정보로 만들었어요. README와 다르면 README를 따르세요.
이 서버의 연결 방식과 각 앱의 공식 문서를 바탕으로 했어요. 2026년 11월 10일 확인.
내 컴퓨터에서 실행하는 앱
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
내 컴퓨터에서 실행돼요. 설치하면 AI 앱에 도구 목록이 나타나요.
누구나 볼 수 있는 정보를 점검했고, 코드는 읽지 않았어요. 해당하지 않는 항목은 개수에서 뺐어요. · 2026년 11월 20일 점검
레지스트리 이름이 GitHub 계정 presidio-v 기준으로 확인되었고, 이 계정이 저장소를 소유하고 있어요
아직 GitHub에서 이 저장소를 읽어 오지 않았어요
아직 GitHub에서 이 저장소를 읽어 오지 않았어요
내 컴퓨터에서 실행되는 서버라 인터넷 엔드포인트가 없어요
내 컴퓨터에서 실행되며, 대신 로컬 설정을 사용해요
내 컴퓨터에서 실행돼요. 도구 목록은 인터넷 엔드포인트가 있는 서버에서만 읽을 수 있어요
OSV.dev에 presidio-hardened-x402-mcp@0.4.0 항목이 없습니다
이 버전의 패키지 자체만 확인하며 모든 의존성은 아닙니다 · 확인 2026년 11월 15일
제작자라면 이 코드를 README에 붙여 넣으세요. 배지는 이 페이지로 연결됩니다.
[](https://mcp.popnx.com/en/servers/presidio-v-presidio-hardened-x402-mcp)질문하고, 팁을 나누고, 안 되는 점을 알려 주세요. "도움이 됨"이 많은 순서예요.
아직 리뷰가 없어요
레지스트리에서 이 카테고리의 활성 서버 전체와 비교했어요. 스타는 게시자가 저장소를 소유한 경우에만 세요.
해당하는 기본 점검 1개 중 1개를 통과했어요. 코드는 읽지 않았어요. 키나 토큰을 넣기 전에 서버가 어떤 권한을 요구하는지 확인하고, 꼭 필요한 권한만 있는 키를 쓰세요.
레지스트리에 필수 키가 나와 있지 않아요. 다만 처음 쓸 때 로그인을 요구하는 서버도 있어요.
내 컴퓨터에서 실행돼요. AI 앱이 필요할 때 실행하고, 데이터는 제작자의 서버를 거치지 않아요(서버 자체가 온라인 서비스를 호출하는 경우는 제외).
GitHub 저장소는 마지막으로 – 변경됐고, 최신 버전(0.4.0)은 12일 전 레지스트리에 올라왔어요.
Claude Desktop, Claude Code, Cursor, VS Code처럼 MCP를 지원하는 앱에서 쓸 수 있어요. 내 컴퓨터에 Python (uv)도 있어야 해요.
같은 카테고리에는: Stripe MCP, flightclaw, Trade It, Marketplace Ad Pros: Amazon Ads & Seller Central, idealo MCP Server
같은 카테고리, 다른 제작자, 명령 확인 완료. 공식이 먼저, 그다음 스타 순.
카드 보는 법:↓ 주간 다운로드i★ GitHub 스타i세 기둥: 리뷰 · 점검 · 사용 정도i업데이트 = 최신 버전을 레지스트리에 공개한 날i
MCP server integrating with Stripe - tools for customers, products, payments, and more.
Search ~300 airlines and book flights with a checkout link. OAuth sign-in by email code.
Connect brokerage accounts to AI assistants: holdings, orders, asset lookup, and approved trading.
Amazon Ads, Seller Central, Vendor Central and AMC data for AI agents. Read-only by default.
Search products, compare prices and discover deals across 6 European markets with your AI assistant.
| 이 항목 Presidio Hardened X402 MCP | Stripe MCP | flightclaw | Trade It | Marketplace Ad Pros: Amazon Ads & Seller Central | idealo MCP Server | |
|---|---|---|---|---|---|---|
| 실행 위치 | 컴퓨터에 설치 필요 | 클라우드에서 동작, 설치 불필요 | 클라우드에서 동작, 설치 불필요 | 클라우드에서 동작, 설치 불필요 | 클라우드에서 동작, 설치 불필요 | 클라우드에서 동작, 설치 불필요 |
| 키 필요 | 아니요 | 아니요 | 아니요 | 아니요 | 아니요 | 아니요 |
| Claude에서 +로 추가 | 아니요 | 예 | 아니요 | 아니요 | 아니요 | 아니요 |
| 기본 점검 | 1/1 | 4/4 | 4/4 | 5/5 | 4/4 | 4/4 |
| 라이선스 | – | MIT | MIT | CC0-1.0 | MIT | MIT |
| 가격 | 등록 정보에 비용 없음 | 등록 정보에 비용 없음 | 등록 정보에 비용 없음 | 등록 정보에 비용 없음 | 등록 정보에 비용 없음 | 등록 정보에 비용 없음 |
제작자의 저장소에서 쓰인 그대로 가져왔어요. PopNx MCP가 검토하거나 보증한 내용이 아니에요. HTML, 이미지, 스크립트는 제거했어요. 링크를 누르면 이 사이트를 벗어나요.
Pre-payment safety gate for x402 — agents call screen_payment_metadata(...), check_payment_policy(...), and check_payment_replay(...) before signing, catching PII, budget overruns, and duplicate payments before metadata or money leaves the agent host.
Part of the presidio-hardened-* toolkit family. Thin MCP (Model Context Protocol) adapter over the presidio-hardened-x402 library, pinned to parent 0.14.x (presidio-hardened-x402>=0.14.0,<0.15.0), the parent's Python 3.11 line. 0.13.0 was the first parent that can record a control as NOT_EVALUATED, which signed decision evidence needs; it also includes the 0.11.1 fix for the percent-encoded PII redaction bypass, which remains a security floor.
x402 agentic payments routinely carry user-supplied free text — descriptions, memos, query-string parameters — straight through to merchants and facilitators. When an LLM agent generates that text, it can include PII the user never intended to share. Once the merchant logs it, retention is their decision, not yours.
This MCP server gives agents a small default-deny gate *before* payment leaves the agent host. Three tools expose the parent library's stable pre-payment controls: PII redaction, spending policy, and replay detection. Since 0.3.0 each decision can also be emitted as a signed payment-decision@1 record that a third party verifies offline (see Signed decision evidence). The tools are designed to compose with payment-execution and endpoint-safety MCP servers (x402station, Coinbase x402, Sardis, ...), while other parent-library surfaces — evidence-ref@1 verification of inbound evidence, the v0.9.1 SLO broker, the v0.10.0 settlement-ref@1 treasury binding, and the v0.11.0 CapabilityEnforcer — stay in the Python library unless an MCP tool explicitly wraps them later.
Requires Python ≥ 3.11. Distributed on PyPI; recommended invocation via uvx (no global install).
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or the equivalent on your platform:
{
"mcpServers": { "presidio-x402": { "command": "uvx", "args": ["presidio-hardened-x402-mcp"] } } }
Same shape — every MCP host accepts command / args / env. See your editor's MCP-server docs for the config-file path.
All optional. Defaults give a zero-config in-process mode with no quota, no network, and no PII storage.
| Variable | Purpose | Default |
|---|---|---|
PRESIDIO_X402_MCP_MODE | regex (zero-setup) or nlp (needs [nlp] extra + a spaCy model) | regex |
PRESIDIO_X402_MCP_MAX_PER_CALL_USD | Max USD per single payment (policy gate) | unset → no limit |
PRESIDIO_X402_MCP_DAILY_LIMIT_USD | Max USD per rolling window (policy gate) | unset → no limit |
PRESIDIO_X402_MCP_PER_ENDPOINT_JSON | Per-endpoint cap, e.g. '{"api.foo.com": 5.00}' | unset |
PRESIDIO_X402_MCP_WINDOW_SECONDS | Rolling window for the daily limit | 86400 |
PRESIDIO_X402_MCP_AGENT_ID | Label written into audit records | unset |
PRESIDIO_X402_MCP_REPLAY_TTL | Fingerprint cache TTL (seconds) | 300 |
PRESIDIO_X402_MCP_REDIS_URL | Use Redis for replay state instead of in-memory | unset |
PRESIDIO_X402_MCP_AUDIT_PATH | Append-only JSON-L audit log path; omit to disable | unset |
PRESIDIO_X402_MCP_LOG_LEVEL | DEBUG / INFO / WARNING / ERROR | INFO |
PRESIDIO_X402_MCP_REMOTE_BASE_URL | Enable HTTP-proxy mode for tool 1 — see Modes. Must be https://; plain http:// is accepted only for loopback and otherwise refuses to start | unset |
PRESIDIO_X402_MCP_REMOTE_API_KEY | API key for the remote screening service | unset |
PRESIDIO_X402_FINGERPRINT_KEY | 32-byte hex key for cross-process replay detection | unset (per-process) |
PRESIDIO_X402_CHAIN_KEY | 32-byte hex key for cross-process audit-chain HMAC | unset (per-process) |
PRESIDIO_X402_REQUIRE_FINGERPRINT_KEY | Fail startup if replay key is absent or invalid | unset |
PRESIDIO_X402_REQUIRE_CHAIN_KEY | Fail startup if audit-chain key is absent or invalid | unset |
PRESIDIO_X402_MCP_EVIDENCE_KEY_FILE | File holding the decision-signing key (preferred; wins over the env key) | unset |
PRESIDIO_X402_EVIDENCE_KEY | Decision-signing key (the parent library's variable): Ed25519 private key as 64 hex chars, or an HMAC secret | unset |
PRESIDIO_X402_MCP_DECISION_PATH | Append-only JSON-L file for signed payment-decision@1 records | unset |
PRESIDIO_X402_MCP_EVIDENCE_ALGORITHM | ed25519 or hmac-sha256 | ed25519 |
PRESIDIO_X402_MCP_EVIDENCE_SIGNER | Signer identity; the trust-store key verifiers look up | presidio-hardened-x402-mcp |
PRESIDIO_X402_MCP_EVIDENCE_KEY_ID | Optional key id written into each record (for rotation) | unset |
PRESIDIO_X402_MCP_REQUIRE_EVIDENCE_KEY | Fail startup unless signed evidence is fully configured and the key signs | unset |
PRESIDIO_X402_MCP_GATE_CERTIFICATE | ikigov-assess gate-certificate@1 file(s) the payments are authorised under, os.pathsep-separated; needs the [gate] extra | unset |
PRESIDIO_X402_MCP_GATE_TRUST | Trust store for the certificate issuer (and its embedded evidence signers); required with the above | unset |
Generate cross-process keys with openssl rand -hex 32.
screen_payment_metadata(resource_url, description, reason, entities?)Detects and redacts PII in payment metadata. No side effects — safe to call repeatedly.
// Input
{ "resource_url": "https://api.foo.com/u/jane@example.com", "description": "monthly fee for jane@example.com", "reason": "" }
// Output { "redacted_resource_url": "https://api.foo.com/u/ ", "redacted_description": "monthly fee for ", "redacted_reason": "", "entities_found": [ { "entity_type": "EMAIL_ADDRESS", "field": "resource_url", "count": 1 }, { "entity_type": "EMAIL_ADDRESS", "field": "description", "count": 1 } ], "mode": "in_process" // + "decision_ref": "<64 hex>" when signed decision evidence is enabled }
entities (optional list of Presidio entity types) narrows detection to a whitelist. Field-length caps mirror the screening-api wire contract that remains stable through parent 0.7.x: resource_url ≤ 2048, description ≤ 4096, reason ≤ 4096 characters. Oversized inputs raise ValueError.
check_payment_policy(resource_url, amount_usd, prior_decision_refs?)Spending-policy gate. Records the spend on success — call exactly once, immediately before payment. Skipping the actual payment after a successful check inflates the daily-limit ledger until the window rolls over.
The URL is screened first and only the redacted URL reaches the policy engine, so no raw URL lands in the parent's logs. Per-endpoint limits match on that redacted URL; keep PII out of configured endpoint prefixes. If screening fails, the gate denies without recording spend.
// Input
{ "resource_url": "https://api.foo.com/x", "amount_usd": 1.50 }
// Output (allowed) { "allowed": true }
// Output (denied — over per-call limit of $5.00) { "allowed": false, "reason": "...", "limit_usd": 5.00, "amount_usd": 6.00 }
With signed evidence enabled, both outputs also carry decision_ref. prior_decision_refs (optional, up to 8) links refs this server returned earlier for the same payment — typically the one from screen_payment_metadata — into the signed record; a ref this process did not issue is refused before any spend is recorded.
check_payment_replay(resource_url, pay_to, amount, currency, deadline_seconds, prior_decision_refs?)Duplicate-payment gate via HMAC-SHA256 fingerprint of the canonical fields. Records the fingerprint on success — call exactly once, immediately before payment.
amount is a string to preserve precision. Cross-process detection requires PRESIDIO_X402_FINGERPRINT_KEY (and optionally PRESIDIO_X402_MCP_REDIS_URL); otherwise each MCP server process keeps its own in-memory store.
// Input
{ "resource_url": "https://api.foo.com/x", "pay_to": "0xabc...", "amount": "1.50", "currency": "USDC", "deadline_seconds": 1700000000 }
// Output (first seen) { "is_replay": false, "fingerprint": "29aaf60f..." }
// Output (duplicate within TTL) { "is_replay": true, "fingerprint": "29aaf60f..." }
decision_ref and prior_decision_refs behave as for check_payment_policy.
The audit log (PRESIDIO_X402_MCP_AUDIT_PATH) is HMAC-chained: tamper-evident to whoever holds PRESIDIO_X402_CHAIN_KEY, and to nobody else. From 0.3.0 every tool decision — allow and block alike — can also be written as a signed payment-decision@1 record, built and signed by the parent library (build_payment_decision_content, build_decision_evidence) and checked by anyone with the public key (verify_decision_ref). The audit log is still written; the records go alongside it, never instead of it.
# One-time: an Ed25519 key pair for the signer (hex private key, 0600).
python - <<'PY' from cryptography.hazmat.primitives.asymmetric.ed25519 import Ed25519PrivateKey from cryptography.hazmat.primitives.serialization import Encoding, PublicFormat sk = Ed25519PrivateKey.generate() open("evidence.key", "w").write(sk.private_bytes_raw().hex()) print(sk.public_key().public_bytes(Encoding.Raw, PublicFormat.Raw).hex()) # -> trust store PY chmod 600 evidence.key
"env": {
"PRESIDIO_X402_MCP_EVIDENCE_KEY_FILE": "/etc/presidio/evidence.key", "PRESIDIO_X402_MCP_DECISION_PATH": "/var/log/presidio/x402-mcp-decisions.jsonl", "PRESIDIO_X402_MCP_REQUIRE_EVIDENCE_KEY": "1" }
Verify offline with the parent's CLI against a trust store that pins the public key under the signer name:
echo '{"presidio-hardened-x402-mcp": {"alg": "ed25519", "public_key": "<public hex>"}}' > trust.json
python -m presidio_x402.decision_ref /var/log/presidio/x402-mcp-decisions.jsonl trust.json
Without a key the server behaves exactly as 0.2.x — audit log only — and logs one WARNING at startup saying signed evidence is disabled. A key without PRESIDIO_X402_MCP_DECISION_PATH, an unreadable key file, or a key the signer rejects is logged at ERROR and also leaves evidence off. Set PRESIDIO_X402_MCP_REQUIRE_EVIDENCE_KEY=1 to refuse to start in any of those cases instead. Once running, a failed write is logged and the gate's answer stands: a record of a decision nev
앞부분만 보여 드려요. 나머지는 저장소에서 읽어 보세요