@emilia-protocol/mcp-server 1.0.0 → 1.0.1

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.
Files changed (4) hide show
  1. package/LICENSE +190 -0
  2. package/README.md +3 -1
  3. package/index.js +153 -13
  4. package/package.json +17 -17
package/LICENSE ADDED
@@ -0,0 +1,190 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to the Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by the Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding any notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ Copyright 2024–2026 EMILIA Protocol, Inc. and contributors
179
+
180
+ Licensed under the Apache License, Version 2.0 (the "License");
181
+ you may not use this file except in compliance with the License.
182
+ You may obtain a copy of the License at
183
+
184
+ http://www.apache.org/licenses/LICENSE-2.0
185
+
186
+ Unless required by applicable law or agreed to in writing, software
187
+ distributed under the License is distributed on an "AS IS" BASIS,
188
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
189
+ See the License for the specific language governing permissions and
190
+ limitations under the License.
package/README.md CHANGED
@@ -10,7 +10,7 @@
10
10
 
11
11
  ## What This Is
12
12
 
13
- EMILIA Protocol enforces trust before high-risk action. EP verifies whether a specific high-risk action should proceed under a specific authority context, governing policy, and transaction binding. This MCP server gives any Claude conversation or agent pipeline direct access to EP's trust-decision surfaces: 34 tools covering trust profiles, policy evaluation, handshake verification, signoff orchestration, and pre-action binding. Add it to Claude Desktop in 60 seconds. No self-hosted EP backend required.
13
+ EMILIA Protocol enforces trust before a high-risk action. This MCP server gives any Claude conversation or agent pipeline EP's gate: call **`ep_guard_action`** before any irreversible action a payment, deletion, or account change — to require a named human's signoff and get a verifiable receipt, then poll **`ep_check_signoff`** until it's approved. 36 tools in all, but by default the server advertises a **focused 17** the trust gate plus the pre-action protocol (handshake + commit binding, signoff orchestration, policy evaluation, offline receipt verification, delegation, install preflight). Set `EP_INCLUDE_REGISTRY_TOOLS=true` to also expose the legacy registry and reputation tools. Add it to Claude Desktop in 60 seconds. No self-hosted EP backend required.
14
14
 
15
15
  ---
16
16
 
@@ -255,6 +255,8 @@ The submitter has 7 days to respond. Trust is suspended pending resolution.
255
255
 
256
256
  | Tool | Description | Auth Required |
257
257
  |------|-------------|:---:|
258
+ | `ep_guard_action` | THE GATE — call before any irreversible action; mints a receipt, opens signoff | Yes |
259
+ | `ep_check_signoff` | Poll a pending signoff until a named human approves or denies | Yes |
258
260
  | `ep_trust_profile` | Full trust profile — the canonical read surface | No |
259
261
  | `ep_trust_evaluate` | Policy evaluation with Trust Decision (allow/review/deny) and failure reasons | No |
260
262
  | `ep_trust_gate` | Pre-action trust check — call before irreversible actions | No |
package/index.js CHANGED
@@ -48,7 +48,7 @@
48
48
  * ep_bind_receipt_to_commit — Bind a post-action receipt to a commit
49
49
  *
50
50
  * Setup:
51
- * EP_BASE_URL=https://emiliaprotocol.ai
51
+ * EP_BASE_URL=https://www.emiliaprotocol.ai
52
52
  * EP_API_KEY=ep_live_... (for authenticated writes; registration is public)
53
53
  *
54
54
  * @license Apache-2.0
@@ -66,7 +66,9 @@ import {
66
66
  } from '@modelcontextprotocol/sdk/types.js';
67
67
  import { AutoReceiptMiddleware } from './auto-receipt.js';
68
68
 
69
- const BASE_URL = process.env.EP_BASE_URL || 'https://emiliaprotocol.ai';
69
+ // NOTE: use the www host. The apex 307-redirects to www, and fetch drops the
70
+ // Authorization header on the cross-origin redirect — which would 401 authed calls.
71
+ const BASE_URL = process.env.EP_BASE_URL || 'https://www.emiliaprotocol.ai';
70
72
  const API_KEY = process.env.EP_API_KEY || '';
