nomos-mcp-bridge 1.0.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.
@@ -0,0 +1,309 @@
1
+ import { Client } from '@modelcontextprotocol/sdk/client/index.js';
2
+ import type { Controller } from './config.js';
3
+ export interface ConnectionInfo {
4
+ id: string;
5
+ name: string;
6
+ url: string;
7
+ }
8
+ export declare function connect(controller: Controller): Promise<{
9
+ name: string;
10
+ url: string;
11
+ }>;
12
+ export declare function disconnect(): Promise<void>;
13
+ export declare function isConnected(): boolean;
14
+ export declare function getConnectionInfo(): ConnectionInfo | null;
15
+ export declare function getClient(): Client | null;
16
+ export declare function listTools(): Promise<{
17
+ inputSchema: {
18
+ [x: string]: unknown;
19
+ type: "object";
20
+ properties?: Record<string, object> | undefined;
21
+ required?: string[] | undefined;
22
+ };
23
+ name: string;
24
+ description?: string | undefined;
25
+ outputSchema?: {
26
+ [x: string]: unknown;
27
+ type: "object";
28
+ properties?: Record<string, object> | undefined;
29
+ required?: string[] | undefined;
30
+ } | undefined;
31
+ annotations?: {
32
+ title?: string | undefined;
33
+ readOnlyHint?: boolean | undefined;
34
+ destructiveHint?: boolean | undefined;
35
+ idempotentHint?: boolean | undefined;
36
+ openWorldHint?: boolean | undefined;
37
+ } | undefined;
38
+ execution?: {
39
+ taskSupport?: "optional" | "required" | "forbidden" | undefined;
40
+ } | undefined;
41
+ _meta?: Record<string, unknown> | undefined;
42
+ icons?: {
43
+ src: string;
44
+ mimeType?: string | undefined;
45
+ sizes?: string[] | undefined;
46
+ theme?: "light" | "dark" | undefined;
47
+ }[] | undefined;
48
+ title?: string | undefined;
49
+ }[]>;
50
+ export declare function callTool(name: string, args?: Record<string, unknown>): Promise<{
51
+ [x: string]: unknown;
52
+ content: ({
53
+ type: "text";
54
+ text: string;
55
+ annotations?: {
56
+ audience?: ("user" | "assistant")[] | undefined;
57
+ priority?: number | undefined;
58
+ lastModified?: string | undefined;
59
+ } | undefined;
60
+ _meta?: Record<string, unknown> | undefined;
61
+ } | {
62
+ type: "image";
63
+ data: string;
64
+ mimeType: string;
65
+ annotations?: {
66
+ audience?: ("user" | "assistant")[] | undefined;
67
+ priority?: number | undefined;
68
+ lastModified?: string | undefined;
69
+ } | undefined;
70
+ _meta?: Record<string, unknown> | undefined;
71
+ } | {
72
+ type: "audio";
73
+ data: string;
74
+ mimeType: string;
75
+ annotations?: {
76
+ audience?: ("user" | "assistant")[] | undefined;
77
+ priority?: number | undefined;
78
+ lastModified?: string | undefined;
79
+ } | undefined;
80
+ _meta?: Record<string, unknown> | undefined;
81
+ } | {
82
+ type: "resource";
83
+ resource: {
84
+ uri: string;
85
+ text: string;
86
+ mimeType?: string | undefined;
87
+ _meta?: Record<string, unknown> | undefined;
88
+ } | {
89
+ uri: string;
90
+ blob: string;
91
+ mimeType?: string | undefined;
92
+ _meta?: Record<string, unknown> | undefined;
93
+ };
94
+ annotations?: {
95
+ audience?: ("user" | "assistant")[] | undefined;
96
+ priority?: number | undefined;
97
+ lastModified?: string | undefined;
98
+ } | undefined;
99
+ _meta?: Record<string, unknown> | undefined;
100
+ } | {
101
+ uri: string;
102
+ name: string;
103
+ type: "resource_link";
104
+ description?: string | undefined;
105
+ mimeType?: string | undefined;
106
+ annotations?: {
107
+ audience?: ("user" | "assistant")[] | undefined;
108
+ priority?: number | undefined;
109
+ lastModified?: string | undefined;
110
+ } | undefined;
111
+ _meta?: {
112
+ [x: string]: unknown;
113
+ } | undefined;
114
+ icons?: {
115
+ src: string;
116
+ mimeType?: string | undefined;
117
+ sizes?: string[] | undefined;
118
+ theme?: "light" | "dark" | undefined;
119
+ }[] | undefined;
120
+ title?: string | undefined;
121
+ })[];
122
+ _meta?: {
123
+ [x: string]: unknown;
124
+ progressToken?: string | number | undefined;
125
+ "io.modelcontextprotocol/related-task"?: {
126
+ taskId: string;
127
+ } | undefined;
128
+ } | undefined;
129
+ structuredContent?: Record<string, unknown> | undefined;
130
+ isError?: boolean | undefined;
131
+ } | {
132
+ [x: string]: unknown;
133
+ toolResult: unknown;
134
+ _meta?: {
135
+ [x: string]: unknown;
136
+ progressToken?: string | number | undefined;
137
+ "io.modelcontextprotocol/related-task"?: {
138
+ taskId: string;
139
+ } | undefined;
140
+ } | undefined;
141
+ }>;
142
+ export declare function listResources(): Promise<{
143
+ uri: string;
144
+ name: string;
145
+ description?: string | undefined;
146
+ mimeType?: string | undefined;
147
+ annotations?: {
148
+ audience?: ("user" | "assistant")[] | undefined;
149
+ priority?: number | undefined;
150
+ lastModified?: string | undefined;
151
+ } | undefined;
152
+ _meta?: {
153
+ [x: string]: unknown;
154
+ } | undefined;
155
+ icons?: {
156
+ src: string;
157
+ mimeType?: string | undefined;
158
+ sizes?: string[] | undefined;
159
+ theme?: "light" | "dark" | undefined;
160
+ }[] | undefined;
161
+ title?: string | undefined;
162
+ }[]>;
163
+ export declare function listResourceTemplates(): Promise<{
164
+ uriTemplate: string;
165
+ name: string;
166
+ description?: string | undefined;
167
+ mimeType?: string | undefined;
168
+ annotations?: {
169
+ audience?: ("user" | "assistant")[] | undefined;
170
+ priority?: number | undefined;
171
+ lastModified?: string | undefined;
172
+ } | undefined;
173
+ _meta?: {
174
+ [x: string]: unknown;
175
+ } | undefined;
176
+ icons?: {
177
+ src: string;
178
+ mimeType?: string | undefined;
179
+ sizes?: string[] | undefined;
180
+ theme?: "light" | "dark" | undefined;
181
+ }[] | undefined;
182
+ title?: string | undefined;
183
+ }[]>;
184
+ export declare function readResource(uri: string): Promise<{
185
+ [x: string]: unknown;
186
+ contents: ({
187
+ uri: string;
188
+ text: string;
189
+ mimeType?: string | undefined;
190
+ _meta?: Record<string, unknown> | undefined;
191
+ } | {
192
+ uri: string;
193
+ blob: string;
194
+ mimeType?: string | undefined;
195
+ _meta?: Record<string, unknown> | undefined;
196
+ })[];
197
+ _meta?: {
198
+ [x: string]: unknown;
199
+ progressToken?: string | number | undefined;
200
+ "io.modelcontextprotocol/related-task"?: {
201
+ taskId: string;
202
+ } | undefined;
203
+ } | undefined;
204
+ }>;
205
+ export declare function listPrompts(): Promise<{
206
+ name: string;
207
+ description?: string | undefined;
208
+ arguments?: {
209
+ name: string;
210
+ description?: string | undefined;
211
+ required?: boolean | undefined;
212
+ }[] | undefined;
213
+ _meta?: {
214
+ [x: string]: unknown;
215
+ } | undefined;
216
+ icons?: {
217
+ src: string;
218
+ mimeType?: string | undefined;
219
+ sizes?: string[] | undefined;
220
+ theme?: "light" | "dark" | undefined;
221
+ }[] | undefined;
222
+ title?: string | undefined;
223
+ }[]>;
224
+ export declare function getPrompt(name: string, args?: Record<string, string>): Promise<{
225
+ [x: string]: unknown;
226
+ messages: {
227
+ role: "user" | "assistant";
228
+ content: {
229
+ type: "text";
230
+ text: string;
231
+ annotations?: {
232
+ audience?: ("user" | "assistant")[] | undefined;
233
+ priority?: number | undefined;
234
+ lastModified?: string | undefined;
235
+ } | undefined;
236
+ _meta?: Record<string, unknown> | undefined;
237
+ } | {
238
+ type: "image";
239
+ data: string;
240
+ mimeType: string;
241
+ annotations?: {
242
+ audience?: ("user" | "assistant")[] | undefined;
243
+ priority?: number | undefined;
244
+ lastModified?: string | undefined;
245
+ } | undefined;
246
+ _meta?: Record<string, unknown> | undefined;
247
+ } | {
248
+ type: "audio";
249
+ data: string;
250
+ mimeType: string;
251
+ annotations?: {
252
+ audience?: ("user" | "assistant")[] | undefined;
253
+ priority?: number | undefined;
254
+ lastModified?: string | undefined;
255
+ } | undefined;
256
+ _meta?: Record<string, unknown> | undefined;
257
+ } | {
258
+ type: "resource";
259
+ resource: {
260
+ uri: string;
261
+ text: string;
262
+ mimeType?: string | undefined;
263
+ _meta?: Record<string, unknown> | undefined;
264
+ } | {
265
+ uri: string;
266
+ blob: string;
267
+ mimeType?: string | undefined;
268
+ _meta?: Record<string, unknown> | undefined;
269
+ };
270
+ annotations?: {
271
+ audience?: ("user" | "assistant")[] | undefined;
272
+ priority?: number | undefined;
273
+ lastModified?: string | undefined;
274
+ } | undefined;
275
+ _meta?: Record<string, unknown> | undefined;
276
+ } | {
277
+ uri: string;
278
+ name: string;
279
+ type: "resource_link";
280
+ description?: string | undefined;
281
+ mimeType?: string | undefined;
282
+ annotations?: {
283
+ audience?: ("user" | "assistant")[] | undefined;
284
+ priority?: number | undefined;
285
+ lastModified?: string | undefined;
286
+ } | undefined;
287
+ _meta?: {
288
+ [x: string]: unknown;
289
+ } | undefined;
290
+ icons?: {
291
+ src: string;
292
+ mimeType?: string | undefined;
293
+ sizes?: string[] | undefined;
294
+ theme?: "light" | "dark" | undefined;
295
+ }[] | undefined;
296
+ title?: string | undefined;
297
+ };
298
+ }[];
299
+ _meta?: {
300
+ [x: string]: unknown;
301
+ progressToken?: string | number | undefined;
302
+ "io.modelcontextprotocol/related-task"?: {
303
+ taskId: string;
304
+ } | undefined;
305
+ } | undefined;
306
+ description?: string | undefined;
307
+ }>;
308
+ export declare function getInstructions(): string | undefined;
309
+ //# sourceMappingURL=proxy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"proxy.d.ts","sourceRoot":"","sources":["../src/proxy.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,2CAA2C,CAAC;AAEnE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAM9C,MAAM,WAAW,cAAc;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;CACf;AAED,wBAAsB,OAAO,CAAC,UAAU,EAAE,UAAU,GAAG,OAAO,CAAC;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAAC,CAyB5F;AAED,wBAAsB,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC,CAUhD;AAED,wBAAgB,WAAW,IAAI,OAAO,CAErC;AAED,wBAAgB,iBAAiB,IAAI,cAAc,GAAG,IAAI,CAOzD;AAED,wBAAgB,SAAS,IAAI,MAAM,GAAG,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C,CAAC;aAA6C,CAAC;;;KA5B77U;AAED,wBAAsB,YAAY,CAAC,GAAG,EAAE,MAAM;;;;;gBA0BggW,CAAC;aAAuC,CAAC;;;;gBAA4H,CAAC;aAAuC,CAAC;;;;qBAAkI,CAAC;8CAAiF,CAAC;;;;GAvBh9W;AAED,wBAAsB,WAAW;;;;;mBAqB8vP,CAAC;gBAA8C,CAAC;;;;;;;gBAAsN,CAAC;aAA2C,CAAC;aAA6C,CAAC;;;KAX/nQ;AAED,wBAAsB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;;;;;;;uBASi8I,CAAC;wBAAgC,CAAC;wBAAoE,CAAC;4BAAsD,CAAC;;iBAA0E,CAAC;;;;;uBAAmL,CAAC;wBAAgC,CAAC;wBAAoE,CAAC;4BAAsD,CAAC;;iBAA0E,CAAC;;;;;uBAAmL,CAAC;wBAAgC,CAAC;wBAAoE,CAAC;4BAAsD,CAAC;;iBAA0E,CAAC;;;;;;wBAAsN,CAAC;qBAA+C,CAAC;;;;wBAA4J,CAAC;qBAA+C,CAAC;;uBAAqF,CAAC;wBAAgC,CAAC;wBAAoE,CAAC;4BAAsD,CAAC;;iBAA0E,CAAC;;;;;uBAAsL,CAAC;oBAA8C,CAAC;uBAAiD,CAAC;wBAAgC,CAAC;wBAAoE,CAAC;4BAAsD,CAAC;;iBAA0E,CAAC;;;iBAAkG,CAAC;;wBAAiE,CAAC;qBAA+C,CAAC;qBAAiD,CAAC;;iBAAsF,CAAC;;;;;qBAA+H,CAAC;8CAAiF,CAAC;;;;;GAN92O;AAED,wBAAgB,eAAe,IAAI,MAAM,GAAG,SAAS,CAGpD"}
package/dist/proxy.js ADDED
@@ -0,0 +1,124 @@
1
+ import { Client } from '@modelcontextprotocol/sdk/client/index.js';
2
+ import { StreamableHTTPClientTransport } from '@modelcontextprotocol/sdk/client/streamableHttp.js';
3
+ let activeClient = null;
4
+ let activeTransport = null;
5
+ let activeControllerInfo = null;
6
+ export async function connect(controller) {
7
+ await disconnect();
8
+ const url = new URL(controller.url);
9
+ const transport = new StreamableHTTPClientTransport(url, {
10
+ requestInit: {
11
+ headers: {
12
+ 'Authorization': 'Bearer ' + controller.token,
13
+ },
14
+ },
15
+ });
16
+ const client = new Client({
17
+ name: 'nomos-mcp-bridge',
18
+ version: '1.0.0',
19
+ });
20
+ await client.connect(transport);
21
+ activeClient = client;
22
+ activeTransport = transport;
23
+ activeControllerInfo = controller;
24
+ return { name: controller.name, url: controller.url };
25
+ }
26
+ export async function disconnect() {
27
+ if (activeTransport) {
28
+ try {
29
+ await activeTransport.terminateSession();
30
+ }
31
+ catch { /* ignore */ }
32
+ }
33
+ if (activeClient) {
34
+ try {
35
+ await activeClient.close();
36
+ }
37
+ catch { /* ignore */ }
38
+ }
39
+ activeClient = null;
40
+ activeTransport = null;
41
+ activeControllerInfo = null;
42
+ }
43
+ export function isConnected() {
44
+ return activeClient !== null;
45
+ }
46
+ export function getConnectionInfo() {
47
+ if (!activeControllerInfo)
48
+ return null;
49
+ return {
50
+ id: activeControllerInfo.id,
51
+ name: activeControllerInfo.name,
52
+ url: activeControllerInfo.url,
53
+ };
54
+ }
55
+ export function getClient() {
56
+ return activeClient;
57
+ }
58
+ function ensureClient() {
59
+ if (!activeClient)
60
+ throw new Error('Not connected to any controller.');
61
+ return activeClient;
62
+ }
63
+ export async function listTools() {
64
+ const client = ensureClient();
65
+ const allTools = [];
66
+ let cursor;
67
+ do {
68
+ const result = await client.listTools({ cursor });
69
+ allTools.push(...result.tools);
70
+ cursor = result.nextCursor;
71
+ } while (cursor);
72
+ return allTools;
73
+ }
74
+ export async function callTool(name, args) {
75
+ const client = ensureClient();
76
+ return await client.callTool({ name, arguments: args ?? {} });
77
+ }
78
+ export async function listResources() {
79
+ const client = ensureClient();
80
+ const allResources = [];
81
+ let cursor;
82
+ do {
83
+ const result = await client.listResources({ cursor });
84
+ allResources.push(...result.resources);
85
+ cursor = result.nextCursor;
86
+ } while (cursor);
87
+ return allResources;
88
+ }
89
+ export async function listResourceTemplates() {
90
+ const client = ensureClient();
91
+ const allTemplates = [];
92
+ let cursor;
93
+ do {
94
+ const result = await client.listResourceTemplates({ cursor });
95
+ allTemplates.push(...result.resourceTemplates);
96
+ cursor = result.nextCursor;
97
+ } while (cursor);
98
+ return allTemplates;
99
+ }
100
+ export async function readResource(uri) {
101
+ const client = ensureClient();
102
+ return await client.readResource({ uri });
103
+ }
104
+ export async function listPrompts() {
105
+ const client = ensureClient();
106
+ const allPrompts = [];
107
+ let cursor;
108
+ do {
109
+ const result = await client.listPrompts({ cursor });
110
+ allPrompts.push(...result.prompts);
111
+ cursor = result.nextCursor;
112
+ } while (cursor);
113
+ return allPrompts;
114
+ }
115
+ export async function getPrompt(name, args) {
116
+ const client = ensureClient();
117
+ return await client.getPrompt({ name, arguments: args ?? {} });
118
+ }
119
+ export function getInstructions() {
120
+ if (!activeClient)
121
+ return undefined;
122
+ return activeClient.getInstructions();
123
+ }
124
+ //# sourceMappingURL=proxy.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"proxy.js","sourceRoot":"","sources":["../src/proxy.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,2CAA2C,CAAC;AACnE,OAAO,EAAE,6BAA6B,EAAE,MAAM,oDAAoD,CAAC;AAGnG,IAAI,YAAY,GAAkB,IAAI,CAAC;AACvC,IAAI,eAAe,GAAyC,IAAI,CAAC;AACjE,IAAI,oBAAoB,GAAsB,IAAI,CAAC;AAQnD,MAAM,CAAC,KAAK,UAAU,OAAO,CAAC,UAAsB;IAChD,MAAM,UAAU,EAAE,CAAC;IAEnB,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC;IAEpC,MAAM,SAAS,GAAG,IAAI,6BAA6B,CAAC,GAAG,EAAE;QACrD,WAAW,EAAE;YACT,OAAO,EAAE;gBACL,eAAe,EAAE,SAAS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MAAM,UAAU,eAAe;IAC3B,IAAI,CAAC,YAAY;QAAE,OAAO,SAAS,CAAC;IACpC,OAAO,YAAY,CAAC,eAAe,EAAE,CAAC;AAC1C,CAAC"}
package/package.json ADDED
@@ -0,0 +1,44 @@
1
+ {
2
+ "name": "nomos-mcp-bridge",
3
+ "version": "1.0.0",
4
+ "description": "MCP proxy bridge for managing multiple nomos system controllers",
5
+ "main": "dist/index.js",
6
+ "type": "module",
7
+ "bin": {
8
+ "nomos-mcp-bridge": "dist/index.js"
9
+ },
10
+ "files": [
11
+ "dist/"
12
+ ],
13
+ "scripts": {
14
+ "build": "tsc",
15
+ "start": "node dist/index.js",
16
+ "dev": "tsc && node dist/index.js",
17
+ "prepublishOnly": "npm run build"
18
+ },
19
+ "keywords": [
20
+ "nomos",
21
+ "mcp",
22
+ "model-context-protocol",
23
+ "proxy",
24
+ "bridge",
25
+ "smart-home",
26
+ "iot"
27
+ ],
28
+ "author": "nomos system",
29
+ "license": "MIT",
30
+ "repository": {
31
+ "type": "git",
32
+ "url": "https://github.com/nomos-system/nomos-mcp-bridge.git"
33
+ },
34
+ "homepage": "https://github.com/nomos-system/nomos-mcp-bridge",
35
+ "dependencies": {
36
+ "@modelcontextprotocol/sdk": "^1.27.1",
37
+ "open": "^10.1.0",
38
+ "zod": "^3.24.1"
39
+ },
40
+ "devDependencies": {
41
+ "@types/node": "^20.0.0",
42
+ "typescript": "^5.7.0"
43
+ }
44
+ }