
Agenticpay
io.github.krystiangw由 GitHub 帳號 krystiangw 發布v0.0.1更新於 Oct 25, 2026
x402 USDC paywall bridge for MCP — pay per tool call on Solana.
發布方自己的服務:Agent Rynku - Warsaw Stock Exchange (GPW) data for your agent
概覽
本機 stdio MCP 橋接器,將依 x402 計費的 HTTP 工具包裝成 MCP 工具,讓助理用設定的 Solana 金鑰對按次以 USDC 付費。
- 可以做什麼
- 把 JSON 設定中定義的付費 HTTP 工具暴露為助理可呼叫的 MCP 工具,每個工具有名稱、描述、URL、輸入 schema,並可為個別工具附加請求標頭。當工具呼叫需要付費時,用設定的 Solana 金鑰對簽署 x402 USDC 付款載荷。透過 x402 facilitator 在 Solana 上完成結算,網路與 RPC 端點由設定指定。僅在付款結算成功後回傳工具結果,因此失敗的呼叫不會扣款。
- 適用情境
- 當你希望助理呼叫按次以 USDC 透過 x402 在 Solana 上收費的 HTTP 工具,並願意為付款錢包充值時使用。它適合在 devnet 上測試或實驗代理微付款,而非正式環境,因為專案自稱 pre-alpha。
- 執行需求
- 以 npm 套件 @agenticpay/mcp-bridge 透過 stdio 在本機執行,需要 Node.js。需要 AGENTICPAY_BRIDGE_KEYPAIR 密鑰(64 位元組 Solana 金鑰對 JSON 陣列)、AGENTICPAY_BRIDGE_TOOLS 中的付費工具定義 JSON 陣列,可選 AGENTICPAY_BRIDGE_NETWORK 與 AGENTICPAY_BRIDGE_RPC。付款錢包需要 USDC,視 facilitator 另需 SOL 支付手續費;需要連線 RPC 與 facilitator 的網路。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Agenticpay,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
agenticpay
[CI] [CodeQL] [gitleaks] [License: MIT] [GitHub stars] [npm: @agenticpay/sdk] [npm downloads]
Website · Spend caps · npm
Get paid by AI agents. Open-source payment infrastructure for the MCP ecosystem - declare a price on any tool, agents pay in USDC over x402, settles on Solana in ~1.5 seconds.
No Stripe. No accounts. No API keys.
The full stack is here - SDK, CLI, paywall middleware, self-hosted x402 facilitator, and a live LLM agent demo. All TypeScript, MIT licensed.
Just want to test it? Point your
mcp-serverat our hosted devnet facilitator:FACILITATOR_URL=https://agentpay-facilitator-e9b20a5fee6a.herokuapp.comNo setup needed.
Live demo
A real Claude Opus agent receives a task, decides which paid tools to use, pays autonomously via x402 micropayments on Solana, and answers the user.
On-chain proof (Solana devnet):
- Settled by our self-hosted facilitator:
EsqzTG8id...Bnku - Earlier settle via x402.org:
2d2HcefgJ...vkqY
Why
The current AI agent stack assumes humans hold the credit card. That breaks the moment agents act on their own initiative - calling APIs, hiring sub-agents, paying for compute. You can't OAuth your way through it.
Stablecoin micropayments over HTTP fix it. agenticpay packages the missing ergonomics for the MCP ecosystem specifically: any tool can declare a price, any agent can pay it, and the whole pipeline - including the facilitator that actually submits the on-chain settlement - is open source and self-hostable.
Architecture
You can also point mcp-server at the public x402.org/facilitator for
testnet/devnet, or at Coinbase CDP for mainnet. We just made the
self-hosted route easy.
Packages
Install
Or clone the monorepo to get the live two-agent demo and edit-friendly templates (recommended for first run - see Quickstart below).
Use with Claude Code
This repo ships an Anthropic Skill
at .claude/skills/agenticpay/SKILL.md. Copy it into your ~/.claude/skills/
to give Claude Code first-class context about agenticpay - it'll then walk you
through monetizing an MCP server, generating tool routes, and verifying
on-chain settlements without re-reading the README every time.
Quickstart (devnet, ~5 minutes, free)
Framework integrations
Drop-in templates for the most common AI agent stacks live under examples/:
See examples/README.md for the integration matrix.
Status
Pre-alpha. Devnet validated end-to-end. Mainnet config supported but requires funding the facilitator with real SOL and pointing at a mainnet-capable RPC (Helius, QuickNode, etc.).
Roadmap
- Devnet end-to-end demo (smoke + LLM agent)
- Self-hosted x402 facilitator (verify + settle, fee_payer abstraction)
- Real-world MCP server template (search, fetch, summarize, extract - instead of toy
reverse_string) - On-chain escrow for long-running tasks (Anchor program)
- Agent reputation registry on-chain
- Hosted facilitator service (
agenticpay.com)
What's a facilitator?
If you've never seen x402 before: the facilitator is the trusted middleman that (1) verifies an agent's signed payment payload, (2) submits the USDC transfer on-chain, and (3) pays the SOL gas fees so the agent doesn't need any SOL - only USDC. Most MCP devs don't want to run their own; they point at a hosted one.
This repo ships a complete facilitator implementation. You can self-host it, fork it, audit it, or deploy it as a service for your own users.
What happens when a paid tool call fails?
Short version: a failed tool call is never charged. x402 settlement is an irreversible push, so the middleware is careful about when it settles:
- Verify before execute. The payment payload (signature, funds, requirements match) is verified before your tool handler runs. Invalid payment → HTTP 402, the tool never executes.
- Execute with a buffered response. The handler runs, but its response is held back - nothing is sent to the agent yet.
- Settle only on success. If the handler responds with status ≥ 400, the middleware skips settlement entirely and just returns the error. The agent pays nothing for a failed call.
- No result without payment. If on-chain settlement itself fails, the buffered tool result is discarded and the agent gets a payment error instead - the server never leaks a result it wasn't paid for.
What this doesn't cover: a tool that returns 200 OK with a junk answer is
still charged - the protocol can't judge response quality. That's what keeps
per-call prices micro ($0.0005–$0.001 in the demo): the worst case is capped
at one call's price, and quality enforcement belongs to a reputation layer
(see Roadmap) rather than the payment protocol.
License
MIT
來源:README.md,提交 9072408
工具
0版本歷史
1- v0.0.1最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分