71
73
 
72
74
  // =============================================================================
@@ -108,6 +110,48 @@ async function epFetch(path, options = {}) {
108
110
  // =============================================================================
109
111
 
110
112
  const TOOLS = [
113
+ // ═══════════════════════════════════════════════════════════════════════════
114
+ // HERO — the gate. Use these before any irreversible action. This is the product.
115
+ // ═══════════════════════════════════════════════════════════════════════════
116
+ {
117
+ name: 'ep_guard_action',
118
+ description:
119
+ 'REQUIRED before any irreversible action: payments, wire transfers, fund releases, ' +
120
+ 'deletions, record or account changes, or sending messages with real-world effect. ' +
121
+ 'Submits the exact action for policy evaluation and human authorization. Returns ' +
122
+ 'APPROVED with a receipt the action may proceed under, or BLOCKED with a receipt_id + ' +
123
+ 'signoff_id while a named human reviews. Do NOT execute the action without an APPROVED ' +
124
+ 'result — if BLOCKED, poll ep_check_signoff with the receipt_id.',
125
+ inputSchema: {
126
+ type: 'object',
127
+ properties: {
128
+ organization_id: { type: 'string', description: 'The organization this action belongs to.' },
129
+ action_type: { type: 'string', description: 'Kind of action, e.g. "large_payment_release", "vendor_bank_account_change", "ai_agent_payment_action".' },
130
+ target_resource_id: { type: 'string', description: 'What is being acted on — an invoice id, account id, or record id.' },
131
+ amount: { type: 'number', description: 'Amount, for payments/releases.' },
132
+ currency: { type: 'string', description: 'ISO currency code, e.g. "USD".' },
133
+ destination: { type: 'string', description: 'Where funds or data are going (account, address).' },
134
+ summary: { type: 'string', description: 'One-line, human-readable description the approver will see.' },
135
+ risk_flags: { type: 'array', items: { type: 'string' }, description: 'Optional risk signals, e.g. ["new_destination","after_hours"].' },
136
+ },
137
+ required: ['organization_id', 'action_type', 'target_resource_id'],
138
+ },
139
+ },
140
+ {
141
+ name: 'ep_check_signoff',
142
+ description:
143
+ 'Poll a pending authorization after ep_guard_action returns BLOCKED. Pass the ' +
144
+ 'receipt_id. Returns PENDING, APPROVED (the action may now proceed), or DENIED (with ' +
145
+ 'reason). Safe to call repeatedly until a decision is reached.',
146
+ inputSchema: {
147
+ type: 'object',
148
+ properties: {
149
+ receipt_id: { type: 'string', description: 'The receipt_id returned by ep_guard_action.' },
150
+ },
151
+ required: ['receipt_id'],
152
+ },
153
+ },
154
+
111
155
  // PRIMARY: Trust profile (canonical read surface)
112
156
  {
113
157
  name: 'ep_trust_profile',
@@ -194,7 +238,11 @@ const TOOLS = [
194
238
  // SECONDARY
195
239
  {
196
240
  name: 'ep_search_entities',
197
- description: 'Search for entities by name, capability, or category.',
241
+ description:
242
+ 'Search the EP registry for entities by name, capability, or category. ' +
243
+ 'Read-only, no side effects. Returns a list of matching entities with their ' +
244
+ 'ids, types, and current trust scores — use it to discover an entity before ' +
245
+ 'evaluating or referencing it.',
198
246
  inputSchema: {
199
247
  type: 'object',
200
248
  properties: {
@@ -206,7 +254,11 @@ const TOOLS = [
206
254
  },
207
255
  {
208
256
  name: 'ep_verify_receipt',
209
- description: 'Verify a receipt against the on-chain Merkle root.',
257
+ description:
258
+ 'Verify a trust receipt — its signature and Merkle inclusion against the ' +
259
+ 'anchored root. Read-only. Returns valid/invalid plus the verified claim ' +
260
+ '(action, approver, outcome) and anchor status; use it to independently ' +
261
+ 'confirm a receipt was issued by EP and has not been tampered with.',
210
262
  inputSchema: {
211
263
  type: 'object',
212
264
  properties: {
@@ -217,7 +269,11 @@ const TOOLS = [
217
269
  },
218
270
  {
219
271
  name: 'ep_register_entity',
220
- description: 'Register a new entity. Public — returns the first API key.',
272
+ description:
273
+ 'Create a new entity in the EP registry. SIDE EFFECT: persists the entity ' +
274
+ 'and returns its API key once — store it, it cannot be retrieved later. ' +
275
+ 'Public, no auth required. Use to onboard an agent or service before it ' +
276
+ 'submits receipts or is evaluated.',
221
277
  inputSchema: {
222
278
  type: 'object',
223
279
  properties: {
@@ -232,7 +288,11 @@ const TOOLS = [
232
288
  },
233
289
  {
234
290
  name: 'ep_leaderboard',
235
- description: 'Get top entities ranked by trust confidence.',
291
+ description:
292
+ 'List the top entities ranked by trust confidence. Read-only. Returns up to ' +
293
+ 'the requested limit (default 10, max 50) with scores, optionally filtered by ' +
294
+ 'entity_type. For discovery and benchmarking — for a go/no-go decision on a ' +
295
+ 'specific action, use ep_guard_action instead.',
236
296
  inputSchema: {
237
297
  type: 'object',
238
298
  properties: {
@@ -261,7 +321,10 @@ const TOOLS = [
261
321
  },
262
322
  {
263
323
  name: 'ep_dispute_status',
264
- description: 'Check the status of a dispute. Public — transparency is a protocol value.',
324
+ description:
325
+ 'Look up the current state of a dispute by id. Read-only, public (no auth) — ' +
326
+ 'transparency is a protocol value. Returns the dispute status (open, ' +
327
+ 'under_review, upheld, rejected), the entity it concerns, and any resolution.',
265
328
  inputSchema: {
266
329
  type: 'object',
267
330
  properties: {
@@ -310,9 +373,10 @@ const TOOLS = [
310
373
  {
311
374
  name: 'ep_install_preflight',
312
375
  description:
313
- 'EP-SX: Should I install this plugin/app/package/extension? ' +
314
- 'Evaluates a software entity against a software-specific trust policy with context. ' +
315
- 'Returns allow/review/deny with specific reasons covering publisher, permissions, provenance, and trust history.',
376
+ 'BEFORE installing or enabling third-party software an agent depends on — an npm ' +
377
+ 'package, GitHub app, browser extension, or MCP server check it here. Evaluates the ' +
378
+ 'software against a fit-for-purpose trust policy and returns allow / review / deny with ' +
379
+ 'reasons covering publisher, requested permissions, provenance, and trust history.',
316
380
  inputSchema: {
317
381
  type: 'object',
318
382
  properties: {
@@ -622,7 +686,10 @@ const TOOLS = [
622
686
  },
623
687
  {
624
688
  name: 'ep_get_commit_status',
625
- description: 'Get the current state of a commit (active, revoked, expired, fulfilled).',
689
+ description:
690
+ 'Get the current state of a pre-action commit by id. Read-only. Returns one ' +
691
+ 'of active, revoked, expired, or fulfilled, plus the bound action hash and ' +
692
+ 'expiry — poll this to learn whether a commit may still be consumed.',
626
693
  inputSchema: {
627
694
  type: 'object',
628
695
  properties: {
@@ -633,7 +700,11 @@ const TOOLS = [
633
700
  },
634
701
  {
635
702
  name: 'ep_revoke_commit',
636
- description: 'Revoke an active commit before it is fulfilled or expires.',
703
+ description:
704
+ 'Revoke an active pre-action commit before it is fulfilled or expires. ' +
705
+ 'SIDE EFFECT: terminally cancels the commit — it can never be consumed after ' +
706
+ 'this, and the change is irreversible. Requires auth. Returns the revoked ' +
707
+ 'status; use when a pending action should be called off.',
637
708
  inputSchema: {
638
709
  type: 'object',
639
710
  properties: {
@@ -756,6 +827,54 @@ const TOOLS = [
756
827
 
757
828
  async function handleTool(name, args) {
758
829
  switch (name) {
830
+ // ─── HERO: the gate ──────────────────────────────────────────────────────
831
+ case 'ep_guard_action': {
832
+ if (!API_KEY) return 'Error: EP_API_KEY required to guard actions. Set it in MCP server config.';
833
+ // 1. Mint a pre-action trust receipt — runs the formally-verified policy engine server-side.
834
+ const mint = await epFetch('/api/v1/trust-receipts', {
835
+ method: 'POST', auth: true,
836
+ body: {
837
+ organization_id: args.organization_id,
838
+ action_type: args.action_type,
839
+ target_resource_id: args.target_resource_id,
840
+ amount: args.amount,
841
+ currency: args.currency,
842
+ risk_flags: args.risk_flags || [],
843
+ target_changed_fields: args.action_type === 'vendor_bank_account_change' ? ['bank_account'] : [],
844
+ },
845
+ });
846
+ if (mint.decision === 'deny') {
847
+ return `BLOCKED — denied by policy.\nreason: ${(mint.reasons || []).join('; ') || 'policy denial'}\n` +
848
+ `receipt_id: ${mint.receipt_id}\nDo not execute this action.`;
849
+ }
850
+ if (!mint.signoff_required) {
851
+ return `APPROVED — no human signoff required.\nreceipt_id: ${mint.receipt_id}\nThe action may proceed.`;
852
+ }
853
+ // 2. Signoff required → open the signoff request for a named human.
854
+ const sign = await epFetch('/api/v1/signoffs/request', {
855
+ method: 'POST', auth: true,
856
+ body: { receipt_id: mint.receipt_id, comment: args.summary || undefined },
857
+ });
858
+ return `BLOCKED — a named human must authorize this before it runs.\n` +
859
+ `receipt_id: ${mint.receipt_id}\nsignoff_id: ${sign.signoff_id}\nstatus: ${sign.status}\n` +
860
+ `reason: ${(mint.reasons || []).join('; ') || 'policy requires signoff'}\n` +
861
+ `Do NOT execute the action. Poll ep_check_signoff with this receipt_id until approved.`;
862
+ }
863
+
864
+ case 'ep_check_signoff': {
865
+ if (!API_KEY) return 'Error: EP_API_KEY required. Set it in MCP server config.';
866
+ const data = await epFetch(`/api/v1/trust-receipts/${encodeURIComponent(args.receipt_id)}`, { auth: true });
867
+ const status = data.receipt_status || data.status || 'pending_signoff';
868
+ // approved_pending_consume = signoff granted, not yet consumed; consumed = fully done.
869
+ if (['approved_pending_consume', 'approved', 'consumed', 'fulfilled'].includes(status)) {
870
+ return `APPROVED — the action is authorized and may proceed.\nreceipt_id: ${args.receipt_id}`;
871
+ }
872
+ if (['denied', 'rejected', 'revoked'].includes(status)) {
873
+ return `DENIED — a human rejected this action.\nreceipt_id: ${args.receipt_id}\nreason: ${data.reason || 'not stated'}\nDo not execute the action.`;
874
+ }
875
+ return `PENDING — awaiting a named human's signoff.\nreceipt_id: ${args.receipt_id}\nstatus: ${status}\nSafe to call again shortly.`;
876
+ }
877
+
759
878
  case 'ep_trust_profile': {
760
879
  const data = await epFetch(`/api/trust/profile/${encodeURIComponent(args.entity_id)}`);
761
880
  return formatTrustProfile(data);
@@ -1417,7 +1536,28 @@ const server = new Server(
1417
1536
  { capabilities: { tools: {}, resources: {}, prompts: {} } }
1418
1537
  );
1419
1538
 
1420
- server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: TOOLS }));
1539
+ // The default surface is the trust-gate + pre-action protocol — the reason
1540
+ // to install this server. The legacy registry/reputation tools (entity
1541
+ // scoring, leaderboards, disputes, identity continuity, ZK proofs) remain
1542
+ // fully implemented and callable, but are hidden from tool discovery unless
1543
+ // EP_INCLUDE_REGISTRY_TOOLS=true, so an agent sees a focused, coherent set.
1544
+ const CORE_TOOL_NAMES = new Set([
1545
+ 'ep_guard_action', 'ep_check_signoff', // the gate
1546
+ 'ep_initiate_handshake', 'ep_add_presentation', // pre-action binding
1547
+ 'ep_verify_handshake', 'ep_get_handshake', 'ep_revoke_handshake',
1548
+ 'ep_issue_commit', 'ep_verify_commit', 'ep_get_commit_status',
1549
+ 'ep_revoke_commit', 'ep_bind_receipt_to_commit',
1550
+ 'ep_verify_receipt', // offline-verify a receipt
1551
+ 'ep_list_policies', // discover policies
1552
+ 'ep_create_delegation', 'ep_verify_delegation', // delegated authority
1553
+ 'ep_install_preflight', // vet software before install
1554
+ ]);
1555
+ const INCLUDE_REGISTRY_TOOLS = process.env.EP_INCLUDE_REGISTRY_TOOLS === 'true';
1556
+ const ADVERTISED_TOOLS = INCLUDE_REGISTRY_TOOLS
1557
+ ? TOOLS
1558
+ : TOOLS.filter((t) => CORE_TOOL_NAMES.has(t.name));
1559
+
1560
+ server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: ADVERTISED_TOOLS }));
1421
1561
 
1422
1562
  server.setRequestHandler(CallToolRequestSchema, async (request) => {
1423
1563
  const { name, arguments: args } = request.params;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@emilia-protocol/mcp-server",
3
3
  "mcpName": "io.github.emiliaprotocol/mcp-server",
4
- "version": "1.0.0",
4
+ "version": "1.0.1",
5
5
  "description": "EMILIA Protocol MCP Server — trust enforcement for high-risk actions via MCP. Pre-action binding, policy-bound verification, and accountable human signoff.",
6
6
  "main": "index.js",
7
7
  "type": "module",
@@ -11,7 +11,8 @@
11
11
  "files": [
12
12
  "index.js",
13
13
  "auto-receipt.js",
14
- "README.md"
14
+ "README.md",
15
+ "LICENSE"
15
16
  ],
16
17
  "scripts": {
17
18
  "test": "vitest run"
@@ -25,22 +26,21 @@
25
26
  "keywords": [
26
27
  "mcp",
27
28
  "model-context-protocol",
28
- "trust",
29
- "trust-profile",
30
- "trust-score",
31
- "policy-evaluation",
32
- "install-preflight",
33
- "appeals",
34
- "disputes",
35
- "software-trust",
36
- "marketplace-trust",
37
- "machine-actors",
38
- "counterparties",
39
- "ai-agents",
40
- "behavioral-receipts",
41
- "emilia-protocol",
29
+ "human-in-the-loop",
30
+ "human-signoff",
31
+ "webauthn",
32
+ "passkey",
33
+ "irreversible-actions",
34
+ "payment-guard",
35
+ "agent-accountability",
42
36
  "agent-safety",
43
- "delegation"
37
+ "ai-agents",
38
+ "trust-receipt",
39
+ "offline-verification",
40
+ "separation-of-duties",
41
+ "policy-evaluation",
42
+ "delegation",
43
+ "emilia-protocol"
44
44
  ],
45
45
  "license": "Apache-2.0",
46
46
  "engines": {