@ultimat3/mcp 31.25.0 → 31.27.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
@@ -210,7 +210,7 @@ is `X_MCP_TOOL_UNSAFE` at boot, and an unmarked tool is metered as a write.
210
210
  declaration surface: a scope name → the TOOL NAMES it covers, however each one reached the
211
211
  catalog — a projected action, a projected query, or a key in `tools`. It lives here, not
212
212
  beside the action, because a scope is a capability of the CONNECTION's token — what
213
- `x token grant <scope>` names — not a fact about the operation; the policy beside the action
213
+ `x token create --scopes <a,b>` issues — not a fact about the operation; the policy beside the action
214
214
  stays the only rule that reads the input. A name this server does not project is
215
215
  `X_MCP_SCOPE_UNKNOWN` at boot; one tool claimed by two scopes is `X_MCP_SCOPE_CONFLICT`.
216
216
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ultimat3/mcp",
3
- "version": "31.25.0",
3
+ "version": "31.27.0",
4
4
  "description": "MCP server, dev tools, and the action-to-tool projection \u2014 one authz system, two surfaces",
5
5
  "keywords": [
6
6
  "ultimate",
@@ -44,15 +44,15 @@
44
44
  "test": "bun test"
45
45
  },
46
46
  "dependencies": {
47
- "@ultimat3/action": "31.25.0",
48
- "@ultimat3/auth": "31.25.0",
49
- "@ultimat3/core": "31.25.0",
50
- "@ultimat3/db": "31.25.0",
51
- "@ultimat3/entity": "31.25.0",
52
- "@ultimat3/http": "31.25.0",
53
- "@ultimat3/jobs": "31.25.0",
54
- "@ultimat3/policy": "31.25.0",
55
- "@ultimat3/query": "31.25.0",
56
- "@ultimat3/schema": "31.25.0"
47
+ "@ultimat3/action": "31.27.0",
48
+ "@ultimat3/auth": "31.27.0",
49
+ "@ultimat3/core": "31.27.0",
50
+ "@ultimat3/db": "31.27.0",
51
+ "@ultimat3/entity": "31.27.0",
52
+ "@ultimat3/http": "31.27.0",
53
+ "@ultimat3/jobs": "31.27.0",
54
+ "@ultimat3/policy": "31.27.0",
55
+ "@ultimat3/query": "31.27.0",
56
+ "@ultimat3/schema": "31.27.0"
57
57
  }
58
58
  }
@@ -87,6 +87,16 @@ export function declaredMcpServers(): ReadonlyMap<string, DeclaredMcpServer> {
87
87
  return DECLARED;
88
88
  }
89
89
 
90
+ /**
91
+ * Test seam: exactly `servers` again — a copy of what `declaredMcpServers()` answered earlier. A
92
+ * REPLACE, never a reset: `mcpTools()` runs at module scope, once per process. `@ultimat3/testing`'s
93
+ * file boundary is the caller.
94
+ */
95
+ export function restoreDeclaredMcpServers(servers: ReadonlyMap<string, DeclaredMcpServer>): void {
96
+ DECLARED.clear();
97
+ for (const [name, server] of servers) DECLARED.set(name, server);
98
+ }
99
+
90
100
  export function mcpTools(def: McpToolsDef): McpTools {
91
101
  const maxChars = finiteCount('mcpTools', 'maxResultChars', def.maxResultChars ?? 20_000, 1);
92
102
  const reverifyMs = finiteCount(