Your AI agent has a wallet. It can pay for services, sign transactions, and interact with smart contracts. But when someone asks “who are you?”, it answers with 0xCa5A...612dA — a 42-character hex string that means nothing to humans.
That’s not an identity. That’s a serial number.
ENS (Ethereum Name Service) fixes this. It maps human-readable names like maverickbot.eth to Ethereum addresses, giving your agent a real identity on the decentralized web. Other agents, protocols, and humans can find and verify your agent by name instead of a hex string.
In this guide, we’ll walk through the complete process of registering an ENS name for an AI agent using two tools:
- OWS (Open Wallet Standard) — a CLI for managing agent wallets, signing transactions, and making payments
- RobotDomainSearch ENS API — endpoints that handle the ENS registration complexity so your agent doesn’t have to
By the end, you’ll have a fully registered .eth name tied to your agent’s wallet — verified on Ethereum mainnet.
Why Agent Identity Matters
An Ethereum address works fine for sending transactions. But the agentic web needs more than transaction routing — it needs trust.
Consider:
- Discoverability — Other agents can resolve
maverickbot.ethto find your agent’s address, website, or social handles via ENS records - Reputation — A named identity accumulates history.
maverickbot.eththat’s been active for a year means more than a fresh0xaddress - Human readability — When your agent interacts with humans (or their agents),
maverickbot.ethis instantly recognizable - Composability — ENS names work across the entire Ethereum ecosystem: wallets, dApps, protocols, and other agents all resolve them natively
An ENS name is the difference between an anonymous script and a recognized participant in the onchain economy.
Prerequisites
Before starting, you need:
- OWS CLI installed (v1.1.0+)
curl -sSf https://install.openwallet.sh | sh
Verify the installation:
ows --version
# ows 1.1.2
- A funded wallet with ETH on Ethereum mainnet
ENS registration happens on Ethereum L1 (not Base, not any L2). Your wallet needs enough ETH to cover:
- Registration fee (~0.003 ETH / ~$5 for a 1-year registration of a 5+ character name)
- Gas for two transactions (~0.005-0.01 ETH depending on network conditions)
If you don’t have a wallet yet:
ows wallet create --name my-agent
Check your balance:
ows fund balance --wallet my-agent --chain ethereum
- A name you want to register — ENS names must be 3+ characters. Shorter names cost significantly more (3-char = ~$640/yr, 4-char = ~$160/yr, 5+ char = ~$5/yr).
The ENS Registration Flow
ENS uses a commit-reveal scheme to prevent front-running. This means registration requires two separate transactions with a mandatory wait between them:
1. Check availability
2. Prepare commit → get registration ID + transaction data
3. Submit commit transaction (tx 1)
4. Wait 60+ seconds (commitment maturation)
5. Prepare register → get registration transaction data
6. Submit register transaction (tx 2)
7. Verify — your name is live
The RDS ENS API handles all the complexity of interacting with ENS contracts — computing commitments, encoding calldata, estimating gas. OWS handles signing and broadcasting the transactions. Your agent just orchestrates the flow.
Step 1: Check ENS Name Availability
First, do a quick availability check:
curl -s "https://api.robotdomainsearch.com/v1/ens/check?name=maverickbot.eth"
{
"name": "maverickbot.eth",
"available": true,
"responseMs": 140,
"source": "rpc",
"checkedAt": "2026-03-27T18:44:20.747980093Z"
}
If the name is available, get the full registration details — pricing, gas estimates, and timing:
curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/register/check" \
-H "Content-Type: application/json" \
-d '{"name": "maverickbot.eth"}'
{
"name": "maverickbot.eth",
"available": true,
"rent_price": {
"base_wei": "2527164786585680",
"premium_wei": "0",
"total_wei": "2527164786585680",
"total_eth": "0.002527164786585680",
"usd_estimate": 5
},
"gas_estimate": {
"commit_gas": 60000,
"register_gas": 350000,
"gas_price_wei": "193589480"
},
"commit_wait": {
"min_seconds": 60,
"max_seconds": 86400
}
}
This tells you everything you need to know upfront:
- Availability —
truemeans it’s ready to register - Rent price — ~0.0025 ETH (~$5) per year for a 5+ character name
- Gas estimates — Roughly 60K gas for the commit and 350K for the register transaction
- Commit wait — You must wait at least 60 seconds between commit and register (max 24 hours)
If the name is already taken, you’ll get "available": false along with the current owner and resolver information.
Step 2: Prepare the Commit Transaction
The commit step creates a hash of your registration intent — name, owner, and a secret — and submits it to the ENS controller contract. This “locks in” your claim without revealing which name you’re registering (preventing front-running).
curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/register/prepare-commit" \
-H "Content-Type: application/json" \
-d '{
"name": "maverickbot.eth",
"owner": "0xCa5A9008163c22493511f709199D21eCeAC612dA",
"duration_years": 1
}'
The duration_years specifies the registration length — 1 = one year (default).
Response:
{
"registration_id": "a816dabf71231ebd286a8907976663c9",
"name": "maverickbot.eth",
"secret": "0xa0ccb8457ba71b25c0f7e26fa991a4210dbbb0cb43c9075486c962ceecd3c5fd",
"commitment": "0xdd743aa26cd58c39bda0bcdf9e9796b9703d69ea0fc28dbe203265dd86a57deb",
"transaction": {
"to": "0x253553366Da8546fC250F225fe3d25d0C782303b",
"data": "0xf14fcbc8dd743aa26cd58c39bda0bcdf9e9796b9703d69ea0fc28dbe203265dd86a57deb",
"value": "0x0",
"gas_estimate": 53500,
"chain_id": 1
},
"min_wait_seconds": 60,
"max_wait_seconds": 86400
}
Critical: Save the registration_id — you’ll need it for the register step. The API stores the secret and other registration state server-side, keyed by registration_id. The secret is what makes the commit-reveal scheme work; without it, no one can complete the registration.
The transaction object contains everything OWS needs to sign and broadcast: the contract address (to), encoded calldata (data), the value to send (0x0 for commit — no payment yet), and the chain ID (1 = Ethereum mainnet).
Step 3: Submit the Commit Transaction with OWS
Now sign and broadcast the commit transaction using OWS:
ows sign send-tx \
--chain ethereum \
--wallet my-agent \
--tx <hex-encoded-transaction>
The --tx parameter expects the hex-encoded unsigned transaction bytes. You’ll need to RLP-encode the transaction fields from the API response (to, data, value, gas, chainId) into a raw unsigned transaction.
For our actual maverickbot.eth registration, the commit transaction was confirmed on Ethereum mainnet:
Commit tx: 0x6059b42697c62b38b3d43cbd5e2c56901f76df5f4e9c1245d0322239a9aea1b7
You can verify the transaction status via the RDS API:
curl -s "https://api.robotdomainsearch.com/v1/ens/tx/status?hash=0x6059b42697c62b38b3d43cbd5e2c56901f76df5f4e9c1245d0322239a9aea1b7"
{
"tx_hash": "0x6059b42697c62b38b3d43cbd5e2c56901f76df5f4e9c1245d0322239a9aea1b7",
"status": "confirmed",
"block_number": 24749052,
"gas_used": 44206,
"effective_gas_price": "186349733"
}
Step 4: Wait for Commitment Maturation
After the commit transaction confirms, you must wait at least 60 seconds before submitting the register transaction. This is enforced by the ENS contract — attempting to register too early will revert.
echo "Waiting 70 seconds for commitment to mature..."
sleep 70
Why the wait? The commit-reveal scheme needs a gap between the commit (which hides the name) and the reveal (which exposes it). This prevents miners/validators from front-running your registration by seeing the name in the reveal transaction and racing to register it first.
The maximum wait is 24 hours — if you don’t complete the registration within that window, the commitment expires and you’ll need to start over.
Step 5: Prepare the Register Transaction
Now prepare the actual registration transaction. This is the “reveal” step that pairs with your earlier commitment:
curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/register/prepare-register" \
-H "Content-Type: application/json" \
-d '{
"registration_id": "a816dabf71231ebd286a8907976663c9"
}'
Response:
{
"registration_id": "a816dabf71231ebd286a8907976663c9",
"name": "maverickbot.eth",
"transaction": {
"to": "0x253553366Da8546fC250F225fe3d25d0C782303b",
"data": "0x74694a2b...",
"value": "0x9e0498b552858",
"gas_estimate": 350000,
"chain_id": 1
},
"rent_price": {
"base_wei": "2527164786585680",
"premium_wei": "0",
"total_wei": "2527164786585680",
"total_eth": "0.002527164786585680"
},
"value_with_buffer": "2779881265244248"
}
Note that this transaction has a non-zero value — this is the ENS registration fee paid in ETH. The value_with_buffer includes a ~10% buffer above the rent price to account for ETH price fluctuations during the transaction. Any excess is refunded by the contract.
Step 6: Submit the Register Transaction
Sign and broadcast the register transaction:
ows sign send-tx \
--chain ethereum \
--wallet my-agent \
--tx <hex-encoded-transaction>
For maverickbot.eth, the register transaction was confirmed on Ethereum mainnet:
Register tx: 0x2a6f59198e24cff02bae8168c42b61af74a5c7759f32950d900c9145c199039c
curl -s "https://api.robotdomainsearch.com/v1/ens/tx/status?hash=0x2a6f59198e24cff02bae8168c42b61af74a5c7759f32950d900c9145c199039c"
{
"tx_hash": "0x2a6f59198e24cff02bae8168c42b61af74a5c7759f32950d900c9145c199039c",
"status": "confirmed",
"block_number": 24749062,
"gas_used": 348184,
"effective_gas_price": "198549114"
}
Step 7: Verify Your Registration
Confirm the name is registered and pointing to your wallet:
curl -s "https://api.robotdomainsearch.com/v1/ens/metadata?name=maverickbot.eth"
{
"name": "maverickbot.eth",
"owner": "0xCa5A9008163c22493511f709199D21eCeAC612dA",
"resolver": "0x231b0Ee14048e9dCcD1d247744d114a4EB5E8E63",
"records": {
"avatar": "",
"url": "",
"description": "",
"twitter": "",
"github": "",
"email": "",
"contenthash": ""
},
"responseMs": 224,
"source": "rpc",
"checkedAt": "2026-03-27T18:43:22.014865028Z"
}
maverickbot.eth is now registered to 0xCa5A9008163c22493511f709199D21eCeAC612dA. The resolver is set, and the name is live on Ethereum mainnet.
Managing Your ENS Name
Check Expiry
ENS names require annual renewal. Check when yours expires:
curl -s "https://api.robotdomainsearch.com/v1/ens/expiry?name=maverickbot.eth"
{
"name": "maverickbot.eth",
"expires_at": "2027-03-27T13:01:23Z",
"expires_at_unix": 1806152483,
"grace_period_ends": "2027-06-25T13:01:23Z",
"is_expired": false,
"in_grace_period": false,
"renewal_cost": {
"base_wei": "2527164786585680",
"premium_wei": "0",
"total_wei": "2527164786585680",
"total_eth": "0.002527164786585680",
"usd_estimate": 5
}
}
After expiry, there’s a 90-day grace period where only you can renew. After that, the name returns to the open market (with a temporary premium that decays over 21 days).
Prepare Renewal
When it’s time to renew:
curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/renew/prepare" \
-H "Content-Type: application/json" \
-d '{
"name": "maverickbot.eth",
"duration_years": 1
}'
This returns a transaction you can sign with OWS, just like the registration flow — but it’s a single transaction, no commit-reveal needed.
Update ENS Records
ENS records let you attach metadata to your name — a website, social handles, or even a description:
curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/records/prepare-update" \
-H "Content-Type: application/json" \
-d '{
"name": "maverickbot.eth",
"owner": "0xCa5A9008163c22493511f709199D21eCeAC612dA",
"text": {
"url": "https://robotdomainsearch.com",
"description": "Domain intelligence agent by RobotDomainSearch",
"github": "robotdomainsearch"
}
}'
This returns a transaction that updates the ENS resolver with your new records. Sign and broadcast it with ows sign send-tx to make the changes live.
View Current Records
curl -s "https://api.robotdomainsearch.com/v1/ens/records?name=maverickbot.eth"
{
"name": "maverickbot.eth",
"node": "0xfe9801d29b9dbddcc96924d687b27091aa184d8faed927246cac26237a1e3ae2",
"resolver": "0x231b0Ee14048e9dCcD1d247744d114a4EB5E8E63",
"addresses": {},
"text": {}
}
Complete Registration Script
Here’s the full flow as a script your agent can follow:
#!/bin/bash
# ENS Registration Flow — OWS + RDS
# Prerequisites: ows CLI installed, wallet funded with ETH on mainnet
WALLET="my-agent"
NAME="yourname.eth"
OWNER="0xYOUR_WALLET_ADDRESS" # Your agent's Ethereum address
DURATION_YEARS=1
# Step 1: Check availability
echo "Checking availability for $NAME..."
curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/register/check" \
-H "Content-Type: application/json" \
-d "{\"name\":\"$NAME\",\"duration_years\":$DURATION_YEARS}"
# Step 2: Prepare commit
echo "Preparing commit..."
COMMIT_RESPONSE=$(curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/register/prepare-commit" \
-H "Content-Type: application/json" \
-d "{\"name\":\"$NAME\",\"owner\":\"$OWNER\",\"duration_years\":$DURATION_YEARS}")
REGISTRATION_ID=$(echo $COMMIT_RESPONSE | jq -r '.registration_id')
SECRET=$(echo $COMMIT_RESPONSE | jq -r '.secret')
echo "Registration ID: $REGISTRATION_ID"
echo "Secret: $SECRET (save this!)"
# Step 3: RLP-encode and sign the commit transaction
# Extract fields and build the unsigned transaction hex
# (Your agent framework handles the RLP encoding from the JSON fields:
# to, data, value, gas_estimate, chain_id)
COMMIT_TX_HEX=$(build_unsigned_tx "$COMMIT_RESPONSE") # implement per your stack
echo "Signing and broadcasting commit..."
ows sign send-tx --chain ethereum --wallet $WALLET --tx "$COMMIT_TX_HEX"
# Step 4: Wait for maturation
echo "Waiting 70 seconds for commitment to mature..."
sleep 70
# Step 5: Prepare register
echo "Preparing register..."
REGISTER_RESPONSE=$(curl -s -X POST "https://api.robotdomainsearch.com/v1/ens/register/prepare-register" \
-H "Content-Type: application/json" \
-d "{\"registration_id\":\"$REGISTRATION_ID\"}")
# Step 6: RLP-encode and sign the register transaction
REGISTER_TX_HEX=$(build_unsigned_tx "$REGISTER_RESPONSE") # implement per your stack
echo "Signing and broadcasting register..."
ows sign send-tx --chain ethereum --wallet $WALLET --tx "$REGISTER_TX_HEX"
# Step 7: Verify
echo "Verifying registration..."
sleep 15 # Wait for block confirmation
curl -s "https://api.robotdomainsearch.com/v1/ens/metadata?name=$NAME"
echo "Done! $NAME is registered."
Troubleshooting
“Commitment too new” / Transaction Reverts on Register
You didn’t wait long enough after the commit. The ENS contract requires at least 60 seconds between commit and register. Wait a bit longer and retry — your commitment is still valid for 24 hours.
“Commitment expired”
If more than 24 hours pass between your commit and register transactions, the commitment expires. You’ll need to start the flow over from Step 2 (prepare-commit).
“Insufficient funds”
ENS registration requires ETH on Ethereum mainnet (chain ID 1), not on Base or any L2. Check your mainnet balance:
ows fund balance --wallet my-agent --chain ethereum
You need enough for both the registration fee (~0.003 ETH for a 5+ character name) plus gas for two transactions.
“Name already registered”
Someone else registered the name between your check and your commit. Check availability again and try a different name:
curl -s "https://api.robotdomainsearch.com/v1/ens/check?name=yourname.eth"
Transaction Pending for Too Long
Ethereum mainnet gas prices fluctuate. If your transaction is stuck, it may be because gas prices spiked after the estimate was generated. The RDS API provides gas estimates, but during high-congestion periods you may need to retry with a higher gas price.
Nonce Errors
If you’re submitting multiple transactions from the same wallet, ensure the first (commit) transaction confirms before sending the second (register). The RDS /v1/ens/tx/status endpoint lets you poll for confirmation:
curl -s "https://api.robotdomainsearch.com/v1/ens/tx/status?hash=YOUR_TX_HASH"
Wait until "status": "confirmed" before proceeding.
Security Best Practices for Agent Wallets
Running an autonomous wallet that signs Ethereum mainnet transactions requires serious security considerations:
1. Use Spending Policies
OWS supports policies that limit what your agent can do:
ows policy create --file policy.json
Define per-transaction limits, daily spending caps, and allowed contract addresses. This way, even if your agent’s key is compromised, the damage is bounded.
2. Separate Wallets by Purpose
Don’t use your agent’s main operational wallet for ENS registration. Create a dedicated wallet for identity management:
ows wallet create --name ens-identity
Fund it with just enough ETH for registration and renewal. Keep your main operational funds in a separate wallet.
3. Protect the Secret
The secret returned by prepare-commit is critical during registration. If someone obtains your secret and name before you submit the register transaction, they could theoretically front-run your registration. Store it securely and complete the registration promptly.
4. Use API Keys for Agents
For unattended agent access, use OWS API keys instead of raw wallet credentials:
ows key create --wallet my-agent --name "ens-registration-key"
API keys can be scoped and revoked independently, and they don’t expose the wallet’s mnemonic or private key.
5. Monitor Expiry
Set up automated monitoring for your ENS name expiry. A lapsed name means your agent loses its identity — and someone else could register it:
# Check expiry programmatically
curl -s "https://api.robotdomainsearch.com/v1/ens/expiry?name=maverickbot.eth"
Build renewal into your agent’s maintenance cycle. The grace period (90 days after expiry) gives you a buffer, but don’t rely on it.
RDS ENS API Reference
Here’s a quick reference for all the ENS endpoints used in this guide:
| Endpoint | Method | Description |
|---|---|---|
/v1/ens/check |
GET | Check ENS name availability |
/v1/ens/register/check |
POST | Detailed availability check with pricing and gas |
/v1/ens/register/prepare-commit |
POST | Prepare commit transaction |
/v1/ens/register/prepare-register |
POST | Prepare register transaction |
/v1/ens/tx/status |
GET | Check transaction confirmation status |
/v1/ens/metadata |
GET | Get name metadata (owner, resolver, records) |
/v1/ens/records |
GET | Get detailed ENS records |
/v1/ens/records/prepare-update |
POST | Prepare record update transaction |
/v1/ens/expiry |
GET | Check name expiry and renewal cost |
/v1/ens/renew/prepare |
POST | Prepare renewal transaction |
/v1/ens/health |
GET | ENS service health check |
All endpoints are on https://api.robotdomainsearch.com. ENS endpoints are currently free — no x402 payment required.
What’s Next
With your agent’s ENS name registered, you can:
- Set up ENS records — Add a website URL, avatar, social handles, and description to make your agent discoverable
- Use it for payments — Other agents and users can send ETH/tokens to
yourname.ethinstead of a hex address - Build reputation — Start using the name across protocols to build onchain history
- Combine with RDS — Use the RDS domain intelligence API alongside ENS for a complete naming strategy (traditional domains + onchain identity)
Resources
- RDS API Documentation: robotdomainsearch.com/docs
- OWS Documentation: openwallet.sh
- OWS on GitHub: github.com/openwallet-sh
- ENS Documentation: docs.ens.domains
- Etherscan (verify transactions): etherscan.io
ENS names are a small investment — ~$5/year for a 5+ character name — but they transform your agent from an anonymous address into a recognizable identity on the decentralized web. Combined with OWS for wallet management and RDS for the registration API, the entire flow is scriptable, auditable, and ready for autonomous operation.
Register your agent’s .eth name today. Give it a name worth remembering.