nodestorm-mcp 0.1.0 → 0.1.2
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 +83 -29
- package/dist/client.d.ts +63 -3
- package/dist/client.js +35 -0
- package/dist/index.js +109 -52
- package/dist/instructions.d.ts +8 -0
- package/dist/instructions.js +23 -0
- package/dist/tools/docs.d.ts +7 -0
- package/dist/tools/docs.js +51 -0
- package/package.json +4 -4
- package/dist/tools/describe.d.ts +0 -18
- package/dist/tools/describe.js +0 -284
- package/dist/workflow-guide.md +0 -1655
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Docs tool definitions for the docs endpoints
|
|
3
|
+
* NodeStorm product documentation — node behavior, workflow mechanics, guides.
|
|
4
|
+
* These wrap the backend's v1 docs endpoints via NodeStormClient.
|
|
5
|
+
*/
|
|
6
|
+
export const DOCS_TOOL_DEFINITIONS = [
|
|
7
|
+
{
|
|
8
|
+
name: 'list_docs',
|
|
9
|
+
description: 'List NodeStorm product documentation pages — node behavior, workflow mechanics, guides. ' +
|
|
10
|
+
'Returns slug, title, category, and description for each page. Pass `category` to filter.',
|
|
11
|
+
inputSchema: {
|
|
12
|
+
type: 'object',
|
|
13
|
+
properties: {
|
|
14
|
+
category: {
|
|
15
|
+
type: 'string',
|
|
16
|
+
description: "Filter to a single category (e.g., 'node', 'guide', 'help')",
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
name: 'get_doc',
|
|
23
|
+
description: 'Get a NodeStorm documentation page by slug, including its full markdown body. ' +
|
|
24
|
+
'Use list_docs or search_docs to find slugs.',
|
|
25
|
+
inputSchema: {
|
|
26
|
+
type: 'object',
|
|
27
|
+
properties: {
|
|
28
|
+
slug: {
|
|
29
|
+
type: 'string',
|
|
30
|
+
description: 'Page slug (from list_docs or search_docs results)',
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
required: ['slug'],
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
name: 'search_docs',
|
|
38
|
+
description: 'Search NodeStorm product documentation using semantic (meaning-based) search. ' +
|
|
39
|
+
'Returns matching content chunks ranked by relevance to the query.',
|
|
40
|
+
inputSchema: {
|
|
41
|
+
type: 'object',
|
|
42
|
+
properties: {
|
|
43
|
+
query: {
|
|
44
|
+
type: 'string',
|
|
45
|
+
description: 'Natural language search query',
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
required: ['query'],
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
];
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nodestorm-mcp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"description": "MCP server for NodeStorm workflow automation",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
|
-
"nodestorm-mcp": "
|
|
7
|
+
"nodestorm-mcp": "dist/index.js"
|
|
8
8
|
},
|
|
9
9
|
"main": "./dist/index.js",
|
|
10
10
|
"types": "./dist/index.d.ts",
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"dist"
|
|
13
13
|
],
|
|
14
14
|
"scripts": {
|
|
15
|
-
"build": "tsc
|
|
15
|
+
"build": "tsc",
|
|
16
16
|
"dev": "tsc --watch",
|
|
17
17
|
"start": "node dist/index.js",
|
|
18
18
|
"test": "vitest run",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"license": "MIT",
|
|
32
32
|
"repository": {
|
|
33
33
|
"type": "git",
|
|
34
|
-
"url": "https://github.com/nodestorm/nodestorm-mcp"
|
|
34
|
+
"url": "git+https://github.com/nodestorm/nodestorm-mcp.git"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@modelcontextprotocol/sdk": "^1.0.0"
|
package/dist/tools/describe.d.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Node definitions for the describe_nodes tool
|
|
3
|
-
* These are bundled statically to avoid API calls
|
|
4
|
-
*/
|
|
5
|
-
export interface NodeDefinition {
|
|
6
|
-
type: string;
|
|
7
|
-
description: string;
|
|
8
|
-
category: string;
|
|
9
|
-
config_schema: Record<string, any>;
|
|
10
|
-
handles: {
|
|
11
|
-
inputs: string[];
|
|
12
|
-
outputs: string[];
|
|
13
|
-
};
|
|
14
|
-
}
|
|
15
|
-
/**
|
|
16
|
-
* Get node definitions, optionally filtered by type
|
|
17
|
-
*/
|
|
18
|
-
export declare function getNodeDefinitions(types?: string[]): NodeDefinition[];
|
package/dist/tools/describe.js
DELETED
|
@@ -1,284 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Node definitions for the describe_nodes tool
|
|
3
|
-
* These are bundled statically to avoid API calls
|
|
4
|
-
*/
|
|
5
|
-
// Static node definitions
|
|
6
|
-
const NODE_DEFINITIONS = [
|
|
7
|
-
{
|
|
8
|
-
type: 'text',
|
|
9
|
-
description: 'Provide static text content to the workflow',
|
|
10
|
-
category: 'Data',
|
|
11
|
-
config_schema: {
|
|
12
|
-
input: { type: 'string', description: 'The static text content' },
|
|
13
|
-
},
|
|
14
|
-
handles: {
|
|
15
|
-
inputs: ['input'],
|
|
16
|
-
outputs: ['output'],
|
|
17
|
-
},
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
type: 'list',
|
|
21
|
-
description: 'Extract list items using LLM or enter items manually',
|
|
22
|
-
category: 'Data',
|
|
23
|
-
config_schema: {
|
|
24
|
-
mode: { type: 'string', enum: ['extract', 'manual'], description: 'Mode of operation' },
|
|
25
|
-
input: { type: 'string', description: 'Manual items (one per line) or extraction prompt' },
|
|
26
|
-
},
|
|
27
|
-
handles: {
|
|
28
|
-
inputs: ['input'],
|
|
29
|
-
outputs: ['output', 'each'],
|
|
30
|
-
},
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
type: 'table',
|
|
34
|
-
description: 'Store and manipulate tabular data with rows and columns',
|
|
35
|
-
category: 'Data',
|
|
36
|
-
config_schema: {
|
|
37
|
-
columns: { type: 'array', description: 'Column definitions' },
|
|
38
|
-
rows: { type: 'array', description: 'Row data' },
|
|
39
|
-
storage_mode: { type: 'string', enum: ['inline', 'file'], description: 'Where to store data' },
|
|
40
|
-
},
|
|
41
|
-
handles: {
|
|
42
|
-
inputs: ['input'],
|
|
43
|
-
outputs: ['output', 'each'],
|
|
44
|
-
},
|
|
45
|
-
},
|
|
46
|
-
{
|
|
47
|
-
type: 'file',
|
|
48
|
-
description: 'Read from or write to persistent user files',
|
|
49
|
-
category: 'Data',
|
|
50
|
-
config_schema: {
|
|
51
|
-
operation: { type: 'string', enum: ['read', 'write', 'append'], description: 'File operation' },
|
|
52
|
-
file_id: { type: 'string', description: 'User file ID' },
|
|
53
|
-
},
|
|
54
|
-
handles: {
|
|
55
|
-
inputs: ['input'],
|
|
56
|
-
outputs: ['output'],
|
|
57
|
-
},
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
type: 'search',
|
|
61
|
-
description: 'Search the web using Google and return results',
|
|
62
|
-
category: 'Web',
|
|
63
|
-
config_schema: {
|
|
64
|
-
input: { type: 'string', description: 'Search query' },
|
|
65
|
-
maxResults: { type: 'number', description: 'Maximum results (default: 5)' },
|
|
66
|
-
useLlmCleaning: { type: 'boolean', description: 'Use LLM to clean/summarize results' },
|
|
67
|
-
},
|
|
68
|
-
handles: {
|
|
69
|
-
inputs: ['input'],
|
|
70
|
-
outputs: ['output'],
|
|
71
|
-
},
|
|
72
|
-
},
|
|
73
|
-
{
|
|
74
|
-
type: 'scraper',
|
|
75
|
-
description: 'Scrape web pages and extract content',
|
|
76
|
-
category: 'Web',
|
|
77
|
-
config_schema: {
|
|
78
|
-
input: { type: 'string', description: 'URL to scrape' },
|
|
79
|
-
},
|
|
80
|
-
handles: {
|
|
81
|
-
inputs: ['input'],
|
|
82
|
-
outputs: ['output'],
|
|
83
|
-
},
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
type: 'prompt',
|
|
87
|
-
description: 'Process text using an LLM with custom prompts',
|
|
88
|
-
category: 'AI',
|
|
89
|
-
config_schema: {
|
|
90
|
-
input: { type: 'string', description: 'Prompt/instructions for the LLM' },
|
|
91
|
-
modelConfig: {
|
|
92
|
-
type: 'object',
|
|
93
|
-
description: 'LLM configuration',
|
|
94
|
-
properties: {
|
|
95
|
-
provider: { type: 'string', enum: ['openai', 'anthropic', 'google'] },
|
|
96
|
-
chat_model: { type: 'string', description: 'Model ID' },
|
|
97
|
-
systemMessage: { type: 'string', description: 'System prompt' },
|
|
98
|
-
temperature: { type: 'number', description: '0-2' },
|
|
99
|
-
maxTokens: { type: 'number', description: 'Max response tokens' },
|
|
100
|
-
},
|
|
101
|
-
},
|
|
102
|
-
},
|
|
103
|
-
handles: {
|
|
104
|
-
inputs: ['input'],
|
|
105
|
-
outputs: ['output'],
|
|
106
|
-
},
|
|
107
|
-
},
|
|
108
|
-
{
|
|
109
|
-
type: 'boolean',
|
|
110
|
-
description: 'Make a yes/no decision using LLM',
|
|
111
|
-
category: 'AI',
|
|
112
|
-
config_schema: {
|
|
113
|
-
input: { type: 'string', description: 'Question to answer (yes/no)' },
|
|
114
|
-
modelConfig: { type: 'object', description: 'LLM configuration' },
|
|
115
|
-
},
|
|
116
|
-
handles: {
|
|
117
|
-
inputs: ['input'],
|
|
118
|
-
outputs: ['true', 'false'],
|
|
119
|
-
},
|
|
120
|
-
},
|
|
121
|
-
{
|
|
122
|
-
type: 'json',
|
|
123
|
-
description: 'Extract structured JSON data using LLM',
|
|
124
|
-
category: 'AI',
|
|
125
|
-
config_schema: {
|
|
126
|
-
input: { type: 'string', description: 'Extraction instructions' },
|
|
127
|
-
schema: { type: 'object', description: 'JSON schema for output' },
|
|
128
|
-
modelConfig: { type: 'object', description: 'LLM configuration' },
|
|
129
|
-
},
|
|
130
|
-
handles: {
|
|
131
|
-
inputs: ['input'],
|
|
132
|
-
outputs: ['output'],
|
|
133
|
-
},
|
|
134
|
-
},
|
|
135
|
-
{
|
|
136
|
-
type: 'switch',
|
|
137
|
-
description: 'Route to different paths based on conditions',
|
|
138
|
-
category: 'Control',
|
|
139
|
-
config_schema: {
|
|
140
|
-
condition_type: { type: 'string', enum: ['llm', 'regex', 'contains', 'equals'] },
|
|
141
|
-
cases: { type: 'array', description: 'List of case definitions' },
|
|
142
|
-
},
|
|
143
|
-
handles: {
|
|
144
|
-
inputs: ['input'],
|
|
145
|
-
outputs: ['case-*'], // Dynamic based on cases
|
|
146
|
-
},
|
|
147
|
-
},
|
|
148
|
-
{
|
|
149
|
-
type: 'wait',
|
|
150
|
-
description: 'Pause execution for a specified time',
|
|
151
|
-
category: 'Control',
|
|
152
|
-
config_schema: {
|
|
153
|
-
delay_type: { type: 'string', enum: ['seconds', 'minutes', 'hours', 'until'] },
|
|
154
|
-
delay_amount: { type: 'number', description: 'Duration (for seconds/minutes/hours)' },
|
|
155
|
-
until_time: { type: 'string', description: 'ISO timestamp (for until)' },
|
|
156
|
-
},
|
|
157
|
-
handles: {
|
|
158
|
-
inputs: ['input'],
|
|
159
|
-
outputs: ['output'],
|
|
160
|
-
},
|
|
161
|
-
},
|
|
162
|
-
{
|
|
163
|
-
type: 'aggregate',
|
|
164
|
-
description: 'Collect results from iteration into a single array',
|
|
165
|
-
category: 'Control',
|
|
166
|
-
config_schema: {},
|
|
167
|
-
handles: {
|
|
168
|
-
inputs: ['input'],
|
|
169
|
-
outputs: ['output'],
|
|
170
|
-
},
|
|
171
|
-
},
|
|
172
|
-
{
|
|
173
|
-
type: 'http_request',
|
|
174
|
-
description: 'Make HTTP requests to external APIs',
|
|
175
|
-
category: 'Actions',
|
|
176
|
-
config_schema: {
|
|
177
|
-
url: { type: 'string', description: 'Request URL (required)' },
|
|
178
|
-
method: { type: 'string', enum: ['GET', 'POST', 'PUT', 'PATCH', 'DELETE'] },
|
|
179
|
-
headers: { type: 'object', description: 'Request headers' },
|
|
180
|
-
body: { type: 'string', description: 'Request body' },
|
|
181
|
-
credential_id: { type: 'string', description: 'API credential ID' },
|
|
182
|
-
},
|
|
183
|
-
handles: {
|
|
184
|
-
inputs: ['input'],
|
|
185
|
-
outputs: ['output'],
|
|
186
|
-
},
|
|
187
|
-
},
|
|
188
|
-
{
|
|
189
|
-
type: 'email',
|
|
190
|
-
description: 'Send email to the authenticated user',
|
|
191
|
-
category: 'Actions',
|
|
192
|
-
config_schema: {
|
|
193
|
-
subject: { type: 'string', description: 'Email subject (required)' },
|
|
194
|
-
body: { type: 'string', description: 'Email body (required)' },
|
|
195
|
-
format: { type: 'string', enum: ['plain', 'html'] },
|
|
196
|
-
},
|
|
197
|
-
handles: {
|
|
198
|
-
inputs: ['input'],
|
|
199
|
-
outputs: ['output'],
|
|
200
|
-
},
|
|
201
|
-
},
|
|
202
|
-
{
|
|
203
|
-
type: 'google_drive',
|
|
204
|
-
description: 'Manage files and folders in Google Drive',
|
|
205
|
-
category: 'Integrations',
|
|
206
|
-
config_schema: {
|
|
207
|
-
operation: {
|
|
208
|
-
type: 'string',
|
|
209
|
-
enum: ['list_files', 'get_metadata', 'download_file', 'upload_file', 'update_file', 'create_folder', 'copy_file', 'move_file', 'delete_file', 'search_files'],
|
|
210
|
-
},
|
|
211
|
-
file_id: { type: 'string', description: 'File/folder ID' },
|
|
212
|
-
folder_id: { type: 'string', description: 'Parent folder ID' },
|
|
213
|
-
},
|
|
214
|
-
handles: {
|
|
215
|
-
inputs: ['input'],
|
|
216
|
-
outputs: ['output'],
|
|
217
|
-
},
|
|
218
|
-
},
|
|
219
|
-
{
|
|
220
|
-
type: 'transcription',
|
|
221
|
-
description: 'Transcribe audio to text',
|
|
222
|
-
category: 'Media',
|
|
223
|
-
config_schema: {
|
|
224
|
-
audio_source: { type: 'string', enum: ['url', 'content'] },
|
|
225
|
-
provider: { type: 'string', enum: ['openai', 'google'] },
|
|
226
|
-
},
|
|
227
|
-
handles: {
|
|
228
|
-
inputs: ['input'],
|
|
229
|
-
outputs: ['output'],
|
|
230
|
-
},
|
|
231
|
-
},
|
|
232
|
-
{
|
|
233
|
-
type: 'image_generation',
|
|
234
|
-
description: 'Generate images using AI (DALL-E)',
|
|
235
|
-
category: 'Media',
|
|
236
|
-
config_schema: {
|
|
237
|
-
provider: { type: 'string', enum: ['openai'] },
|
|
238
|
-
operation: { type: 'string', enum: ['generate', 'edit', 'variation'] },
|
|
239
|
-
prompt: { type: 'string', description: 'Image prompt' },
|
|
240
|
-
size: { type: 'string', enum: ['256x256', '512x512', '1024x1024', '1024x1792', '1792x1024'] },
|
|
241
|
-
quality: { type: 'string', enum: ['standard', 'hd'] },
|
|
242
|
-
style: { type: 'string', enum: ['vivid', 'natural'] },
|
|
243
|
-
count: { type: 'number', description: 'Number of images (1-4)' },
|
|
244
|
-
},
|
|
245
|
-
handles: {
|
|
246
|
-
inputs: ['input'],
|
|
247
|
-
outputs: ['output'],
|
|
248
|
-
},
|
|
249
|
-
},
|
|
250
|
-
{
|
|
251
|
-
type: 'keyword_data',
|
|
252
|
-
description: 'Look up SEO keyword data (search volume, CPC, competition) via Keywords Everywhere API',
|
|
253
|
-
category: 'Web',
|
|
254
|
-
config_schema: {
|
|
255
|
-
input: { type: 'string', description: 'Keywords (one per line) or extraction prompt' },
|
|
256
|
-
country: { type: 'string', description: "Country code (e.g. 'us')" },
|
|
257
|
-
},
|
|
258
|
-
handles: {
|
|
259
|
-
inputs: ['input'],
|
|
260
|
-
outputs: ['output'],
|
|
261
|
-
},
|
|
262
|
-
},
|
|
263
|
-
{
|
|
264
|
-
type: 'result',
|
|
265
|
-
description: 'Render flow output on the canvas. LLM-formats the upstream value into the chosen target (~$0.01, ~4s per render).',
|
|
266
|
-
category: 'Output',
|
|
267
|
-
config_schema: {
|
|
268
|
-
format: { type: 'string', enum: ['html', 'markdown', 'plain'], description: "Output target. Default 'html'." },
|
|
269
|
-
},
|
|
270
|
-
handles: {
|
|
271
|
-
inputs: ['input'],
|
|
272
|
-
outputs: [],
|
|
273
|
-
},
|
|
274
|
-
},
|
|
275
|
-
];
|
|
276
|
-
/**
|
|
277
|
-
* Get node definitions, optionally filtered by type
|
|
278
|
-
*/
|
|
279
|
-
export function getNodeDefinitions(types) {
|
|
280
|
-
if (!types || types.length === 0) {
|
|
281
|
-
return NODE_DEFINITIONS;
|
|
282
|
-
}
|
|
283
|
-
return NODE_DEFINITIONS.filter((node) => types.includes(node.type));
|
|
284
|
-
}
|