n8n 2.9.2 → 2.10.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 (209) hide show
  1. package/dist/abstract-server.js +2 -1
  2. package/dist/abstract-server.js.map +1 -1
  3. package/dist/active-workflow-manager.d.ts +1 -1
  4. package/dist/active-workflow-manager.js +3 -3
  5. package/dist/active-workflow-manager.js.map +1 -1
  6. package/dist/auth/auth.service.d.ts +1 -0
  7. package/dist/auth/auth.service.js +6 -0
  8. package/dist/auth/auth.service.js.map +1 -1
  9. package/dist/build.tsbuildinfo +1 -1
  10. package/dist/collaboration/collaboration.message.d.ts +7 -0
  11. package/dist/collaboration/collaboration.message.js +1 -0
  12. package/dist/collaboration/collaboration.message.js.map +1 -1
  13. package/dist/collaboration/collaboration.service.d.ts +6 -3
  14. package/dist/collaboration/collaboration.service.js +55 -34
  15. package/dist/collaboration/collaboration.service.js.map +1 -1
  16. package/dist/collaboration/collaboration.state.d.ts +10 -5
  17. package/dist/collaboration/collaboration.state.js +50 -19
  18. package/dist/collaboration/collaboration.state.js.map +1 -1
  19. package/dist/commands/base-command.js +2 -4
  20. package/dist/commands/base-command.js.map +1 -1
  21. package/dist/commands/export/credentials.d.ts +2 -2
  22. package/dist/commands/export/workflow.d.ts +2 -2
  23. package/dist/commands/start.js +4 -0
  24. package/dist/commands/start.js.map +1 -1
  25. package/dist/controllers/ai.controller.d.ts +5 -2
  26. package/dist/controllers/ai.controller.js +36 -6
  27. package/dist/controllers/ai.controller.js.map +1 -1
  28. package/dist/credentials/credentials.service.d.ts +0 -1
  29. package/dist/credentials/credentials.service.ee.d.ts +7 -1
  30. package/dist/credentials/credentials.service.ee.js +17 -2
  31. package/dist/credentials/credentials.service.ee.js.map +1 -1
  32. package/dist/credentials/credentials.service.js +50 -19
  33. package/dist/credentials/credentials.service.js.map +1 -1
  34. package/dist/credentials/validation.d.ts +1 -1
  35. package/dist/credentials/validation.js +4 -3
  36. package/dist/credentials/validation.js.map +1 -1
  37. package/dist/environments.ee/variables/variables.controller.ee.d.ts +2 -2
  38. package/dist/environments.ee/variables/variables.controller.ee.js +1 -1
  39. package/dist/environments.ee/variables/variables.controller.ee.js.map +1 -1
  40. package/dist/environments.ee/variables/variables.service.ee.js +8 -0
  41. package/dist/environments.ee/variables/variables.service.ee.js.map +1 -1
  42. package/dist/errors/response-errors/locked.error.d.ts +4 -0
  43. package/dist/errors/response-errors/locked.error.js +11 -0
  44. package/dist/errors/response-errors/locked.error.js.map +1 -0
  45. package/dist/evaluation.ee/test-runner/test-runner.service.ee.d.ts +9 -2
  46. package/dist/evaluation.ee/test-runner/test-runner.service.ee.js +50 -9
  47. package/dist/evaluation.ee/test-runner/test-runner.service.ee.js.map +1 -1
  48. package/dist/evaluation.ee/test-runs.controller.ee.d.ts +3 -3
  49. package/dist/evaluation.ee/test-runs.controller.ee.js +1 -8
  50. package/dist/evaluation.ee/test-runs.controller.ee.js.map +1 -1
  51. package/dist/events/maps/relay.event-map.d.ts +2 -1
  52. package/dist/events/relays/log-streaming.event-relay.js +4 -1
  53. package/dist/events/relays/log-streaming.event-relay.js.map +1 -1
  54. package/dist/events/relays/telemetry.event-relay.d.ts +3 -0
  55. package/dist/events/relays/telemetry.event-relay.js +27 -0
  56. package/dist/events/relays/telemetry.event-relay.js.map +1 -1
  57. package/dist/execution-lifecycle/execution-lifecycle-hooks.js +2 -2
  58. package/dist/execution-lifecycle/execution-lifecycle-hooks.js.map +1 -1
  59. package/dist/modules/community-packages/community-node-types-utils.d.ts +4 -3
  60. package/dist/modules/community-packages/community-node-types-utils.js +4 -2
  61. package/dist/modules/community-packages/community-node-types-utils.js.map +1 -1
  62. package/dist/modules/community-packages/community-node-types.service.js +3 -3
  63. package/dist/modules/community-packages/community-node-types.service.js.map +1 -1
  64. package/dist/modules/community-packages/community-packages.config.d.ts +1 -0
  65. package/dist/modules/community-packages/community-packages.config.js +2 -0
  66. package/dist/modules/community-packages/community-packages.config.js.map +1 -1
  67. package/dist/modules/community-packages/community-packages.service.js +1 -1
  68. package/dist/modules/community-packages/community-packages.service.js.map +1 -1
  69. package/dist/modules/community-packages/strapi-utils.d.ts +1 -0
  70. package/dist/modules/community-packages/strapi-utils.js.map +1 -1
  71. package/dist/modules/data-table/csv-parser.service.d.ts +1 -0
  72. package/dist/modules/data-table/csv-parser.service.js +19 -4
  73. package/dist/modules/data-table/csv-parser.service.js.map +1 -1
  74. package/dist/modules/data-table/data-table.controller.js +3 -0
  75. package/dist/modules/data-table/data-table.controller.js.map +1 -1
  76. package/dist/modules/data-table/data-table.service.js +23 -7
  77. package/dist/modules/data-table/data-table.service.js.map +1 -1
  78. package/dist/modules/external-secrets.ee/constants.d.ts +0 -1
  79. package/dist/modules/external-secrets.ee/constants.js +1 -2
  80. package/dist/modules/external-secrets.ee/constants.js.map +1 -1
  81. package/dist/modules/external-secrets.ee/external-secrets-manager.ee.d.ts +2 -1
  82. package/dist/modules/external-secrets.ee/external-secrets-manager.ee.js +8 -1
  83. package/dist/modules/external-secrets.ee/external-secrets-manager.ee.js.map +1 -1
  84. package/dist/modules/external-secrets.ee/external-secrets.config.d.ts +1 -0
  85. package/dist/modules/external-secrets.ee/external-secrets.config.js +5 -0
  86. package/dist/modules/external-secrets.ee/external-secrets.config.js.map +1 -1
  87. package/dist/modules/external-secrets.ee/provider-registry.service.d.ts +2 -1
  88. package/dist/modules/external-secrets.ee/provider-registry.service.js +10 -1
  89. package/dist/modules/external-secrets.ee/provider-registry.service.js.map +1 -1
  90. package/dist/modules/external-secrets.ee/providers/aws-secrets-manager.js +1 -1
  91. package/dist/modules/external-secrets.ee/providers/aws-secrets-manager.js.map +1 -1
  92. package/dist/modules/external-secrets.ee/providers/azure-key-vault/azure-key-vault.js +1 -3
  93. package/dist/modules/external-secrets.ee/providers/azure-key-vault/azure-key-vault.js.map +1 -1
  94. package/dist/modules/external-secrets.ee/providers/gcp-secrets-manager/gcp-secrets-manager.js +2 -2
  95. package/dist/modules/external-secrets.ee/providers/gcp-secrets-manager/gcp-secrets-manager.js.map +1 -1
  96. package/dist/modules/external-secrets.ee/providers/infisical.js +1 -2
  97. package/dist/modules/external-secrets.ee/providers/infisical.js.map +1 -1
  98. package/dist/modules/external-secrets.ee/providers/vault.js +0 -6
  99. package/dist/modules/external-secrets.ee/providers/vault.js.map +1 -1
  100. package/dist/modules/external-secrets.ee/secrets-providers-completions.controller.ee.d.ts +1 -1
  101. package/dist/modules/external-secrets.ee/secrets-providers-completions.controller.ee.js +18 -5
  102. package/dist/modules/external-secrets.ee/secrets-providers-completions.controller.ee.js.map +1 -1
  103. package/dist/modules/external-secrets.ee/secrets-providers-connections.controller.ee.d.ts +2 -2
  104. package/dist/modules/external-secrets.ee/secrets-providers-connections.controller.ee.js +20 -7
  105. package/dist/modules/external-secrets.ee/secrets-providers-connections.controller.ee.js.map +1 -1
  106. package/dist/modules/external-secrets.ee/secrets-providers-connections.service.ee.d.ts +3 -1
  107. package/dist/modules/external-secrets.ee/secrets-providers-connections.service.ee.js +18 -5
  108. package/dist/modules/external-secrets.ee/secrets-providers-connections.service.ee.js.map +1 -1
  109. package/dist/modules/external-secrets.ee/secrets-providers-project.controller.ee.d.ts +1 -1
  110. package/dist/modules/external-secrets.ee/secrets-providers-project.controller.ee.js +3 -3
  111. package/dist/modules/external-secrets.ee/secrets-providers-project.controller.ee.js.map +1 -1
  112. package/dist/modules/external-secrets.ee/secrets-providers-types.controller.ee.js +4 -3
  113. package/dist/modules/external-secrets.ee/secrets-providers-types.controller.ee.js.map +1 -1
  114. package/dist/modules/external-secrets.ee/secrets-providers.responses.ee.d.ts +2 -2
  115. package/dist/modules/quick-connect/handlers/firecrawl.handler.d.ts +7 -5
  116. package/dist/modules/quick-connect/handlers/firecrawl.handler.js +5 -5
  117. package/dist/modules/quick-connect/handlers/firecrawl.handler.js.map +1 -1
  118. package/dist/modules/quick-connect/handlers/handler.interface.d.ts +9 -0
  119. package/dist/modules/quick-connect/handlers/handler.interface.js +3 -0
  120. package/dist/modules/quick-connect/handlers/handler.interface.js.map +1 -0
  121. package/dist/modules/quick-connect/quick-connect.config.d.ts +185 -54
  122. package/dist/modules/quick-connect/quick-connect.config.js +20 -8
  123. package/dist/modules/quick-connect/quick-connect.config.js.map +1 -1
  124. package/dist/modules/quick-connect/quick-connect.controller.d.ts +3 -3
  125. package/dist/modules/quick-connect/quick-connect.controller.js +5 -5
  126. package/dist/modules/quick-connect/quick-connect.controller.js.map +1 -1
  127. package/dist/modules/quick-connect/quick-connect.module.d.ts +19 -3
  128. package/dist/modules/quick-connect/quick-connect.module.js +3 -4
  129. package/dist/modules/quick-connect/quick-connect.module.js.map +1 -1
  130. package/dist/modules/quick-connect/quick-connect.service.d.ts +6 -39
  131. package/dist/modules/quick-connect/quick-connect.service.js +58 -54
  132. package/dist/modules/quick-connect/quick-connect.service.js.map +1 -1
  133. package/dist/modules/workflow-builder/index.d.ts +3 -0
  134. package/dist/modules/workflow-builder/index.js +10 -0
  135. package/dist/modules/workflow-builder/index.js.map +1 -0
  136. package/dist/modules/workflow-builder/workflow-builder-session.entity.d.ts +21 -0
  137. package/dist/modules/workflow-builder/workflow-builder-session.entity.js +52 -0
  138. package/dist/modules/workflow-builder/workflow-builder-session.entity.js.map +1 -0
  139. package/dist/modules/workflow-builder/workflow-builder-session.repository.d.ts +10 -0
  140. package/dist/modules/workflow-builder/workflow-builder-session.repository.js +63 -0
  141. package/dist/modules/workflow-builder/workflow-builder-session.repository.js.map +1 -0
  142. package/dist/modules/workflow-builder/workflow-builder.module.d.ts +4 -0
  143. package/dist/modules/workflow-builder/workflow-builder.module.js +54 -0
  144. package/dist/modules/workflow-builder/workflow-builder.module.js.map +1 -0
  145. package/dist/public-api/types.d.ts +9 -0
  146. package/dist/public-api/v1/handlers/credentials/credentials.service.js +1 -1
  147. package/dist/public-api/v1/handlers/credentials/credentials.service.js.map +1 -1
  148. package/dist/public-api/v1/handlers/data-tables/data-tables.handler.js +22 -2
  149. package/dist/public-api/v1/handlers/data-tables/data-tables.handler.js.map +1 -1
  150. package/dist/public-api/v1/handlers/executions/executions.handler.d.ts +2 -0
  151. package/dist/public-api/v1/handlers/executions/executions.handler.js +56 -0
  152. package/dist/public-api/v1/handlers/executions/executions.handler.js.map +1 -1
  153. package/dist/public-api/v1/handlers/variables/variables.handler.js +1 -1
  154. package/dist/public-api/v1/handlers/variables/variables.handler.js.map +1 -1
  155. package/dist/public-api/v1/openapi.yml +81 -0
  156. package/dist/scaling/constants.d.ts +2 -2
  157. package/dist/scaling/constants.js +1 -0
  158. package/dist/scaling/constants.js.map +1 -1
  159. package/dist/scaling/job-processor.js +19 -9
  160. package/dist/scaling/job-processor.js.map +1 -1
  161. package/dist/scaling/pubsub/pubsub.event-map.d.ts +5 -1
  162. package/dist/scaling/pubsub/pubsub.types.d.ts +2 -1
  163. package/dist/scaling/worker-server.js +2 -1
  164. package/dist/scaling/worker-server.js.map +1 -1
  165. package/dist/server.js +4 -0
  166. package/dist/server.js.map +1 -1
  167. package/dist/services/ai-workflow-builder.service.d.ts +5 -2
  168. package/dist/services/ai-workflow-builder.service.js +13 -3
  169. package/dist/services/ai-workflow-builder.service.js.map +1 -1
  170. package/dist/services/frontend.service.js +2 -1
  171. package/dist/services/frontend.service.js.map +1 -1
  172. package/dist/services/ownership.service.d.ts +4 -2
  173. package/dist/services/ownership.service.js +9 -1
  174. package/dist/services/ownership.service.js.map +1 -1
  175. package/dist/services/user.service.d.ts +3 -1
  176. package/dist/services/user.service.js +6 -2
  177. package/dist/services/user.service.js.map +1 -1
  178. package/dist/task-runners/task-broker/task-broker-server.js +1 -2
  179. package/dist/task-runners/task-broker/task-broker-server.js.map +1 -1
  180. package/dist/utils/health-endpoint.util.d.ts +2 -0
  181. package/dist/utils/health-endpoint.util.js +11 -0
  182. package/dist/utils/health-endpoint.util.js.map +1 -0
  183. package/dist/utils.js +1 -0
  184. package/dist/utils.js.map +1 -1
  185. package/dist/webhooks/test-webhooks.d.ts +1 -0
  186. package/dist/webhooks/test-webhooks.js +9 -3
  187. package/dist/webhooks/test-webhooks.js.map +1 -1
  188. package/dist/webhooks/webhook-helpers.js +12 -11
  189. package/dist/webhooks/webhook-helpers.js.map +1 -1
  190. package/dist/webhooks/webhook-request-handler.js +4 -9
  191. package/dist/webhooks/webhook-request-handler.js.map +1 -1
  192. package/dist/webhooks/webhook-response-headers.d.ts +15 -0
  193. package/dist/webhooks/webhook-response-headers.js +54 -0
  194. package/dist/webhooks/webhook-response-headers.js.map +1 -0
  195. package/dist/webhooks/webhook-response.d.ts +1 -1
  196. package/dist/webhooks/webhook.types.d.ts +0 -7
  197. package/dist/workflows/workflow-execution.service.js +1 -0
  198. package/dist/workflows/workflow-execution.service.js.map +1 -1
  199. package/dist/workflows/workflow.request.d.ts +1 -0
  200. package/dist/workflows/workflow.service.d.ts +2 -5
  201. package/dist/workflows/workflow.service.js +14 -21
  202. package/dist/workflows/workflow.service.js.map +1 -1
  203. package/dist/workflows/workflows.controller.d.ts +3 -2
  204. package/dist/workflows/workflows.controller.js +14 -8
  205. package/dist/workflows/workflows.controller.js.map +1 -1
  206. package/package.json +25 -24
  207. package/dist/modules/quick-connect/handlers/quick-connect.handler.d.ts +0 -12
  208. package/dist/modules/quick-connect/handlers/quick-connect.handler.js +0 -26
  209. package/dist/modules/quick-connect/handlers/quick-connect.handler.js.map +0 -1
