ENS Registration Agent

Register .eth names via API/MCP · Paid with USDC on Base via x402 · GitHub
(Is it really an agent or is it a service? Or just an MCP?)

// What is this?

An autonomous ENS registration service. Point your agent at this API, pay with USDC on Base via the x402 payment protocol, and get a .eth name registered on Ethereum mainnet. No need to interact with ENS contracts directly — the service handles the two-step commit-reveal process for you.

Registered on-chain as a trustless agent via ERC-8004 on both Ethereum and Base. Identity verified through ens-registration-agent.ses.eth via ENSIP-25. Learn how it’s made →

// For Agents

Two integration paths. Pick what fits your stack.

HTTP + x402

Standard REST API. Payment handled automatically via the x402 protocol — send a request, get a 402 response with payment details, pay on Base (USDC), retry with receipt.

RESTx402USDC

MCP Server

Model Context Protocol server over Streamable HTTP at /mcp. Connect from Claude, Cursor, or any MCP client. Registration tool is paywalled via x402; lookups are free.

MCPHTTPx402

// API Endpoints

GET /api/availability/:name
Check if an ENS name is available. Free
curl /api/availability/example.eth
// {"name":"example.eth","available":true}
GET /api/price/:name
Get registration price in ETH. Optional ?years=1 param. Free
curl /api/price/example.eth?years=1
// {"name":"example.eth","years":1,"totalEth":"0.003..."}
POST /api/register
Register an ENS name.
# First request returns 402 with x402 payment details.
# Pay via x402, then retry with payment receipt header.
curl -X POST /api/register \
  -H "Content-Type: application/json" \
  -d '{"name":"example.eth","owner":"0xYourAddress"}'

# Response on success:
// {"success":true,"name":"example.eth","owner":"0x...",
//  "commitTxHash":"0x...","registerTxHash":"0x..."}
GET /api/health
Health check. Free

// MCP Tools

Connect via Streamable HTTP at /mcp

checkAvailability Free
Check if an ENS name is available for registration.
params: { name: "example.eth" }
getRegistrationPrice Free
Get price for registering an ENS name.
params: { name: "example.eth", years: 1 }
registerName
Register an ENS name (commit-reveal, ~60s). Requires x402 payment.
params: { name: "example.eth", years: 1, owner: "0x..." }

// x402 Payment Flow

The x402 protocol enables machine-to-machine payments. When you hit a paid endpoint, you get a 402 Payment Required response with payment details in the headers. Your agent pays on-chain (USDC on Base), then retries with the payment receipt.

// 1. Agent calls POST /api/register
// 2. Server returns 402 + x402 payment header
// 3. Agent pays $6.00 USDC on Base (chain eip155:8453)
// 4. Agent retries with X-PAYMENT header
// 5. Server verifies payment, registers ENS name

Payment address: 0x6B4D6eaFAE2dC638e991f66825c1eb46f561537f
Network: eip155:8453
Facilitator: https://facilitator.payai.network


// Register a Name

Or just use the form. Humans welcome too.

.eth
⚠ Registration takes ~65 seconds (commit-reveal). Do not close the tab after paying.

Service fee: $6.00 USDC · 5+ characters · 1 year

How it's made · GitHub · @schmidsi · ses.eth