agent-payment-x402

agent-payment-x402 is a skill for Claude Code, Codex from sifxprime/kodelyth-ecc. It costs 47 tokens per session (1,728 once invoked), scanned A, original, MIT.

A skill that lets AI agents pay for external APIs, services, or other agents using the x402 payment protocol. It supports per-task and per-session budgets, recipient allowlists, rate limits, and non-custodial wallets.

In plain words
What is it for?
Use it to execute API payments, purchase services, settle with other agents, and enforce spending policies.
Why use it?
It gives agents controlled ways to pay for services while limiting spending and avoiding a custodial wallet.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions subagents; mentions Claude Code.

Good fit Use it to execute API payments, purchase services, settle with other agents, and enforce spending policies.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/sifxprime/kodelyth-ecc/agent-payment-x402
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add sifxprime/kodelyth-ecc --skill agent-payment-x402
Clone the repo
git clone --depth 1 https://github.com/sifxprime/kodelyth-ecc

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for agent-payment-x402

README.md
[![agentmods](https://agentmods.dev/badge/skills/sifxprime/kodelyth-ecc/agent-payment-x402.svg)](https://agentmods.dev/skills/sifxprime/kodelyth-ecc/agent-payment-x402)
Your own site
<a href="https://agentmods.dev/skills/sifxprime/kodelyth-ecc/agent-payment-x402"><img src="https://agentmods.dev/badge/skills/sifxprime/kodelyth-ecc/agent-payment-x402.svg" alt="Measured on agentmods" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,728 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00047 $0.01728
Opus 5 $0.00023 $0.00864
Sonnet 5 $0.00009 $0.00346
Haiku 4.5 $0.00005 $0.00173

Measured 4d ago against content hash 1477c93f4a9d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

agent-payment-x402 scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

skills/agent-payment-x402/SKILL.md · 179 lines

How it starts

The opening of the file, as written. The whole thing — 179 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Agent Payment Execution (x402)

Enable AI agents to make autonomous payments with built-in spending controls. Uses the x402 HTTP payment protocol and MCP tools so agents can pay for external services, APIs, or other agents without custodial risk.

When to Use

Use when: your agent needs to pay for an API call, purchase a service, settle with another agent, enforce per-task spending limits, or manage a non-custodial wallet. Pairs naturally with cost-aware-llm-pipeline and security-review skills.

How It Works

x402 Protocol

x402 extends HTTP 402 (Payment Required) into a machine-negotiable flow. When a server returns 402, the agent's payment tool automatically negotiates price, checks budget, signs a transaction, and retries — no human in the loop.

Spending Controls

Every payment tool call enforces a SpendingPolicy:

  • Per-task budget — max spend for a single agent action
  • Per-session budget — cumulative limit across an entire session
  • Allowlisted recipients — restrict which addresses/services the agent can pay
  • Rate limits — max transactions per minute/hour

Non-Custodial Wallets

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.

MCP Integration

The payment layer exposes standard MCP tools that slot into any Claude Code or agent harness setup.

Security note: Always pin the package version. This tool manages private keys — unpinned npx installs introduce supply-chain risk.

{
  "mcpServers": {
    "agentpay": {
      "command": "npx",
      "args": ["[email protected]"]
    }
  }
}

Available Tools (agent-callable)

Tool Purpose
get_balance Check agent wallet balance
send_payment Send payment to address or ENS
check_spending Query remaining budget
list_transactions Audit trail of all payments

Note: Spending policy is set by the orchestrator before delegating to the agent — not by the agent itself. This prevents agents from escalating their own spending limits. Configure policy via set_policy in your orchestration layer or pre-task hook, never as an agent-callable tool.

Read the full file on GitHub · 179 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 179 lines · 47 tokens per session scan A 1477c93f4a9d

Subscribe to this mod's changes

agent-payment-x402 is a skill published in the GitHub repository sifxprime/kodelyth-ecc (11 stars, last pushed yesterday), licensed MIT. It adds 47 tokens to every session and 1,728 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.