@valiron/sdk 0.9.1 → 0.10.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/docs/llms.txt ADDED
@@ -0,0 +1,106 @@
1
+ # Valiron
2
+
3
+ > Trust and reputation infrastructure for AI agents.
4
+
5
+ Valiron evaluates AI agent trustworthiness using on-chain identity (ERC-8004), behavioral sandbox testing, and Moody's-style credit ratings (AAA to C). Agents with high trust get production access. Agents with low trust are sandboxed or blocked.
6
+
7
+ ## API
8
+
9
+ Base URL: https://valiron-edge-proxy.onrender.com
10
+
11
+ ### Check agent trust profile
12
+ GET /operator/agent/{agentId}?chain={chain}
13
+
14
+ ### Lookup by wallet
15
+ GET /operator/wallet/{wallet}?chain={chain}
16
+
17
+ ### Run sandbox test
18
+ POST /operator/trigger-sandbox/{agentId}
19
+
20
+ ### Trust gate (allow/deny)
21
+ POST /operator/gate/{agentId}
22
+ Body: { "ttlMs": 86400000 }
23
+
24
+ ### Behavioral snapshot hash
25
+ GET /operator/agent/{agentId}/snapshot
26
+
27
+ ### Register webhook
28
+ POST /operator/webhooks/register
29
+ Body: { "event": "evaluation_complete", "url": "https://your-endpoint.com/hooks", "agentIds": [42] }
30
+
31
+ ### Health check
32
+ GET /operator/health
33
+
34
+ ## SDK
35
+
36
+ Install: npm install @valiron/sdk
37
+
38
+ ```typescript
39
+ import { ValironSDK } from "@valiron/sdk";
40
+ const valiron = new ValironSDK({ chain: "ethereum" });
41
+
42
+ // Quick routing check
43
+ const route = await valiron.checkAgent("AGENT_ID");
44
+ // Returns: "prod" | "prod_throttled" | "sandbox" | "sandbox_only"
45
+
46
+ // Full profile
47
+ const profile = await valiron.getAgentProfile("AGENT_ID");
48
+
49
+ // Trust gate (allow/deny for payments)
50
+ const gate = await valiron.gate("AGENT_ID");
51
+ if (gate.allow) { /* proceed */ }
52
+
53
+ // Behavioral snapshot (for hash-chain commitments)
54
+ const snapshot = await valiron.getAgentSnapshot("AGENT_ID");
55
+ console.log(snapshot.snapshotHash); // "0xabc..."
56
+ console.log(snapshot.previousHash); // "0x0" (genesis)
57
+ ```
58
+
59
+ ## Trust Tiers
60
+
61
+ Valiron assigns Moody's-style credit tiers: AAA (highest trust) through C (lowest trust). Higher tiers route to production, lower tiers are sandboxed or blocked. Exact score ranges are not disclosed.
62
+
63
+ | Tier | Meaning | Route |
64
+ |------|---------|-------|
65
+ | AAA | Prime | prod |
66
+ | AA | High grade | prod |
67
+ | A | Upper medium | prod |
68
+ | BAA | Medium grade | prod_throttled |
69
+ | BA | Speculative | prod_throttled |
70
+ | B | Highly speculative | sandbox |
71
+ | CAA | Substantial risk | sandbox_only |
72
+ | CA | Extremely speculative | sandbox_only |
73
+ | C | Default risk | sandbox_only |
74
+
75
+ ## Key Behaviors That Affect Trust
76
+
77
+ - Respect 429 rate limits (critical)
78
+ - Honor Retry-After headers
79
+ - Use exponential backoff
80
+ - Don't retry 401/403 auth errors
81
+ - Stay in scope — don't probe unauthorized paths
82
+ - Don't forward injections or tainted payloads
83
+ - Handle 402 payment required correctly
84
+ - Maintain session isolation
85
+
86
+ ## Contracts (ERC-8004, same address all chains)
87
+
88
+ - Identity Registry: 0x8004A169FB4a3325136EB29fA0ceB6D2e539a432
89
+ - Reputation Registry: 0x8004BAa17C55a88189AE136b182e5fdA19dE9b63
90
+
91
+ ## Supported Chains
92
+
93
+ ethereum, monad, arbitrum, base, avalanche, celo, polygon, linea, abstract, bsc, gnosis, goat, mantle, megaeth, metis, optimism, scroll, skale_base, soneium, taiko, xlayer
94
+
95
+ ## Documentation
96
+
97
+ - [Full documentation (llms-full.txt)](https://valiron.co/llms-full.txt) — Complete AI-optimized documentation in a single file
98
+ - docs/agents/README.md — Index
99
+ - docs/agents/QUICKSTART.md — Get started
100
+ - docs/agents/API-REFERENCE.md — HTTP API reference
101
+ - docs/agents/SDK-REFERENCE.md — TypeScript SDK reference
102
+ - docs/agents/TRUST-MODEL.md — Trust evaluation and behavioral factors
103
+ - docs/agents/IDENTITY.md — ERC-8004 identity and reputation
104
+ - docs/agents/SANDBOX.md — Sandbox testing environment
105
+ - docs/agents/CHAINS.md — Supported blockchains
106
+ - docs/agents/ERRORS.md — Error handling and troubleshooting
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@valiron/sdk",
3
- "version": "0.9.1",
3
+ "version": "0.10.0",
4
4
  "description": "Official TypeScript SDK for Valiron - Trust Layer for Agentic Economy",
5
5
  "repository": {
6
6
  "type": "git",
@@ -46,6 +46,7 @@
46
46
  },
47
47
  "files": [
48
48
  "dist",
49
+ "docs",
49
50
  "README.md"
50
51
  ]
51
52
  }