|
1 | 1 | <!DOCTYPE html> |
2 | 2 | <html lang="en"> |
3 | 3 | <head> |
4 | | - <meta charset="UTF-8" /> |
5 | | - <meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
6 | | - <title>VerifyAgent.eth Discovery Record | CommandLayer</title> |
7 | | - <meta name="description" content="Discover VerifyAgent.eth callable verification endpoint, SDK package, and receipt capabilities for CommandLayer proofs." /> |
8 | | - <link rel="icon" href="/icon2.png" /> |
9 | | - <link rel="preconnect" href="https://fonts.googleapis.com" /> |
10 | | - <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /> |
11 | | - <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap" rel="stylesheet" /> |
12 | | - <link rel="stylesheet" href="/css/site.css" /> |
13 | | - <style> |
14 | | - .brand{gap:0}.brand img{height:68px;width:auto;object-fit:contain}.brand span{display:none}.nav-links a.active{color:var(--text);background:var(--surface)} |
15 | | - .records-grid { margin-top: 38px; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; } |
16 | | - .records-grid .feat-card code, |
17 | | - .records-grid .feat-card .mono { display:block; margin:8px 0; color:#1d4ed8; font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace; } |
18 | | - .link-list { margin:8px 0 0; padding-left:16px; } |
19 | | - .link-list a { color: var(--purple); } |
20 | | - .caps { margin:8px 0 0; padding-left:18px; color:var(--text-2); font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace; } |
21 | | - .profile { margin-top:8px; display:grid; gap:7px; font-size:.95rem; } |
22 | | - .profile div { display:grid; grid-template-columns:160px 1fr; gap:10px; } |
23 | | - .profile span { color:#1e3a8a; font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace; } |
24 | | - </style> |
| 4 | +<meta charset="UTF-8" /> |
| 5 | +<meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
| 6 | +<title>CommandLayer SDK | @commandlayer/agent-sdk</title> |
| 7 | +<meta name="description" content="@commandlayer/agent-sdk wraps agent actions, emits canonical metadata.proof receipts, and verifies them against CommandLayer verifiers." /> |
| 8 | +<link rel="icon" href="/icon2.png" /> |
| 9 | +<link rel="preconnect" href="https://fonts.googleapis.com" /> |
| 10 | +<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /> |
| 11 | +<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap" rel="stylesheet" /> |
| 12 | +<link rel="stylesheet" href="/css/site.css" /> |
| 13 | +<style> |
| 14 | + .brand{gap:0}.brand img{height:68px;width:auto;object-fit:contain}.brand span{display:none}.nav-links a.active{color:var(--text);background:var(--surface)} |
| 15 | + .sdk-hero{padding:76px 0 46px;text-align:center;background:#fff}.sdk-kicker{display:inline-flex;align-items:center;gap:8px;padding:5px 14px;border-radius:999px;border:1px solid rgba(82,152,255,.3);background:rgba(82,152,255,.06);color:var(--purple);font-size:13px;font-weight:700;margin-bottom:18px} |
| 16 | + .sdk-h1{font-size:clamp(2.2rem,5.2vw,4.3rem);line-height:1.04;letter-spacing:-.04em;margin:0 0 16px;font-weight:800} |
| 17 | + .sdk-sub{color:var(--text-2);font-size:clamp(1rem,2vw,1.2rem);max-width:860px;margin:0 auto 20px;line-height:1.65} |
| 18 | + .hero-actions{display:flex;justify-content:center;gap:12px;flex-wrap:wrap;margin-top:14px}.hero-btn{display:inline-flex;padding:10px 14px;border-radius:12px;border:1px solid var(--border);text-decoration:none;color:var(--text-2);font-weight:700;background:#fff} |
| 19 | + .hero-btn.primary{background:var(--gradient);color:#fff;border-color:rgba(99,91,255,.5)} |
| 20 | + .status{margin:24px auto 0;max-width:900px;text-align:left;background:#f8fbff;border:1px solid #d8e5ff;border-radius:14px;padding:14px 16px;color:var(--text-2);font-size:14px;line-height:1.55} |
| 21 | + .section{padding:46px 0;background:#fff}.section-alt{background:linear-gradient(180deg,#fbfcff 0%,#f4f7ff 100%);border-top:1px solid var(--border);border-bottom:1px solid var(--border)} |
| 22 | + .cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;margin-top:16px}.card{border:1px solid var(--border);border-radius:14px;padding:14px;background:#fff;box-shadow:0 1px 2px rgba(15,23,42,.04)} |
| 23 | + .mono{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace} |
| 24 | + .code{margin-top:14px;background:#0f172a;color:#dbeafe;border-radius:14px;padding:14px;overflow:auto;font:12.5px/1.55 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace} |
| 25 | + .list{margin-top:12px;padding-left:20px;color:var(--text-2)} .list li{margin:6px 0} |
| 26 | + .cta-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;margin-top:14px} |
| 27 | + .cta{display:block;border:1px solid var(--border);border-radius:12px;padding:12px;text-decoration:none;background:#fff;color:var(--text)} |
| 28 | + .cta:hover{border-color:rgba(99,91,255,.35);background:#faf9ff} |
| 29 | + footer{padding:30px 0 36px;border-top:1px solid var(--border);background:#fff}.footer-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:24px}.footer-col h4{margin:0 0 10px}.footer-col a{display:block;color:var(--muted);text-decoration:none;margin-bottom:6px} |
| 30 | + @media(max-width:960px){.footer-grid{grid-template-columns:1fr}} |
| 31 | +</style> |
25 | 32 | </head> |
26 | 33 | <body> |
27 | | - <nav> |
28 | | - <div class="container nav-inner"> |
29 | | - <a href="/" class="brand"><img src="/commandlayer-logo.png" alt="CommandLayer" /><span>CommandLayer</span></a> |
30 | | - <div class="nav-links"> |
31 | | - <a href="/">Home</a> |
32 | | - <a href="/capabilities.html">Capabilities</a> |
33 | | - <a href="/verify.html">Verifier</a> |
34 | | - <a href="/sdk-records.html" class="active">SDK</a> |
35 | | - <a href="/docs/wrap-your-agent.html">Docs</a> |
36 | | - <a href="/claim.html">Claim</a> |
37 | | - <a href="https://github.com/commandlayer" target="_blank" rel="noopener">GitHub</a> |
38 | | - </div> |
39 | | - </div> |
40 | | - </nav> |
| 34 | +<nav><div class="container nav-inner"><a href="/" class="brand"><img src="/commandlayer-logo.png" alt="CommandLayer" /><span>CommandLayer</span></a><div class="nav-links"><a href="/">Home</a><a href="/protocol.html">Protocol</a><a href="/capabilities.html">Capabilities</a><a href="/verify.html">Verifier</a><a href="/sdk-records.html" class="active">SDK</a><a href="/docs/wrap-your-agent.html">Docs</a><a href="/claim.html">Claim</a><a href="https://github.com/commandlayer" target="_blank" rel="noopener">GitHub</a></div></div></nav> |
| 35 | +<main> |
| 36 | +<section class="sdk-hero"><div class="container"><div class="sdk-kicker">SDK</div><h1 class="sdk-h1">Add verifiable receipts to agent actions.</h1><p class="sdk-sub">@commandlayer/agent-sdk wraps agent actions and emits canonical metadata.proof receipts that can be checked by CommandLayer verifiers.</p><div class="hero-actions"><a class="hero-btn primary" href="https://github.com/commandlayer/agent-sdk" target="_blank" rel="noopener">View SDK on GitHub</a><a class="hero-btn" href="/verify.html">Verify a receipt</a></div><div class="status"><strong>Wrap an agent action, emit a canonical receipt, and verify the proof.</strong><br/>Runtime production is live. Runtime signs canonical Trust Verification receipts. MCP E2E against production runtime passes: STEP 1 SIGNED, STEP 2 VERIFIED, STEP 3 TAMPERED INVALID. Runtime signer: <code>signer_id = runtime.commandlayer.eth</code>, <code>kid = vC4WbcNoq2znSCiQ</code>. Canonical proof: <code>metadata.proof.canonicalization = json.sorted_keys.v1</code>, <code>metadata.proof.hash.alg = SHA-256</code>, <code>metadata.proof.signature.alg = Ed25519</code>.</div></div></section> |
41 | 37 |
|
42 | | - <section class="hero"> |
43 | | - <div class="container"> |
44 | | - <div class="hero-badge"><span class="badge-dot"></span>Registry & Discovery</div> |
45 | | - <h1 class="hero-h1">VerifyAgent.eth <span class="grad">Discovery Record</span></h1> |
46 | | - <p class="hero-sub">Agents and apps can discover VerifyAgent.eth’s callable verification endpoint, SDK package, and receipt capabilities.</p> |
47 | | - <div class="hero-actions"> |
48 | | - <a class="btn btn-primary" href="/sdk-records/verifyagent.eth.json">Open JSON Record</a> |
49 | | - <a class="btn btn-secondary" href="/verify/r/demo-valid-receipt">View Demo Verification Report</a> |
50 | | - </div> |
51 | | - </div> |
52 | | - </section> |
| 38 | +<section class="section section-alt"><div class="container"><div class="section-eyebrow">Install</div><h2 class="section-h2">Install the SDK package.</h2><pre class="code">npm install @commandlayer/agent-sdk |
53 | 39 |
|
54 | | - <section class="section section-alt"> |
55 | | - <div class="container"> |
56 | | - <div class="section-eyebrow">Discovery Surface</div> |
57 | | - <h2 class="section-h2">Discovery endpoints, artifacts, and compatibility.</h2> |
58 | | - <p class="section-p">VerifyAgent.eth is ERC-8004-ready and discoverable through ENS TXT records plus JSON metadata.</p> |
| 40 | +@commandlayer/agent-sdk@1.2.0</pre></div></section> |
59 | 41 |
|
| 42 | +<section class="section"><div class="container"><div class="section-eyebrow">Quickstart</div><h2 class="section-h2">Canonical SDK configuration and wrap flow.</h2><pre class="code">import { CommandLayer } from "@commandlayer/agent-sdk"; |
60 | 43 |
|
61 | | - <section class="feat-card" style="margin-top:18px;"> |
62 | | - <h3 class="feat-title">SDK emits canonical receipts</h3> |
63 | | - <p class="feat-desc">The SDK emits version <code>"1.0.0"</code>, family <code>"trust-verification"</code>, short verb receipts, and canonical proof fields. Fully-qualified capability names like <code>clas.trust-verification.verify</code> are used for catalog/discovery, while receipts use <code>verb: "verify"</code>.</p> |
64 | | - <ul class="link-list"> |
65 | | - <li><a href="https://github.com/commandlayer/clas/blob/main/schemas/trust-verification/capabilities.json" target="_blank" rel="noopener">Capability catalog</a></li> |
66 | | - <li><a href="https://github.com/commandlayer/clas/blob/main/schemas/trust-verification/discovery/verifyagent.discovery.json" target="_blank" rel="noopener">Discovery record</a></li> |
67 | | - <li><a href="https://github.com/commandlayer/clas/blob/main/schemas/trust-verification/verify/verify.mcp.tool.schema.json" target="_blank" rel="noopener">MCP tool schema</a></li> |
68 | | - </ul> |
69 | | - </section> |
70 | | - <div class="records-grid"> |
71 | | - <article class="feat-card"> |
72 | | - <h3 class="feat-title">VerifyAgent discovery</h3> |
73 | | - <p class="feat-desc">Canonical discovery metadata path and callable verification routes.</p> |
74 | | - <code>/sdk-records/verifyagent.eth.json</code> |
75 | | - <code>POST /api/agents/verifyagent</code> |
76 | | - <code>POST /api/verify</code> |
77 | | - </article> |
| 44 | +const cl = new CommandLayer({ |
| 45 | + agent: "runtime.commandlayer.eth", |
| 46 | + privateKeyPem: process.env.CL_PRIVATE_KEY_PEM, |
| 47 | + keyId: "vC4WbcNoq2znSCiQ", |
| 48 | + verifierUrl: "https://runtime.commandlayer.org/verify" |
| 49 | +}); |
78 | 50 |
|
79 | | - <article class="feat-card"> |
80 | | - <h3 class="feat-title">CLAS artifacts</h3> |
81 | | - <p class="feat-desc">CommandLayer SDK distribution and implementation references.</p> |
82 | | - <span class="mono">@commandlayer/agent-sdk</span> |
83 | | - <span class="mono">npm install @commandlayer/agent-sdk</span> |
84 | | - <ul class="link-list"> |
85 | | - <li><a href="https://www.npmjs.com/package/@commandlayer/agent-sdk" target="_blank" rel="noopener">npm package</a></li> |
86 | | - <li><a href="https://github.com/commandlayer/agent-sdk" target="_blank" rel="noopener">GitHub repository</a></li> |
87 | | - <li><a href="https://github.com/commandlayer/clas/blob/main/schemas/trust-verification/verify/verify.openapi.yaml" target="_blank" rel="noopener">Verify OpenAPI schema</a></li> |
88 | | - </ul> |
89 | | - </article> |
| 51 | +const { output, receipt } = await cl.wrap("sign", async () => { |
| 52 | + return { |
| 53 | + message: "hello from SDK" |
| 54 | + }; |
| 55 | +}); |
90 | 56 |
|
91 | | - <article class="feat-card"> |
92 | | - <h3 class="feat-title">ENS discovery</h3> |
93 | | - <p class="feat-desc">Profile fields advertised for signer and cryptographic compatibility.</p> |
94 | | - <div class="profile"> |
95 | | - <div><strong>signer:</strong><span>runtime.commandlayer.eth</span></div> |
96 | | - <div><strong>key_id:</strong><span>vC4WbcNoq2znSCiQ</span></div> |
97 | | - <div><strong>canonicalization:</strong><span>json.sorted_keys.v1</span></div> |
98 | | - <div><strong>hash:</strong><span>sha256</span></div> |
99 | | - <div><strong>signature:</strong><span>ed25519</span></div> |
100 | | - </div> |
101 | | - </article> |
| 57 | +const verified = await cl.verify(receipt);</pre></div></section> |
102 | 58 |
|
103 | | - <article class="feat-card"> |
104 | | - <h3 class="feat-title">ERC-8004 alignment</h3> |
105 | | - <p class="feat-desc">Capabilities exposed to agents and apps through the verification service.</p> |
106 | | - <ul class="caps"> |
107 | | - <li>verify_receipt</li> |
108 | | - <li>detect_tampering</li> |
109 | | - <li>resolve_ens_signer</li> |
110 | | - <li>validate_ed25519_signature</li> |
111 | | - <li>return_verified_or_invalid</li> |
112 | | - </ul> |
113 | | - </article> |
| 59 | +<section class="section section-alt"><div class="container"><div class="section-eyebrow">Receipt shape</div><h2 class="section-h2">Canonical metadata.proof fields.</h2><pre class="code">metadata.proof.canonicalization = "json.sorted_keys.v1" |
| 60 | +metadata.proof.hash.alg = "SHA-256" |
| 61 | +metadata.proof.hash.value = "..." |
| 62 | +metadata.proof.signature.alg = "Ed25519" |
| 63 | +metadata.proof.signature.kid = "vC4WbcNoq2znSCiQ" |
| 64 | +metadata.proof.signature.value = "..." |
| 65 | +metadata.proof.signer_id = "runtime.commandlayer.eth"</pre></div></section> |
114 | 66 |
|
115 | | - <article class="feat-card"> |
116 | | - <h3 class="feat-title">Ambient verification links</h3> |
117 | | - <p class="feat-desc">Direct entry points to report and ambient verification pages.</p> |
118 | | - <ul class="link-list"> |
119 | | - <li><a href="/verify/r/demo-valid-receipt">/verify/r/demo-valid-receipt</a></li> |
120 | | - <li><a href="/verify/r/demo-tampered-receipt">/verify/r/demo-tampered-receipt</a></li> |
121 | | - <li><a href="/ambient-verification.html">Ambient verification overview</a></li> |
122 | | - </ul> |
123 | | - </article> |
124 | | - </div> |
125 | | - </div> |
126 | | - </section> |
| 67 | +<section class="section"><div class="container"><div class="section-eyebrow">What the SDK does</div><div class="cards"><article class="card">Wraps agent actions into consistent execution envelopes.</article><article class="card">Emits canonical receipts for each wrapped action.</article><article class="card">Normalizes canonical proof shape under metadata.proof.</article><article class="card">Calls verifier endpoints to confirm receipt validity.</article><article class="card">Helps developers integrate without rebuilding proof plumbing.</article></div></div></section> |
| 68 | + |
| 69 | +<section class="section section-alt"><div class="container"><div class="section-eyebrow">Trust boundaries</div><h2 class="section-h2">What the SDK does not do.</h2><ul class="list"><li>SDK is not the protocol itself.</li><li>SDK is not the verifier.</li><li>SDK is not MCP.</li><li>SDK does not make schema-valid equal verified.</li><li>Verification requires hash and signature checks.</li></ul></div></section> |
| 70 | + |
| 71 | +<section class="section"><div class="container"><div class="section-eyebrow">Runtime vs SDK</div><h2 class="section-h2">How the layers fit together.</h2><p class="section-p">The SDK is for developers wrapping actions and generating canonical receipt metadata in client or server code.</p><p class="section-p">The runtime is the production signer/executor. MCP is a bridge. VerifyAgent/verifier validates receipts and returns verification states.</p></div></section> |
| 72 | + |
| 73 | +<section class="section section-alt"><div class="container"><div class="section-eyebrow">Trust Verification verbs supported</div><h2 class="section-h2">Canonical Trust Verification v1 verbs.</h2><div class="cards"><article class="card mono">verify</article><article class="card mono">sign</article><article class="card mono">attest</article><article class="card mono">authorize</article><article class="card mono">approve</article><article class="card mono">reject</article><article class="card mono">permit</article><article class="card mono">grant</article><article class="card mono">authenticate</article><article class="card mono">endorse</article></div><p class="section-p" style="margin-top:12px">These verbs are canonical Trust Verification v1 verbs, and runtime-backed production receipt endpoints exist for production verification flows.</p></div></section> |
| 74 | + |
| 75 | +<section class="section"><div class="container"><div class="section-eyebrow">Verification states</div><p class="section-p"><strong>VALID / VERIFIED</strong> = hash and signature checks passed. <strong>INVALID</strong> = proof failed. <strong>TRANSPORT_ERROR</strong> = verifier/runtime unavailable or request failed.</p><div class="cta-grid"><a class="cta" href="https://github.com/commandlayer/agent-sdk" target="_blank" rel="noopener"><strong>View SDK on GitHub</strong></a><a class="cta" href="/docs/wrap-your-agent.html"><strong>Read Docs</strong></a><a class="cta" href="/verify.html"><strong>Try Verifier</strong></a><a class="cta" href="/stack-proof-demo.html"><strong>View Production Proof</strong></a><a class="cta" href="/capabilities.html"><strong>Explore Capabilities</strong></a></div></div></section> |
| 76 | +</main> |
| 77 | +<footer><div class="container footer-grid"><div class="footer-col"><h4>Product</h4><a href="/protocol.html">Protocol</a><a href="/capabilities.html">Capabilities</a><a href="/verify.html">Verifier</a><a href="/runtime.html">Runtime</a><a href="/mcp.html">MCP</a><a href="/claim.html">Claim</a></div><div class="footer-col"><h4>Developers</h4><a href="/docs/wrap-your-agent.html">Docs</a><a href="/sdk-records.html">SDK</a><a href="/schemas/">Schemas</a><a href="/api/verify">API</a><a href="https://github.com/commandlayer" target="_blank" rel="noopener">GitHub</a></div><div class="footer-col"><h4>Proof</h4><a href="/stack-proof-demo.html">Production Proof</a><a href="/verify.html">VerifyAgent</a><a href="/capabilities/trust-verification/">Trust Verification</a><a href="/receipts/">Canonical Receipts</a></div></div></footer> |
127 | 78 | </body> |
128 | 79 | </html> |
0 commit comments