n8n-nodes-browser-smart-automation 0.1.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.
Files changed (71) hide show
  1. package/dist/McpClient/McpClient.node.js +333 -0
  2. package/dist/McpClient/McpClient.node.js.map +1 -0
  3. package/dist/McpClient/listSearch.js +58 -0
  4. package/dist/McpClient/listSearch.js.map +1 -0
  5. package/dist/McpClient/resourceMapping.js +61 -0
  6. package/dist/McpClient/resourceMapping.js.map +1 -0
  7. package/dist/McpClient/utils.js +248 -0
  8. package/dist/McpClient/utils.js.map +1 -0
  9. package/dist/McpClientTool/McpClientTool.node.js +417 -0
  10. package/dist/McpClientTool/McpClientTool.node.js.map +1 -0
  11. package/dist/McpClientTool/loadOptions.js +61 -0
  12. package/dist/McpClientTool/loadOptions.js.map +1 -0
  13. package/dist/McpClientTool/types.js +17 -0
  14. package/dist/McpClientTool/types.js.map +1 -0
  15. package/dist/McpClientTool/utils.js +120 -0
  16. package/dist/McpClientTool/utils.js.map +1 -0
  17. package/dist/McpTrigger/FlushingTransport.js +61 -0
  18. package/dist/McpTrigger/FlushingTransport.js.map +1 -0
  19. package/dist/McpTrigger/McpServer.js +246 -0
  20. package/dist/McpTrigger/McpServer.js.map +1 -0
  21. package/dist/McpTrigger/McpTrigger.node.js +196 -0
  22. package/dist/McpTrigger/McpTrigger.node.js.map +1 -0
  23. package/dist/shared/descriptions.js +89 -0
  24. package/dist/shared/descriptions.js.map +1 -0
  25. package/dist/shared/helpers.js +47 -0
  26. package/dist/shared/helpers.js.map +1 -0
  27. package/dist/shared/httpProxyAgent.js +31 -0
  28. package/dist/shared/httpProxyAgent.js.map +1 -0
  29. package/dist/shared/logWrapper.js +31 -0
  30. package/dist/shared/logWrapper.js.map +1 -0
  31. package/dist/shared/schemaParsing.js +32 -0
  32. package/dist/shared/schemaParsing.js.map +1 -0
  33. package/dist/shared/sharedFields.js +41 -0
  34. package/dist/shared/sharedFields.js.map +1 -0
  35. package/dist/shared/types.js +17 -0
  36. package/dist/shared/types.js.map +1 -0
  37. package/dist/shared/utils.js +231 -0
  38. package/dist/shared/utils.js.map +1 -0
  39. package/jest.config.js +24 -0
  40. package/nodes/McpClient/McpClient.node.ts +327 -0
  41. package/nodes/McpClient/__test__/McpClient.node.test.ts +221 -0
  42. package/nodes/McpClient/__test__/utils.test.ts +302 -0
  43. package/nodes/McpClient/listSearch.ts +48 -0
  44. package/nodes/McpClient/resourceMapping.ts +48 -0
  45. package/nodes/McpClient/utils.ts +281 -0
  46. package/nodes/McpClientTool/McpClientTool.node.ts +468 -0
  47. package/nodes/McpClientTool/__test__/McpClientTool.node.test.ts +730 -0
  48. package/nodes/McpClientTool/loadOptions.ts +45 -0
  49. package/nodes/McpClientTool/types.ts +1 -0
  50. package/nodes/McpClientTool/utils.ts +116 -0
  51. package/nodes/McpTrigger/FlushingTransport.ts +61 -0
  52. package/nodes/McpTrigger/McpServer.ts +317 -0
  53. package/nodes/McpTrigger/McpTrigger.node.ts +204 -0
  54. package/nodes/McpTrigger/__test__/FlushingTransport.test.ts +102 -0
  55. package/nodes/McpTrigger/__test__/McpServer.test.ts +532 -0
  56. package/nodes/McpTrigger/__test__/McpTrigger.node.test.ts +171 -0
  57. package/nodes/mcp.dark.svg +7 -0
  58. package/nodes/mcp.svg +7 -0
  59. package/nodes/shared/__test__/utils.test.ts +318 -0
  60. package/nodes/shared/descriptions.ts +65 -0
  61. package/nodes/shared/helpers.ts +31 -0
  62. package/nodes/shared/httpProxyAgent.ts +11 -0
  63. package/nodes/shared/logWrapper.ts +13 -0
  64. package/nodes/shared/schemaParsing.ts +9 -0
  65. package/nodes/shared/sharedFields.ts +20 -0
  66. package/nodes/shared/types.ts +12 -0
  67. package/nodes/shared/utils.ts +296 -0
  68. package/officail/package.json +255 -0
  69. package/package.json +46 -0
  70. package/tsconfig.json +32 -0
  71. package/tsup.config.ts +11 -0
