@ours.network/mcp 1.2.0-nightly.11 → 1.2.0-nightly.13
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 +16 -0
- package/dist/cli.js +1 -1
- package/dist/connector.js +23 -23
- package/dist/server.js +29 -29
- package/dist/types/mcp/registry.d.ts +3 -0
- package/dist/types/mcp/server.d.ts +7 -0
- package/dist/types/mcp/tools/messaging.d.ts +16 -2
- package/package.json +5 -5
|
@@ -19,4 +19,7 @@ export declare class ToolRegistry {
|
|
|
19
19
|
}>;
|
|
20
20
|
constructor(server: McpServer, policy?: ToolPolicy | undefined);
|
|
21
21
|
tool(effect: ToolEffect): McpServer['tool'];
|
|
22
|
+
/** Public registration API accepts a strict Zod object without stripping route fields. */
|
|
23
|
+
registerTool(effect: ToolEffect): McpServer['registerTool'];
|
|
24
|
+
private registration;
|
|
22
25
|
}
|
|
@@ -4,6 +4,7 @@ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
|
4
4
|
import type { OursClient } from '@ours.network/sdk';
|
|
5
5
|
import type { ApplicationIdentityStore } from '../application-identities.js';
|
|
6
6
|
import type { OursClientProvider } from './tool.js';
|
|
7
|
+
import { type CurrentChatFileSender } from './tools/messaging.js';
|
|
7
8
|
/**
|
|
8
9
|
* Build one per-session MCP server around the already-attached shared-daemon
|
|
9
10
|
* client.
|
|
@@ -12,6 +13,8 @@ export declare function createOursMcpServer(client: OursClient | OursClientProvi
|
|
|
12
13
|
remoteDaemonFiles?: boolean;
|
|
13
14
|
policy?: ToolPolicy;
|
|
14
15
|
fileContext?: FileExecutionContext;
|
|
16
|
+
currentChatFile?: CurrentChatFileSender;
|
|
17
|
+
currentChatFileDirectory?: string;
|
|
15
18
|
}): McpServer;
|
|
16
19
|
export { REGISTRY_VERSION, TOOL_EFFECTS, type ToolEffect, type ToolPolicy } from "./registry.js";
|
|
17
20
|
export type { FileExecutionContext } from "./file-context.js";
|
|
@@ -20,4 +23,8 @@ export declare function createManagedOursMcpServer(client: OursClient, version:
|
|
|
20
23
|
fileContext: FileExecutionContext;
|
|
21
24
|
admit: ToolPolicy['admit'];
|
|
22
25
|
remoteDaemonFiles?: boolean;
|
|
26
|
+
currentChatFile?: CurrentChatFileSender;
|
|
27
|
+
currentChatFileDirectory?: string;
|
|
23
28
|
}): McpServer;
|
|
29
|
+
export type { CurrentChatFileSender } from "./tools/messaging.js";
|
|
30
|
+
export declare const MANAGED_FILE_DELIVERY_VERSION: 1;
|
|
@@ -1,4 +1,18 @@
|
|
|
1
1
|
import { type FileExecutionContext } from '../file-context.js';
|
|
2
2
|
import type { ToolRegistry } from '../registry.js';
|
|
3
|
-
import { type OursClientProvider } from '../tool.js';
|
|
4
|
-
|
|
3
|
+
import { type OursClientProvider, type ToolRequestExtra } from '../tool.js';
|
|
4
|
+
/** Optional supervisor-owned delivery sink. Never obtains an Ours client. */
|
|
5
|
+
export type CurrentChatFileSender = (input: {
|
|
6
|
+
path: string;
|
|
7
|
+
filename?: string;
|
|
8
|
+
mime?: string;
|
|
9
|
+
}, extra: ToolRequestExtra) => Promise<{
|
|
10
|
+
id: string;
|
|
11
|
+
name: string;
|
|
12
|
+
mimeType: string;
|
|
13
|
+
size: number;
|
|
14
|
+
sessionGeneration: string;
|
|
15
|
+
acpSessionId: string;
|
|
16
|
+
turnId: string;
|
|
17
|
+
}>;
|
|
18
|
+
export declare function registerMessagingTools(server: ToolRegistry, clientFor: OursClientProvider, files?: FileExecutionContext, currentChatFile?: CurrentChatFileSender, currentChatFileDirectory?: string): void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ours.network/mcp",
|
|
3
|
-
"version": "1.2.0-nightly.
|
|
3
|
+
"version": "1.2.0-nightly.13",
|
|
4
4
|
"description": "MCP adapter for the shared ours daemon, with application-local identity bookkeeping and secure agent-to-agent messaging tools over stdio.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "FSL-1.1-Apache-2.0",
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
"test:external-profile": "node test/native-profile-session.test.mjs && node test/external-profile-stdio-refresh.test.mjs"
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@ours.network/sdk": "3.8.1-nightly.
|
|
62
|
-
"@modelcontextprotocol/sdk": "^1.0
|
|
61
|
+
"@ours.network/sdk": "3.8.1-nightly.17",
|
|
62
|
+
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
63
63
|
"zod": "^3.23.8"
|
|
64
64
|
},
|
|
65
65
|
"devDependencies": {
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"esbuild": "^0.24.2",
|
|
68
68
|
"tsx": "^4.19.0",
|
|
69
69
|
"typescript": "^5.5.4",
|
|
70
|
-
"@ours.network/cli": "2.8.1-nightly.
|
|
71
|
-
"@ours.network/daemon": "3.8.1-nightly.
|
|
70
|
+
"@ours.network/cli": "2.8.1-nightly.15",
|
|
71
|
+
"@ours.network/daemon": "3.8.1-nightly.9"
|
|
72
72
|
}
|
|
73
73
|
}
|