ag402: Skill for Claude Code

.claude/skills/sell/SKILL.md

sell is a skill for Claude Code from AetherCore-Dev/ag402. It costs 47 tokens per session (3,290 once invoked), scanned B, original, MIT.

A workflow for putting an x402 payment gate in front of an existing HTTP API, using USDC payments on Solana.

In plain words
What is it for?
Use it to configure and deploy a gateway that charges compatible agents, command-line tools, or software libraries per request.
Why use it?
It lets an API require payment before forwarding requests to its backend.

Skill for Claude Code

Written for Claude Code: installed under .claude/. Also seen: positional $N argument.

This is AetherCore-Dev/ag402's own configuration. It tells Claude Code how to work on ag402 itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything ag402 configures →

Reuse

Borrowing it

Nothing to install: this file belongs to AetherCore-Dev/ag402. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/AetherCore-Dev/ag402/main/.claude/skills/sell/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/AetherCore-Dev/ag402

Made for: Claude Code.

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 sell

README.md
[![agentmods](https://agentmods.dev/badge/skills/aethercore-dev/ag402/sell/github.svg)](https://agentmods.dev/skills/aethercore-dev/ag402/sell)
Your own site
<a href="https://agentmods.dev/skills/aethercore-dev/ag402/sell"><img src="https://agentmods.dev/badge/skills/aethercore-dev/ag402/sell/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 sell

Your own site · 80×15
<a href="https://agentmods.dev/skills/aethercore-dev/ag402/sell"><img src="https://agentmods.dev/badge/skills/aethercore-dev/ag402/sell.svg" alt="Reviewed on agentmods" width="80" 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 3,290 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 2 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.00047 $0.03290
Opus 5.5 $0.00019 $0.01316
Sonnet 5.5 $0.00009 $0.00658
Haiku 4.5 $0.00005 $0.00329

Measured 2mo ago against content hash 3619f4f2c44a, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

sell scanned grade B with 2 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 2mo 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.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

ssh <user>@<host> "sudo mv /tmp/ag402-gateway.service /etc/systemd/system/ && sudo systemctl daemon-reload && sudo systemctl enable --now ag402-gateway"

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s -o /dev/null -w "%{http_code}" http://127.0.0.1:4020/health
.claude/skills/sell/SKILL.md · 361 lines

How it starts

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

Sell — Turn Any API into a Paid x402 API

Overview

This skill converts an existing HTTP API into a paid API using the x402 payment protocol on Solana (USDC). It configures ag402 as a reverse proxy that returns 402 Payment Required to unauthenticated requests, verifies on-chain USDC payments, and forwards paid requests to the backend.

Result: A gateway URL that any x402-compatible buyer (AI agent, CLI, SDK) can call and pay per-request.

When to Use

  • User says "sell", "monetize", "paywall", "charge for", "paid API", or "payment gateway"
  • User wants to put an API behind x402
  • User wants to deploy ag402 in provider/seller mode
  • User has a running HTTP service and wants to gate it with USDC payments

Step 1: Prerequisites Check (Silent)

Check that ag402 is installed. Run silently — only speak if something is missing.

ag402 --version

If this fails, install it:

pip install ag402-core ag402-mcp

Verify again after install. If it still fails, STOP and tell the user.

Step 2: Gather Information

Treat the user as a beginner who prefers choosing over typing. Present choices, not open-ended questions. Use the defaults aggressively — only ask when truly needed.

Question 1: Backend API

Ask the user to choose:

  • A) I have a running API → ask for the URL (provide http://localhost:8000 as placeholder)
  • B) I don't have an API yet / just want to try it → use http://localhost:8000 (ag402 will auto-start a built-in demo backend)

Most users pick B. Default to B if the user is unsure.

Question 2: Price per call

Present choices (1 USDC ≈ $1):

  • A) $0.001 — micro-task (e.g., a single lookup, translation)
  • B) $0.01 — light task (e.g., search query, short text)
  • C) $0.05 — medium task (e.g., image analysis, long generation)
  • D) Custom — let the user type a number

Default: B ($0.01) if the user doesn't pick.

Question 3: Wallet address

Ask the user to choose:

  • A) I don't have a wallet / just testing → use DemoRecipientWa11et11111111111111111111 + test mode. Tell the user: "No real money involved. You can switch to production later."
  • B) I have a Solana wallet address → ask them to paste it (must be ~32-44 character base58 string)

Read the full file on GitHub · 361 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. 2mo ago First seen · 361 lines · 47 tokens per session scan B 3619f4f2c44a

Subscribe to this mod's changes

sell is a skill published in the GitHub repository AetherCore-Dev/ag402 (9 stars, last pushed 3mo ago), licensed MIT. It adds 47 tokens to every session and 3,290 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it B with 2 findings (asks for root, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.