@@ -0,0 +1,196 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var McpTrigger_node_exports = {};
20
+ __export(McpTrigger_node_exports, {
21
+ McpTrigger: () => McpTrigger
22
+ });
23
+ module.exports = __toCommonJS(McpTrigger_node_exports);
24
+ var import_error = require("n8n-nodes-base/dist/nodes/Webhook/error");
25
+ var import_utils = require("n8n-nodes-base/dist/nodes/Webhook/utils");
26
+ var import_n8n_workflow = require("n8n-workflow");
27
+ var import_helpers = require("@utils/helpers");
28
+ var import_McpServer = require("./McpServer");
29
+ const MCP_SSE_SETUP_PATH = "sse";
30
+ const MCP_SSE_MESSAGES_PATH = "messages";
31
+ class McpTrigger extends import_n8n_workflow.Node {
32
+ description = {
33
+ displayName: "MCP Server Trigger",
34
+ name: "mcpTrigger",
35
+ icon: {
36
+ light: "file:../mcp.svg",
37
+ dark: "file:../mcp.dark.svg"
38
+ },
39
+ group: ["trigger"],
40
+ version: [1, 1.1, 2],
41
+ description: "Expose n8n tools as an MCP Server endpoint",
42
+ activationMessage: "You can now connect your MCP Clients to the URL, using SSE or Streamable HTTP transports.",
43
+ defaults: {
44
+ name: "MCP Server Trigger"
45
+ },
46
+ codex: {
47
+ categories: ["AI", "Core Nodes"],
48
+ subcategories: {
49
+ AI: ["Root Nodes", "Model Context Protocol"],
50
+ "Core Nodes": ["Other Trigger Nodes"]
51
+ },
52
+ alias: ["Model Context Protocol", "MCP Server"],
53
+ resources: {
54
+ primaryDocumentation: [
55
+ {
56
+ url: "https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-langchain.mcptrigger/"
57
+ }
58
+ ]
59
+ }
60
+ },
61
+ triggerPanel: {
62
+ header: "Listen for MCP events",
63
+ executionsHelp: {
64
+ inactive: "This trigger has two modes: test and production.<br /><br /><b>Use test mode while you build your workflow</b>. Click the 'execute step' button, then make an MCP request to the test URL. The executions will show up in the editor.<br /><br /><b>Use production mode to run your workflow automatically</b>. Publish the workflow, then make requests to the production URL. These executions will show up in the <a data-key='executions'>executions list</a>, but not the editor.",
65
+ active: "This trigger has two modes: test and production.<br /><br /><b>Use test mode while you build your workflow</b>. Click the 'execute step' button, then make an MCP request to the test URL. The executions will show up in the editor.<br /><br /><b>Use production mode to run your workflow automatically</b>. Since your workflow is activated, you can make requests to the production URL. These executions will show up in the <a data-key='executions'>executions list</a>, but not the editor."
66
+ },
67
+ activationHint: "Once you\u2019ve finished building your workflow, run it without having to click this button by using the production URL."
68
+ },
69
+ inputs: [
70
+ {
71
+ type: import_n8n_workflow.NodeConnectionTypes.AiTool,
72
+ displayName: "Tools"
73
+ }
74
+ ],
75
+ outputs: [],
76
+ credentials: [
77
+ {
78
+ // eslint-disable-next-line n8n-nodes-base/node-class-description-credentials-name-unsuffixed
79
+ name: "httpBearerAuth",
80
+ required: true,
81
+ displayOptions: {
82
+ show: {
83
+ authentication: ["bearerAuth"]
84
+ }
85
+ }
86
+ },
87
+ {
88
+ name: "httpHeaderAuth",
89
+ required: true,
90
+ displayOptions: {
91
+ show: {
92
+ authentication: ["headerAuth"]
93
+ }
94
+ }
95
+ }
96
+ ],
97
+ properties: [
98
+ {
99
+ displayName: "Authentication",
100
+ name: "authentication",
101
+ type: "options",
102
+ options: [
103
+ { name: "None", value: "none" },
104
+ { name: "Bearer Auth", value: "bearerAuth" },
105
+ { name: "Header Auth", value: "headerAuth" }
106
+ ],
107
+ default: "none",
108
+ description: "The way to authenticate"
109
+ },
110
+ {
111
+ displayName: "Path",
112
+ name: "path",
113
+ type: "string",
114
+ default: "",
115
+ placeholder: "webhook",
116
+ required: true,
117
+ description: "The base path for this MCP server"
118
+ }
119
+ ],
120
+ webhooks: [
121
+ {
122
+ name: "setup",
123
+ httpMethod: "GET",
124
+ responseMode: "onReceived",
125
+ isFullPath: true,
126
+ path: `={{$parameter["path"]}}{{parseFloat($nodeVersion)<2 ? '/${MCP_SSE_SETUP_PATH}' : ''}}`,
127
+ nodeType: "mcp",
128
+ ndvHideMethod: true,
129
+ ndvHideUrl: false
130
+ },
131
+ {
132
+ name: "default",
133
+ httpMethod: "POST",
134
+ responseMode: "onReceived",
135
+ isFullPath: true,
136
+ path: `={{$parameter["path"]}}{{parseFloat($nodeVersion)<2 ? '/${MCP_SSE_MESSAGES_PATH}' : ''}}`,
137
+ nodeType: "mcp",
138
+ ndvHideMethod: true,
139
+ ndvHideUrl: true
140
+ },
141
+ {
142
+ name: "default",
143
+ httpMethod: "DELETE",
144
+ responseMode: "onReceived",
145
+ isFullPath: true,
146
+ path: '={{$parameter["path"]}}',
147
+ nodeType: "mcp",
148
+ ndvHideMethod: true,
149
+ ndvHideUrl: true
150
+ }
151
+ ]
152
+ };
153
+ async webhook(context) {
154
+ const webhookName = context.getWebhookName();
155
+ const req = context.getRequestObject();
156
+ const resp = context.getResponseObject();
157
+ try {
158
+ await (0, import_utils.validateWebhookAuthentication)(context, "authentication");
159
+ } catch (error) {
160
+ if (error instanceof import_error.WebhookAuthorizationError) {
161
+ resp.writeHead(error.responseCode);
162
+ resp.end(error.message);
163
+ return { noWebhookResponse: true };
164
+ }
165
+ throw error;
166
+ }
167
+ const node = context.getNode();
168
+ const serverName = node.typeVersion > 1 ? (0, import_n8n_workflow.nodeNameToToolName)(node) : "n8n-mcp-server";
169
+ const mcpServerManager = import_McpServer.McpServerManager.instance(context.logger);
170
+ if (webhookName === "setup") {
171
+ const postUrl = node.typeVersion < 2 ? req.path.replace(new RegExp(`/${MCP_SSE_SETUP_PATH}$`), `/${MCP_SSE_MESSAGES_PATH}`) : req.path;
172
+ await mcpServerManager.createServerWithSSETransport(serverName, postUrl, resp);
173
+ return { noWebhookResponse: true };
174
+ } else if (webhookName === "default") {
175
+ if (req.method === "DELETE") {
176
+ await mcpServerManager.handleDeleteRequest(req, resp);
177
+ } else {
178
+ const sessionId = mcpServerManager.getSessionId(req);
179
+ if (sessionId && mcpServerManager.getTransport(sessionId)) {
180
+ const connectedTools = await (0, import_helpers.getConnectedTools)(context, true);
181
+ const wasToolCall = await mcpServerManager.handlePostMessage(req, resp, connectedTools);
182
+ if (wasToolCall) return { noWebhookResponse: true, workflowData: [[{ json: {} }]] };
183
+ } else {
184
+ await mcpServerManager.createServerWithStreamableHTTPTransport(serverName, resp, req);
185
+ }
186
+ }
187
+ return { noWebhookResponse: true };
188
+ }
189
+ return { workflowData: [[{ json: {} }]] };
190
+ }
191
+ }
192
+ // Annotate the CommonJS export names for ESM import in node:
193
+ 0 && (module.exports = {
194
+ McpTrigger
195
+ });
196
+ //# sourceMappingURL=McpTrigger.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/McpTrigger/McpTrigger.node.ts"],"sourcesContent":["import { WebhookAuthorizationError } from 'n8n-nodes-base/dist/nodes/Webhook/error';\nimport { validateWebhookAuthentication } from 'n8n-nodes-base/dist/nodes/Webhook/utils';\nimport type { INodeTypeDescription, IWebhookFunctions, IWebhookResponseData } from 'n8n-workflow';\nimport { NodeConnectionTypes, Node, nodeNameToToolName } from 'n8n-workflow';\n\nimport { getConnectedTools } from '@utils/helpers';\n\nimport type { CompressionResponse } from './FlushingTransport';\nimport { McpServerManager } from './McpServer';\n\nconst MCP_SSE_SETUP_PATH = 'sse';\nconst MCP_SSE_MESSAGES_PATH = 'messages';\n\nexport class McpTrigger extends Node {\n\tdescription: INodeTypeDescription = {\n\t\tdisplayName: 'MCP Server Trigger',\n\t\tname: 'mcpTrigger',\n\t\ticon: {\n\t\t\tlight: 'file:../mcp.svg',\n\t\t\tdark: 'file:../mcp.dark.svg',\n\t\t},\n\t\tgroup: ['trigger'],\n\t\tversion: [1, 1.1, 2],\n\t\tdescription: 'Expose n8n tools as an MCP Server endpoint',\n\t\tactivationMessage:\n\t\t\t'You can now connect your MCP Clients to the URL, using SSE or Streamable HTTP transports.',\n\t\tdefaults: {\n\t\t\tname: 'MCP Server Trigger',\n\t\t},\n\t\tcodex: {\n\t\t\tcategories: ['AI', 'Core Nodes'],\n\t\t\tsubcategories: {\n\t\t\t\tAI: ['Root Nodes', 'Model Context Protocol'],\n\t\t\t\t'Core Nodes': ['Other Trigger Nodes'],\n\t\t\t},\n\t\t\talias: ['Model Context Protocol', 'MCP Server'],\n\t\t\tresources: {\n\t\t\t\tprimaryDocumentation: [\n\t\t\t\t\t{\n\t\t\t\t\t\turl: 'https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-langchain.mcptrigger/',\n\t\t\t\t\t},\n\t\t\t\t],\n\t\t\t},\n\t\t},\n\t\ttriggerPanel: {\n\t\t\theader: 'Listen for MCP events',\n\t\t\texecutionsHelp: {\n\t\t\t\tinactive:\n\t\t\t\t\t\"This trigger has two modes: test and production.<br /><br /><b>Use test mode while you build your workflow</b>. Click the 'execute step' button, then make an MCP request to the test URL. The executions will show up in the editor.<br /><br /><b>Use production mode to run your workflow automatically</b>. Publish the workflow, then make requests to the production URL. These executions will show up in the <a data-key='executions'>executions list</a>, but not the editor.\",\n\t\t\t\tactive:\n\t\t\t\t\t\"This trigger has two modes: test and production.<br /><br /><b>Use test mode while you build your workflow</b>. Click the 'execute step' button, then make an MCP request to the test URL. The executions will show up in the editor.<br /><br /><b>Use production mode to run your workflow automatically</b>. Since your workflow is activated, you can make requests to the production URL. These executions will show up in the <a data-key='executions'>executions list</a>, but not the editor.\",\n\t\t\t},\n\t\t\tactivationHint:\n\t\t\t\t'Once you’ve finished building your workflow, run it without having to click this button by using the production URL.',\n\t\t},\n\t\tinputs: [\n\t\t\t{\n\t\t\t\ttype: NodeConnectionTypes.AiTool,\n\t\t\t\tdisplayName: 'Tools',\n\t\t\t},\n\t\t],\n\t\toutputs: [],\n\t\tcredentials: [\n\t\t\t{\n\t\t\t\t// eslint-disable-next-line n8n-nodes-base/node-class-description-credentials-name-unsuffixed\n\t\t\t\tname: 'httpBearerAuth',\n\t\t\t\trequired: true,\n\t\t\t\tdisplayOptions: {\n\t\t\t\t\tshow: {\n\t\t\t\t\t\tauthentication: ['bearerAuth'],\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'httpHeaderAuth',\n\t\t\t\trequired: true,\n\t\t\t\tdisplayOptions: {\n\t\t\t\t\tshow: {\n\t\t\t\t\t\tauthentication: ['headerAuth'],\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t],\n\t\tproperties: [\n\t\t\t{\n\t\t\t\tdisplayName: 'Authentication',\n\t\t\t\tname: 'authentication',\n\t\t\t\ttype: 'options',\n\t\t\t\toptions: [\n\t\t\t\t\t{ name: 'None', value: 'none' },\n\t\t\t\t\t{ name: 'Bearer Auth', value: 'bearerAuth' },\n\t\t\t\t\t{ name: 'Header Auth', value: 'headerAuth' },\n\t\t\t\t],\n\t\t\t\tdefault: 'none',\n\t\t\t\tdescription: 'The way to authenticate',\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Path',\n\t\t\t\tname: 'path',\n\t\t\t\ttype: 'string',\n\t\t\t\tdefault: '',\n\t\t\t\tplaceholder: 'webhook',\n\t\t\t\trequired: true,\n\t\t\t\tdescription: 'The base path for this MCP server',\n\t\t\t},\n\t\t],\n\t\twebhooks: [\n\t\t\t{\n\t\t\t\tname: 'setup',\n\t\t\t\thttpMethod: 'GET',\n\t\t\t\tresponseMode: 'onReceived',\n\t\t\t\tisFullPath: true,\n\t\t\t\tpath: `={{$parameter[\"path\"]}}{{parseFloat($nodeVersion)<2 ? '/${MCP_SSE_SETUP_PATH}' : ''}}`,\n\t\t\t\tnodeType: 'mcp',\n\t\t\t\tndvHideMethod: true,\n\t\t\t\tndvHideUrl: false,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'default',\n\t\t\t\thttpMethod: 'POST',\n\t\t\t\tresponseMode: 'onReceived',\n\t\t\t\tisFullPath: true,\n\t\t\t\tpath: `={{$parameter[\"path\"]}}{{parseFloat($nodeVersion)<2 ? '/${MCP_SSE_MESSAGES_PATH}' : ''}}`,\n\t\t\t\tnodeType: 'mcp',\n\t\t\t\tndvHideMethod: true,\n\t\t\t\tndvHideUrl: true,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'default',\n\t\t\t\thttpMethod: 'DELETE',\n\t\t\t\tresponseMode: 'onReceived',\n\t\t\t\tisFullPath: true,\n\t\t\t\tpath: '={{$parameter[\"path\"]}}',\n\t\t\t\tnodeType: 'mcp',\n\t\t\t\tndvHideMethod: true,\n\t\t\t\tndvHideUrl: true,\n\t\t\t},\n\t\t],\n\t};\n\n\tasync webhook(context: IWebhookFunctions): Promise<IWebhookResponseData> {\n\t\tconst webhookName = context.getWebhookName();\n\t\tconst req = context.getRequestObject();\n\t\tconst resp = context.getResponseObject() as unknown as CompressionResponse;\n\n\t\ttry {\n\t\t\tawait validateWebhookAuthentication(context, 'authentication');\n\t\t} catch (error) {\n\t\t\tif (error instanceof WebhookAuthorizationError) {\n\t\t\t\tresp.writeHead(error.responseCode);\n\t\t\t\tresp.end(error.message);\n\t\t\t\treturn { noWebhookResponse: true };\n\t\t\t}\n\t\t\tthrow error;\n\t\t}\n\t\tconst node = context.getNode();\n\t\t// Get a url/tool friendly name for the server, based on the node name\n\t\tconst serverName = node.typeVersion > 1 ? nodeNameToToolName(node) : 'n8n-mcp-server';\n\n\t\tconst mcpServerManager: McpServerManager = McpServerManager.instance(context.logger);\n\n\t\tif (webhookName === 'setup') {\n\t\t\t// Sets up the transport and opens the long-lived connection. This resp\n\t\t\t// will stay streaming, and is the channel that sends the events\n\n\t\t\t// Prior to version 2.0, we use different paths for the setup and messages.\n\t\t\tconst postUrl =\n\t\t\t\tnode.typeVersion < 2\n\t\t\t\t\t? req.path.replace(new RegExp(`/${MCP_SSE_SETUP_PATH}$`), `/${MCP_SSE_MESSAGES_PATH}`)\n\t\t\t\t\t: req.path;\n\t\t\tawait mcpServerManager.createServerWithSSETransport(serverName, postUrl, resp);\n\n\t\t\treturn { noWebhookResponse: true };\n\t\t} else if (webhookName === 'default') {\n\t\t\t// Here we handle POST and DELETE requests.\n\t\t\t// POST can be either:\n\t\t\t// 1) Client calls in an established session using the SSE transport, or\n\t\t\t// 2) Client calls in an established session using the StreamableHTTPServerTransport\n\t\t\t// 3) Session setup requests using the StreamableHTTPServerTransport\n\t\t\t// DELETE is used to terminate the session using the StreamableHTTPServerTransport\n\n\t\t\tif (req.method === 'DELETE') {\n\t\t\t\tawait mcpServerManager.handleDeleteRequest(req, resp);\n\t\t\t} else {\n\t\t\t\t// Check if there is a session and a transport is already established\n\t\t\t\tconst sessionId = mcpServerManager.getSessionId(req);\n\n\t\t\t\tif (sessionId && mcpServerManager.getTransport(sessionId)) {\n\t\t\t\t\tconst connectedTools = await getConnectedTools(context, true);\n\t\t\t\t\tconst wasToolCall = await mcpServerManager.handlePostMessage(req, resp, connectedTools);\n\t\t\t\t\tif (wasToolCall) return { noWebhookResponse: true, workflowData: [[{ json: {} }]] };\n\t\t\t\t} else {\n\t\t\t\t\t// If no session is established, this is a setup request\n\t\t\t\t\t// for the StreamableHTTPServerTransport, so we create a new transport\n\t\t\t\t\tawait mcpServerManager.createServerWithStreamableHTTPTransport(serverName, resp, req);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn { noWebhookResponse: true };\n\t\t}\n\n\t\treturn { workflowData: [[{ json: {} }]] };\n\t}\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAA0C;AAC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perty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var descriptions_exports = {};
20
+ __export(descriptions_exports, {
21
+ credentials: () => credentials,
22
+ transportSelect: () => transportSelect
23
+ });
24
+ module.exports = __toCommonJS(descriptions_exports);
25
+ const transportSelect = ({
26
+ defaultOption,
27
+ displayOptions
28
+ }) => ({
29
+ displayName: "Server Transport",
30
+ name: "serverTransport",
31
+ type: "options",
32
+ options: [
33
+ {
34
+ name: "HTTP Streamable",
35
+ value: "httpStreamable"
36
+ },
37
+ {
38
+ name: "Server Sent Events (Deprecated)",
39
+ value: "sse"
40
+ }
41
+ ],
42
+ default: defaultOption,
43
+ description: "The transport used by your endpoint",
44
+ displayOptions
45
+ });
46
+ const credentials = [
47
+ {
48
+ name: "httpBearerAuth",
49
+ required: true,
50
+ displayOptions: {
51
+ show: {
52
+ authentication: ["bearerAuth"]
53
+ }
54
+ }
55
+ },
56
+ {
57
+ name: "httpHeaderAuth",
58
+ required: true,
59
+ displayOptions: {
60
+ show: {
61
+ authentication: ["headerAuth"]
62
+ }
63
+ }
64
+ },
65
+ {
66
+ name: "mcpOAuth2Api",
67
+ required: true,
68
+ displayOptions: {
69
+ show: {
70
+ authentication: ["mcpOAuth2Api"]
71
+ }
72
+ }
73
+ },
74
+ {
75
+ name: "httpMultipleHeadersAuth",
76
+ required: true,
77
+ displayOptions: {
78
+ show: {
79
+ authentication: ["multipleHeadersAuth"]
80
+ }
81
+ }
82
+ }
83
+ ];
84
+ // Annotate the CommonJS export names for ESM import in node:
85
+ 0 && (module.exports = {
86
+ credentials,
87
+ transportSelect
88
+ });
89
+ //# sourceMappingURL=descriptions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/shared/descriptions.ts"],"sourcesContent":["import type { IDisplayOptions, INodeCredentialDescription, INodeProperties } from 'n8n-workflow';\n\nexport const transportSelect = ({\n\tdefaultOption,\n\tdisplayOptions,\n}: {\n\tdefaultOption: 'sse' | 'httpStreamable';\n\tdisplayOptions?: IDisplayOptions;\n}): INodeProperties => ({\n\tdisplayName: 'Server Transport',\n\tname: 'serverTransport',\n\ttype: 'options',\n\toptions: [\n\t\t{\n\t\t\tname: 'HTTP Streamable',\n\t\t\tvalue: 'httpStreamable',\n\t\t},\n\t\t{\n\t\t\tname: 'Server Sent Events (Deprecated)',\n\t\t\tvalue: 'sse',\n\t\t},\n\t],\n\tdefault: defaultOption,\n\tdescription: 'The transport used by your endpoint',\n\tdisplayOptions,\n});\n\nexport const credentials: INodeCredentialDescription[] = [\n\t{\n\t\tname: 'httpBearerAuth',\n\t\trequired: true,\n\t\tdisplayOptions: {\n\t\t\tshow: {\n\t\t\t\tauthentication: ['bearerAuth'],\n\t\t\t},\n\t\t},\n\t},\n\t{\n\t\tname: 'httpHeaderAuth',\n\t\trequired: true,\n\t\tdisplayOptions: {\n\t\t\tshow: {\n\t\t\t\tauthentication: ['headerAuth'],\n\t\t\t},\n\t\t},\n\t},\n\t{\n\t\tname: 'mcpOAuth2Api',\n\t\trequired: true,\n\t\tdisplayOptions: {\n\t\t\tshow: {\n\t\t\t\tauthentication: ['mcpOAuth2Api'],\n\t\t\t},\n\t\t},\n\t},\n\t{\n\t\tname: 'httpMultipleHeadersAuth',\n\t\trequired: true,\n\t\tdisplayOptions: {\n\t\t\tshow: {\n\t\t\t\tauthentication: ['multipleHeadersAuth'],\n\t\t\t},\n\t\t},\n\t},\n];\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAEO,MAAM,kBAAkB,CAAC;AAAA,EAC/B;AAAA,EACA;AACD,OAGwB;AAAA,EACvB,aAAa;AAAA,EACb,MAAM;AAAA,EACN,MAAM;AAAA,EACN,SAAS;AAAA,IACR;AAAA,MACC,MAAM;AAAA,MACN,OAAO;AAAA,IACR;AAAA,IACA;AAAA,MACC,MAAM;AAAA,MACN,OAAO;AAAA,IACR;AAAA,EACD;AAAA,EACA,SAAS;AAAA,EACT,aAAa;AAAA,EACb;AACD;AAEO,MAAM,cAA4C;AAAA,EACxD;AAAA,IACC,MAAM;AAAA,IACN,UAAU;AAAA,IACV,gBAAgB;AAAA,MACf,MAAM;AAAA,QACL,gBAAgB,CAAC,YAAY;AAAA,MAC9B;AAAA,IACD;AAAA,EACD;AAAA,EACA;AAAA,IACC,MAAM;AAAA,IACN,UAAU;AAAA,IACV,gBAAgB;AAAA,MACf,MAAM;AAAA,QACL,gBAAgB,CAAC,YAAY;AAAA,MAC9B;AAAA,IACD;AAAA,EACD;AAAA,EACA;AAAA,IACC,MAAM;AAAA,IACN,UAAU;AAAA,IACV,gBAAgB;AAAA,MACf,MAAM;AAAA,QACL,gBAAgB,CAAC,cAAc;AAAA,MAChC;AAAA,IACD;AAAA,EACD;AAAA,EACA;AAAA,IACC,MAAM;AAAA,IACN,UAAU;AAAA,IACV,gBAAgB;AAAA,MACf,MAAM;AAAA,QACL,gBAAgB,CAAC,qBAAqB;AAAA,MACvC;AAAA,IACD;AAAA,EACD;AACD;","names":[]}
@@ -0,0 +1,47 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var helpers_exports = {};
20
+ __export(helpers_exports, {
21
+ getConnectedTools: () => getConnectedTools
22
+ });
23
+ module.exports = __toCommonJS(helpers_exports);
24
+ var import_n8n_workflow = require("n8n-workflow");
25
+ async function getConnectedTools(context, includeBuiltIn = true) {
26
+ const tools = [];
27
+ try {
28
+ const connectedTools = await context.getInputConnectionData(
29
+ import_n8n_workflow.NodeConnectionTypes.AiTool,
30
+ 0
31
+ );
32
+ if (connectedTools) {
33
+ if (Array.isArray(connectedTools)) {
34
+ tools.push(...connectedTools);
35
+ } else {
36
+ tools.push(connectedTools);
37
+ }
38
+ }
39
+ } catch (error) {
40
+ }
41
+ return tools;
42
+ }
43
+ // Annotate the CommonJS export names for ESM import in node:
44
+ 0 && (module.exports = {
45
+ getConnectedTools
46
+ });
47
+ //# sourceMappingURL=helpers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/shared/helpers.ts"],"sourcesContent":["\nimport type { IWebhookFunctions } from 'n8n-workflow';\nimport { NodeConnectionTypes } from 'n8n-workflow';\nimport type { Tool } from '@langchain/core/tools';\n\nexport async function getConnectedTools(\n context: IWebhookFunctions,\n includeBuiltIn: boolean = true\n): Promise<Tool[]> {\n const tools: Tool[] = [];\n \n try {\n // Get tools from connected nodes via the 'Tools' input connection\n const connectedTools = (await context.getInputConnectionData(\n NodeConnectionTypes.AiTool,\n 0,\n )) as Tool[] | Tool | undefined;\n\n if (connectedTools) {\n if (Array.isArray(connectedTools)) {\n tools.push(...connectedTools);\n } else {\n tools.push(connectedTools);\n }\n }\n } catch (error) {\n // No tools connected or error retrieving them - return empty array\n }\n\n return tools;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAEA,0BAAoC;AAGpC,eAAsB,kBAClB,SACA,iBAA0B,MACX;AACf,QAAM,QAAgB,CAAC;AAEvB,MAAI;AAEA,UAAM,iBAAkB,MAAM,QAAQ;AAAA,MAClC,wCAAoB;AAAA,MACpB;AAAA,IACJ;AAEA,QAAI,gBAAgB;AAChB,UAAI,MAAM,QAAQ,cAAc,GAAG;AAC/B,cAAM,KAAK,GAAG,cAAc;AAAA,MAChC,OAAO;AACH,cAAM,KAAK,cAAc;AAAA,MAC7B;AAAA,IACJ;AAAA,EACJ,SAAS,OAAO;AAAA,EAEhB;AAEA,SAAO;AACX;","names":[]}
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var httpProxyAgent_exports = {};
20
+ __export(httpProxyAgent_exports, {
21
+ proxyFetch: () => proxyFetch
22
+ });
23
+ module.exports = __toCommonJS(httpProxyAgent_exports);
24
+ async function proxyFetch(url, init) {
25
+ return globalThis.fetch(url, init);
26
+ }
27
+ // Annotate the CommonJS export names for ESM import in node:
28
+ 0 && (module.exports = {
29
+ proxyFetch
30
+ });
31
+ //# sourceMappingURL=httpProxyAgent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/shared/httpProxyAgent.ts"],"sourcesContent":["\nimport type { RequestInit, Response } from 'node-fetch';\n\n// Simple pass-through fetch since we don't have the original proxy logic.\n// In a real n8n node, you might want to integrate with n8n's proxy settings.\nexport async function proxyFetch(url: string | URL, init?: RequestInit): Promise<Response> {\n // @ts-ignore - native fetch vs node-fetch types mismatch might occur, but for now we try global fetch or assume node-fetch is available\n // If running in Node 18+, global fetch exists. \n // n8n environments often have fetch.\n return (globalThis.fetch as unknown as typeof fetch)(url as any, init as any);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAKA,eAAsB,WAAW,KAAmB,MAAuC;AAIvF,SAAQ,WAAW,MAAkC,KAAY,IAAW;AAChF;","names":[]}
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var logWrapper_exports = {};
20
+ __export(logWrapper_exports, {
21
+ logWrapper: () => logWrapper
22
+ });
23
+ module.exports = __toCommonJS(logWrapper_exports);
24
+ function logWrapper(tool, context) {
25
+ return tool;
26
+ }
27
+ // Annotate the CommonJS export names for ESM import in node:
28
+ 0 && (module.exports = {
29
+ logWrapper
30
+ });
31
+ //# sourceMappingURL=logWrapper.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/shared/logWrapper.ts"],"sourcesContent":["import type { DynamicTool } from '@langchain/core/tools';\nimport type { ISupplyDataFunctions } from 'n8n-workflow';\n\n/**\n * Wraps a LangChain tool with logging functionality for n8n\n */\nexport function logWrapper(\n\ttool: DynamicTool,\n\tcontext: ISupplyDataFunctions,\n): DynamicTool {\n\t// Simply return the tool as-is since we don't have full n8n logging infrastructure\n\treturn tool;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAMO,SAAS,WACf,MACA,SACc;AAEd,SAAO;AACR;","names":[]}
@@ -0,0 +1,32 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var schemaParsing_exports = {};
20
+ __export(schemaParsing_exports, {
21
+ convertJsonSchemaToZod: () => convertJsonSchemaToZod
22
+ });
23
+ module.exports = __toCommonJS(schemaParsing_exports);
24
+ function convertJsonSchemaToZod(schema) {
25
+ const { z } = require("zod");
26
+ return z.any();
27
+ }
28
+ // Annotate the CommonJS export names for ESM import in node:
29
+ 0 && (module.exports = {
30
+ convertJsonSchemaToZod
31
+ });
32
+ //# sourceMappingURL=schemaParsing.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/shared/schemaParsing.ts"],"sourcesContent":["/**\n * Utility for parsing JSON schemas for n8n resource mapping\n */\nexport function convertJsonSchemaToZod(schema: any): any {\n\t// This is a simplified stub - real implementation would convert JSON Schema to Zod schema\n\t// For now, return a passthrough that accepts any object\n\tconst { z } = require('zod');\n\treturn z.any();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAGO,SAAS,uBAAuB,QAAkB;AAGxD,QAAM,EAAE,EAAE,IAAI,QAAQ,KAAK;AAC3B,SAAO,EAAE,IAAI;AACd;","names":[]}
@@ -0,0 +1,41 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var sharedFields_exports = {};
20
+ __export(sharedFields_exports, {
21
+ getConnectionHintNoticeField: () => getConnectionHintNoticeField
22
+ });
23
+ module.exports = __toCommonJS(sharedFields_exports);
24
+ function getConnectionHintNoticeField(connectionTypes) {
25
+ return {
26
+ displayName: "",
27
+ name: "notice",
28
+ type: "notice",
29
+ default: "",
30
+ displayOptions: {
31
+ show: {
32
+ "@version": [{ _cnd: { gte: 1 } }]
33
+ }
34
+ }
35
+ };
36
+ }
37
+ // Annotate the CommonJS export names for ESM import in node:
38
+ 0 && (module.exports = {
39
+ getConnectionHintNoticeField
40
+ });
41
+ //# sourceMappingURL=sharedFields.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/shared/sharedFields.ts"],"sourcesContent":["import type { INodeProperties } from 'n8n-workflow';\n\n/**\n * Returns a connection hint notice field for AI nodes\n */\nexport function getConnectionHintNoticeField(\n\tconnectionTypes: string[],\n): INodeProperties {\n\treturn {\n\t\tdisplayName: '',\n\t\tname: 'notice',\n\t\ttype: 'notice',\n\t\tdefault: '',\n\t\tdisplayOptions: {\n\t\t\tshow: {\n\t\t\t\t'@version': [{ _cnd: { gte: 1 } }],\n\t\t\t},\n\t\t},\n\t};\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAKO,SAAS,6BACf,iBACkB;AAClB,SAAO;AAAA,IACN,aAAa;AAAA,IACb,MAAM;AAAA,IACN,MAAM;AAAA,IACN,SAAS;AAAA,IACT,gBAAgB;AAAA,MACf,MAAM;AAAA,QACL,YAAY,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC;AAAA,MAClC;AAAA,IACD;AAAA,EACD;AACD;","names":[]}
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
15
+ var types_exports = {};
16
+ module.exports = __toCommonJS(types_exports);
17
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../nodes/shared/types.ts"],"sourcesContent":["import type { JSONSchema7 } from 'json-schema';\n\nexport type McpTool = { name: string; description?: string; inputSchema: JSONSchema7 };\n\nexport type McpServerTransport = 'sse' | 'httpStreamable';\n\nexport type McpAuthenticationOption =\n\t| 'none'\n\t| 'headerAuth'\n\t| 'bearerAuth'\n\t| 'mcpOAuth2Api'\n\t| 'multipleHeadersAuth';\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}