@agledger/mcp-server 1.3.0 → 1.4.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 +6 -6
- package/dist/enums.d.ts +6 -3
- package/dist/enums.d.ts.map +1 -1
- package/dist/enums.js +2 -1
- package/dist/enums.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +19 -15
- package/dist/index.js.map +1 -1
- package/dist/server.d.ts +2 -2
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +12 -5
- package/dist/server.js.map +1 -1
- package/dist/tool-scopes.js +1 -1
- package/dist/tool-scopes.js.map +1 -1
- package/dist/tools/a2a.d.ts.map +1 -1
- package/dist/tools/a2a.js +142 -43
- package/dist/tools/a2a.js.map +1 -1
- package/dist/tools/mandates.d.ts.map +1 -1
- package/dist/tools/mandates.js +0 -40
- package/dist/tools/mandates.js.map +1 -1
- package/dist/tools/receipts.d.ts +5 -1
- package/dist/tools/receipts.d.ts.map +1 -1
- package/dist/tools/receipts.js +94 -53
- package/dist/tools/receipts.js.map +1 -1
- package/dist/tools/verification.d.ts.map +1 -1
- package/dist/tools/verification.js +2 -1
- package/dist/tools/verification.js.map +1 -1
- package/package.json +1 -1
- package/src/enums.ts +2 -1
- package/src/index.ts +20 -16
- package/src/server.ts +14 -7
- package/src/tool-scopes.ts +1 -1
- package/src/tools/a2a.ts +629 -505
- package/src/tools/mandates.ts +0 -44
- package/src/tools/receipts.ts +214 -167
- package/src/tools/verification.ts +2 -1
package/src/server.ts
CHANGED
|
@@ -23,12 +23,12 @@ import { registerCodeModeTools } from './tools/code-mode.js';
|
|
|
23
23
|
import { registerVerificationKeysTools } from './tools/verification-keys.js';
|
|
24
24
|
import { registerContractTypeResources } from './resources/contract-types.js';
|
|
25
25
|
|
|
26
|
-
export type ToolProfile = 'full' | 'code' | '
|
|
26
|
+
export type ToolProfile = 'full' | 'code' | 'agent' | 'openclaw' | 'schema-dev' | 'admin' | 'audit' | 'federation';
|
|
27
27
|
|
|
28
28
|
export interface AgledgerMcpServerOptions {
|
|
29
29
|
apiKey: string;
|
|
30
30
|
apiUrl?: string;
|
|
31
|
-
/** Tool profile: "code" (2 tools — SDK code execution + docs
|
|
31
|
+
/** Tool profile: "code" (2 tools — SDK code execution + docs), "agent", "openclaw", "schema-dev", "admin", "audit", "federation", or "full" (legacy, all individual tools). */
|
|
32
32
|
profile?: ToolProfile;
|
|
33
33
|
/** Enterprise ID for A2A search queries. Falls back to AGLEDGER_ENTERPRISE_ID env var. */
|
|
34
34
|
enterpriseId?: string;
|
|
@@ -47,7 +47,7 @@ export class AgledgerMcpServer {
|
|
|
47
47
|
this.mcp = new McpServer(
|
|
48
48
|
{
|
|
49
49
|
name: 'agledger-mcp-server',
|
|
50
|
-
version: '1.
|
|
50
|
+
version: '1.4.0',
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
53
|
capabilities: {
|
|
@@ -72,16 +72,21 @@ export class AgledgerMcpServer {
|
|
|
72
72
|
} else if (this.profile === 'openclaw') {
|
|
73
73
|
// OpenClaw profile: 5 thin notarization tools (<500 tokens total schema)
|
|
74
74
|
registerOpenClawTools(this.mcp, this.client);
|
|
75
|
-
} else if (this.profile === '
|
|
76
|
-
//
|
|
75
|
+
} else if (this.profile === 'agent') {
|
|
76
|
+
// Standard agent profile: create mandates, submit receipts, get verdicts, verify, check status
|
|
77
77
|
registerA2aTools(this.mcp, this.client, { enterpriseId: this.enterpriseId });
|
|
78
|
+
registerReceiptTools(this.mcp, this.client, { skipSubmit: true }); // a2a tools include submit_receipt with workflow guidance
|
|
79
|
+
registerVerificationTools(this.mcp, this.client);
|
|
78
80
|
registerAgentsRefsTools(this.mcp, this.client);
|
|
81
|
+
registerHealthTools(this.mcp, this.client);
|
|
79
82
|
} else if (this.profile === 'schema-dev') {
|
|
80
83
|
// Schema development profile: schema tools + health check
|
|
81
84
|
registerSchemaTools(this.mcp, this.client);
|
|
82
85
|
registerHealthTools(this.mcp, this.client);
|
|
83
86
|
} else if (this.profile === 'admin') {
|
|
84
|
-
// Admin profile: enterprise + agent management + references + federation admin
|
|
87
|
+
// Admin profile: enterprise + agent management + mandate visibility + references + federation admin
|
|
88
|
+
registerMandateTools(this.mcp, this.client);
|
|
89
|
+
registerReceiptTools(this.mcp, this.client);
|
|
85
90
|
registerEnterpriseTools(this.mcp, this.client);
|
|
86
91
|
registerCapabilityTools(this.mcp, this.client);
|
|
87
92
|
registerReputationTools(this.mcp, this.client);
|
|
@@ -96,7 +101,9 @@ export class AgledgerMcpServer {
|
|
|
96
101
|
registerAgentsRefsTools(this.mcp, this.client);
|
|
97
102
|
registerHealthTools(this.mcp, this.client);
|
|
98
103
|
} else if (this.profile === 'audit') {
|
|
99
|
-
// Audit profile: read-only compliance monitoring + dashboard + agent lookup
|
|
104
|
+
// Audit profile: read-only compliance monitoring + mandate visibility + dashboard + agent lookup
|
|
105
|
+
registerMandateTools(this.mcp, this.client);
|
|
106
|
+
registerReceiptTools(this.mcp, this.client);
|
|
100
107
|
registerEventTools(this.mcp, this.client);
|
|
101
108
|
registerVerificationTools(this.mcp, this.client);
|
|
102
109
|
registerDisputeTools(this.mcp, this.client);
|
package/src/tool-scopes.ts
CHANGED