Skip to content

cakewinner/agent-smith-10

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Agent Smith 10 — ENS Agent

The Synthesis Hackathon — ENS-powered agent for identity, communication, and discovery.

Uses ENS names for all onchain interactions — no raw addresses in the UX.

Targets

  • ENS Communication ($600) — Send messages and pay by ENS name
  • ENS Identity ($600) — Resolve, verify, and manage agent identity via ENS
  • ENS Open Integration ($300) — Discover agents and capabilities via ENS

Features

  • Identity: Resolve ENS → address, reverse lookup, text records, profile management
  • Communication: Send messages and payments using ENS names only
  • Discovery: Find agents under domains, register subdomains, lookup capabilities

Setup

npm install

Create .env:

ETH_RPC_URL=https://eth.llamarpc.com
# Optional, for sending txs / setting records:
# PRIVATE_KEY=0x...
# AGENT_ENS_NAME=youragent.eth

Run

# Demo with real ENS names (vitalik.eth, nick.eth, etc.)
npm run demo

# Full agent demo
npm start

Project Structure

10-ens-agent/
├── src/
│   ├── ens-identity.ts    # ENS for agent identity
│   ├── ens-communication.ts # ENS for communication
│   ├── ens-discovery.ts   # ENS for agent discovery
│   └── agent.ts           # Main ENSAgent
├── scripts/
│   └── demo.ts            # Resolve real ENS names, show UX
├── package.json
├── tsconfig.json
└── README.md

API Overview

ENSIdentity

  • resolveAddress(ensName) — ENS → address
  • reverseLookup(address) — address → ENS name
  • getTextRecords(ensName) — profile data (avatar, description, url, etc.)
  • setAgentProfile(ensName, records, dryRun) — set identity via text records
  • verifyIdentity(ensName) — verify name ↔ address

ENSCommunication

  • sendMessage(toEns, message, dryRun) — send onchain message by ENS name
  • resolvePaymentTarget(ensName) — resolve payment address
  • payByName(ensName, amount, dryRun) — pay using ENS name

ENSDiscovery

  • discoverAgents(domain) — find agents under a domain
  • registerSubdomain(parentName, label, dryRun) — register agent subdomain
  • lookupAgentCapabilities(ensName) — read capabilities from text records

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors