Not writing code? You can add these records in the Celonames app. See Set ERC-8004 agent records.
How the pieces fit
Celonames are ENS subnames of
celo.eth. Their records are stored on Celo in the CeloNames Registry, which is also the resolver for every *.celo.eth name. You write records with a Celo transaction. Apps on Ethereum read them through the ENS universal resolver, which follows the celo.eth L1 resolver and its CCIP-Read gateway back to Celo.
Contracts
ERC-8004 registries
Celonames (Celo mainnet)
See Deployment Addresses for the full list.
ENSIP-25: the agent-registration record
ENSIP-25 defines one parameterized text record key:<registry>is the registry contract encoded as an ERC-7930 interoperable address: a hex string that carries both the chain and the contract address.<agentId>is the agent’s ID in that registry.
1. Verifiers only check that it is non-empty.
Encode the registry address
For EVM chains, ERC-7930 concatenates these fields:
That gives these values:
So the record key for Celo agent
42 is:
agent-keys.ts.
agent-keys.ts
ENSIP-26: agent-context and agent-endpoint records
ENSIP-26 adds two keys for discovery:
A client resolving an agent reads
agent-context first. If it’s missing, the name publishes no agent context. Endpoint values must be valid URLs, and ipfs:// URIs are allowed.
Build an agent identity on Celo
The examples use viem and a private key inPRIVATE_KEY. Install viem with npm install viem.
1
Register a Celoname
Register The registrar prices names like this:
myagent.celo.eth with the L2Registrar. Skip this step if you already own a name. You can also register in the Celonames app.register-name.ts
- Prices are set in US cents per year, by label length. On Nov 27 2026 the registrar returned $400 for 3 characters, $160 for 4, $50 for 5, $5 for 6 to 9, and $1 for 10 or more. The registrar owner can change these tiers, so always read
rentPricebefore you register. rentPrice(label, durationInYears, paymentToken)returns the amount in the payment token’s smallest unit. PasszeroAddressfor CELO (wei, 18 decimals). The registrar converts USD to CELO with a CELO/USD price feed, so the CELO amount moves with the market. For USDC, USDT or cUSD it returns the USD amount in that token’s decimals, for example5000000for $5 in USDC.durationInYearsis a whole number of years, from 1 to 10,000. One year is 31,536,000 seconds.- Labels must be at least 3 characters.
availablereturnsfalsefor labels that are taken, too short or too long, or blocklisted. - The price already includes any share the registrar forwards to the ENS treasury.
registerERC20 with an EIP-2612 permit. See the integration guide for the permit flow.2
Register the agent in ERC-8004
Create a registration file that follows the ERC-8004 Register first to get the agent ID, then add it to On Celo Sepolia, use
registration-v1 format, and host it on HTTPS or IPFS. List your Celoname as an ENS service so verifiers know which name to check.agent.json
registrations. If you move the file, point the agent at the new location with setAgentURI.register-agent.ts
celoSepolia from viem/chains and the Sepolia Identity Registry address.3
Set the ENSIP-25 and ENSIP-26 records on Celo
Write the records to the CeloNames Registry on Celo. The To set the ENSIP-25 and ENSIP-26 records in one transaction, encode each
node is the ENS namehash of the full name, namehash("myagent.celo.eth"). The registry derives the same node: its root is namehash("celo.eth"). Only the name’s owner, or an operator the owner approved for all their names, can write records.To set one record, call setText:set-agent-record.ts
setText call and send them through multicall. Every call must use the same node.set-agent-records.ts
4
Verify the agent from Ethereum
Any ENS client can now read the records. With viem, ENSIP-25 verification starts from the registry entry. Read the agent’s registration file, take the name from its For a
getEnsText on an Ethereum mainnet client goes through the ENS universal resolver and CCIP-Read, so it works the same for *.celo.eth names and other ENS names.verify-agent.ts
ENS service, and check the record on that name:verify-from-registry.ts
*.celo.eth name you can also read the record straight from Celo, which skips the gateway:Reputation
Clients can leave feedback on an agent in the Reputation Registry and read a summary before they delegate work to it. The agent’s owner and operators can’t give feedback to their own agent.reputation.ts