@atom8n/n8n 2.4.7 → 2.5.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.
Files changed (231) hide show
  1. package/dist/build.tsbuildinfo +1 -1
  2. package/dist/chat/chat-service.types.d.ts +6 -6
  3. package/dist/commands/execute-batch.d.ts +2 -2
  4. package/dist/commands/execute.js +0 -0
  5. package/dist/commands/import/credentials.d.ts +2 -2
  6. package/dist/commands/import/credentials.js +0 -0
  7. package/dist/commands/import/workflow.d.ts +2 -2
  8. package/dist/commands/ldap/reset.d.ts +2 -2
  9. package/dist/commands/mcp.d.ts +23 -0
  10. package/dist/commands/mcp.js +315 -0
  11. package/dist/commands/run.d.ts +23 -0
  12. package/dist/commands/run.js +162 -0
  13. package/dist/controllers/annotation-tags.controller.ee.d.ts +1 -1
  14. package/dist/controllers/cli.controller.d.ts +26 -0
  15. package/dist/controllers/cli.controller.js +334 -0
  16. package/dist/controllers/orchestration.controller.js +0 -0
  17. package/dist/controllers/users.controller.d.ts +1 -1
  18. package/dist/environments.ee/source-control/source-control-status.service.ee.d.ts +2 -2
  19. package/dist/environments.ee/source-control/source-control.controller.ee.d.ts +4 -4
  20. package/dist/environments.ee/source-control/source-control.service.ee.d.ts +2 -2
  21. package/dist/environments.ee/source-control/types/source-control-set-branch.js +0 -0
  22. package/dist/eventbus/event-message-classes/index.js +0 -0
  23. package/dist/events/relays/workflow-failure-notification.event-relay.d.ts +13 -0
  24. package/dist/events/relays/workflow-failure-notification.event-relay.js +77 -0
  25. package/dist/executions/execution-data/types.d.ts +17 -0
  26. package/dist/executions/execution-data/types.js +2 -0
  27. package/dist/executions/failed-run-factory.d.ts +4 -0
  28. package/dist/executions/failed-run-factory.js +71 -0
  29. package/dist/index.d.ts +2 -1
  30. package/dist/index.js +8 -0
  31. package/dist/interfaces.d.ts +1 -1
  32. package/dist/license.js +1 -1
  33. package/dist/middlewares/webview-frame-options.d.ts +2 -0
  34. package/dist/middlewares/webview-frame-options.js +22 -0
  35. package/dist/modules/chat-hub/chat-hub-extractor.d.ts +22 -0
  36. package/dist/modules/chat-hub/chat-hub-extractor.js +63 -0
  37. package/dist/modules/dynamic-credentials.ee/credential-resolvers/storage/dynamic-credential-user-entry-storage.d.ts +11 -0
  38. package/dist/modules/dynamic-credentials.ee/credential-resolvers/storage/dynamic-credential-user-entry-storage.js +58 -0
  39. package/dist/modules/dynamic-credentials.ee/database/entities/dynamic-credential-user-entry.d.ts +12 -0
  40. package/dist/modules/dynamic-credentials.ee/database/entities/dynamic-credential-user-entry.js +64 -0
  41. package/dist/modules/dynamic-credentials.ee/database/repositories/dynamic-credential-user-entry.repository.d.ts +5 -0
  42. package/dist/modules/dynamic-credentials.ee/database/repositories/dynamic-credential-user-entry.repository.js +25 -0
  43. package/dist/modules/dynamic-credentials.ee/dynamic-credentials.config.d.ts +5 -0
  44. package/dist/modules/dynamic-credentials.ee/dynamic-credentials.config.js +36 -0
  45. package/dist/modules/dynamic-credentials.ee/services/dynamic-credential-cors.service.d.ts +12 -0
  46. package/dist/modules/dynamic-credentials.ee/services/dynamic-credential-cors.service.js +69 -0
  47. package/dist/modules/dynamic-credentials.ee/services/resolver-config-expression.service.d.ts +7 -0
  48. package/dist/modules/dynamic-credentials.ee/services/resolver-config-expression.service.js +46 -0
  49. package/dist/modules/insights/database/entities/insights-metadata.js +1 -1
  50. package/dist/modules/insights/database/repositories/insights-by-period-query.helper.js +4 -1
  51. package/dist/modules/insights/database/repositories/insights-by-period.repository.d.ts +1 -1
  52. package/dist/modules/insights/insights.module.d.ts +1 -1
  53. package/dist/modules/insights/insights.service.d.ts +1 -1
  54. package/dist/modules/log-streaming.ee/database/entities/event-destination.entity.d.ts +6 -0
  55. package/dist/modules/log-streaming.ee/database/entities/event-destination.entity.js +28 -0
  56. package/dist/modules/log-streaming.ee/database/entities/index.d.ts +1 -0
  57. package/dist/modules/log-streaming.ee/database/entities/index.js +5 -0
  58. package/dist/modules/log-streaming.ee/database/repositories/event-destination.repository.d.ts +5 -0
  59. package/dist/modules/log-streaming.ee/database/repositories/event-destination.repository.js +25 -0
  60. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-from-db.d.ts +4 -0
  61. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-from-db.js +24 -0
  62. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-sentry.ee.d.ts +17 -0
  63. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-sentry.ee.js +131 -0
  64. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-syslog.ee.d.ts +22 -0
  65. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-syslog.ee.js +116 -0
  66. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-webhook.ee.d.ts +35 -0
  67. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination-webhook.ee.js +328 -0
  68. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination.ee.d.ts +28 -0
  69. package/dist/modules/log-streaming.ee/destinations/message-event-bus-destination.ee.js +74 -0
  70. package/dist/modules/log-streaming.ee/log-streaming-destination.service.d.ts +32 -0
  71. package/dist/modules/log-streaming.ee/log-streaming-destination.service.js +175 -0
  72. package/dist/modules/log-streaming.ee/log-streaming.controller.d.ts +15 -0
  73. package/dist/modules/log-streaming.ee/log-streaming.controller.js +149 -0
  74. package/dist/modules/log-streaming.ee/log-streaming.module.d.ts +5 -0
  75. package/dist/modules/log-streaming.ee/log-streaming.module.js +66 -0
  76. package/dist/modules/mcp/mcp-oauth.helpers.js +0 -0
  77. package/dist/modules/mcp/mcp.oauth-clients.controller.js +0 -0
  78. package/dist/modules/mcp/tools/execute-workflow.tool.d.ts +10 -10
  79. package/dist/modules/mcp/tools/schemas.d.ts +10 -10
  80. package/dist/modules/source-control.ee/constants.d.ts +17 -0
  81. package/dist/modules/source-control.ee/constants.js +22 -0
  82. package/dist/modules/source-control.ee/middleware/source-control-enabled-middleware.ee.d.ts +2 -0
  83. package/dist/modules/source-control.ee/middleware/source-control-enabled-middleware.ee.js +18 -0
  84. package/dist/modules/source-control.ee/source-control-export.service.ee.d.ts +37 -0
  85. package/dist/modules/source-control.ee/source-control-export.service.ee.js +426 -0
  86. package/dist/modules/source-control.ee/source-control-git.service.ee.d.ts +59 -0
  87. package/dist/modules/source-control.ee/source-control-git.service.ee.js +427 -0
  88. package/dist/modules/source-control.ee/source-control-helper.ee.d.ts +49 -0
  89. package/dist/modules/source-control.ee/source-control-helper.ee.js +241 -0
  90. package/dist/modules/source-control.ee/source-control-import.service.ee.d.ts +110 -0
  91. package/dist/modules/source-control.ee/source-control-import.service.ee.js +957 -0
  92. package/dist/modules/source-control.ee/source-control-preferences.service.ee.d.ts +46 -0
  93. package/dist/modules/source-control.ee/source-control-preferences.service.ee.js +309 -0
  94. package/dist/modules/source-control.ee/source-control-resource-helper.d.ts +4 -0
  95. package/dist/modules/source-control.ee/source-control-resource-helper.js +20 -0
  96. package/dist/modules/source-control.ee/source-control-scoped.service.d.ts +17 -0
  97. package/dist/modules/source-control.ee/source-control-scoped.service.js +134 -0
  98. package/dist/modules/source-control.ee/source-control-status.service.ee.d.ts +90 -0
  99. package/dist/modules/source-control.ee/source-control-status.service.ee.js +596 -0
  100. package/dist/modules/source-control.ee/source-control.config.d.ts +3 -0
  101. package/dist/modules/source-control.ee/source-control.config.js +26 -0
  102. package/dist/modules/source-control.ee/source-control.controller.ee.d.ts +157 -0
  103. package/dist/modules/source-control.ee/source-control.controller.ee.js +347 -0
  104. package/dist/modules/source-control.ee/source-control.module.d.ts +4 -0
  105. package/dist/modules/source-control.ee/source-control.module.js +59 -0
  106. package/dist/modules/source-control.ee/source-control.service.ee.d.ts +125 -0
  107. package/dist/modules/source-control.ee/source-control.service.ee.js +466 -0
  108. package/dist/modules/source-control.ee/types/export-result.d.ts +10 -0
  109. package/dist/modules/source-control.ee/types/export-result.js +2 -0
  110. package/dist/modules/source-control.ee/types/exportable-credential.d.ts +14 -0
  111. package/dist/modules/source-control.ee/types/exportable-credential.js +2 -0
  112. package/dist/modules/source-control.ee/types/exportable-folders.d.ts +11 -0
  113. package/dist/modules/source-control.ee/types/exportable-folders.js +2 -0
  114. package/dist/modules/source-control.ee/types/exportable-project.d.ts +17 -0
  115. package/dist/modules/source-control.ee/types/exportable-project.js +2 -0
  116. package/dist/modules/source-control.ee/types/exportable-tags.d.ts +5 -0
  117. package/dist/modules/source-control.ee/types/exportable-tags.js +2 -0
  118. package/dist/modules/source-control.ee/types/exportable-variable.d.ts +7 -0
  119. package/dist/modules/source-control.ee/types/exportable-variable.js +2 -0
  120. package/dist/modules/source-control.ee/types/exportable-workflow.d.ts +14 -0
  121. package/dist/modules/source-control.ee/types/exportable-workflow.js +2 -0
  122. package/dist/modules/source-control.ee/types/import-result.d.ts +20 -0
  123. package/dist/modules/source-control.ee/types/import-result.js +2 -0
  124. package/dist/modules/source-control.ee/types/key-pair-type.d.ts +1 -0
  125. package/dist/modules/source-control.ee/types/key-pair-type.js +2 -0
  126. package/dist/modules/source-control.ee/types/key-pair.d.ts +4 -0
  127. package/dist/modules/source-control.ee/types/key-pair.js +2 -0
  128. package/dist/modules/source-control.ee/types/requests.d.ts +21 -0
  129. package/dist/modules/source-control.ee/types/requests.js +2 -0
  130. package/dist/modules/source-control.ee/types/resource-owner.d.ts +17 -0
  131. package/dist/modules/source-control.ee/types/resource-owner.js +2 -0
  132. package/dist/modules/source-control.ee/types/source-control-commit.d.ts +3 -0
  133. package/dist/modules/source-control.ee/types/source-control-commit.js +20 -0
  134. package/dist/modules/source-control.ee/types/source-control-context.d.ts +7 -0
  135. package/dist/modules/source-control.ee/types/source-control-context.js +16 -0
  136. package/dist/modules/source-control.ee/types/source-control-disconnect.d.ts +3 -0
  137. package/dist/modules/source-control.ee/types/source-control-disconnect.js +21 -0
  138. package/dist/modules/source-control.ee/types/source-control-generate-key-pair.d.ts +4 -0
  139. package/dist/modules/source-control.ee/types/source-control-generate-key-pair.js +21 -0
  140. package/dist/modules/source-control.ee/types/source-control-get-status.d.ts +10 -0
  141. package/dist/modules/source-control.ee/types/source-control-get-status.js +42 -0
  142. package/dist/modules/source-control.ee/types/source-control-preferences.d.ts +17 -0
  143. package/dist/modules/source-control.ee/types/source-control-preferences.js +88 -0
  144. package/dist/modules/source-control.ee/types/source-control-push.d.ts +3 -0
  145. package/dist/modules/source-control.ee/types/source-control-push.js +21 -0
  146. package/dist/modules/source-control.ee/types/source-control-set-branch.d.ts +3 -0
  147. package/dist/modules/source-control.ee/types/source-control-set-branch.js +20 -0
  148. package/dist/modules/source-control.ee/types/source-control-set-read-only.d.ts +3 -0
  149. package/dist/modules/source-control.ee/types/source-control-set-read-only.js +20 -0
  150. package/dist/modules/source-control.ee/types/source-control-stage.d.ts +5 -0
  151. package/dist/modules/source-control.ee/types/source-control-stage.js +31 -0
  152. package/dist/modules/source-control.ee/types/source-control-workflow-version-id.d.ts +12 -0
  153. package/dist/modules/source-control.ee/types/source-control-workflow-version-id.js +2 -0
  154. package/dist/modules/sso-oidc/constants.d.ts +3 -0
  155. package/dist/modules/sso-oidc/constants.js +6 -0
  156. package/dist/modules/sso-oidc/oidc.controller.ee.d.ts +23 -0
  157. package/dist/modules/sso-oidc/oidc.controller.ee.js +123 -0
  158. package/dist/modules/sso-oidc/oidc.service.ee.d.ts +56 -0
  159. package/dist/modules/sso-oidc/oidc.service.ee.js +468 -0
  160. package/dist/modules/sso-oidc/sso-oidc.module.d.ts +4 -0
  161. package/dist/modules/sso-oidc/sso-oidc.module.js +55 -0
  162. package/dist/modules/sso-saml/constants.d.ts +3 -0
  163. package/dist/modules/sso-saml/constants.js +6 -0
  164. package/dist/modules/sso-saml/errors/invalid-saml-metadata-url.error.d.ts +4 -0
  165. package/dist/modules/sso-saml/errors/invalid-saml-metadata-url.error.js +10 -0
  166. package/dist/modules/sso-saml/errors/invalid-saml-metadata.error.d.ts +4 -0
  167. package/dist/modules/sso-saml/errors/invalid-saml-metadata.error.js +10 -0
  168. package/dist/modules/sso-saml/middleware/saml-enabled-middleware.d.ts +3 -0
  169. package/dist/modules/sso-saml/middleware/saml-enabled-middleware.js +22 -0
  170. package/dist/modules/sso-saml/saml-helpers.d.ts +19 -0
  171. package/dist/modules/sso-saml/saml-helpers.js +129 -0
  172. package/dist/modules/sso-saml/saml-validator.d.ts +16 -0
  173. package/dist/modules/sso-saml/saml-validator.js +129 -0
  174. package/dist/modules/sso-saml/saml.controller.ee.d.ts +50 -0
  175. package/dist/modules/sso-saml/saml.controller.ee.js +227 -0
  176. package/dist/modules/sso-saml/saml.service.ee.d.ts +52 -0
  177. package/dist/modules/sso-saml/saml.service.ee.js +462 -0
  178. package/dist/modules/sso-saml/schema/metadata-exchange.xsd.d.ts +2 -0
  179. package/dist/modules/sso-saml/schema/metadata-exchange.xsd.js +118 -0
  180. package/dist/modules/sso-saml/schema/oasis-200401-wss-wssecurity-secext-1.0.xsd.d.ts +2 -0
  181. package/dist/modules/sso-saml/schema/oasis-200401-wss-wssecurity-secext-1.0.xsd.js +201 -0
  182. package/dist/modules/sso-saml/schema/oasis-200401-wss-wssecurity-utility-1.0.xsd.d.ts +2 -0
  183. package/dist/modules/sso-saml/schema/oasis-200401-wss-wssecurity-utility-1.0.xsd.js +114 -0
  184. package/dist/modules/sso-saml/schema/saml-schema-assertion-2.0.xsd.d.ts +2 -0
  185. package/dist/modules/sso-saml/schema/saml-schema-assertion-2.0.xsd.js +289 -0
  186. package/dist/modules/sso-saml/schema/saml-schema-metadata-2.0.xsd.d.ts +2 -0
  187. package/dist/modules/sso-saml/schema/saml-schema-metadata-2.0.xsd.js +344 -0
  188. package/dist/modules/sso-saml/schema/saml-schema-protocol-2.0.xsd.d.ts +2 -0
  189. package/dist/modules/sso-saml/schema/saml-schema-protocol-2.0.xsd.js +308 -0
  190. package/dist/modules/sso-saml/schema/ws-addr.xsd.d.ts +2 -0
  191. package/dist/modules/sso-saml/schema/ws-addr.xsd.js +143 -0
  192. package/dist/modules/sso-saml/schema/ws-authorization.xsd.d.ts +2 -0
  193. package/dist/modules/sso-saml/schema/ws-authorization.xsd.js +151 -0
  194. package/dist/modules/sso-saml/schema/ws-federation.xsd.d.ts +2 -0
  195. package/dist/modules/sso-saml/schema/ws-federation.xsd.js +476 -0
  196. package/dist/modules/sso-saml/schema/ws-securitypolicy-1.2.xsd.d.ts +2 -0
  197. package/dist/modules/sso-saml/schema/ws-securitypolicy-1.2.xsd.js +1211 -0
  198. package/dist/modules/sso-saml/schema/xenc-schema.xsd.d.ts +2 -0
  199. package/dist/modules/sso-saml/schema/xenc-schema.xsd.js +151 -0
  200. package/dist/modules/sso-saml/schema/xml.xsd.d.ts +2 -0
  201. package/dist/modules/sso-saml/schema/xml.xsd.js +123 -0
  202. package/dist/modules/sso-saml/schema/xmldsig-core-schema.xsd.d.ts +2 -0
  203. package/dist/modules/sso-saml/schema/xmldsig-core-schema.xsd.js +324 -0
  204. package/dist/modules/sso-saml/service-provider.ee.d.ts +6 -0
  205. package/dist/modules/sso-saml/service-provider.ee.js +44 -0
  206. package/dist/modules/sso-saml/sso-saml.module.d.ts +4 -0
  207. package/dist/modules/sso-saml/sso-saml.module.js +55 -0
  208. package/dist/modules/sso-saml/types.d.ts +4 -0
  209. package/dist/modules/sso-saml/types.js +2 -0
  210. package/dist/modules/sso-saml/views/init-sso-post.d.ts +2 -0
  211. package/dist/modules/sso-saml/views/init-sso-post.js +16 -0
  212. package/dist/node-lib.d.ts +10 -0
  213. package/dist/node-lib.js +137 -0
  214. package/dist/push/index.d.ts +1 -1
  215. package/dist/server.d.ts +1 -0
  216. package/dist/server.js +1 -0
  217. package/dist/services/cors-service.d.ts +7 -0
  218. package/dist/services/cors-service.js +50 -0
  219. package/dist/services/static-auth-service.d.ts +4 -0
  220. package/dist/services/static-auth-service.js +29 -0
  221. package/dist/sso.ee/saml/schema/metadata-exchange.xsd.js +0 -0
  222. package/dist/task-runners/task-broker/errors/task-runner-accept-timeout.error.js +0 -0
  223. package/dist/typecheck.tsbuildinfo +1 -0
  224. package/dist/user-management/email/templates/workflow-failure.handlebars +211 -0
  225. package/dist/utils/cors.util.d.ts +2 -0
  226. package/dist/utils/cors.util.js +17 -0
  227. package/dist/webhooks/waiting-forms.js +3 -3
  228. package/dist/webhooks/waiting-webhooks.js +2 -0
  229. package/dist/workflows/workflow.service.d.ts +2 -2
  230. package/dist/workflows/workflows.controller.d.ts +6 -6
  231. package/package.json +22 -21