@@ -1,7 +1,7 @@
1
1
  import type { SecretProviderConnection } from '@n8n/api-types';
2
2
  export declare namespace SecretsProvidersResponses {
3
- type ConnectionListItem = Omit<SecretProviderConnection, 'settings' | 'state' | 'isEnabled' | 'secrets'>;
4
- type Connection = Omit<SecretProviderConnection, 'state' | 'isEnabled'>;
3
+ type ConnectionListItem = Omit<SecretProviderConnection, 'settings' | 'isEnabled' | 'secrets'>;
4
+ type Connection = Omit<SecretProviderConnection, 'isEnabled'>;
5
5
  type StrippedConnection = ConnectionListItem;
6
6
  type PublicConnection = Promise<Connection>;
7
7
  type PublicConnectionList = Promise<ConnectionListItem[]>;
@@ -1,8 +1,10 @@
1
1
  import type { User } from '@n8n/db';
2
- import type { ICredentialDataDecryptedObject } from 'n8n-workflow';
3
- import type { QuickConnectBackendOption } from '../quick-connect.config';
4
- import type { IQuickConnectHandler } from './quick-connect.handler';
2
+ import { FirecrawlQuickConnect } from '../quick-connect.config';
3
+ import { IQuickConnectHandler } from './handler.interface';
5
4
  export declare class FirecrawlHandler implements IQuickConnectHandler {
6
- readonly credentialType = "firecrawlApi";
7
- getCredentialData(config: QuickConnectBackendOption, user: User): Promise<ICredentialDataDecryptedObject>;
5
+ private config;
6
+ setConfig(config: FirecrawlQuickConnect): void;
7
+ getCredentialData({ email }: User): Promise<{
8
+ apiKey: string;
9
+ }>;
8
10
  }
@@ -14,12 +14,12 @@ const di_1 = require("@n8n/di");
14
14
  const axios_1 = __importDefault(require("axios"));
15
15
  const FIRECRAWL_API_BASE_URL = 'https://api.firecrawl.dev';
16
16
  let FirecrawlHandler = class FirecrawlHandler {
17
- constructor() {
18
- this.credentialType = 'firecrawlApi';
17
+ setConfig(config) {
18
+ this.config = config;
19
19
  }
20
- async getCredentialData(config, user) {
21
- const secret = config.backendFlowConfig.secret;
22
- const response = await axios_1.default.post(`${FIRECRAWL_API_BASE_URL}/admin/integration/create-user`, { email: user.email }, {
20
+ async getCredentialData({ email }) {
21
+ const secret = this.config.backendFlowConfig.secret;
22
+ const response = await axios_1.default.post(`${FIRECRAWL_API_BASE_URL}/admin/integration/create-user`, { email }, {
23
23
  headers: {
24
24
  Authorization: `Bearer ${secret}`,
25
25
  'Content-Type': 'application/json',
@@ -1 +1 @@
1
- {"version":3,"file":"firecrawl.handler.js","sourceRoot":"","sources":["../../../../src/modules/quick-connect/handlers/firecrawl.handler.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,gCAAkC;AAClC,kDAA0B;AAM1B,MAAM,sBAAsB,GAAG,2BAA2B,CAAC;AAOpD,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;IAAtB;QACG,mBAAc,GAAG,cAAc,CAAC;IAsB1C,CAAC;IApBA,KAAK,CAAC,iBAAiB,CACtB,MAAiC,EACjC,IAAU;QAEV,MAAM,MAAM,GAAG,MAAM,CAAC,iBAAiB,CAAC,MAAM,CAAC;QAC/C,MAAM,QAAQ,GAAG,MAAM,eAAK,CAAC,IAAI,CAChC,GAAG,sBAAsB,gCAAgC,EACzD,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE,EACrB;YACC,OAAO,EAAE;gBACR,aAAa,EAAE,UAAU,MAAM,EAAE;gBACjC,cAAc,EAAE,kBAAkB;aAClC;SACD,CACD,CAAC;QAEF,OAAO;YACN,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,MAAM;SAC5B,CAAC;IACH,CAAC;CACD,CAAA;AAvBY,4CAAgB;2BAAhB,gBAAgB;IAD5B,IAAA,YAAO,GAAE;GACG,gBAAgB,CAuB5B"}
1
+ {"version":3,"file":"firecrawl.handler.js","sourceRoot":"","sources":["../../../../src/modules/quick-connect/handlers/firecrawl.handler.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,gCAAkC;AAIlC,kDAA0B;AAE1B,MAAM,sBAAsB,GAAG,2BAA2B,CAAC;AAOpD,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;IAG5B,SAAS,CAAC,MAA6B;QACtC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACtB,CAAC;IAED,KAAK,CAAC,iBAAiB,CAAC,EAAE,KAAK,EAAQ;QACtC,MAAM,MAAM,GAAG,IAAI,CAAC,MAAO,CAAC,iBAAiB,CAAC,MAAM,CAAC;QACrD,MAAM,QAAQ,GAAG,MAAM,eAAK,CAAC,IAAI,CAChC,GAAG,sBAAsB,gCAAgC,EACzD,EAAE,KAAK,EAAE,EACT;YACC,OAAO,EAAE;gBACR,aAAa,EAAE,UAAU,MAAM,EAAE;gBACjC,cAAc,EAAE,kBAAkB;aAClC;SACD,CACD,CAAC;QAEF,OAAO;YACN,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,MAAM;SAC5B,CAAC;IACH,CAAC;CACD,CAAA;AAxBY,4CAAgB;2BAAhB,gBAAgB;IAD5B,IAAA,YAAO,GAAE;GACG,gBAAgB,CAwB5B"}
@@ -0,0 +1,9 @@
1
+ import type { User } from '@n8n/db';
2
+ import type { QuickConnectOption } from '../quick-connect.config';
3
+ export interface IQuickConnectHandler<ConfigOption = QuickConnectOption> {
4
+ setConfig(config: ConfigOption): void;
5
+ getCredentialData(user: User): Promise<{
6
+ apiKey: string;
7
+ }>;
8
+ }
9
+ export type IQuickConnectHandlerOption<Handler> = Handler extends IQuickConnectHandler<infer Option> ? Option : never;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=handler.interface.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handler.interface.js","sourceRoot":"","sources":["../../../../src/modules/quick-connect/handlers/handler.interface.ts"],"names":[],"mappings":""}
@@ -1,55 +1,49 @@
1
1
  import { z } from 'zod';
2
- declare const backendFlowConfigSchema: z.ZodObject<{
3
- secret: z.ZodString;
4
- }, "strip", z.ZodTypeAny, {
5
- secret: string;
6
- }, {
7
- secret: string;
8
- }>;
9
- export type BackendFlowConfig = z.infer<typeof backendFlowConfigSchema>;
10
- declare const quickConnectOptionSchema: z.ZodObject<{
2
+ declare const firecrawlQuickConnectSchema: z.ZodObject<{
11
3
  packageName: z.ZodString;
12
4
  credentialType: z.ZodString;
13
5
  text: z.ZodString;
14
- quickConnectType: z.ZodString;
15
- serviceName: z.ZodString;
16
- consentText: z.ZodOptional<z.ZodString>;
17
- backendFlowConfig: z.ZodOptional<z.ZodObject<{
6
+ config: z.ZodOptional<z.ZodNever>;
7
+ } & {
8
+ quickConnectType: z.ZodLiteral<"firecrawl">;
9
+ consentText: z.ZodString;
10
+ backendFlowConfig: z.ZodObject<{
18
11
  secret: z.ZodString;
19
12
  }, "strip", z.ZodTypeAny, {
20
13
  secret: string;
21
14
  }, {
22
15
  secret: string;
23
- }>>;
16
+ }>;
24
17
  }, "strip", z.ZodTypeAny, {
25
18
  packageName: string;
26
19
  text: string;
27
20
  credentialType: string;
28
- quickConnectType: string;
29
- serviceName: string;
30
- consentText?: string | undefined;
31
- backendFlowConfig?: {
21
+ quickConnectType: "firecrawl";
22
+ consentText: string;
23
+ backendFlowConfig: {
32
24
  secret: string;
33
- } | undefined;
25
+ };
26
+ config?: undefined;
34
27
  }, {
35
28
  packageName: string;
36
29
  text: string;
37
30
  credentialType: string;
38
- quickConnectType: string;
39
- serviceName: string;
40
- consentText?: string | undefined;
41
- backendFlowConfig?: {
31
+ quickConnectType: "firecrawl";
32
+ consentText: string;
33
+ backendFlowConfig: {
42
34
  secret: string;
43
- } | undefined;
35
+ };
36
+ config?: undefined;
44
37
  }>;
45
- export type QuickConnectOption = z.infer<typeof quickConnectOptionSchema>;
46
- declare const quickConnectBackendOptionSchema: z.ZodObject<{
38
+ export type FirecrawlQuickConnect = z.infer<typeof firecrawlQuickConnectSchema>;
39
+ declare const quickConnectOptionSchema: z.ZodUnion<[z.ZodObject<{
47
40
  packageName: z.ZodString;
48
- text: z.ZodString;
49
41
  credentialType: z.ZodString;
50
- quickConnectType: z.ZodString;
51
- serviceName: z.ZodString;
52
- consentText: z.ZodOptional<z.ZodString>;
42
+ text: z.ZodString;
43
+ config: z.ZodOptional<z.ZodNever>;
44
+ } & {
45
+ quickConnectType: z.ZodLiteral<"firecrawl">;
46
+ consentText: z.ZodString;
53
47
  backendFlowConfig: z.ZodObject<{
54
48
  secret: z.ZodString;
55
49
  }, "strip", z.ZodTypeAny, {
@@ -61,69 +55,206 @@ declare const quickConnectBackendOptionSchema: z.ZodObject<{
61
55
  packageName: string;
62
56
  text: string;
63
57
  credentialType: string;
64
- quickConnectType: string;
65
- serviceName: string;
58
+ quickConnectType: "firecrawl";
59
+ consentText: string;
66
60
  backendFlowConfig: {
67
61
  secret: string;
68
62
  };
69
- consentText?: string | undefined;
63
+ config?: undefined;
70
64
  }, {
71
65
  packageName: string;
72
66
  text: string;
73
67
  credentialType: string;
74
- quickConnectType: string;
75
- serviceName: string;
68
+ quickConnectType: "firecrawl";
69
+ consentText: string;
76
70
  backendFlowConfig: {
77
71
  secret: string;
78
72
  };
73
+ config?: undefined;
74
+ }>, z.ZodObject<{
75
+ packageName: z.ZodString;
76
+ credentialType: z.ZodString;
77
+ text: z.ZodString;
78
+ consentText: z.ZodOptional<z.ZodString>;
79
+ backendFlowConfig: z.ZodOptional<z.ZodNever>;
80
+ } & {
81
+ quickConnectType: z.ZodLiteral<"pinecone">;
82
+ config: z.ZodObject<{
83
+ integrationId: z.ZodString;
84
+ }, "strip", z.ZodTypeAny, {
85
+ integrationId: string;
86
+ }, {
87
+ integrationId: string;
88
+ }>;
89
+ }, "strip", z.ZodTypeAny, {
90
+ packageName: string;
91
+ config: {
92
+ integrationId: string;
93
+ };
94
+ text: string;
95
+ credentialType: string;
96
+ quickConnectType: "pinecone";
79
97
  consentText?: string | undefined;
80
- }>;
81
- export type QuickConnectBackendOption = z.infer<typeof quickConnectBackendOptionSchema>;
82
- declare const quickConnectOptionsSchema: z.ZodPipeline<z.ZodString, z.ZodEffects<z.ZodArray<z.ZodObject<{
98
+ backendFlowConfig?: undefined;
99
+ }, {
100
+ packageName: string;
101
+ config: {
102
+ integrationId: string;
103
+ };
104
+ text: string;
105
+ credentialType: string;
106
+ quickConnectType: "pinecone";
107
+ consentText?: string | undefined;
108
+ backendFlowConfig?: undefined;
109
+ }>, z.ZodObject<{
83
110
  packageName: z.ZodString;
84
111
  credentialType: z.ZodString;
85
112
  text: z.ZodString;
86
113
  quickConnectType: z.ZodString;
87
- serviceName: z.ZodString;
88
114
  consentText: z.ZodOptional<z.ZodString>;
89
- backendFlowConfig: z.ZodOptional<z.ZodObject<{
115
+ config: z.ZodOptional<z.ZodNever>;
116
+ backendFlowConfig: z.ZodOptional<z.ZodNever>;
117
+ }, "strip", z.ZodTypeAny, {
118
+ packageName: string;
119
+ text: string;
120
+ credentialType: string;
121
+ quickConnectType: string;
122
+ config?: undefined;
123
+ consentText?: string | undefined;
124
+ backendFlowConfig?: undefined;
125
+ }, {
126
+ packageName: string;
127
+ text: string;
128
+ credentialType: string;
129
+ quickConnectType: string;
130
+ config?: undefined;
131
+ consentText?: string | undefined;
132
+ backendFlowConfig?: undefined;
133
+ }>]>;
134
+ export type QuickConnectOption = z.infer<typeof quickConnectOptionSchema>;
135
+ declare const quickConnectOptionsSchema: z.ZodPipeline<z.ZodString, z.ZodEffects<z.ZodArray<z.ZodUnion<[z.ZodObject<{
136
+ packageName: z.ZodString;
137
+ credentialType: z.ZodString;
138
+ text: z.ZodString;
139
+ config: z.ZodOptional<z.ZodNever>;
140
+ } & {
141
+ quickConnectType: z.ZodLiteral<"firecrawl">;
142
+ consentText: z.ZodString;
143
+ backendFlowConfig: z.ZodObject<{
90
144
  secret: z.ZodString;
91
145
  }, "strip", z.ZodTypeAny, {
92
146
  secret: string;
93
147
  }, {
94
148
  secret: string;
95
- }>>;
149
+ }>;
150
+ }, "strip", z.ZodTypeAny, {
151
+ packageName: string;
152
+ text: string;
153
+ credentialType: string;
154
+ quickConnectType: "firecrawl";
155
+ consentText: string;
156
+ backendFlowConfig: {
157
+ secret: string;
158
+ };
159
+ config?: undefined;
160
+ }, {
161
+ packageName: string;
162
+ text: string;
163
+ credentialType: string;
164
+ quickConnectType: "firecrawl";
165
+ consentText: string;
166
+ backendFlowConfig: {
167
+ secret: string;
168
+ };
169
+ config?: undefined;
170
+ }>, z.ZodObject<{
171
+ packageName: z.ZodString;
172
+ credentialType: z.ZodString;
173
+ text: z.ZodString;
174
+ consentText: z.ZodOptional<z.ZodString>;
175
+ backendFlowConfig: z.ZodOptional<z.ZodNever>;
176
+ } & {
177
+ quickConnectType: z.ZodLiteral<"pinecone">;
178
+ config: z.ZodObject<{
179
+ integrationId: z.ZodString;
180
+ }, "strip", z.ZodTypeAny, {
181
+ integrationId: string;
182
+ }, {
183
+ integrationId: string;
184
+ }>;
185
+ }, "strip", z.ZodTypeAny, {
186
+ packageName: string;
187
+ config: {
188
+ integrationId: string;
189
+ };
190
+ text: string;
191
+ credentialType: string;
192
+ quickConnectType: "pinecone";
193
+ consentText?: string | undefined;
194
+ backendFlowConfig?: undefined;
195
+ }, {
196
+ packageName: string;
197
+ config: {
198
+ integrationId: string;
199
+ };
200
+ text: string;
201
+ credentialType: string;
202
+ quickConnectType: "pinecone";
203
+ consentText?: string | undefined;
204
+ backendFlowConfig?: undefined;
205
+ }>, z.ZodObject<{
206
+ packageName: z.ZodString;
207
+ credentialType: z.ZodString;
208
+ text: z.ZodString;
209
+ quickConnectType: z.ZodString;
210
+ consentText: z.ZodOptional<z.ZodString>;
211
+ config: z.ZodOptional<z.ZodNever>;
212
+ backendFlowConfig: z.ZodOptional<z.ZodNever>;
96
213
  }, "strip", z.ZodTypeAny, {
97
214
  packageName: string;
98
215
  text: string;
99
216
  credentialType: string;
100
217
  quickConnectType: string;
101
- serviceName: string;
218
+ config?: undefined;
102
219
  consentText?: string | undefined;
103
- backendFlowConfig?: {
104
- secret: string;
105
- } | undefined;
220
+ backendFlowConfig?: undefined;
106
221
  }, {
107
222
  packageName: string;
108
223
  text: string;
109
224
  credentialType: string;
110
225
  quickConnectType: string;
111
- serviceName: string;
226
+ config?: undefined;
112
227
  consentText?: string | undefined;
113
- backendFlowConfig?: {
114
- secret: string;
115
- } | undefined;
116
- }>, "many">, {
228
+ backendFlowConfig?: undefined;
229
+ }>]>, "many">, ({
117
230
  packageName: string;
118
231
  text: string;
119
232
  credentialType: string;
120
233
  quickConnectType: string;
121
- serviceName: string;
234
+ config?: undefined;
122
235
  consentText?: string | undefined;
123
- backendFlowConfig?: {
236
+ backendFlowConfig?: undefined;
237
+ } | {
238
+ packageName: string;
239
+ config: {
240
+ integrationId: string;
241
+ };
242
+ text: string;
243
+ credentialType: string;
244
+ quickConnectType: "pinecone";
245
+ consentText?: string | undefined;
246
+ backendFlowConfig?: undefined;
247
+ } | {
248
+ packageName: string;
249
+ text: string;
250
+ credentialType: string;
251
+ quickConnectType: "firecrawl";
252
+ consentText: string;
253
+ backendFlowConfig: {
124
254
  secret: string;
125
- } | undefined;
126
- }[], unknown>>;
255
+ };
256
+ config?: undefined;
257
+ })[], unknown>>;
127
258
  export type QuickConnectOptions = z.infer<typeof quickConnectOptionsSchema>;
128
259
  export declare class QuickConnectConfig {
129
260
  options: QuickConnectOptions;
@@ -12,21 +12,33 @@ Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.QuickConnectConfig = void 0;
13
13
  const config_1 = require("@n8n/config");
14
14
  const zod_1 = require("zod");
15
- const backendFlowConfigSchema = zod_1.z.object({
16
- secret: zod_1.z.string(),
17
- });
18
- const quickConnectOptionSchema = zod_1.z.object({
15
+ const baseQuickConnectOptionSchema = zod_1.z.object({
19
16
  packageName: zod_1.z.string(),
20
17
  credentialType: zod_1.z.string(),
21
18
  text: zod_1.z.string(),
22
19
  quickConnectType: zod_1.z.string(),
23
- serviceName: zod_1.z.string(),
24
20
  consentText: zod_1.z.string().optional(),
25
- backendFlowConfig: backendFlowConfigSchema.optional(),
21
+ config: zod_1.z.never().optional(),
22
+ backendFlowConfig: zod_1.z.never().optional(),
23
+ });
24
+ const pineconeQuickConnectOptionSchema = baseQuickConnectOptionSchema.extend({
25
+ quickConnectType: zod_1.z.literal('pinecone'),
26
+ config: zod_1.z.object({
27
+ integrationId: zod_1.z.string(),
28
+ }),
26
29
  });
27
- const quickConnectBackendOptionSchema = quickConnectOptionSchema.required({
28
- backendFlowConfig: true,
30
+ const firecrawlQuickConnectSchema = baseQuickConnectOptionSchema.extend({
31
+ quickConnectType: zod_1.z.literal('firecrawl'),
32
+ consentText: zod_1.z.string(),
33
+ backendFlowConfig: zod_1.z.object({
34
+ secret: zod_1.z.string(),
35
+ }),
29
36
  });
37
+ const quickConnectOptionSchema = zod_1.z.union([
38
+ firecrawlQuickConnectSchema,
39
+ pineconeQuickConnectOptionSchema,
40
+ baseQuickConnectOptionSchema,
41
+ ]);
30
42
  const quickConnectOptionsSchema = zod_1.z.string().pipe(zod_1.z.preprocess((input) => {
31
43
  try {
32
44
  return JSON.parse(input);
@@ -1 +1 @@
1
- {"version":3,"file":"quick-connect.config.js","sourceRoot":"","sources":["../../../src/modules/quick-connect/quick-connect.config.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,wCAA0C;AAC1C,6BAAwB;AAExB,MAAM,uBAAuB,GAAG,OAAC,CAAC,MAAM,CAAC;IACxC,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE;CAClB,CAAC,CAAC;AAIH,MAAM,wBAAwB,GAAG,OAAC,CAAC,MAAM,CAAC;IACzC,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE;IACvB,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE;IAChB,gBAAgB,EAAE,OAAC,CAAC,MAAM,EAAE;IAC5B,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE;IACvB,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAClC,iBAAiB,EAAE,uBAAuB,CAAC,QAAQ,EAAE;CACrD,CAAC,CAAC;AAIH,MAAM,+BAA+B,GAAG,wBAAwB,CAAC,QAAQ,CAAC;IACzE,iBAAiB,EAAE,IAAI;CACvB,CAAC,CAAC;AAIH,MAAM,yBAAyB,GAAG,OAAC,CAAC,MAAM,EAAE,CAAC,IAAI,CAChD,OAAC,CAAC,UAAU,CAAC,CAAC,KAAa,EAAE,EAAE;IAC9B,IAAI,CAAC;QACJ,OAAO,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IAC1B,CAAC;IAAC,MAAM,CAAC;QACR,OAAO,EAAE,CAAC;IACX,CAAC;AACF,CAAC,EAAE,OAAC,CAAC,KAAK,CAAC,wBAAwB,CAAC,CAAC,CACrC,CAAC;AAKK,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAAxB;QAGN,YAAO,GAAwB,EAAE,CAAC;IACnC,CAAC;CAAA,CAAA;AAJY,gDAAkB;AAG9B;IADC,IAAA,YAAG,EAAC,2BAA2B,EAAE,yBAAyB,CAAC;;mDAC1B;6BAHtB,kBAAkB;IAD9B,eAAM;GACM,kBAAkB,CAI9B"}
1
+ {"version":3,"file":"quick-connect.config.js","sourceRoot":"","sources":["../../../src/modules/quick-connect/quick-connect.config.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,wCAA0C;AAC1C,6BAAwB;AAExB,MAAM,4BAA4B,GAAG,OAAC,CAAC,MAAM,CAAC;IAC7C,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE;IACvB,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE;IAChB,gBAAgB,EAAE,OAAC,CAAC,MAAM,EAAE;IAC5B,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAClC,MAAM,EAAE,OAAC,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE;IAC5B,iBAAiB,EAAE,OAAC,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE;CACvC,CAAC,CAAC;AAEH,MAAM,gCAAgC,GAAG,4BAA4B,CAAC,MAAM,CAAC;IAC5E,gBAAgB,EAAE,OAAC,CAAC,OAAO,CAAC,UAAU,CAAC;IACvC,MAAM,EAAE,OAAC,CAAC,MAAM,CAAC;QAChB,aAAa,EAAE,OAAC,CAAC,MAAM,EAAE;KACzB,CAAC;CACF,CAAC,CAAC;AAEH,MAAM,2BAA2B,GAAG,4BAA4B,CAAC,MAAM,CAAC;IACvE,gBAAgB,EAAE,OAAC,CAAC,OAAO,CAAC,WAAW,CAAC;IACxC,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE;IACvB,iBAAiB,EAAE,OAAC,CAAC,MAAM,CAAC;QAC3B,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE;KAClB,CAAC;CACF,CAAC,CAAC;AAIH,MAAM,wBAAwB,GAAG,OAAC,CAAC,KAAK,CAAC;IACxC,2BAA2B;IAC3B,gCAAgC;IAChC,4BAA4B;CAC5B,CAAC,CAAC;AAIH,MAAM,yBAAyB,GAAG,OAAC,CAAC,MAAM,EAAE,CAAC,IAAI,CAChD,OAAC,CAAC,UAAU,CAAC,CAAC,KAAa,EAAE,EAAE;IAC9B,IAAI,CAAC;QACJ,OAAO,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IAC1B,CAAC;IAAC,MAAM,CAAC;QACR,OAAO,EAAE,CAAC;IACX,CAAC;AACF,CAAC,EAAE,OAAC,CAAC,KAAK,CAAC,wBAAwB,CAAC,CAAC,CACrC,CAAC;AAKK,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAAxB;QAGN,YAAO,GAAwB,EAAE,CAAC;IACnC,CAAC;CAAA,CAAA;AAJY,gDAAkB;AAG9B;IADC,IAAA,YAAG,EAAC,2BAA2B,EAAE,yBAAyB,CAAC;;mDAC1B;6BAHtB,kBAAkB;IAD9B,eAAM;GACM,kBAAkB,CAI9B"}
@@ -1,10 +1,10 @@
1
- import { CreateQuickConnectCredentialDto } from '@n8n/api-types';
1
+ import { GetQuickConnectApiKeyDto } from '@n8n/api-types';
2
2
  import type { AuthenticatedRequest } from '@n8n/db';
3
3
  import { QuickConnectService } from './quick-connect.service';
4
4
  export declare class QuickConnectController {
5
5
  private readonly quickConnectService;
6
6
  constructor(quickConnectService: QuickConnectService);
7
- createCredential(req: AuthenticatedRequest, _res: unknown, body: CreateQuickConnectCredentialDto): Promise<{
8
- id: string;
7
+ getCredentialData(req: AuthenticatedRequest, _res: unknown, body: GetQuickConnectApiKeyDto): Promise<{
8
+ apiKey: string;
9
9
  }>;
10
10
  }
@@ -20,18 +20,18 @@ let QuickConnectController = class QuickConnectController {
20
20
  constructor(quickConnectService) {
21
21
  this.quickConnectService = quickConnectService;
22
22
  }
23
- async createCredential(req, _res, body) {
24
- return await this.quickConnectService.createCredential(body.credentialType, req.user, body.projectId);
23
+ async getCredentialData(req, _res, body) {
24
+ return await this.quickConnectService.getCredentialData(body.quickConnectType, req.user);
25
25
  }
26
26
  };
27
27
  exports.QuickConnectController = QuickConnectController;
28
28
  __decorate([
29
- (0, decorators_1.Post)('/create'),
29
+ (0, decorators_1.Post)('/'),
30
30
  __param(2, decorators_1.Body),
31
31
  __metadata("design:type", Function),
32
- __metadata("design:paramtypes", [Object, Object, api_types_1.CreateQuickConnectCredentialDto]),
32
+ __metadata("design:paramtypes", [Object, Object, api_types_1.GetQuickConnectApiKeyDto]),
33
33
  __metadata("design:returntype", Promise)
34
- ], QuickConnectController.prototype, "createCredential", null);
34
+ ], QuickConnectController.prototype, "getCredentialData", null);
35
35
  exports.QuickConnectController = QuickConnectController = __decorate([
36
36
  (0, decorators_1.RestController)('/quick-connect'),
37
37
  __metadata("design:paramtypes", [quick_connect_service_1.QuickConnectService])
@@ -1 +1 @@
1
- {"version":3,"file":"quick-connect.controller.js","sourceRoot":"","sources":["../../../src/modules/quick-connect/quick-connect.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,8CAAiE;AAEjE,gDAA6D;AAE7D,mEAA8D;AAGvD,IAAM,sBAAsB,GAA5B,MAAM,sBAAsB;IAClC,YAA6B,mBAAwC;QAAxC,wBAAmB,GAAnB,mBAAmB,CAAqB;IAAG,CAAC;IAGnE,AAAN,KAAK,CAAC,gBAAgB,CACrB,GAAyB,EACzB,IAAa,EACP,IAAqC;QAE3C,OAAO,MAAM,IAAI,CAAC,mBAAmB,CAAC,gBAAgB,CACrD,IAAI,CAAC,cAAc,EACnB,GAAG,CAAC,IAAI,EACR,IAAI,CAAC,SAAS,CACd,CAAC;IACH,CAAC;CACD,CAAA;AAfY,wDAAsB;AAI5B;IADL,IAAA,iBAAI,EAAC,SAAS,CAAC;IAId,WAAA,iBAAI,CAAA;;qDAAO,2CAA+B;;8DAO3C;iCAdW,sBAAsB;IADlC,IAAA,2BAAc,EAAC,gBAAgB,CAAC;qCAEkB,2CAAmB;GADzD,sBAAsB,CAelC"}
1
+ {"version":3,"file":"quick-connect.controller.js","sourceRoot":"","sources":["../../../src/modules/quick-connect/quick-connect.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,8CAA0D;AAE1D,gDAA6D;AAE7D,mEAA8D;AAGvD,IAAM,sBAAsB,GAA5B,MAAM,sBAAsB;IAClC,YAA6B,mBAAwC;QAAxC,wBAAmB,GAAnB,mBAAmB,CAAqB;IAAG,CAAC;IAGnE,AAAN,KAAK,CAAC,iBAAiB,CACtB,GAAyB,EACzB,IAAa,EACP,IAA8B;QAEpC,OAAO,MAAM,IAAI,CAAC,mBAAmB,CAAC,iBAAiB,CAAC,IAAI,CAAC,gBAAgB,EAAE,GAAG,CAAC,IAAI,CAAC,CAAC;IAC1F,CAAC;CACD,CAAA;AAXY,wDAAsB;AAI5B;IADL,IAAA,iBAAI,EAAC,GAAG,CAAC;IAIR,WAAA,iBAAI,CAAA;;qDAAO,oCAAwB;;+DAGpC;iCAVW,sBAAsB;IADlC,IAAA,2BAAc,EAAC,gBAAgB,CAAC;qCAEkB,2CAAmB;GADzD,sBAAsB,CAWlC"}
@@ -2,14 +2,30 @@ import type { ModuleInterface } from '@n8n/decorators';
2
2
  export declare class QuickConnectModule implements ModuleInterface {
3
3
  init(): Promise<void>;
4
4
  settings(): Promise<{
5
- options: {
5
+ options: ({
6
6
  packageName: string;
7
7
  text: string;
8
8
  credentialType: string;
9
9
  quickConnectType: string;
10
- serviceName: string;
10
+ config?: undefined;
11
11
  consentText?: string | undefined;
12
- }[];
12
+ } | {
13
+ packageName: string;
14
+ config: {
15
+ integrationId: string;
16
+ };
17
+ text: string;
18
+ credentialType: string;
19
+ quickConnectType: "pinecone";
20
+ consentText?: string | undefined;
21
+ } | {
22
+ packageName: string;
23
+ text: string;
24
+ credentialType: string;
25
+ quickConnectType: "firecrawl";
26
+ consentText: string;
27
+ config?: undefined;
28
+ })[];
13
29
  }>;
14
30
  private registerHandlers;
15
31
  }
@@ -57,10 +57,9 @@ let QuickConnectModule = class QuickConnectModule {
57
57
  };
58
58
  }
59
59
  async registerHandlers() {
60
- const { QuickConnectHandlerRegistry } = await Promise.resolve().then(() => __importStar(require('./handlers/quick-connect.handler')));
61
- const { FirecrawlHandler } = await Promise.resolve().then(() => __importStar(require('./handlers/firecrawl.handler')));
62
- const registry = di_1.Container.get(QuickConnectHandlerRegistry);
63
- registry.register(di_1.Container.get(FirecrawlHandler));
60
+ const { QuickConnectService } = await Promise.resolve().then(() => __importStar(require('./quick-connect.service')));
61
+ const quickConnectService = di_1.Container.get(QuickConnectService);
62
+ await quickConnectService.registerHandlers();
64
63
  }
65
64
  };
66
65
  exports.QuickConnectModule = QuickConnectModule;
@@ -1 +1 @@
1
- {"version":3,"file":"quick-connect.module.js","sourceRoot":"","sources":["../../../src/modules/quick-connect/quick-connect.module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,gDAAgD;AAChD,gCAAoC;AAG7B,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAC9B,KAAK,CAAC,IAAI;QACT,MAAM,IAAI,CAAC,gBAAgB,EAAE,CAAC;QAC9B,wDAAa,4BAA4B,GAAC,CAAC;IAC5C,CAAC;IAQD,KAAK,CAAC,QAAQ;QACb,MAAM,EAAE,kBAAkB,EAAE,GAAG,wDAAa,wBAAwB,GAAC,CAAC;QACtE,MAAM,EAAE,OAAO,EAAE,GAAG,cAAS,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC;QAEtD,OAAO;YACN,OAAO,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC,EAAE,iBAAiB,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC;gBACzD,GAAG,IAAI;aACP,CAAC,CAAC;SACH,CAAC;IACH,CAAC;IAEO,KAAK,CAAC,gBAAgB;QAC7B,MAAM,EAAE,2BAA2B,EAAE,GAAG,wDAAa,kCAAkC,GAAC,CAAC;QACzF,MAAM,EAAE,gBAAgB,EAAE,GAAG,wDAAa,8BAA8B,GAAC,CAAC;QAC1E,MAAM,QAAQ,GAAG,cAAS,CAAC,GAAG,CAAC,2BAA2B,CAAC,CAAC;QAC5D,QAAQ,CAAC,QAAQ,CAAC,cAAS,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC,CAAC;IACpD,CAAC;CACD,CAAA;AA7BY,gDAAkB;6BAAlB,kBAAkB;IAD9B,IAAA,0BAAa,EAAC,EAAE,IAAI,EAAE,eAAe,EAAE,CAAC;GAC5B,kBAAkB,CA6B9B"}
1
+ {"version":3,"file":"quick-connect.module.js","sourceRoot":"","sources":["../../../src/modules/quick-connect/quick-connect.module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,gDAAgD;AAChD,gCAAoC;AAG7B,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAC9B,KAAK,CAAC,IAAI;QACT,MAAM,IAAI,CAAC,gBAAgB,EAAE,CAAC;QAC9B,wDAAa,4BAA4B,GAAC,CAAC;IAC5C,CAAC;IAQD,KAAK,CAAC,QAAQ;QACb,MAAM,EAAE,kBAAkB,EAAE,GAAG,wDAAa,wBAAwB,GAAC,CAAC;QACtE,MAAM,EAAE,OAAO,EAAE,GAAG,cAAS,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC;QAEtD,OAAO;YACN,OAAO,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC,EAAE,iBAAiB,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC;gBACzD,GAAG,IAAI;aACP,CAAC,CAAC;SACH,CAAC;IACH,CAAC;IAEO,KAAK,CAAC,gBAAgB;QAC7B,MAAM,EAAE,mBAAmB,EAAE,GAAG,wDAAa,yBAAyB,GAAC,CAAC;QACxE,MAAM,mBAAmB,GAAG,cAAS,CAAC,GAAG,CAAC,mBAAmB,CAAC,CAAC;QAC/D,MAAM,mBAAmB,CAAC,gBAAgB,EAAE,CAAC;IAC9C,CAAC;CACD,CAAA;AA5BY,gDAAkB;6BAAlB,kBAAkB;IAD9B,IAAA,0BAAa,EAAC,EAAE,IAAI,EAAE,eAAe,EAAE,CAAC;GAC5B,kBAAkB,CA4B9B"}
@@ -1,46 +1,13 @@
1
1
  import { Logger } from '@n8n/backend-common';
2
2
  import type { User } from '@n8n/db';
3
- import type { ICredentialDataDecryptedObject } from 'n8n-workflow';
4
- import { CredentialsFinderService } from '../../credentials/credentials-finder.service';
5
- import { CredentialsService } from '../../credentials/credentials.service';
6
- import { QuickConnectHandlerRegistry } from './handlers/quick-connect.handler';
7
3
  import { QuickConnectConfig } from './quick-connect.config';
8
4
  export declare class QuickConnectService {
9
- private readonly credentialsService;
10
- private readonly credentialsFinderService;
11
- private readonly config;
12
- private readonly handlerRegistry;
13
5
  private readonly logger;
14
- constructor(credentialsService: CredentialsService, credentialsFinderService: CredentialsFinderService, config: QuickConnectConfig, handlerRegistry: QuickConnectHandlerRegistry, logger: Logger);
15
- createCredential(credentialType: string, user: User, projectId?: string): Promise<{
16
- name: string;
17
- type: string;
18
- shared: import("@n8n/db").SharedCredentials[];
19
- isManaged: boolean;
20
- isGlobal: boolean;
21
- isResolvable: boolean;
22
- resolvableAllowFallback: boolean;
23
- resolverId: string | null;
24
- id: string;
25
- generateId(): void;
26
- createdAt: Date;
27
- updatedAt: Date;
28
- setUpdateDate(): void;
29
- data: ICredentialDataDecryptedObject;
30
- } | {
31
- name: string;
32
- type: string;
33
- shared: import("@n8n/db").SharedCredentials[];
34
- isManaged: boolean;
35
- isGlobal: boolean;
36
- isResolvable: boolean;
37
- resolvableAllowFallback: boolean;
38
- resolverId: string | null;
39
- id: string;
40
- generateId(): void;
41
- createdAt: Date;
42
- updatedAt: Date;
43
- setUpdateDate(): void;
6
+ private readonly quickConnectConfig;
7
+ private readonly handlers;
8
+ constructor(logger: Logger, quickConnectConfig: QuickConnectConfig);
9
+ getCredentialData(quickConnectType: string, user: User): Promise<{
10
+ apiKey: string;
44
11
  }>;
45
- private isValidBackendConfig;
12
+ registerHandlers(): Promise<void>;
46
13
  }