@contextual-io/cli 0.8.0 → 0.8.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.
- package/README.md +3 -3
- package/dist/commands/mcp/index.d.ts +3 -1
- package/dist/commands/mcp/index.js +12 -3
- package/oclif.manifest.json +116 -109
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -20,7 +20,7 @@ $ npm install -g @contextual-io/cli
|
|
|
20
20
|
$ ctxl COMMAND
|
|
21
21
|
running command...
|
|
22
22
|
$ ctxl (--version)
|
|
23
|
-
@contextual-io/cli/0.8.
|
|
23
|
+
@contextual-io/cli/0.8.1 linux-x64 node-v25.9.0
|
|
24
24
|
$ ctxl --help [COMMAND]
|
|
25
25
|
USAGE
|
|
26
26
|
$ ctxl COMMAND
|
|
@@ -273,9 +273,9 @@ DESCRIPTION
|
|
|
273
273
|
Manage local MCP server commands. Start with 'ctxl mcp serve' to run the local MCP bridge.
|
|
274
274
|
|
|
275
275
|
EXAMPLES
|
|
276
|
-
$ ctxl mcp
|
|
276
|
+
$ ctxl mcp serve
|
|
277
277
|
|
|
278
|
-
$ ctxl mcp flow-editor --flow my-flow-id
|
|
278
|
+
$ ctxl mcp serve flow-editor --flow my-flow-id
|
|
279
279
|
```
|
|
280
280
|
|
|
281
281
|
## `ctxl mcp serve [INTERFACE]`
|
|
@@ -3,7 +3,9 @@ export default class Mcp extends BaseConfigCommand<typeof Mcp> {
|
|
|
3
3
|
static args: {};
|
|
4
4
|
static description: string;
|
|
5
5
|
static examples: string[];
|
|
6
|
-
static flags: {
|
|
6
|
+
static flags: {
|
|
7
|
+
debug: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
};
|
|
7
9
|
static usage: string[];
|
|
8
10
|
run(): Promise<void>;
|
|
9
11
|
}
|
|
@@ -1,16 +1,25 @@
|
|
|
1
|
+
import { Flags } from "@oclif/core";
|
|
1
2
|
import { BaseConfigCommand } from "../../base.js";
|
|
2
3
|
export default class Mcp extends BaseConfigCommand {
|
|
3
4
|
static args = {};
|
|
4
5
|
static description = "Manage local MCP server commands. Start with 'ctxl mcp serve' to run the local MCP bridge.";
|
|
5
6
|
static examples = [
|
|
6
|
-
"<%= config.bin %> <%= command.id %>",
|
|
7
|
-
"<%= config.bin %> <%= command.id %> flow-editor --flow my-flow-id",
|
|
7
|
+
"<%= config.bin %> <%= command.id %> serve",
|
|
8
|
+
"<%= config.bin %> <%= command.id %> serve flow-editor --flow my-flow-id",
|
|
8
9
|
];
|
|
9
|
-
static flags = {
|
|
10
|
+
static flags = {
|
|
11
|
+
"debug": Flags.boolean({
|
|
12
|
+
default: false,
|
|
13
|
+
hidden: true,
|
|
14
|
+
}),
|
|
15
|
+
};
|
|
10
16
|
static usage = [
|
|
11
17
|
"<%= command.id %> <COMMAND>",
|
|
12
18
|
];
|
|
13
19
|
async run() {
|
|
20
|
+
if (this.flags.debug) {
|
|
21
|
+
console.log("user-agent: %s", process.env.npm_config_user_agent);
|
|
22
|
+
}
|
|
14
23
|
await this.showHelp();
|
|
15
24
|
}
|
|
16
25
|
}
|
package/oclif.manifest.json
CHANGED
|
@@ -1,5 +1,120 @@
|
|
|
1
1
|
{
|
|
2
2
|
"commands": {
|
|
3
|
+
"mcp": {
|
|
4
|
+
"aliases": [],
|
|
5
|
+
"args": {},
|
|
6
|
+
"description": "Manage local MCP server commands. Start with 'ctxl mcp serve' to run the local MCP bridge.",
|
|
7
|
+
"examples": [
|
|
8
|
+
"<%= config.bin %> <%= command.id %> serve",
|
|
9
|
+
"<%= config.bin %> <%= command.id %> serve flow-editor --flow my-flow-id"
|
|
10
|
+
],
|
|
11
|
+
"flags": {
|
|
12
|
+
"debug": {
|
|
13
|
+
"hidden": true,
|
|
14
|
+
"name": "debug",
|
|
15
|
+
"allowNo": false,
|
|
16
|
+
"type": "boolean"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"hasDynamicHelp": false,
|
|
20
|
+
"hiddenAliases": [],
|
|
21
|
+
"id": "mcp",
|
|
22
|
+
"pluginAlias": "@contextual-io/cli",
|
|
23
|
+
"pluginName": "@contextual-io/cli",
|
|
24
|
+
"pluginType": "core",
|
|
25
|
+
"strict": true,
|
|
26
|
+
"usage": [
|
|
27
|
+
"<%= command.id %> <COMMAND>"
|
|
28
|
+
],
|
|
29
|
+
"enableJsonFlag": false,
|
|
30
|
+
"isESM": true,
|
|
31
|
+
"relativePath": [
|
|
32
|
+
"dist",
|
|
33
|
+
"commands",
|
|
34
|
+
"mcp",
|
|
35
|
+
"index.js"
|
|
36
|
+
]
|
|
37
|
+
},
|
|
38
|
+
"mcp:serve": {
|
|
39
|
+
"aliases": [],
|
|
40
|
+
"args": {
|
|
41
|
+
"interface": {
|
|
42
|
+
"default": "flow-editor",
|
|
43
|
+
"description": "Interface type to scope tools for. Available interfaces depend on your platform version.",
|
|
44
|
+
"name": "interface",
|
|
45
|
+
"required": false
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"description": "Start a local MCP HTTP server that connects to SolutionAI for a given interface type. By default it binds to http://localhost:5051/. The server fetches the full tool manifest from SolutionAI and serves all tools immediately. Pass a flowId with each tool call to target a specific flow, or use list_sessions to discover available flows.",
|
|
49
|
+
"examples": [
|
|
50
|
+
"<%= config.bin %> <%= command.id %>",
|
|
51
|
+
"<%= config.bin %> <%= command.id %> flow-editor --flow my-flow-id"
|
|
52
|
+
],
|
|
53
|
+
"flags": {
|
|
54
|
+
"config-id": {
|
|
55
|
+
"char": "C",
|
|
56
|
+
"helpGroup": "GLOBAL",
|
|
57
|
+
"name": "config-id",
|
|
58
|
+
"summary": "Specify config id to use for call.",
|
|
59
|
+
"hasDynamicHelp": false,
|
|
60
|
+
"multiple": false,
|
|
61
|
+
"type": "option"
|
|
62
|
+
},
|
|
63
|
+
"flow": {
|
|
64
|
+
"char": "f",
|
|
65
|
+
"description": "pre-filter session listing to a specific flow ID",
|
|
66
|
+
"name": "flow",
|
|
67
|
+
"hasDynamicHelp": false,
|
|
68
|
+
"multiple": false,
|
|
69
|
+
"type": "option"
|
|
70
|
+
},
|
|
71
|
+
"port": {
|
|
72
|
+
"char": "p",
|
|
73
|
+
"description": "local HTTP port (default: 5051)",
|
|
74
|
+
"name": "port",
|
|
75
|
+
"hasDynamicHelp": false,
|
|
76
|
+
"multiple": false,
|
|
77
|
+
"type": "option"
|
|
78
|
+
},
|
|
79
|
+
"tool-prefix": {
|
|
80
|
+
"char": "t",
|
|
81
|
+
"description": "prefix all MCP tool names with ctxl_",
|
|
82
|
+
"name": "tool-prefix",
|
|
83
|
+
"allowNo": true,
|
|
84
|
+
"type": "boolean"
|
|
85
|
+
},
|
|
86
|
+
"url": {
|
|
87
|
+
"description": "override MCP route URL (http/https)",
|
|
88
|
+
"hidden": true,
|
|
89
|
+
"name": "url",
|
|
90
|
+
"hasDynamicHelp": false,
|
|
91
|
+
"multiple": false,
|
|
92
|
+
"type": "option"
|
|
93
|
+
},
|
|
94
|
+
"verbose": {
|
|
95
|
+
"char": "V",
|
|
96
|
+
"description": "emit verbose MCP runtime diagnostics",
|
|
97
|
+
"name": "verbose",
|
|
98
|
+
"allowNo": false,
|
|
99
|
+
"type": "boolean"
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
"hasDynamicHelp": false,
|
|
103
|
+
"hiddenAliases": [],
|
|
104
|
+
"id": "mcp:serve",
|
|
105
|
+
"pluginAlias": "@contextual-io/cli",
|
|
106
|
+
"pluginName": "@contextual-io/cli",
|
|
107
|
+
"pluginType": "core",
|
|
108
|
+
"strict": true,
|
|
109
|
+
"enableJsonFlag": false,
|
|
110
|
+
"isESM": true,
|
|
111
|
+
"relativePath": [
|
|
112
|
+
"dist",
|
|
113
|
+
"commands",
|
|
114
|
+
"mcp",
|
|
115
|
+
"serve.js"
|
|
116
|
+
]
|
|
117
|
+
},
|
|
3
118
|
"config:add": {
|
|
4
119
|
"aliases": [],
|
|
5
120
|
"args": {
|
|
@@ -265,114 +380,6 @@
|
|
|
265
380
|
"use.js"
|
|
266
381
|
]
|
|
267
382
|
},
|
|
268
|
-
"mcp": {
|
|
269
|
-
"aliases": [],
|
|
270
|
-
"args": {},
|
|
271
|
-
"description": "Manage local MCP server commands. Start with 'ctxl mcp serve' to run the local MCP bridge.",
|
|
272
|
-
"examples": [
|
|
273
|
-
"<%= config.bin %> <%= command.id %>",
|
|
274
|
-
"<%= config.bin %> <%= command.id %> flow-editor --flow my-flow-id"
|
|
275
|
-
],
|
|
276
|
-
"flags": {},
|
|
277
|
-
"hasDynamicHelp": false,
|
|
278
|
-
"hiddenAliases": [],
|
|
279
|
-
"id": "mcp",
|
|
280
|
-
"pluginAlias": "@contextual-io/cli",
|
|
281
|
-
"pluginName": "@contextual-io/cli",
|
|
282
|
-
"pluginType": "core",
|
|
283
|
-
"strict": true,
|
|
284
|
-
"usage": [
|
|
285
|
-
"<%= command.id %> <COMMAND>"
|
|
286
|
-
],
|
|
287
|
-
"enableJsonFlag": false,
|
|
288
|
-
"isESM": true,
|
|
289
|
-
"relativePath": [
|
|
290
|
-
"dist",
|
|
291
|
-
"commands",
|
|
292
|
-
"mcp",
|
|
293
|
-
"index.js"
|
|
294
|
-
]
|
|
295
|
-
},
|
|
296
|
-
"mcp:serve": {
|
|
297
|
-
"aliases": [],
|
|
298
|
-
"args": {
|
|
299
|
-
"interface": {
|
|
300
|
-
"default": "flow-editor",
|
|
301
|
-
"description": "Interface type to scope tools for. Available interfaces depend on your platform version.",
|
|
302
|
-
"name": "interface",
|
|
303
|
-
"required": false
|
|
304
|
-
}
|
|
305
|
-
},
|
|
306
|
-
"description": "Start a local MCP HTTP server that connects to SolutionAI for a given interface type. By default it binds to http://localhost:5051/. The server fetches the full tool manifest from SolutionAI and serves all tools immediately. Pass a flowId with each tool call to target a specific flow, or use list_sessions to discover available flows.",
|
|
307
|
-
"examples": [
|
|
308
|
-
"<%= config.bin %> <%= command.id %>",
|
|
309
|
-
"<%= config.bin %> <%= command.id %> flow-editor --flow my-flow-id"
|
|
310
|
-
],
|
|
311
|
-
"flags": {
|
|
312
|
-
"config-id": {
|
|
313
|
-
"char": "C",
|
|
314
|
-
"helpGroup": "GLOBAL",
|
|
315
|
-
"name": "config-id",
|
|
316
|
-
"summary": "Specify config id to use for call.",
|
|
317
|
-
"hasDynamicHelp": false,
|
|
318
|
-
"multiple": false,
|
|
319
|
-
"type": "option"
|
|
320
|
-
},
|
|
321
|
-
"flow": {
|
|
322
|
-
"char": "f",
|
|
323
|
-
"description": "pre-filter session listing to a specific flow ID",
|
|
324
|
-
"name": "flow",
|
|
325
|
-
"hasDynamicHelp": false,
|
|
326
|
-
"multiple": false,
|
|
327
|
-
"type": "option"
|
|
328
|
-
},
|
|
329
|
-
"port": {
|
|
330
|
-
"char": "p",
|
|
331
|
-
"description": "local HTTP port (default: 5051)",
|
|
332
|
-
"name": "port",
|
|
333
|
-
"hasDynamicHelp": false,
|
|
334
|
-
"multiple": false,
|
|
335
|
-
"type": "option"
|
|
336
|
-
},
|
|
337
|
-
"tool-prefix": {
|
|
338
|
-
"char": "t",
|
|
339
|
-
"description": "prefix all MCP tool names with ctxl_",
|
|
340
|
-
"name": "tool-prefix",
|
|
341
|
-
"allowNo": true,
|
|
342
|
-
"type": "boolean"
|
|
343
|
-
},
|
|
344
|
-
"url": {
|
|
345
|
-
"description": "override MCP route URL (http/https)",
|
|
346
|
-
"hidden": true,
|
|
347
|
-
"name": "url",
|
|
348
|
-
"hasDynamicHelp": false,
|
|
349
|
-
"multiple": false,
|
|
350
|
-
"type": "option"
|
|
351
|
-
},
|
|
352
|
-
"verbose": {
|
|
353
|
-
"char": "V",
|
|
354
|
-
"description": "emit verbose MCP runtime diagnostics",
|
|
355
|
-
"name": "verbose",
|
|
356
|
-
"allowNo": false,
|
|
357
|
-
"type": "boolean"
|
|
358
|
-
}
|
|
359
|
-
},
|
|
360
|
-
"hasDynamicHelp": false,
|
|
361
|
-
"hiddenAliases": [],
|
|
362
|
-
"id": "mcp:serve",
|
|
363
|
-
"pluginAlias": "@contextual-io/cli",
|
|
364
|
-
"pluginName": "@contextual-io/cli",
|
|
365
|
-
"pluginType": "core",
|
|
366
|
-
"strict": true,
|
|
367
|
-
"enableJsonFlag": false,
|
|
368
|
-
"isESM": true,
|
|
369
|
-
"relativePath": [
|
|
370
|
-
"dist",
|
|
371
|
-
"commands",
|
|
372
|
-
"mcp",
|
|
373
|
-
"serve.js"
|
|
374
|
-
]
|
|
375
|
-
},
|
|
376
383
|
"records:add": {
|
|
377
384
|
"aliases": [
|
|
378
385
|
"records:create",
|
|
@@ -1367,5 +1374,5 @@
|
|
|
1367
1374
|
]
|
|
1368
1375
|
}
|
|
1369
1376
|
},
|
|
1370
|
-
"version": "0.8.
|
|
1377
|
+
"version": "0.8.1"
|
|
1371
1378
|
}
|