@@ -29,30 +29,30 @@ export declare const chatMessageSchema: z.ZodObject<{
29
29
  type: z.ZodString;
30
30
  data: z.ZodString;
31
31
  }, "strip", z.ZodTypeAny, {
32
- data: string;
33
32
  name: string;
33
+ data: string;
34
34
  type: string;
35
35
  }, {
36
- data: string;
37
36
  name: string;
37
+ data: string;
38
38
  type: string;
39
39
  }>, "many">>;
40
40
  }, "strip", z.ZodTypeAny, {
41
+ chatInput: string;
41
42
  action: "sendMessage";
42
43
  sessionId: string;
43
- chatInput: string;
44
44
  files?: {
45
- data: string;
46
45
  name: string;
46
+ data: string;
47
47
  type: string;
48
48
  }[] | undefined;
49
49
  }, {
50
+ chatInput: string;
50
51
  action: "sendMessage";
51
52
  sessionId: string;
52
- chatInput: string;
53
53
  files?: {
54
- data: string;
55
54
  name: string;
55
+ data: string;
56
56
  type: string;
57
57
  }[] | undefined;
58
58
  }>;
@@ -20,8 +20,8 @@ declare const flagsSchema: z.ZodObject<{
20
20
  concurrency: number;
21
21
  retries: number;
22
22
  output?: string | undefined;
23
- ids?: string | undefined;
24
23
  compare?: string | undefined;
24
+ ids?: string | undefined;
25
25
  snapshot?: string | undefined;
26
26
  shallow?: boolean | undefined;
27
27
  githubWorkflow?: boolean | undefined;
@@ -31,8 +31,8 @@ declare const flagsSchema: z.ZodObject<{
31
31
  debug?: boolean | undefined;
32
32
  output?: string | undefined;
33
33
  concurrency?: number | undefined;
34
- ids?: string | undefined;
35
34
  compare?: string | undefined;
35
+ ids?: string | undefined;
36
36
  snapshot?: string | undefined;
37
37
  shallow?: boolean | undefined;
38
38
  githubWorkflow?: boolean | undefined;
File without changes
@@ -8,12 +8,12 @@ declare const flagsSchema: z.ZodObject<{
8
8
  }, "strip", z.ZodTypeAny, {
9
9
  separate: boolean;
10
10
  input?: string | undefined;
11
- userId?: string | undefined;
12
11
  projectId?: string | undefined;
12
+ userId?: string | undefined;
13
13
  }, {
14
14
  input?: string | undefined;
15
- userId?: string | undefined;
16
15
  projectId?: string | undefined;
16
+ userId?: string | undefined;
17
17
  separate?: boolean | undefined;
18
18
  }>;
19
19
  export declare class ImportCredentialsCommand extends BaseCommand<z.infer<typeof flagsSchema>> {
File without changes
@@ -8,12 +8,12 @@ declare const flagsSchema: z.ZodObject<{
8
8
  }, "strip", z.ZodTypeAny, {
9
9
  separate: boolean;
10
10
  input?: string | undefined;
11
- userId?: string | undefined;
12
11
  projectId?: string | undefined;
12
+ userId?: string | undefined;
13
13
  }, {
14
14
  input?: string | undefined;
15
- userId?: string | undefined;
16
15
  projectId?: string | undefined;
16
+ userId?: string | undefined;
17
17
  separate?: boolean | undefined;
18
18
  }>;
19
19
  export declare class ImportWorkflowsCommand extends BaseCommand<z.infer<typeof flagsSchema>> {
@@ -5,12 +5,12 @@ declare const flagsSchema: z.ZodObject<{
5
5
  projectId: z.ZodOptional<z.ZodString>;
6
6
  deleteWorkflowsAndCredentials: z.ZodOptional<z.ZodBoolean>;
7
7
  }, "strip", z.ZodTypeAny, {
8
- userId?: string | undefined;
9
8
  projectId?: string | undefined;
9
+ userId?: string | undefined;
10
10
  deleteWorkflowsAndCredentials?: boolean | undefined;
11
11
  }, {
12
- userId?: string | undefined;
13
12
  projectId?: string | undefined;
13
+ userId?: string | undefined;
14
14
  deleteWorkflowsAndCredentials?: boolean | undefined;
15
15
  }>;
16
16
  export declare class Reset extends BaseCommand<z.infer<typeof flagsSchema>> {
@@ -0,0 +1,23 @@
1
+ import { z } from 'zod';
2
+ import { BaseCommand } from './base-command';
3
+ declare const flagsSchema: z.ZodObject<{
4
+ file: z.ZodOptional<z.ZodString>;
5
+ }, "strip", z.ZodTypeAny, {
6
+ file?: string | undefined;
7
+ }, {
8
+ file?: string | undefined;
9
+ }>;
10
+ export declare class Mcp extends BaseCommand<z.infer<typeof flagsSchema>> {
11
+ needsCommunityPackages: boolean;
12
+ needsTaskRunner: boolean;
13
+ init(): Promise<void>;
14
+ run(): Promise<void>;
15
+ private executeWorkflowTool;
16
+ private resolveAllFiles;
17
+ private resolvePositionalFiles;
18
+ private logStderr;
19
+ private sanitizeToolName;
20
+ catch(error: Error): Promise<void>;
21
+ finally(error: Error | undefined): Promise<void>;
22
+ }
23
+ export {};
@@ -0,0 +1,315 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
19
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
20
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
21
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
22
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
23
+ };
24
+ var __importStar = (this && this.__importStar) || (function () {
25
+ var ownKeys = function(o) {
26
+ ownKeys = Object.getOwnPropertyNames || function (o) {
27
+ var ar = [];
28
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
29
+ return ar;
30
+ };
31
+ return ownKeys(o);
32
+ };
33
+ return function (mod) {
34
+ if (mod && mod.__esModule) return mod;
35
+ var result = {};
36
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
37
+ __setModuleDefault(result, mod);
38
+ return result;
39
+ };
40
+ })();
41
+ var __importDefault = (this && this.__importDefault) || function (mod) {
42
+ return (mod && mod.__esModule) ? mod : { "default": mod };
43
+ };
44
+ Object.defineProperty(exports, "__esModule", { value: true });
45
+ exports.Mcp = void 0;
46
+ const decorators_1 = require("@n8n/decorators");
47
+ const fs_1 = __importDefault(require("fs"));
48
+ const path_1 = __importDefault(require("path"));
49
+ const n8n_workflow_1 = require("n8n-workflow");
50
+ const zod_1 = require("zod");
51
+ const base_command_1 = require("./base-command");
52
+ const flagsSchema = zod_1.z.object({
53
+ file: zod_1.z.string().describe('Path to the .n8n workflow file to expose as an MCP tool').optional(),
54
+ });
55
+ let Mcp = class Mcp extends base_command_1.BaseCommand {
56
+ constructor() {
57
+ super(...arguments);
58
+ this.needsCommunityPackages = false;
59
+ this.needsTaskRunner = false;
60
+ }
61
+ async init() {
62
+ await super.init();
63
+ }
64
+ async run() {
65
+ const { flags } = this;
66
+ const filePaths = this.resolveAllFiles(flags.file);
67
+ this.logStderr(`[mcp] Resolved ${filePaths.length} workflow file(s)`);
68
+ if (filePaths.length === 0) {
69
+ throw new n8n_workflow_1.UserError('No workflow file specified. Usage: n8n mcp <file.n8n> [file2.n8n ...] or n8n mcp --file=<file.n8n>');
70
+ }
71
+ this.logStderr(`[mcp] ── STARTING MCP SERVER ──`);
72
+ const workflows = [];
73
+ for (const fileArg of filePaths) {
74
+ const filePath = path_1.default.resolve(fileArg);
75
+ this.logStderr(`[mcp] Loading: ${filePath}`);
76
+ if (!fs_1.default.existsSync(filePath)) {
77
+ throw new n8n_workflow_1.UserError(`[mcp] The workflow file does not exist: ${filePath}`);
78
+ }
79
+ try {
80
+ const fileContent = fs_1.default.readFileSync(filePath, { encoding: 'utf8' });
81
+ const workflowData = (0, n8n_workflow_1.jsonParse)(fileContent);
82
+ this.logStderr(`[mcp] ✓ "${workflowData.name}" (${workflowData.nodes?.length ?? 0} nodes)`);
83
+ workflows.push({ filePath, data: workflowData });
84
+ }
85
+ catch (error) {
86
+ throw new n8n_workflow_1.UserError(`[mcp] Failed to parse ${filePath}: ${error instanceof Error ? error.message : String(error)}`);
87
+ }
88
+ }
89
+ this.logStderr(`[mcp] Loaded ${workflows.length} workflow(s)`);
90
+ this.logStderr(`[mcp] Creating MCP server...`);
91
+ const { McpServer } = await Promise.resolve().then(() => __importStar(require('@modelcontextprotocol/sdk/server/mcp.js')));
92
+ const { StdioServerTransport } = await Promise.resolve().then(() => __importStar(require('@modelcontextprotocol/sdk/server/stdio.js')));
93
+ const serverPort = this.globalConfig.port;
94
+ const serverUrl = `http://localhost:${serverPort}`;
95
+ this.logStderr(`[mcp] n8n server URL: ${serverUrl}`);
96
+ const serverName = workflows.length === 1
97
+ ? workflows[0].data.name ||
98
+ this.sanitizeToolName(path_1.default.basename(workflows[0].filePath, '.n8n'))
99
+ : 'n8n MCP Server';
100
+ const server = new McpServer({
101
+ name: serverName,
102
+ version: '1.0.0',
103
+ });
104
+ const usedToolNames = new Set();
105
+ for (const { filePath, data: workflowData } of workflows) {
106
+ let toolName = this.sanitizeToolName(workflowData.name || path_1.default.basename(filePath, '.n8n'));
107
+ if (usedToolNames.has(toolName)) {
108
+ let suffix = 2;
109
+ while (usedToolNames.has(`${toolName}_${suffix}`))
110
+ suffix++;
111
+ toolName = `${toolName}_${suffix}`;
112
+ }
113
+ usedToolNames.add(toolName);
114
+ const triggerNode = workflowData.nodes?.find((node) => node.type.toLowerCase().includes('trigger') ||
115
+ node.type.toLowerCase().includes('webhook') ||
116
+ node.type === 'n8n-nodes-base.start');
117
+ const triggerType = triggerNode?.type ?? 'unknown';
118
+ const isChatTrigger = triggerType === '@n8n/n8n-nodes-langchain.chatTrigger';
119
+ this.logStderr(`[mcp] Registering tool "${toolName}" (trigger: ${triggerType})`);
120
+ const inputSchemaShape = isChatTrigger
121
+ ? { input: zod_1.z.string().describe('Input text for the chat workflow') }
122
+ : { input: zod_1.z.string().optional().describe('Input text or data for the workflow') };
123
+ const wfData = workflowData;
124
+ const wfIsChatTrigger = isChatTrigger;
125
+ const wfToolName = toolName;
126
+ server.registerTool(toolName, {
127
+ description: `Execute the n8n workflow "${workflowData.name}". ${isChatTrigger
128
+ ? 'This is a chat-based workflow — provide input text.'
129
+ : 'Provide optional input text for the workflow trigger.'}`,
130
+ inputSchema: inputSchemaShape,
131
+ }, async (args) => {
132
+ return await this.executeWorkflowTool(wfToolName, wfData, wfIsChatTrigger, serverUrl, args);
133
+ });
134
+ }
135
+ this.logStderr(`[mcp] Registered ${usedToolNames.size} tool(s): ${[...usedToolNames].join(', ')}`);
136
+ this.logStderr(`[mcp] Connecting via stdio transport...`);
137
+ const transport = new StdioServerTransport();
138
+ await server.connect(transport);
139
+ this.logStderr(`[mcp] ✅ MCP server is running. Waiting for requests on stdin...`);
140
+ await new Promise((resolve) => {
141
+ process.stdin.on('end', () => {
142
+ this.logStderr(`[mcp] stdin closed. Shutting down.`);
143
+ resolve();
144
+ });
145
+ process.stdin.on('close', () => {
146
+ this.logStderr(`[mcp] stdin closed. Shutting down.`);
147
+ resolve();
148
+ });
149
+ });
150
+ this.logStderr(`[mcp] Server stopped.`);
151
+ }
152
+ async executeWorkflowTool(toolName, workflowData, isChatTrigger, serverUrl, args) {
153
+ this.logStderr(`[mcp] ── TOOL CALL: "${toolName}" ──`);
154
+ this.logStderr(`[mcp] Input: ${JSON.stringify(args)}`);
155
+ try {
156
+ this.logStderr(`[mcp] Checking server health at ${serverUrl}...`);
157
+ const healthResponse = await fetch(`${serverUrl}/rest/cli/health`);
158
+ if (!healthResponse.ok) {
159
+ throw new Error(`Health check returned ${healthResponse.status}`);
160
+ }
161
+ this.logStderr(`[mcp] Server is reachable.`);
162
+ const executeUrl = `${serverUrl}/rest/cli/run`;
163
+ this.logStderr(`[mcp] POST ${executeUrl}`);
164
+ const requestBody = { workflowData };
165
+ if (args.input !== undefined) {
166
+ if (isChatTrigger) {
167
+ requestBody.chatInput = String(args.input);
168
+ }
169
+ else {
170
+ try {
171
+ const parsed = JSON.parse(String(args.input));
172
+ if (typeof parsed === 'object' && parsed !== null) {
173
+ requestBody.inputData = parsed;
174
+ }
175
+ else {
176
+ requestBody.chatInput = String(args.input);
177
+ }
178
+ }
179
+ catch {
180
+ requestBody.chatInput = String(args.input);
181
+ }
182
+ }
183
+ }
184
+ const response = await fetch(executeUrl, {
185
+ method: 'POST',
186
+ headers: { 'Content-Type': 'application/json' },
187
+ body: JSON.stringify(requestBody),
188
+ });
189
+ this.logStderr(`[mcp] Response status: ${response.status} ${response.statusText}`);
190
+ if (!response.ok) {
191
+ const errorBody = await response.text();
192
+ this.logStderr(`[mcp] API error: ${errorBody}`);
193
+ return {
194
+ content: [
195
+ {
196
+ type: 'text',
197
+ text: `Error executing workflow: ${response.status} ${response.statusText} — ${errorBody}`,
198
+ },
199
+ ],
200
+ isError: true,
201
+ };
202
+ }
203
+ const result = (await response.json());
204
+ this.logStderr(`[mcp] Execution complete — success: ${result.success}, executionId: ${result.executionId ?? 'unknown'}, time: ${result.executionTime ?? '?'}s`);
205
+ const lastNodeName = result.data?.lastNodeExecuted;
206
+ const outputItems = [];
207
+ if (lastNodeName && result.data?.runData?.[lastNodeName]) {
208
+ const nodeRuns = result.data.runData[lastNodeName];
209
+ const lastRun = nodeRuns[nodeRuns.length - 1];
210
+ if (lastRun?.data?.main) {
211
+ for (const branch of lastRun.data.main) {
212
+ if (branch) {
213
+ for (const item of branch) {
214
+ outputItems.push(item.json);
215
+ }
216
+ }
217
+ }
218
+ }
219
+ }
220
+ this.logStderr(`[mcp] Output items: ${outputItems.length}`);
221
+ if (!result.success) {
222
+ return {
223
+ content: [
224
+ {
225
+ type: 'text',
226
+ text: `Workflow execution failed: ${result.error ?? JSON.stringify(result.data?.error ?? 'Unknown error')}`,
227
+ },
228
+ ],
229
+ isError: true,
230
+ };
231
+ }
232
+ return {
233
+ content: [
234
+ {
235
+ type: 'text',
236
+ text: JSON.stringify(outputItems.length === 1 ? outputItems[0] : outputItems, null, 2),
237
+ },
238
+ ],
239
+ };
240
+ }
241
+ catch (error) {
242
+ const errorMsg = error instanceof Error ? error.message : String(error);
243
+ this.logStderr(`[mcp] Error: ${errorMsg}`);
244
+ return {
245
+ content: [{ type: 'text', text: `Error: ${errorMsg}` }],
246
+ isError: true,
247
+ };
248
+ }
249
+ }
250
+ resolveAllFiles(flagFile) {
251
+ const files = [];
252
+ if (flagFile) {
253
+ this.logStderr(`[mcp] From --file flag: "${flagFile}"`);
254
+ files.push(flagFile);
255
+ }
256
+ const positionalFiles = this.resolvePositionalFiles();
257
+ for (const f of positionalFiles) {
258
+ if (!files.includes(f)) {
259
+ files.push(f);
260
+ }
261
+ }
262
+ return files;
263
+ }
264
+ resolvePositionalFiles() {
265
+ const argv = process.argv;
266
+ const mcpIndex = argv.indexOf('mcp');
267
+ if (mcpIndex === -1)
268
+ return [];
269
+ const files = [];
270
+ for (let i = mcpIndex + 1; i < argv.length; i++) {
271
+ const arg = argv[i];
272
+ if (!arg.startsWith('--') && !arg.startsWith('-')) {
273
+ this.logStderr(`[mcp] Found positional file argument: "${arg}"`);
274
+ files.push(arg);
275
+ }
276
+ }
277
+ return files;
278
+ }
279
+ logStderr(message) {
280
+ process.stderr.write(`${message}\n`);
281
+ }
282
+ sanitizeToolName(name) {
283
+ return (name
284
+ .toLowerCase()
285
+ .replace(/[^a-z0-9_-]/g, '_')
286
+ .replace(/_+/g, '_')
287
+ .replace(/^_|_$/g, '') || 'n8n_workflow');
288
+ }
289
+ async catch(error) {
290
+ this.logStderr(`[mcp] Fatal error: ${error.message}`);
291
+ if (error.stack)
292
+ this.logStderr(`[mcp] ${error.stack}`);
293
+ }
294
+ async finally(error) {
295
+ if (error) {
296
+ await super.finally(error);
297
+ }
298
+ }
299
+ };
300
+ exports.Mcp = Mcp;
301
+ exports.Mcp = Mcp = __decorate([
302
+ (0, decorators_1.Command)({
303
+ name: 'mcp',
304
+ description: 'Starts an MCP (Model Context Protocol) server over stdio, exposing one or more .n8n ' +
305
+ 'workflow files as callable tools. The server reads JSON-RPC from stdin and writes to stdout. ' +
306
+ 'Designed to be used as an MCP server command in MCP client configurations.',
307
+ examples: [
308
+ 'workflow.n8n',
309
+ 'workflow1.n8n workflow2.n8n workflow3.n8n',
310
+ '--file=workflow.n8n',
311
+ '/path/to/*.n8n',
312
+ ],
313
+ flagsSchema,
314
+ })
315
+ ], Mcp);
@@ -0,0 +1,23 @@
1
+ import { z } from 'zod';
2
+ import { BaseCommand } from './base-command';
3
+ declare const flagsSchema: z.ZodObject<{
4
+ file: z.ZodString;
5
+ rawOutput: z.ZodOptional<z.ZodBoolean>;
6
+ input: z.ZodOptional<z.ZodString>;
7
+ }, "strip", z.ZodTypeAny, {
8
+ file: string;
9
+ input?: string | undefined;
10
+ rawOutput?: boolean | undefined;
11
+ }, {
12
+ file: string;
13
+ input?: string | undefined;
14
+ rawOutput?: boolean | undefined;
15
+ }>;
16
+ export declare class Run extends BaseCommand<z.infer<typeof flagsSchema>> {
17
+ needsCommunityPackages: boolean;
18
+ needsTaskRunner: boolean;
19
+ init(): Promise<void>;
20
+ run(): Promise<void>;
21
+ catch(error: Error): Promise<void>;
22
+ }
23
+ export {};
@@ -0,0 +1,162 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __importDefault = (this && this.__importDefault) || function (mod) {
9
+ return (mod && mod.__esModule) ? mod : { "default": mod };
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.Run = void 0;
13
+ const decorators_1 = require("@n8n/decorators");
14
+ const fs_1 = __importDefault(require("fs"));
15
+ const path_1 = __importDefault(require("path"));
16
+ const n8n_workflow_1 = require("n8n-workflow");
17
+ const zod_1 = require("zod");
18
+ const base_command_1 = require("./base-command");
19
+ const flagsSchema = zod_1.z.object({
20
+ file: zod_1.z.string().describe('Path to the .n8n workflow file to run'),
21
+ rawOutput: zod_1.z.boolean().describe('Outputs only JSON data, with no other text').optional(),
22
+ input: zod_1.z.string().describe('Input text for chat/webhook trigger workflows').optional(),
23
+ });
24
+ let Run = class Run extends base_command_1.BaseCommand {
25
+ constructor() {
26
+ super(...arguments);
27
+ this.needsCommunityPackages = false;
28
+ this.needsTaskRunner = false;
29
+ }
30
+ async init() {
31
+ await super.init();
32
+ }
33
+ async run() {
34
+ const { flags } = this;
35
+ if (!flags.file) {
36
+ throw new n8n_workflow_1.UserError('The --file flag is required. Please provide a path to the .n8n workflow file.');
37
+ }
38
+ const filePath = path_1.default.resolve(flags.file);
39
+ this.logger.info(`[run] ── READING FILE ──`);
40
+ this.logger.info(`[run] File path: ${filePath}`);
41
+ if (!fs_1.default.existsSync(filePath)) {
42
+ throw new n8n_workflow_1.UserError(`[run] The workflow file does not exist: ${filePath}`);
43
+ }
44
+ const fileStat = fs_1.default.statSync(filePath);
45
+ this.logger.info(`[run] File size: ${fileStat.size} bytes, Last modified: ${fileStat.mtime.toISOString()}`);
46
+ let fileData;
47
+ try {
48
+ const fileContent = fs_1.default.readFileSync(filePath, { encoding: 'utf8' });
49
+ fileData = (0, n8n_workflow_1.jsonParse)(fileContent);
50
+ this.logger.info(`[run] Successfully parsed workflow file.`);
51
+ this.logger.info(`[run] Name: "${fileData.name}"`);
52
+ this.logger.info(`[run] ID: "${fileData.id ?? 'none'}"`);
53
+ this.logger.info(`[run] Nodes (${fileData.nodes?.length ?? 0}):`);
54
+ if (fileData.nodes && Array.isArray(fileData.nodes)) {
55
+ for (const node of fileData.nodes) {
56
+ this.logger.info(`[run] - "${node.name}" (type: ${node.type}, version: ${node.typeVersion})`);
57
+ }
58
+ }
59
+ }
60
+ catch (error) {
61
+ throw new n8n_workflow_1.UserError(`[run] Failed to parse workflow file: ${error instanceof Error ? error.message : String(error)}`);
62
+ }
63
+ const serverPort = this.globalConfig.port;
64
+ const serverUrl = `http://localhost:${serverPort}`;
65
+ this.logger.info(`[run] ── EXECUTING ──`);
66
+ this.logger.info(`[run] n8n server URL: ${serverUrl}`);
67
+ try {
68
+ const healthResponse = await fetch(`${serverUrl}/rest/cli/health`);
69
+ if (!healthResponse.ok) {
70
+ throw new Error(`Health check returned ${healthResponse.status}`);
71
+ }
72
+ this.logger.info(`[run] Server is reachable.`);
73
+ }
74
+ catch (error) {
75
+ throw new n8n_workflow_1.UserError(`[run] Cannot reach n8n server at ${serverUrl}. Is the server running? Error: ${error instanceof Error ? error.message : String(error)}`);
76
+ }
77
+ const executeUrl = `${serverUrl}/rest/cli/run`;
78
+ this.logger.info(`[run] POST ${executeUrl}`);
79
+ const response = await fetch(executeUrl, {
80
+ method: 'POST',
81
+ headers: {
82
+ 'Content-Type': 'application/json',
83
+ },
84
+ body: JSON.stringify({
85
+ workflowData: fileData,
86
+ chatInput: flags.input,
87
+ }),
88
+ });
89
+ this.logger.info(`[run] Response status: ${response.status} ${response.statusText}`);
90
+ if (!response.ok) {
91
+ const errorBody = await response.text();
92
+ this.logger.error(`[run] API error response: ${errorBody}`);
93
+ throw new n8n_workflow_1.UserError(`[run] Failed to execute workflow: ${response.status} ${response.statusText} — ${errorBody}`);
94
+ }
95
+ const result = (await response.json());
96
+ this.logger.info(`[run] ── RESULTS ──`);
97
+ this.logger.info(`[run] Execution ID: ${result.executionId ?? 'unknown'}, Status: ${result.status ?? 'unknown'}, Time: ${result.executionTime ?? '?'}s`);
98
+ if (result.success) {
99
+ if (flags.rawOutput === undefined) {
100
+ this.logger.info('[run] ✅ Execution was successful!');
101
+ this.logger.info('====================================');
102
+ }
103
+ }
104
+ else {
105
+ this.logger.error(`[run] ❌ Execution FAILED`);
106
+ this.logger.error('====================================');
107
+ if (result.error) {
108
+ this.logger.error(`[run] Error: ${result.error}`);
109
+ }
110
+ }
111
+ if (result.data?.runData) {
112
+ const runData = result.data.runData;
113
+ const nodeNames = Object.keys(runData);
114
+ this.logger.info(`[run] Nodes executed (${nodeNames.length}): ${nodeNames.join(' → ')}`);
115
+ for (const [nodeName, nodeRuns] of Object.entries(runData)) {
116
+ for (const nodeRun of nodeRuns) {
117
+ const status = nodeRun.executionStatus ?? 'unknown';
118
+ const time = nodeRun.executionTime ?? 0;
119
+ this.logger.info(`[run] ✅ "${nodeName}" — status: ${status}, time: ${time}ms`);
120
+ if (nodeRun.data?.main) {
121
+ for (const outputBranch of nodeRun.data.main) {
122
+ if (outputBranch) {
123
+ this.logger.info(`[run] Output items: ${outputBranch.length}`);
124
+ for (const item of outputBranch) {
125
+ if (item.json) {
126
+ this.logger.info(`[run] → ${JSON.stringify(item.json)}`);
127
+ }
128
+ }
129
+ }
130
+ }
131
+ }
132
+ }
133
+ }
134
+ }
135
+ this.log(JSON.stringify(result, null, 2));
136
+ this.logger.info(`[run] Done.`);
137
+ }
138
+ async catch(error) {
139
+ this.logger.error('[run] Error executing workflow. See log messages for details.');
140
+ this.logger.error('[run] Execution error:');
141
+ this.logger.info('====================================');
142
+ this.logger.error(error.message);
143
+ if (error instanceof n8n_workflow_1.ExecutionBaseError)
144
+ this.logger.error(error.description);
145
+ if (error.stack)
146
+ this.logger.error(error.stack);
147
+ }
148
+ };
149
+ exports.Run = Run;
150
+ exports.Run = Run = __decorate([
151
+ (0, decorators_1.Command)({
152
+ name: 'run',
153
+ description: 'Syncs a .n8n workflow file to the server and executes it synchronously. ' +
154
+ 'Returns the full execution result including per-node outputs.',
155
+ examples: [
156
+ '--file=workflow.n8n',
157
+ '--file=/path/to/workflow.n8n --input="Hello"',
158
+ '--file=workflow.n8n --rawOutput',
159
+ ],
160
+ flagsSchema,
161
+ })
162
+ ], Run);
@@ -4,8 +4,8 @@ export declare class AnnotationTagsController {
4
4
  private readonly annotationTagService;
5
5
  constructor(annotationTagService: AnnotationTagService);
6
6
  getAll(req: AnnotationTagsRequest.GetAll): Promise<{
7
- id: string;
8
7
  name: string;
8
+ id: string;
9
9
  createdAt: Date;
10
10
  updatedAt: Date;
11
11
  }[]>;
@@ -0,0 +1,26 @@
1
+ import { Logger } from '@n8n/backend-common';
2
+ import { WorkflowRepository, SharedWorkflowRepository, ProjectRepository, ExecutionRepository } from '@n8n/db';
3
+ import type { Request, Response } from 'express';
4
+ import { ActiveExecutions } from '../active-executions';
5
+ import { OwnershipService } from '../services/ownership.service';
6
+ import { WorkflowRunner } from '../workflow-runner';
7
+ export declare class CliController {
8
+ private readonly logger;
9
+ private readonly workflowRepository;
10
+ private readonly sharedWorkflowRepository;
11
+ private readonly projectRepository;
12
+ private readonly executionRepository;
13
+ private readonly ownershipService;
14
+ private readonly activeExecutions;
15
+ private readonly workflowRunner;
16
+ private static readonly MAX_WAIT_MS;
17
+ constructor(logger: Logger, workflowRepository: WorkflowRepository, sharedWorkflowRepository: SharedWorkflowRepository, projectRepository: ProjectRepository, executionRepository: ExecutionRepository, ownershipService: OwnershipService, activeExecutions: ActiveExecutions, workflowRunner: WorkflowRunner);
18
+ private isWebhookBasedTrigger;
19
+ private isLocalRequest;
20
+ run(req: Request, res: Response): Promise<void>;
21
+ private syncWorkflow;
22
+ health(): Promise<{
23
+ status: string;
24
+ timestamp: string;
25
+ }>;
26
+ }