eigen-skills 1.1.7 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,196 +1,745 @@
1
1
  # eigen-skills
2
2
 
3
- **Deploy any app to EigenCompute TEE hardware-isolated enclaves with encrypted memory, sealed secrets, and cryptographic attestation**
3
+ **EigenLayer Agent SkillsPlug-and-play AI agent capabilities for the entire EigenLayer stack**
4
4
 
5
- [![npm](https://img.shields.io/npm/v/eigen-skills)](https://www.npmjs.com/package/eigen-skills)
6
- [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
5
+ [Installation](#installation) | [Skills](#skills-overview) | [Architecture](#architecture) | [Usage](#usage) | [API Reference](#api-reference)
7
6
 
8
7
  ---
9
8
 
10
- ## Quick Start
9
+ ## What is this?
10
+
11
+ **eigen-skills** is a modular skills package that gives any AI agent instant access to the full EigenLayer ecosystem. Inspired by the [Agent Skills specification](https://github.com/anthropics/skills), it follows the `SKILL.md` standard so agents like Claude Code, OpenClaw, or any compatible framework can discover and use these capabilities automatically.
11
12
 
12
13
  ```bash
13
- npm install eigen-skills
14
+ npx skills add zeeshan8281/eigen-skills
14
15
  ```
15
16
 
16
- The postinstall script copies `SKILL.md` into `.claude/skills/eigen/` so Claude Code discovers it automatically. Then just ask:
17
+ > Think of it like `npm install` but for AI agents instead of code libraries, you're installing **knowledge and capabilities**.
18
+
19
+ ---
20
+
21
+ ## Skills Overview
17
22
 
18
- > "Read https://eigencloud-skills.vercel.app/ and deploy my app to eigencompute"
23
+ | Skill | Emoji | Domain | Data Source |
24
+ |-------|-------|--------|-------------|
25
+ | [`eigen-restaking`](#eigen-restaking) | 🔄 | Operators, TVL, stakers, deposits, withdrawals | EigenExplorer API |
26
+ | [`eigen-avs`](#eigen-avs) | 🛡️ | Actively Validated Services, registrations, operator-sets | EigenExplorer API |
27
+ | [`eigen-rewards`](#eigen-rewards) | 💰 | Rewards, APY rankings, yield strategies | EigenExplorer API |
28
+ | [`eigen-delegation`](#eigen-delegation) | 🤝 | Delegation events, staker positions, top operators | EigenExplorer API |
29
+ | [`eigen-compute`](#eigen-compute) | 🔒 | TEE deployment, attestation, lifecycle management | EigenCompute (ecloud CLI) |
30
+ | [`eigen-da`](#eigen-da) | 📦 | Blob storage & retrieval, data availability | EigenDA Proxy |
19
31
 
20
32
  ---
21
33
 
22
- ## What is EigenCompute?
34
+ ## Architecture
23
35
 
24
- EigenCompute runs your Docker containers inside **hardware-isolated Trusted Execution Environments** (Intel TDX / SEV-SNP). Every deployment gets:
36
+ ### How Agent Skills Work
25
37
 
26
- - **Encrypted memory** — the host cannot read your app's data
27
- - **Unique wallet** — cryptographic identity per deployment
28
- - **KMS signing key** — at `/usr/local/bin/kms-signing-public-key.pem`
29
- - **Sealed secrets** env vars decrypted only inside the TEE
30
- - **Cryptographic attestation** — verifiable proof of code integrity
38
+ ```
39
+ ┌─────────────────────────────────────────────────────────────┐
40
+ │ AI Agent │
41
+ │ (Claude Code / OpenClaw / Any Agent Skills-compatible) │
42
+ │ │
43
+ │ 1. User asks: "What are the top EigenLayer operators?" │
44
+ │ 2. Agent scans installed skills/ │
45
+ │ 3. Matches intent → eigen-restaking/SKILL.md │
46
+ │ 4. Reads SKILL.md for instructions │
47
+ │ 5. Executes the appropriate curl/CLI command │
48
+ │ 6. Formats and returns results │
49
+ └──────────────┬──────────────────────────────────────────────┘
50
+
51
+
52
+ ┌──────────────────────────────────────────────────────────────┐
53
+ │ eigen-skills/ │
54
+ │ │
55
+ │ skills/ │
56
+ │ ├── eigen-restaking/ │
57
+ │ │ ├── SKILL.md ← Agent reads this │
58
+ │ │ └── scripts/ │
59
+ │ │ └── eigen-api.js ← JS client (optional) │
60
+ │ ├── eigen-avs/ │
61
+ │ ├── eigen-rewards/ │
62
+ │ ├── eigen-delegation/ │
63
+ │ ├── eigen-compute/ │
64
+ │ └── eigen-da/ │
65
+ └──────────────┬──────────────────────────────────────────────┘
66
+
67
+
68
+ ┌──────────────────────────────────────────────────────────────┐
69
+ │ EigenLayer Ecosystem │
70
+ │ │
71
+ │ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ │
72
+ │ │ EigenExplorer │ │ EigenCompute │ │ EigenDA │ │
73
+ │ │ REST API │ │ (ecloud CLI)│ │ (Proxy) │ │
74
+ │ │ │ │ │ │ │ │
75
+ │ │ Operators │ │ TEE Deploy │ │ Blob Store │ │
76
+ │ │ AVS │ │ Attestation │ │ Blob Get │ │
77
+ │ │ Stakers │ │ KMS Signing │ │ KZG Verify │ │
78
+ │ │ Rewards │ │ Lifecycle │ │ Commitment │ │
79
+ │ │ Events │ │ Monitoring │ │ Explorer │ │
80
+ │ └──────────────┘ └──────────────┘ └──────────────┘ │
81
+ │ │ │ │ │
82
+ │ ▼ ▼ ▼ │
83
+ │ ┌─────────────────────────────────────────────────┐ │
84
+ │ │ EigenLayer Protocol (L1) │ │
85
+ │ │ DelegationManager · StrategyManager · AVSDir │ │
86
+ │ │ AllocationManager · RewardsCoordinator │ │
87
+ │ └─────────────────────────────────────────────────┘ │
88
+ └──────────────────────────────────────────────────────────────┘
89
+ ```
90
+
91
+ ### Data Flow
92
+
93
+ ```
94
+ ┌─────────────────┐
95
+ │ User Query │
96
+ │ "top operators" │
97
+ └────────┬────────┘
98
+
99
+ ┌────────▼────────┐
100
+ │ AI Agent │
101
+ │ reads SKILL.md│
102
+ └────────┬────────┘
103
+
104
+ ┌──────────────┼──────────────┐
105
+ │ │ │
106
+ ┌────────▼─────┐ ┌─────▼──────┐ ┌─────▼──────┐
107
+ │ REST API │ │ ecloud CLI │ │ DA Proxy │
108
+ │ (curl) │ │ (shell) │ │ (curl) │
109
+ └────────┬─────┘ └─────┬──────┘ └─────┬──────┘
110
+ │ │ │
111
+ ┌────────▼─────┐ ┌─────▼──────┐ ┌─────▼──────┐
112
+ │ EigenExplorer│ │ EigenCloud │ │ EigenDA │
113
+ │ Mainnet │ │ TEE │ │ Network │
114
+ └──────────────┘ └────────────┘ └────────────┘
115
+ ```
31
116
 
32
117
  ---
33
118
 
34
- ## Setup
119
+ ## Installation
35
120
 
36
- ### 1. Install the ecloud CLI
121
+ ### For Claude Code (one command)
37
122
 
38
123
  ```bash
39
- npm install -g @layr-labs/ecloud-cli
124
+ npm install eigen-skills
40
125
  ```
41
126
 
42
- ### 2. Authenticate
127
+ That's it. The postinstall script automatically copies the `SKILL.md` into `.claude/skills/eigen/` — Claude Code discovers it instantly. Just set your API key:
43
128
 
44
129
  ```bash
45
- # First time — generates a new key
46
- ecloud auth generate --store
130
+ export EIGEN_API_KEY="your-key-here"
131
+ ```
47
132
 
48
- # Or login with an existing key
49
- ecloud auth login
133
+ Then open Claude Code and ask anything about EigenLayer.
134
+
135
+ ### Alternative: curl (no npm)
136
+
137
+ ```bash
138
+ mkdir -p .claude/skills/eigen
139
+ curl -o .claude/skills/eigen/SKILL.md https://raw.githubusercontent.com/zeeshan8281/eigen-agent-skills/main/SKILL.md
140
+ ```
141
+
142
+ ### For Programmatic Use (JavaScript)
50
143
 
51
- # Verify
52
- ecloud auth whoami
144
+ ```javascript
145
+ const { EigenAPI, AVSAPI, RewardsAPI, DelegationAPI, EigenCompute, EigenDA } = require('eigen-skills');
53
146
  ```
54
147
 
55
- ### 3. Subscribe to billing
148
+ ---
149
+
150
+ ## Prerequisites
151
+
152
+ ### Data Skills (restaking, AVS, rewards, delegation)
153
+
154
+ | Requirement | How to Get |
155
+ |-------------|-----------|
156
+ | EigenExplorer API Key | Free at [developer.eigenexplorer.com](https://developer.eigenexplorer.com) |
157
+ | Set env var | `export EIGEN_API_KEY=your_key` |
158
+
159
+ ### EigenCompute Skill
160
+
161
+ | Requirement | How to Get |
162
+ |-------------|-----------|
163
+ | ecloud CLI | `npm install -g @layr-labs/ecloud-cli` |
164
+ | Auth | `ecloud auth login` or `ecloud auth generate --store` |
165
+
166
+ ### EigenDA Skill
167
+
168
+ | Requirement | How to Get |
169
+ |-------------|-----------|
170
+ | EigenDA Proxy | See [EigenDA Proxy Setup](#eigenda-proxy-setup) below |
171
+ | Ethereum RPC | Any Sepolia RPC endpoint |
172
+
173
+ ---
56
174
 
175
+ ## Usage
176
+
177
+ ### Agent Usage (SKILL.md driven)
178
+
179
+ When an agent has eigen-skills installed, it reads the `SKILL.md` files to know what to do:
180
+
181
+ **User:** "What are the top EigenLayer operators by TVL?"
182
+ **Agent reads:** `skills/eigen-restaking/SKILL.md`
183
+ **Agent runs:**
57
184
  ```bash
58
- ecloud billing subscribe
59
- ecloud billing status
185
+ curl -s "https://api.eigenexplorer.com/operators?withTvl=true&sortByTvl=desc&take=10" \
186
+ -H "x-api-token: $EIGEN_API_KEY"
60
187
  ```
188
+ **Agent formats:** Bold names, TVL in human-readable form, staker counts.
61
189
 
62
- ### 4. Docker
190
+ ---
63
191
 
64
- Docker must be installed and running. The deploy process builds and pushes images.
192
+ **User:** "Deploy my Dockerfile to EigenCompute"
193
+ **Agent reads:** `skills/eigen-compute/SKILL.md`
194
+ **Agent runs:**
195
+ ```bash
196
+ ecloud compute app deploy
197
+ # Selects "Build and deploy from Dockerfile"
198
+ # Selects Linux/AMD64
199
+ ```
200
+
201
+ ---
65
202
 
203
+ **User:** "Store this verification proof on EigenDA"
204
+ **Agent reads:** `skills/eigen-da/SKILL.md`
205
+ **Agent runs:**
66
206
  ```bash
67
- docker info
207
+ curl -s -X POST "http://127.0.0.1:3100/put?commitment_mode=standard" \
208
+ -H "Content-Type: application/json" \
209
+ -d '{"verified": true, "model": "gpt-oss-120b", "timestamp": "2025-01-01"}'
210
+ ```
211
+
212
+ ### Programmatic Usage (JavaScript)
213
+
214
+ ```javascript
215
+ const { EigenAPI, AVSAPI, RewardsAPI, DelegationAPI, EigenCompute, EigenDA } = require('eigen-skills');
216
+
217
+ // ─── Restaking Data ─────────────────────────────────
218
+ const eigen = new EigenAPI(process.env.EIGEN_API_KEY);
219
+
220
+ // Ecosystem overview
221
+ const metrics = await eigen.getMetrics();
222
+ console.log(`Total TVL: ${metrics.tvl}`);
223
+ console.log(`Operators: ${metrics.totalOperators}`);
224
+ console.log(`Stakers: ${metrics.totalStakers}`);
225
+
226
+ // Top operators
227
+ const ops = await eigen.getOperators({ sortByTvl: 'desc', take: 5 });
228
+ ops.data.forEach(op => {
229
+ console.log(`${op.metadataName} — TVL: ${op.tvl?.tvl} — Stakers: ${op.totalStakers}`);
230
+ });
231
+
232
+ // ─── AVS Data ───────────────────────────────────────
233
+ const avs = new AVSAPI(process.env.EIGEN_API_KEY);
234
+
235
+ // All services
236
+ const services = await avs.getAllAVS({ sortByTvl: 'desc', take: 10 });
237
+
238
+ // Operators securing a specific AVS
239
+ const avsOps = await avs.getAVSOperators('0xAVS_ADDRESS');
240
+
241
+ // ─── Rewards & Yield ────────────────────────────────
242
+ const rewards = new RewardsAPI(process.env.EIGEN_API_KEY);
243
+
244
+ // Best yield operators
245
+ const topYield = await rewards.getTopOperatorsByAPY(10);
246
+
247
+ // Rewards for a specific operator
248
+ const opRewards = await rewards.getOperatorRewards('0xOPERATOR');
249
+
250
+ // ─── Delegation ─────────────────────────────────────
251
+ const delegation = new DelegationAPI(process.env.EIGEN_API_KEY);
252
+
253
+ // Most delegated operators
254
+ const topDelegated = await delegation.getTopDelegatedOperators(10);
255
+
256
+ // Staker's delegation position
257
+ const stakerInfo = await delegation.getStakerDelegation('0xSTAKER');
258
+
259
+ // ─── TEE Compute ────────────────────────────────────
260
+ const compute = new EigenCompute();
261
+
262
+ // Check if running inside TEE
263
+ const health = compute.healthCheck();
264
+ console.log(`Inside TEE: ${health.insideTEE}`);
265
+
266
+ // Collect attestation (inside TEE container)
267
+ const attestation = compute.collectAttestation();
268
+ console.log(`App ID: ${attestation.appId}`);
269
+ console.log(`KMS Key: ${attestation.kmsKeyFingerprint}`);
270
+
271
+ // ─── Data Availability ──────────────────────────────
272
+ const da = new EigenDA();
273
+
274
+ // Store data
275
+ const commitment = await da.store({
276
+ proof: { verified: true, model: 'gpt-oss-120b' },
277
+ timestamp: new Date().toISOString(),
278
+ });
279
+ console.log(`Stored! Commitment: ${commitment}`);
280
+ console.log(`Explorer: ${da.getExplorerUrl(commitment)}`);
281
+
282
+ // Retrieve data
283
+ const data = await da.retrieve(commitment);
284
+ console.log(`Retrieved:`, data);
68
285
  ```
69
286
 
70
287
  ---
71
288
 
72
- ## Deploying an App
289
+ ## Detailed Skill Reference
73
290
 
74
- ### Step 1: Ensure a Dockerfile exists
291
+ ### eigen-restaking
75
292
 
76
- If the project doesn't have one, the agent will generate one based on the project type (Node.js, Python, Go, Rust, etc.).
293
+ 🔄 **Query EigenLayer restaking data**
77
294
 
78
- ### Step 2: Build for linux/amd64
295
+ ```
296
+ Operators ←→ Stakers ←→ Strategies ←→ TVL
297
+
298
+ └── Deposits / Withdrawals / Events
299
+ ```
79
300
 
80
- EigenCompute TEEs run on x86_64:
301
+ **Key endpoints:**
81
302
 
303
+ | Method | What |
304
+ |--------|------|
305
+ | `getMetrics()` | Ecosystem-wide TVL, operator count, staker count |
306
+ | `getOperators(opts)` | List operators with sorting/filtering |
307
+ | `getOperator(address)` | Single operator detail |
308
+ | `getStaker(address)` | Staker info and positions |
309
+ | `getDeposits()` | Recent deposit events |
310
+ | `getWithdrawals()` | Recent withdrawal events |
311
+ | `getHistoricalMetrics()` | TVL over time |
312
+
313
+ **Example queries:**
82
314
  ```bash
83
- docker build --platform linux/amd64 -t <REGISTRY_USER>/<APP_NAME>:latest .
315
+ # Top 10 operators by TVL
316
+ curl -s "https://api.eigenexplorer.com/operators?withTvl=true&sortByTvl=desc&take=10" \
317
+ -H "x-api-token: $EIGEN_API_KEY"
318
+
319
+ # Search operator by name
320
+ curl -s "https://api.eigenexplorer.com/operators?searchByText=p2p&withTvl=true" \
321
+ -H "x-api-token: $EIGEN_API_KEY"
322
+
323
+ # Staker position
324
+ curl -s "https://api.eigenexplorer.com/stakers/0xADDRESS" \
325
+ -H "x-api-token: $EIGEN_API_KEY"
84
326
  ```
85
327
 
86
- ### Step 3: Push to a public registry
328
+ ---
329
+
330
+ ### eigen-avs
87
331
 
88
- ```bash
89
- docker push <REGISTRY_USER>/<APP_NAME>:latest
332
+ 🛡️ **Query Actively Validated Services**
333
+
334
+ ```
335
+ AVS (Service)
336
+ ├── Operators (securing it)
337
+ ├── Stakers (delegated via operators)
338
+ ├── Registration Events
339
+ └── Operator-Sets (slashing-era grouping)
90
340
  ```
91
341
 
92
- ### Step 4: Deploy
342
+ **Key endpoints:**
93
343
 
94
- The `ecloud compute app deploy` CLI is interactive. The agent uses an expect script to automate all prompts:
344
+ | Method | What |
345
+ |--------|------|
346
+ | `getAllAVS(opts)` | List all AVS with sorting/filtering |
347
+ | `getAVS(address)` | Single AVS detail |
348
+ | `getAVSOperators(address)` | Operators registered to an AVS |
349
+ | `getAVSStakers(address)` | Stakers delegated to an AVS |
350
+ | `getAVSRegistrationEvents(address)` | Registration/deregistration events |
351
+ | `getAVSOperatorSets(address)` | Operator-sets for an AVS |
352
+
353
+ ---
354
+
355
+ ### eigen-rewards
356
+
357
+ 💰 **Query rewards and yield data**
95
358
 
96
- ```bash
97
- ecloud compute app deploy \
98
- --name "<APP_NAME>" \
99
- --image-ref "<REGISTRY_USER>/<APP_NAME>:latest" \
100
- --skip-profile \
101
- --log-visibility public
359
+ ```
360
+ AVS distributes rewards
361
+
362
+
363
+ ┌─────────┐
364
+ │ Operator │ ← takes fee (0-100%)
365
+ └────┬────┘
366
+
367
+
368
+ ┌─────────┐
369
+ │ Staker │ ← receives remaining rewards
370
+ └─────────┘
102
371
  ```
103
372
 
104
- On success you get an **App ID** and **IP address**.
373
+ **Key endpoints:**
105
374
 
106
- ### Step 5: Verify
375
+ | Method | What |
376
+ |--------|------|
377
+ | `getTopOperatorsByAPY(limit)` | Best yield operators |
378
+ | `getTopAVSByAPY(limit)` | Best yield AVS |
379
+ | `getOperatorRewards(address)` | Reward strategies for an operator |
380
+ | `getStakerRewards(address)` | Rewards earned by a staker |
381
+ | `getAVSRewards(address)` | Rewards distributed by an AVS |
107
382
 
108
- ```bash
109
- ecloud compute app list
110
- ecloud compute app info <APP_ID>
383
+ ---
384
+
385
+ ### eigen-delegation
386
+
387
+ 🤝 **Query delegation relationships**
388
+
389
+ ```
390
+ Staker ──delegates──▶ Operator ──registers──▶ AVS
391
+ │ │
392
+ └── withdrawals └── operator-sets
111
393
  ```
112
394
 
395
+ **Key endpoints:**
396
+
397
+ | Method | What |
398
+ |--------|------|
399
+ | `getTopDelegatedOperators(limit)` | Most delegated by staker count |
400
+ | `getTopOperatorsByTVL(limit)` | Most capital delegated |
401
+ | `getOperatorDelegation(address)` | Operator's full delegation profile |
402
+ | `getOperatorStakers(address)` | Stakers delegating to an operator |
403
+ | `getStakerDelegation(address)` | Which operator a staker is delegated to |
404
+ | `getDelegationEvents()` | Recent delegation/undelegation events |
405
+ | `getOperatorSets()` | Operator-sets (slashing-era model) |
406
+
113
407
  ---
114
408
 
115
- ## Instance Types
409
+ ### eigen-compute
410
+
411
+ 🔒 **Deploy and manage TEE applications**
116
412
 
117
- | Instance | Specs | TEE Type |
118
- |----------|-------|----------|
119
- | g1-micro-1v | 2 shared vCPUs, 1 GB RAM | Shielded VM |
120
- | g1-medium-1v | 2 shared vCPUs, 4 GB RAM | Shielded VM |
121
- | g1-custom-2-4096s | 2 vCPUs, 4 GB RAM | SEV-SNP |
122
- | g1-standard-2s | 2 vCPUs, 8 GB RAM | SEV-SNP |
123
- | g1-standard-4t | 4 vCPUs, 16 GB RAM | TDX |
124
- | g1-standard-8t | 8 vCPUs, 32 GB RAM | TDX |
413
+ ```
414
+ ┌─────────────────────────────────────────┐
415
+ │ EigenCompute TEE │
416
+ │ (Intel TDX Enclave) │
417
+ │ │
418
+ │ ┌─────────────────────────────────┐ │
419
+ │ │ Your Docker Container │ │
420
+ │ │ │ │
421
+ │ │ • Encrypted memory │ │
422
+ │ │ • Sealed secrets │ │
423
+ │ │ • KMS signing key │ │
424
+ │ │ • Unique wallet identity │ │
425
+ │ │ • Cryptographic attestation │ │
426
+ │ └─────────────────────────────────┘ │
427
+ │ │
428
+ │ /usr/local/bin/ │
429
+ │ ├── compute-source-env.sh (secrets) │
430
+ │ ├── kms-signing-public-key.pem │
431
+ │ └── kms-client │
432
+ └─────────────────────────────────────────┘
433
+ ```
434
+
435
+ **Lifecycle:**
436
+
437
+ ```
438
+ ecloud auth login
439
+
440
+
441
+ ecloud compute app deploy ← builds Dockerfile in TEE
442
+
443
+
444
+ ecloud compute app list ← check status + IP
445
+
446
+
447
+ ecloud compute app logs <id> ← view logs
448
+
449
+
450
+ ecloud compute app stop <id> ← pause
451
+
452
+
453
+ ecloud compute app terminate <id> ← permanent destroy
454
+ ```
455
+
456
+ **Key methods:**
457
+
458
+ | Method | What |
459
+ |--------|------|
460
+ | `whoami()` | Check authenticated address |
461
+ | `listApps()` | List all deployed apps |
462
+ | `getAppInfo(id)` | App status and details |
463
+ | `getAppLogs(id)` | View app logs |
464
+ | `startApp(id)` / `stopApp(id)` | Lifecycle control |
465
+ | `collectAttestation()` | Gather TEE attestation data |
466
+ | `computeConfigHash(files)` | Hash config files for integrity proof |
467
+
468
+ **Known issues:** See [Troubleshooting](#troubleshooting).
125
469
 
126
470
  ---
127
471
 
128
- ## Managing Apps
472
+ ### eigen-da
473
+
474
+ 📦 **Store and retrieve data blobs**
475
+
476
+ ```
477
+ Your App ──POST /put──▶ EigenDA Proxy ──disperse──▶ EigenDA Network
478
+ │ │
479
+ commitment KZG commitment
480
+ │ stored on-chain
481
+
482
+ ┌──────────┐
483
+ │ Explorer │
484
+ │ blobs- │
485
+ │ sepolia. │
486
+ │eigenda. │
487
+ │ xyz │
488
+ └──────────┘
489
+
490
+ Your App ──GET /get/X──▶ EigenDA Proxy ──retrieve──▶ EigenDA Network
491
+
492
+ original data
493
+ ```
494
+
495
+ **Proxy endpoints:**
496
+
497
+ | Endpoint | Method | What |
498
+ |----------|--------|------|
499
+ | `/put?commitment_mode=standard` | POST | Store a blob, returns commitment |
500
+ | `/get/<commitment>?commitment_mode=standard` | GET | Retrieve a blob by commitment |
501
+ | `/health` | GET | Proxy health check |
502
+
503
+ **Key methods:**
504
+
505
+ | Method | What |
506
+ |--------|------|
507
+ | `store(data)` | Store JSON on EigenDA, returns commitment |
508
+ | `retrieve(commitment)` | Retrieve JSON by commitment |
509
+ | `getExplorerUrl(commitment)` | Get blob explorer URL |
510
+ | `healthCheck()` | Check proxy availability |
511
+
512
+ **Networks:**
513
+
514
+ | Network | Disperser RPC | Service Manager |
515
+ |---------|---------------|-----------------|
516
+ | Sepolia | `disperser-sepolia.eigenda.xyz:443` | `0xD4A7E1Bd8015057293f0D0A557088c286942e84b` |
517
+ | Mainnet | `disperser.eigenda.xyz:443` | See EigenLayer docs |
518
+
519
+ ### EigenDA Proxy Setup
129
520
 
130
521
  ```bash
131
- ecloud compute app list # List all apps
132
- ecloud compute app info <APP_ID> # App status and IP
133
- ecloud compute app logs <APP_ID> # View logs
134
- ecloud compute app start <APP_ID> # Start a stopped app
135
- ecloud compute app stop <APP_ID> # Stop a running app
136
- ecloud compute app terminate <APP_ID> # Permanently destroy
137
- ecloud compute app upgrade <APP_ID> # Update running app
522
+ docker run -d \
523
+ --name eigenda-proxy \
524
+ -p 3100:3100 \
525
+ ghcr.io/layr-labs/eigenda-proxy:latest \
526
+ --eigenda.disperser-rpc=disperser-sepolia.eigenda.xyz:443 \
527
+ --eigenda.service-manager-addr=0xD4A7E1Bd8015057293f0D0A557088c286942e84b \
528
+ --eigenda.eth-rpc=YOUR_SEPOLIA_RPC_URL \
529
+ --eigenda.status-query-timeout=45s \
530
+ --eigenda.signer-private-key-hex=YOUR_PRIVATE_KEY \
531
+ --memstore.enabled=false \
532
+ --eigenda.disable-tls=false
138
533
  ```
139
534
 
140
535
  ---
141
536
 
142
- ## Sealed Secrets
537
+ ## API Reference
143
538
 
144
- ```bash
145
- ecloud compute app env set MY_SECRET="value" API_KEY="key"
539
+ ### Constructor Options
540
+
541
+ #### EigenAPI / AVSAPI / RewardsAPI / DelegationAPI
542
+
543
+ ```javascript
544
+ new EigenAPI(apiKey, { network: 'mainnet' | 'holesky' })
146
545
  ```
147
546
 
148
- Secrets are encrypted at rest and only decrypted inside the TEE at runtime. You cannot inspect them after they're set.
547
+ | Param | Type | Default | Description |
548
+ |-------|------|---------|-------------|
549
+ | `apiKey` | string | **required** | EigenExplorer API key |
550
+ | `network` | string | `'mainnet'` | `'mainnet'` or `'holesky'` |
149
551
 
150
- ---
552
+ #### EigenDA
151
553
 
152
- ## Attestation
554
+ ```javascript
555
+ new EigenDA({ proxyUrl, commitmentMode, timeout })
556
+ ```
557
+
558
+ | Param | Type | Default | Description |
559
+ |-------|------|---------|-------------|
560
+ | `proxyUrl` | string | `'http://127.0.0.1:3100'` | EigenDA proxy URL |
561
+ | `commitmentMode` | string | `'standard'` | `'standard'` or `'optimistic'` |
562
+ | `timeout` | number | `60000` | Request timeout in ms |
153
563
 
154
- Verify any deployed app at:
564
+ #### EigenCompute
155
565
 
566
+ ```javascript
567
+ new EigenCompute() // No args — wraps ecloud CLI
156
568
  ```
157
- https://verify-sepolia.eigencloud.xyz/app/<APP_ID>
569
+
570
+ ### Pagination
571
+
572
+ All list endpoints support pagination:
573
+
574
+ ```javascript
575
+ const results = await eigen.getOperators({
576
+ skip: 0, // offset
577
+ take: 12, // page size (default: 12)
578
+ sortByTvl: 'desc',
579
+ });
580
+
581
+ console.log(results.meta.total); // total records
582
+ console.log(results.meta.skip); // current offset
583
+ console.log(results.meta.take); // page size
158
584
  ```
159
585
 
160
- Inside the TEE, the KMS signing key is at `/usr/local/bin/kms-signing-public-key.pem`.
586
+ ### Sorting Options
587
+
588
+ | Parameter | Valid Values | Available On |
589
+ |-----------|-------------|-------------|
590
+ | `sortByTvl` | `'asc'` / `'desc'` | Operators, AVS |
591
+ | `sortByApy` | `'asc'` / `'desc'` | Operators, AVS |
592
+ | `sortByTotalStakers` | `'asc'` / `'desc'` | Operators, AVS |
593
+ | `sortByTotalAvs` | `'asc'` / `'desc'` | Operators |
594
+ | `searchByText` | any string | Operators, AVS |
595
+ | `withTvl` | `true` / `false` | Operators, AVS |
161
596
 
162
597
  ---
163
598
 
164
- ## TEE Container Internals
599
+ ## Environment Variables
600
+
601
+ | Variable | Required For | Description |
602
+ |----------|-------------|-------------|
603
+ | `EIGEN_API_KEY` | Data skills | EigenExplorer API key |
604
+ | `EIGENDA_PROXY_URL` | eigen-da | Proxy URL (default: `http://127.0.0.1:3100`) |
605
+ | `EIGENDA_COMMITMENT_MODE` | eigen-da | `standard` or `optimistic` |
606
+ | `EIGENDA_TIMEOUT` | eigen-da | Timeout in ms (default: `60000`) |
607
+ | `ECLOUD_APP_ID` | eigen-compute | Auto-set inside TEE |
608
+
609
+ ---
165
610
 
166
- | Path | What |
167
- |------|------|
168
- | `/usr/local/bin/compute-source-env.sh` | Sources sealed env vars at runtime |
169
- | `/usr/local/bin/kms-signing-public-key.pem` | KMS signing public key |
170
- | `/usr/local/bin/kms-client` | KMS signing client binary |
611
+ ## Demo
171
612
 
172
- ### Entrypoint pattern
613
+ Run the interactive demo to verify all data skills work:
173
614
 
174
615
  ```bash
175
- #!/bin/bash
176
- if [ -f "/usr/local/bin/compute-source-env.sh" ]; then
177
- source /usr/local/bin/compute-source-env.sh
178
- fi
179
- node server.js
616
+ EIGEN_API_KEY=your_key npm run demo
617
+ ```
618
+
619
+ Sample output:
620
+ ```
621
+ 🔄 Eigen Agent Skills — Demo
622
+
623
+ 📡 Health check...
624
+ Status: ✅ Healthy
625
+ EigenLayer TVL: 4,754,266
626
+
627
+ 👥 Top 5 Operators by TVL:
628
+ 1. EigenYields — Stakers: 25,700 — AVS: 32
629
+ 2. AltLayer — Stakers: 21,826 — AVS: 14
630
+ 3. InfStones — Stakers: 21,617 — AVS: 11
631
+
632
+ 🛡️ Top 5 AVS:
633
+ 1. Brevis coChain AVS
634
+ 2. DIN
635
+ 3. Renzo wBTC DVN
636
+
637
+ 💰 Top 5 by APY:
638
+ 1. EigenYields — APY: 484.3%
639
+ 2. Nodes.Guru — APY: 484.3%
640
+
641
+ ✅ All skills working!
180
642
  ```
181
643
 
182
644
  ---
183
645
 
184
646
  ## Troubleshooting
185
647
 
648
+ ### Data Skills (EigenExplorer)
649
+
650
+ | Issue | Fix |
651
+ |-------|-----|
652
+ | `401 Unauthorized` | Check your `EIGEN_API_KEY` is set correctly |
653
+ | Timeout on `withTvl=true` | TVL calculations are expensive — set `withTvl=false` for faster queries, or increase timeout |
654
+ | Rate limited | EigenExplorer has rate limits on the free tier — add delays between requests |
655
+
656
+ ### EigenCompute
657
+
186
658
  | Issue | Fix |
187
659
  |-------|-----|
188
- | `ecloud: command not found` | `npm install -g @layr-labs/ecloud-cli` |
189
- | App stuck in `Status: Unknown` | Use "Build from Dockerfile" instead of "Deploy from registry" |
190
- | `app logs` returns 403 | Add HTTP logging endpoint in your app as workaround |
191
- | 429 rate limiting after deploy | Wait 30-60s before running `app list` or `app info` |
192
- | IP changes on every deploy | No static IP — use DNS/webhook updates in your entrypoint |
193
- | Secret rotation | Requires terminate + redeploy (no hot update) |
660
+ | `ecloud: command not found` | Run `npm install -g @layr-labs/ecloud-cli` |
661
+ | App stuck in `Status: Unknown` | Use "Build from Dockerfile" method instead of "Deploy from registry" |
662
+ | `app logs` returns 403 | Known issue — add HTTP logging endpoint in your app as workaround |
663
+ | 429 rate limiting after deploy | Wait 30-60 seconds before running `app list` or `app info` |
664
+ | IP changes on every deploy | No static IP available — use DNS/webhook updates in your entrypoint |
665
+
666
+ ### EigenDA
667
+
668
+ | Issue | Fix |
669
+ |-------|-----|
670
+ | `ECONNREFUSED 127.0.0.1:3100` | Start the EigenDA proxy Docker container |
671
+ | Store timeout | Increase `EIGENDA_TIMEOUT` — dispersal can take 30-60s |
672
+ | Invalid commitment | Ensure `commitment_mode` matches between store and retrieve |
673
+
674
+ ---
675
+
676
+ ## Project Structure
677
+
678
+ ```
679
+ eigen-skills/
680
+ ├── package.json # npm package with "agents" field
681
+ ├── index.js # programmatic entry point (all 6 modules)
682
+ ├── README.md # this file
683
+ ├── .gitignore
684
+ ├── .npmignore
685
+ ├── scripts/
686
+ │ └── demo.js # interactive demo
687
+ └── skills/
688
+ ├── eigen-restaking/ # 🔄 Operators, TVL, stakers
689
+ │ ├── SKILL.md # agent instructions
690
+ │ └── scripts/
691
+ │ └── eigen-api.js # JS API client
692
+
693
+ ├── eigen-avs/ # 🛡️ Actively Validated Services
694
+ │ ├── SKILL.md
695
+ │ └── scripts/
696
+ │ └── avs-api.js
697
+
698
+ ├── eigen-rewards/ # 💰 Rewards & APY
699
+ │ ├── SKILL.md
700
+ │ └── scripts/
701
+ │ └── rewards-api.js
702
+
703
+ ├── eigen-delegation/ # 🤝 Delegation & operator-sets
704
+ │ ├── SKILL.md
705
+ │ └── scripts/
706
+ │ └── delegation-api.js
707
+
708
+ ├── eigen-compute/ # 🔒 TEE deployment & attestation
709
+ │ ├── SKILL.md
710
+ │ └── scripts/
711
+ │ └── compute-api.js
712
+
713
+ └── eigen-da/ # 📦 Blob storage & data availability
714
+ ├── SKILL.md
715
+ └── scripts/
716
+ └── da-api.js
717
+ ```
718
+
719
+ ---
720
+
721
+ ## How It Compares
722
+
723
+ | Feature | eigen-skills | Manual curl | Custom SDK |
724
+ |---------|-------------|-------------|------------|
725
+ | Agent-compatible | ✅ SKILL.md standard | ❌ | ❌ |
726
+ | Zero config | ✅ just add API key | ✅ | ❌ needs setup |
727
+ | Covers restaking data | ✅ | ✅ manual | ✅ |
728
+ | Covers TEE compute | ✅ | ❌ need CLI | ❌ |
729
+ | Covers data availability | ✅ | ✅ manual | ❌ |
730
+ | Programmatic JS API | ✅ | ❌ | ✅ |
731
+ | Works with Claude/OpenClaw | ✅ auto-discovered | ❌ | ❌ |
732
+
733
+ ---
734
+
735
+ ## Contributing
736
+
737
+ 1. Fork the repo
738
+ 2. Create a new skill directory under `skills/`
739
+ 3. Add a `SKILL.md` following the [Agent Skills spec](https://github.com/anthropics/skills)
740
+ 4. Add scripts in `scripts/` for programmatic use
741
+ 5. Update `index.js` to export the new module
742
+ 6. PR it
194
743
 
195
744
  ---
196
745
 
@@ -201,5 +750,5 @@ MIT
201
750
  ---
202
751
 
203
752
  <p align="center">
204
- Built on <a href="https://eigencloud.xyz">EigenCompute</a>
753
+ Built with data from <a href="https://eigenexplorer.com">EigenExplorer</a>, <a href="https://eigencloud.xyz">EigenCloud</a>, and <a href="https://docs.eigenlayer.xyz">EigenDA</a>
205
754
  </p>