Agent Payment Execution (x402)
Let AI agents pay for APIs and services themselves over the x402 protocol, with per-task budgets, spending controls, allowlists, and non-custodial wallets on Base and X Layer.
- What
- Let AI agents pay for APIs and services themselves over the x402 protocol, with per-task budgets, spending controls, allowlists, and non-custodial wallets on Base and X Layer.
- Cost
- Free
- Needs
- Node.js/npm for the MCP server or the @x402 packages; a wallet you control whose keys you can supply through environment variables (start with a testnet wallet); for Option A, install the pinned package first (npm install -g [email protected]) so npx does not hang waiting for a confirmation in non-interactive environments.
- Level
- Intermediate — Node.js/npm for the MCP server or the @x402…
- Install
- Copy the installer prompt below into your Muse — your agent does the rest.
Curated by Skill Harbor: enable AI agents to make policy-gated payments with built-in spending controls, from a community contributor, listed here with credit to its creator. The x402 protocol extends HTTP 402 (Payment Required) into a machine-negotiable flow: when a server returns 402, the agent's payment tool negotiates the price, checks the budget, signs a transaction, and retries only inside the policy and confirmation boundary set by the orchestrator. Every payment tool call enforces a SpendingPolicy: per-task budget, per-session cumulative budget, allowlisted recipients, and rate limits. Agents hold their own keys via ERC-4337 smart accounts; the orchestrator sets policy before delegation, the agent can only spend within bounds, no pooled funds, no custodial risk. Two integration paths: agentwallet-sdk as an MCP payment server on Base (Base Sepolia is the safest development default, Base mainnet the production path), and the OKX Agent Payments Protocol on X Layer for seller-side SDKs in TypeScript, Go, Rust and Java. Pairs naturally with cost-aware pipelines and security review skills. From the affaan-m/ECC repository (MIT). Honest caveats: real money moves here; never run on mainnet without tight budgets and allowlists, start on testnet; always pin package versions because this tool manages private keys and unpinned npx installs introduce supply-chain risk; payment packages and facilitator behavior change quickly, so fetch current SDK docs before generating production code. Skill Harbor never reviews the code, review it yourself before use.
Version:
Quick answer
Agent Payment Execution (x402) is a free Muse skill that lets AI agents pay for APIs and services over the x402 protocol, with per-task budgets, spending controls, allowlists and non-custodial wallets on Base and X Layer. When a server returns HTTP 402, the agent negotiates the price, checks the budget, signs a transaction, and retries only inside the set policy.
Install
Copy the install package below, then paste it into Muse🧪 Install ran in our test sandbox · Nov 11, 2026📌 Pinned version: commit 4eb71d9Pinned version: install the code at commit 4eb71d92a39cab44ad40ac9d8a6a5ccb4029d6c2 exactly (Skill Harbor tested this version). Do not substitute a newer version. If this commit is unreachable, stop and tell me. Use "Agent Payment Execution (x402)" with your Muse. Update notice (October 10, 2026): the upstream SKILL.md was rewritten and nearly tripled in size. It now documents a third integration path — the upstream x402 packages (Option C: Solana and multi-network EVM with facilitator-based settlement, including a hardened PaymentPolicy example) — on top of the agentwallet-sdk (Option A) and OKX Agent Payments (Option B) paths, plus facilitator choices and Solana seller details. This prompt adds a stronger warning block and an integrity check with the current fingerprint, recorded October 10, 2026, and restates the safeguards below. Prerequisites: Node.js/npm for the MCP server or the @x402 packages; a wallet you control whose keys you can supply through environment variables (start with a testnet wallet); for Option A, install the pinned package first (npm install -g [email protected]) so npx does not hang waiting for a confirmation in non-interactive environments. ⚠️ STRONG WARNING — REAL FUNDS, REAL KEYS: this skill gives your agent a non-custodial wallet holding private keys and the ability to spend REAL crypto on its own. Read this before installing: - Private keys go in environment variables ONLY (e.g. WALLET_PRIVATE_KEY, EVM_PRIVATE_KEY, SVM_PRIVATE_KEY) — never paste a private key or seed phrase in chat, and never hardcode one. - TESTNET FIRST: develop on Base Sepolia / Solana devnet with the free x402.org facilitator — it is testnet-only. Mainnet spends real money and requires your own facilitator or a hosted production one. - PIN package versions exactly ([email protected], @x402/[email protected], ...). This tool manages private keys — unpinned npx installs are a supply-chain risk. - Set the spending policy yourself, in the orchestration layer, BEFORE delegating anything: per-task budget, per-session budget, allowlisted recipients, rate limits. The agent must never be able to set or raise its own limits — set_policy is never an agent-callable tool. 1. Open the skill: https://raw.githubusercontent.com/affaan-m/ECC/4eb71d92a39cab44ad40ac9d8a6a5ccb4029d6c2/skills/agent-payment-x402/SKILL.md and copy the full SKILL.md text. 2. Integrity check: compute the SHA-256 of the file you fetched and compare it with the fingerprint recorded by Skill Harbor on October 10, 2026: 07e9231d4bf62a3fbdead8937d707001ddb4e266328fc769950aecae82c3f1a3. If it does not match, STOP — the upstream file has changed again since our review; do not install until it has been re-checked. 3. Paste the SKILL.md into a chat with Muse and add: "Set up x402 payments for my agent on Base Sepolia" or "Wire the OKX Agent Payments seller SDK for [Express/Fastify/Gin/Axum]." 4. Work through the decision tree with Muse: buyer path A (agentwallet-sdk as MCP payment server, Base/multi-chain), path B (OKX Agent Payments Protocol, X Layer — buyer and seller flows), or path C (upstream x402 packages for Solana / multi-network EVM: wrap the agent's HTTP client, a facilitator verifies and settles). Define the SpendingPolicy before the first payment, and require explicit user confirmation before any wallet status check or payment action — never hide a payment behind a generic tool call. Tip: pair it with the security-review skill before going live; a second pair of eyes on spending policy is cheap insurance. Safety: a skill is plain-text instructions; it runs nothing by itself. The safeguards above live in the SKILL.md text and in your orchestration layer — they only protect you if you actually configure them.
Saved to your recent installs. Find it anytime on /connect.
🔒 Security, provenance and what this touches
- It can download and install software packages.
What the scan found — excerpts from the install prompt
- installs packages — Prerequisites: Node.js/npm for the MCP server or the @x402 packages; a wallet you control whose keys you can s · - PIN package versions exactly ([email protected], @x402/[email protected], ...). This tool manages private key · Prérequis : Node.js/npm pour le serveur MCP ou les paquets @x402 ; un portefeuille que vous contrôlez et dont
The install prompt below already includes the vetting steps: your agent follows the community checklist before installing anything with executable code. Want more?
Verification certificate
Dated facts about what was checked for this listing, and how. This is not a safety certification.
- Pinned version
- 4eb71d9 · 2026-10-13
- Sandbox install test
- Install ran in our test sandbox · Nov 11, 2026
- Creator identity
- Not verified
- Fingerprint watch
- Last checked · Nov 21, 2026 : no change detected in the files linked by this install prompt
- Install prompt analysis
- 2026-10-13 : installs packages
Skill Harbor never reviews the code of a listed skill. These are dated facts about the install prompt and our install test, not a safety certification. Review a skill yourself before you install it. How we verify
Questions
How do I install a skill?
Every product page includes a copy-paste install prompt. Paste it into your Muse and it sets the skill up for you — no manual configuration.
Where does my money go?
Straight to the seller. Skill Harbor never processes payments: checkout happens on the seller’s own page, usually Stripe.
What does the ✓ next to a creator’s name mean?
It means we confirmed the identity of the person behind the listing. It says nothing about the code itself — always check a skill before installing it.