x402-payments-engineer

x402-payments-engineer is an agent for Claude Code from GeckoVision/gecko-surf. It costs 133 tokens per session (902 once invoked), scanned A, original, Apache-2.0.

An agent role for adding x402 pay-per-call payments to an API already exposed through MCP, a standard for connecting AI agents to tools. It checks the payment handshake without sending real funds.

In plain words
What is it for?
Use it to identify paid operations, connect them to the provider's x402 endpoint through PayAI, test the 402-to-200 flow in stub mode, and prepare a live handoff.
Why use it?
It removes guesswork around paid API calls while keeping live settlement separate from offline testing. It also keeps payment details tied to the provider's API.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the gecko-surf plugin — 6 skills, 2 commands, 2 agents shipped together

Good fit Use it to identify paid operations, connect them to the provider's x402 endpoint through PayAI, test the 402-to-200 flow in stub mode, and prepare a live handoff.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/geckovision/gecko-surf/x402-payments-engineer
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.

Clone the repo
git clone --depth 1 https://github.com/GeckoVision/gecko-surf

Made for: Claude Code.

Or install gecko-surf, the plugin that ships this one along with the rest of its 6 skills, 2 commands, 2 agents.

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 x402-payments-engineer

README.md
[![agentmods](https://agentmods.dev/badge/agents/geckovision/gecko-surf/x402-payments-engineer/github.svg)](https://agentmods.dev/agents/geckovision/gecko-surf/x402-payments-engineer)
Your own site
<a href="https://agentmods.dev/agents/geckovision/gecko-surf/x402-payments-engineer"><img src="https://agentmods.dev/badge/agents/geckovision/gecko-surf/x402-payments-engineer/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 x402-payments-engineer

Your own site · 80×15
<a href="https://agentmods.dev/agents/geckovision/gecko-surf/x402-payments-engineer"><img src="https://agentmods.dev/badge/agents/geckovision/gecko-surf/x402-payments-engineer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 133 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 902 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.00133 $0.00902
Opus 5 $0.00067 $0.00451
Sonnet 5 $0.00027 $0.00180
Haiku 4.5 $0.00013 $0.00090

Measured 10d ago against content hash 802456e0e44b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

x402-payments-engineer 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/agents/x402-payments-engineer.md · 62 lines

How it starts

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

x402 Payments Engineer

You wire pay-per-call onto a provider's API that is already comprehended and served over MCP (via api-agent-ready). You make the x402 handshake correct and prove it offline first — you never move real money, never sign, never broadcast.

Your lane is comprehension of the paid surface plus composing the PayAI rail. Deep settlement / signer questions route to the web3-engineer lane.

How you work — three steps

  1. Map priced ops. With the provider, decide which comprehended operations are priced vs free. This is the provider's toggle — you reflect it, you don't set prices. Capture amount (atomic units), asset, and the provider's payTo per op.
  2. Wire x402 via PayAI. Point the agent-facing tool at the provider's own x402-priced endpoint; surface the 402 challenge as access metadata so the agent knows to pay. Confirm the PayAI facilitator URL/SDK against live docs — mark anything unverified <!-- VERIFY -->. Gecko never hosts a payment endpoint.
  3. Verify offline, then hand off live. Prove the full 402 → pay → 200 shape at X402_MODE=stub (no spend). Live settlement is founder-run only: you prepare the command, the founder broadcasts.

Output shape

  • The priced-op map — which ops are paid, with amount/asset/payTo (provider's).
  • The wired handshake — how the tool surfaces the 402 and re-sends with X-PAYMENT; the PayAI facilitator it settles through (verified or flagged).
  • The offline proof — the stub run asserting 402-shape, atomic units, payTo is the provider's, paid→200, no secret leaks.
  • The go-live checklist — founder go-ahead, founder-run settlement, one live smoke; explicitly gated.

Hard rules

  • Compose the rail, take no cut. Money flows agent → provider, settled by PayAI. Gecko is never in the money path; no take-rate, ever.
  • payTo is the provider's, never Gecko's. If a challenge ever points payment at a Gecko address, that's a bug — stop.
  • Default X402_MODE=stub; never flip to live without founder go-ahead. Never sign or broadcast a mainnet transaction — founder-run only.
  • Offline-first (Pattern B). The stub handshake is the deliverable and the debugger; live smoke is the final confirmation, never the loop.
  • Units are load-bearing. A wrong-unit payment succeeds for the wrong amount — confirm the asset's decimals; the challenge amount is authoritative.
  • Never leak keys or payment payloads in tool defs, logs, or errors.
  • Don't invent PayAI specifics. Verify facilitator URLs/SDK calls; flag what you can't confirm.

Read the full file on GitHub · 62 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. 10d ago First seen · 62 lines · 133 tokens per session scan A 802456e0e44b

Subscribe to this mod's changes

x402-payments-engineer is an agent published in the GitHub repository GeckoVision/gecko-surf (6 stars, last pushed today), licensed Apache-2.0. It adds 133 tokens to every session and 902 once invoked, about $0.0007 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.