agent-payment-x402

agent-payment-x402 is a skill for Claude Code, Codex from jxoesneon/Ciel. It costs 28 tokens per session (574 once invoked), scanned A, original, Apache-2.0.

A protocol and set of rules for letting coding agents make payments through x402, a system for paying for HTTP services. It uses preset spending limits, approved recipients, and wallets whose private keys are not given to the agent.

In plain words
What is it for?
Use it to authorize agent payments for individual actions or sessions, check remaining budgets, restrict payment destinations, and fail safely when payment cannot be completed.
Why use it?
It limits how much an agent can spend and prevents it from bypassing a payment requirement when the payment service is unavailable.

Skill for Claude CodeCodex

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

Good fit Use it to authorize agent payments for individual actions or sessions, check remaining budgets, restrict payment destinations, and fail safely when payment cannot be completed.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/jxoesneon/ciel/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 jxoesneon/Ciel --skill agent-payment-x402
Clone the repo
git clone --depth 1 https://github.com/jxoesneon/Ciel

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/jxoesneon/ciel/agent-payment-x402/github.svg)](https://agentmods.dev/skills/jxoesneon/ciel/agent-payment-x402)
Your own site
<a href="https://agentmods.dev/skills/jxoesneon/ciel/agent-payment-x402"><img src="https://agentmods.dev/badge/skills/jxoesneon/ciel/agent-payment-x402/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for agent-payment-x402

Your own site · 80×15
<a href="https://agentmods.dev/skills/jxoesneon/ciel/agent-payment-x402"><img src="https://agentmods.dev/badge/skills/jxoesneon/ciel/agent-payment-x402.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 28 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 574 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.
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.00028 $0.00574
Opus 5 $0.00014 $0.00287
Sonnet 5 $0.00006 $0.00115
Haiku 4.5 $0.00003 $0.00057

Measured 10d ago against content hash 490704aef5db, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, 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 10d 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.

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

What it actually says

CIEL ADAPTATION: Agent Payment Execution (x402)

This skill enables CIEL sub-agents to execute autonomous payments via the x402 HTTP payment protocol. It prioritizes safety through mandatory spending policies and non-custodial wallet management.

Core Mandates

1. Policy-First Delegation

The Orchestrator MUST set a SpendingPolicy before delegating any payment authority to a sub-agent. Sub-agents are prohibited from setting or escalating their own spending limits.

  • Per-Task Budget: Maximum spend for a single atomic action.
  • Per-Session Budget: Cumulative limit for the entire epic.
  • Allowlist: Restricted set of verified recipients or service endpoints.

2. Non-Custodial Security

CIEL agents use non-custodial smart accounts (e.g., ERC-4337). Private keys are managed by the harness, and the sub-agent only has signed permission to spend within the pre-defined policy bounds.

3. Fail-Closed Protocol

If the payment service (x402) is unreachable, the transaction MUST fail. CIEL agents MUST NOT attempt to bypass payment gates or fall back to unmetered access without explicit user authorization.

Workflow

  1. Pre-Check: Query remaining budget (check_spending) before initiating any paid action.
  2. Negotiation: Handle 402 Payment Required responses by negotiating price and checking against the Per-Task Budget.
  3. Execution: Invoke send_payment via the designated MCP tool.
  4. Audit: Log all transactions (list_transactions) to the MemPalace Diary for session auditing.

Anti-Patterns

  • Unlimited Spend: Delegating to an agent without a hard session budget.
  • Self-Escalation: Allowing an agent to modify its own spending policy.
  • Speculative Payment: Sending funds before receiving a verified 402 or invoice.
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. 10d ago First seen · 57 lines · 28 tokens per session scan A 490704aef5db

Subscribe to this mod's changes

agent-payment-x402 is a skill published in the GitHub repository jxoesneon/Ciel (1 stars, last pushed 3d ago), licensed Apache-2.0. It adds 28 tokens to every session and 574 once invoked, about $0.0001 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-08-31.

Related

Other skills, from other repositories

gumroad-support-refund-request

Handle buyer refund requests on Gumroad — standard, subscription, and duplicate-charge cases. Use when a ticket asks for money back, reports a double charge, or a seller is unresponsive to a refund. Decides eligibility, executes, and replies.

antiwork/skills · 57 tokens

api-usage-biller

Usage-based pricing is hard to track. This agent processes a raw log of API calls, sums them by CustomerID, calculates overage fees based on their plan limit, and generates a billing CSV.

akhilkannur/marketing-agent-blueprints · 46 tokens

stock-analyzer

A comprehensive stock deep analysis tool that combines real-time quotes, fundamental metrics, technical indicators, and growth analysis into a single professional report. Supports A-share, US stocks, HK stocks. Generates detailed investment recommendations with risk assessment and actionable trading strategies.

netease-youdao/LobsterAI · 53 tokens

Coinbase Automation

Coinbase Automation: list and manage cryptocurrency wallets, accounts, and portfolio data via Coinbase CDP SDK.

openteams-lab/openteams · 24 tokens

market-research

A guide for conducting market research, including research standards, research modes, and checks on investors or investment funds. The description does not specify its exact outputs or workflow.

TeamWiseFlow/xiaobei · 64 tokens

ticket-spec

Turn a raw Linear Triage ticket into a fully specified ai:agent-ready one by exploring the codebase. Use when specifying, refining, or promoting tickets, or when asked why a ticket isn't dispatchable.

watt-mind/factory · 45 tokens