zeruai
Register agents on the Zeru ERC-8004 Identity Registry, manage wallets and metadata, and read on-chain state. Use when an agent needs to register on-chain, check fees, read agent info, set metadata, or manage agent wallets on Base Mainnet or Base Sepolia.
What this skill does
# Zeru ERC-8004 Identity Registry
Register and manage AI agents on the Zeru Identity Registry. Defaults to Base Mainnet (0.0025 ETH fee). Use `--chain 84532` for Base Sepolia testnet.
## One-Time Setup
Run once to install dependencies:
```bash
cd {baseDir} && npm install
```
## Agent JSON Structure (ERC-8004 registration-v1)
When registering an agent, you provide a JSON file describing the agent. The SDK auto-fills `type`, `registrations`, and defaults for `x402Support`/`active`/`image` if omitted.
**Minimal JSON (just name + description + one service):**
```json
{
"name": "My AI Agent",
"description": "A helpful AI agent that does X",
"services": [
{ "name": "web", "endpoint": "https://myagent.example.com" }
]
}
```
**Full JSON (MCP + A2A + OASF + x402 payments):**
```json
{
"name": "DataAnalyst Pro",
"description": "Enterprise-grade blockchain data analysis agent. Performs on-chain forensics, wallet profiling, and transaction pattern detection.",
"image": "https://cdn.example.com/agents/analyst.png",
"services": [
{
"name": "MCP",
"endpoint": "https://api.dataanalyst.ai/mcp",
"version": "2025-06-18",
"mcpTools": ["analyze_wallet", "trace_transactions", "detect_anomalies"],
"capabilities": []
},
{
"name": "A2A",
"endpoint": "https://api.dataanalyst.ai/.well-known/agent-card.json",
"version": "0.3.0",
"a2aSkills": ["analytical_skills/data_analysis/blockchain_analysis"]
},
{
"name": "OASF",
"endpoint": "https://github.com/agntcy/oasf/",
"version": "0.8.0",
"skills": ["analytical_skills/data_analysis/blockchain_analysis"],
"domains": ["technology/blockchain"]
},
{
"name": "web",
"endpoint": "https://dataanalyst.ai"
},
{
"name": "agentWallet",
"endpoint": "eip155:8453:0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb7"
}
],
"x402Support": true,
"active": true,
"supportedTrust": ["reputation", "ERC-8004"]
}
```
**All fields:**
| Field | Type | Required | Default | Description |
|-------|------|----------|---------|-------------|
| `name` | string | Yes | — | Agent name (1–256 chars) |
| `description` | string | Yes | — | What the agent does (max 2048 chars) |
| `image` | string | No | placeholder | Avatar URL (HTTPS, IPFS, or Arweave) |
| `services` | array | Yes | — | Service endpoints (1–64 items, see below) |
| `x402Support` | boolean | No | `false` | Supports x402 payment protocol |
| `active` | boolean | No | `true` | Agent is actively accepting requests |
| `supportedTrust` | string[] | No | — | Trust models: `"reputation"`, `"crypto-economic"`, `"tee-attestation"`, `"ERC-8004"` |
| `owner` | string | No | signer address | Owner 0x address (auto-set from PRIVATE_KEY) |
**Service types:**
| `name` | `endpoint` | Extra fields |
|--------|-----------|--------------|
| `"web"` | Website URL | — |
| `"MCP"` | MCP server URL | `version`, `mcpTools[]`, `mcpPrompts[]`, `mcpResources[]`, `capabilities[]` |
| `"A2A"` | Agent card URL (`/.well-known/agent-card.json`) | `version`, `a2aSkills[]` |
| `"OASF"` | OASF repo URL | `version`, `skills[]`, `domains[]` |
| `"agentWallet"` | CAIP-10 address (`eip155:{chainId}:{address}`) | — |
| `"ENS"` | ENS name (e.g. `myagent.eth`) | — |
| `"email"` | Email address | — |
| custom | Any URL | `description` |
## Commands
### `/zeruai register --json <file>`
Register a new agent using a full JSON file (recommended). Creates hosted agent URI, mints NFT on-chain, and updates URI with the real agentId.
```
/zeruai register --json agent.json
/zeruai register --json agent.json --chain 84532
```
**Steps to register:**
1. Create a JSON file following the structure above (e.g. `agent.json`)
2. Run: `npx tsx {baseDir}/scripts/zeru.ts register --json agent.json`
The SDK automatically adds `type`, `registrations` (with `agentId: 0` placeholder), and defaults for missing optional fields. After minting, it updates the document with the real `agentId`.
### `/zeruai register --name <name> --description <desc> --endpoint <url>`
Simple registration (single API endpoint only). For richer agents, use `--json` instead.
```
/zeruai register --name "Trading Bot" --description "AI-powered trading agent" --endpoint "https://mybot.com/api"
/zeruai register --name "Data Analyzer" --description "Analyzes datasets" --endpoint "https://analyzer.ai/api" --image "https://example.com/icon.png"
/zeruai register --name "Test Bot" --description "Testing" --endpoint "https://test.com" --chain 84532
```
Requires `PRIVATE_KEY` env var. Wallet must have fee + gas (e.g. ~0.003 ETH on mainnet).
To run: `npx tsx {baseDir}/scripts/zeru.ts register --name "..." --description "..." --endpoint "..."`
### `/zeruai read <agentId>`
Read an agent's on-chain data: owner, URI, wallet, name, services.
```
/zeruai read 16
```
To run: `npx tsx {baseDir}/scripts/zeru.ts read 16`
### `/zeruai fee`
Check current registration fee and whether registration is open.
```
/zeruai fee
```
To run: `npx tsx {baseDir}/scripts/zeru.ts fee`
### `/zeruai set-metadata <agentId> --key <key> --value <value>`
Set custom metadata on an agent. Only the owner can call.
```
/zeruai set-metadata 16 --key "category" --value "trading"
```
Requires `PRIVATE_KEY`.
To run: `npx tsx {baseDir}/scripts/zeru.ts set-metadata 16 --key "category" --value "trading"`
### `/zeruai unset-wallet <agentId>`
Clear the agent wallet. Only the owner can call.
```
/zeruai unset-wallet 16
```
Requires `PRIVATE_KEY`.
To run: `npx tsx {baseDir}/scripts/zeru.ts unset-wallet 16`
## Setup
### Read-Only (no setup needed)
`read` and `fee` work without a private key.
### With Wallet (for registration and writes)
Add to your OpenClaw config (`~/.openclaw/openclaw.json`):
```json
{
"skills": {
"entries": {
"zeruai": {
"enabled": true,
"env": {
"PRIVATE_KEY": "0xYourFundedPrivateKey"
}
}
}
}
}
```
Optional env:
- `RPC_URL` — override default RPC
- `CHAIN_ID` — override chain (default: `8453` for Base Mainnet, use `84532` for Base Sepolia)
## Contract Info
### Base Mainnet (default, chainId 8453)
- **Identity Registry:** `0xFfE9395fa761e52DBC077a2e7Fd84f77e8abCc41`
- **Reputation Registry:** `0x187d72a58b3BF4De6432958fc36CE569Fb15C237`
- **Registration Fee:** 0.0025 ETH
- **RPC:** https://mainnet.base.org
### Base Sepolia (testnet, chainId 84532)
- **Identity Registry:** `0xF0682549516A4BA09803cCa55140AfBC4e5ed2E0`
- **Reputation Registry:** `0xaAC7557475023AEB581ECc8bD6886d1742382421`
- **Registration Fee:** 0.001 ETH
- **RPC:** https://sepolia.base.org
- **Source:** `zeru`
## How It Works
1. **register** creates a hosted JSON document (ERC-8004 registration-v1 schema) via the Agent URI API, mints an NFT on the Identity Registry (paying the fee), then updates the document with the real agentId.
2. **read** queries the on-chain contract for owner, tokenURI, and agentWallet, then fetches and parses the URI JSON.
3. **fee** reads the current `registrationFee()` and `registrationEnabled()` from the contract.
4. **set-metadata** calls `setMetadata(agentId, key, value)` on the contract.
5. **unset-wallet** calls `unsetAgentWallet(agentId)` on the contract.
Related in AI Agents
skill-development
IncludedComprehensive meta-skill for creating, managing, validating, auditing, and distributing Claude Code skills and slash commands (unified in v2.1.3+). Provides skill templates, creation workflows, validation patterns, audit checklists, naming conventions, YAML frontmatter guidance, progressive disclosure examples, and best practices lookup. Use when creating new skills, validating existing skills, auditing skill quality, understanding skill architecture, needing skill templates, learning about YAML frontmatter requirements, progressive disclosure patterns, tool restrictions (allowed-tools), skill composition, skill naming conventions, troubleshooting skill activation issues, creating custom slash commands, configuring command frontmatter, using command arguments ($ARGUMENTS, $1, $2), bash execution in commands, file references in commands, command namespacing, plugin commands, MCP slash commands, Skill tool configuration, or deciding between skills vs slash commands. Delegates to docs-management skill for official documentation.
reprompter
IncludedTransform messy prompts into well-structured, effective prompts — single or multi-agent. Use when: "reprompt", "reprompt this", "clean up this prompt", "structure my prompt", rough text needing XML tags and best practices, "reprompter teams", "repromptception", "run with quality", "smart run", "smart agents", multi-agent tasks, audits, parallel work, anything going to agent teams. Don't use when: simple Q&A, pure chat, immediate execution-only tasks. See "Don't Use When" section for details. Outputs: Structured XML/Markdown prompt, quality score (before/after), optional team brief + per-agent sub-prompts, agent team output files. Success criteria: Single mode quality score ≥ 7/10; Repromptception per-agent prompt quality score 8+/10; all required sections present, actionable and specific.
adaptive-compaction
IncludedAdaptive add-on policy and recovery layer that decides WHEN to compact, prune, snapshot, or fork -- replacing fixed-percent auto-compaction across Claude Code, Codex, and MCP-capable hosts. Trigger on auto-compact timing or damage: "when should I compact", "is it safe to compact now or start a fresh session", "auto-compact fires too early/mid-task", "switching to an unrelated task but the window still has space", "context rot", "answers get worse the longer the session runs", "the agent forgot the plan or my decisions after it summarized", "add a layer on top that manages context without changing the agent", raising autoCompactWindow to give the policy room, or installing/tuning a cross-tool compaction policy or PreCompact hook -- even when "compaction" is never said but the problem is context-window pressure or post-summarization memory loss. Do NOT use to summarize a conversation, build RAG, write a summarization prompt (decides WHEN not HOW), or answer max-context-length trivia.
agent-skill-creator
IncludedCreate cross-platform agent skills from workflow descriptions. Activates when users ask to create an agent, automate a repetitive workflow, create a custom skill, or need advanced agent creation. Triggers on phrases like create agent for, automate workflow, create skill for, every day I have to, daily I need to, turn process into agent, need to automate, create a cross-platform skill, validate this skill, export this skill, migrate this skill. Supports single skills, multi-agent suites, transcript processing, template-based creation, interactive configuration, cross-platform export, and spec validation.
llm-wiki
IncludedUse when building or maintaining a persistent personal knowledge base (second brain) in Obsidian where an LLM incrementally ingests sources, updates entity/concept pages, maintains cross-references, and keeps a synthesis current. Triggers include "second brain", "Obsidian wiki", "personal knowledge management", "ingest this paper/article/book", "build a research wiki", "compound knowledge", "Memex", or whenever the user wants knowledge to accumulate across sessions instead of being re-derived by RAG on every query.
skill-master
IncludedAgent Skills authoring, evaluation, and optimization. Create, edit, validate, benchmark, and improve skills following the agentskills.io specification. Use when designing SKILL.md files, structuring skill folders (references, scripts, assets), ingesting external documentation into skills, running trigger evals, benchmarking skill quality, optimizing descriptions, or performing blind A/B comparisons. Keywords: agentskills.io, SKILL.md, skill authoring, eval, benchmark, trigger optimization.