@n8n/engine 0.18.1 → 0.19.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 (48) hide show
  1. package/dist/auth/action-token.d.ts +2 -1
  2. package/dist/auth/action-token.js +3 -2
  3. package/dist/auth/action-token.js.map +1 -1
  4. package/dist/build.tsbuildinfo +1 -1
  5. package/dist/common/index.d.ts +1 -1
  6. package/dist/common/index.js +2 -1
  7. package/dist/common/index.js.map +1 -1
  8. package/dist/common/json.schema.d.ts +2 -1
  9. package/dist/common/json.schema.js +2 -1
  10. package/dist/common/json.schema.js.map +1 -1
  11. package/dist/database/entities/workflow-execution.entity.d.ts +3 -1
  12. package/dist/database/entities/workflow-execution.entity.js +10 -0
  13. package/dist/database/entities/workflow-execution.entity.js.map +1 -1
  14. package/dist/database/migrations/1778529600000-CreateWorkflowExecution.js +7 -0
  15. package/dist/database/migrations/1778529600000-CreateWorkflowExecution.js.map +1 -1
  16. package/dist/database/typeorm-execution-store.js +11 -1
  17. package/dist/database/typeorm-execution-store.js.map +1 -1
  18. package/dist/database/typeorm-execution-view-store.d.ts +3 -2
  19. package/dist/database/typeorm-execution-view-store.js +34 -24
  20. package/dist/database/typeorm-execution-view-store.js.map +1 -1
  21. package/dist/dependencies/external-dependencies.d.ts +2 -1
  22. package/dist/execution/execution-query.service.d.ts +2 -2
  23. package/dist/execution/execution-query.service.js +2 -2
  24. package/dist/execution/execution-query.service.js.map +1 -1
  25. package/dist/execution/execution-store.d.ts +7 -10
  26. package/dist/execution/execution-store.js.map +1 -1
  27. package/dist/execution/execution-view-store.d.ts +8 -4
  28. package/dist/execution/execution.types.d.ts +7 -1
  29. package/dist/execution/execution.types.js.map +1 -1
  30. package/dist/execution/index.d.ts +2 -2
  31. package/dist/execution/index.js.map +1 -1
  32. package/dist/execution/start-execution.service.d.ts +3 -1
  33. package/dist/execution/start-execution.service.js +2 -0
  34. package/dist/execution/start-execution.service.js.map +1 -1
  35. package/dist/execution/step-ready-handler.js +1 -0
  36. package/dist/execution/step-ready-handler.js.map +1 -1
  37. package/dist/index.d.ts +2 -2
  38. package/dist/index.js.map +1 -1
  39. package/dist/server/api.types.d.ts +3 -4
  40. package/dist/server/create-engine-server.js +2 -1
  41. package/dist/server/create-engine-server.js.map +1 -1
  42. package/dist/server/index.d.ts +1 -1
  43. package/dist/server/routes/workflow-executions.handlers.d.ts +0 -1
  44. package/dist/server/routes/workflow-executions.handlers.js +16 -15
  45. package/dist/server/routes/workflow-executions.handlers.js.map +1 -1
  46. package/dist/server/routes/workflow-executions.js +8 -1
  47. package/dist/server/routes/workflow-executions.js.map +1 -1
  48. package/package.json +11 -11
@@ -1,5 +1,6 @@
1
1
  import { type SharedSecretTokenSpec } from './shared-secret-token';
2
- export type ActionScope = 'lifecycle-events:write';
2
+ export declare const ACTION_SCOPES: readonly ['lifecycle-events:write', 'credentials:read'];
3
+ export type ActionScope = (typeof ACTION_SCOPES)[number];
3
4
  export declare const ACTION_TOKEN: SharedSecretTokenSpec;
4
5
  export declare class InvalidActionTokenError extends Error {
5
6
  }
@@ -1,10 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.InvalidActionTokenError = exports.ACTION_TOKEN = void 0;
3
+ exports.InvalidActionTokenError = exports.ACTION_TOKEN = exports.ACTION_SCOPES = void 0;
4
4
  exports.mintActionToken = mintActionToken;
5
5
  exports.verifyActionToken = verifyActionToken;
6
6
  const zod_1 = require("zod");
7
7
  const shared_secret_token_1 = require("./shared-secret-token");
8
+ exports.ACTION_SCOPES = ['lifecycle-events:write', 'credentials:read'];
8
9
  exports.ACTION_TOKEN = Object.freeze({
9
10
  issuer: 'n8n-engine-dp',
10
11
  audience: 'n8n-cp',
@@ -12,7 +13,7 @@ exports.ACTION_TOKEN = Object.freeze({
12
13
  clockToleranceSeconds: 30,
13
14
  });
14
15
  const actionClaimsSchema = zod_1.z.object({
15
- scope: zod_1.z.enum(['lifecycle-events:write']),
16
+ scope: zod_1.z.enum(exports.ACTION_SCOPES),
16
17
  iat: zod_1.z.number().int(),
17
18
  exp: zod_1.z.number().int(),
18
19
  });
@@ -1 +1 @@
1
- {"version":3,"file":"action-token.js","sourceRoot":"","sources":["../../src/auth/action-token.ts"],"names":[],"mappings":";;;;;AAAA,6BAAwB;AAExB,+DAI+B;AAclB,QAAA,YAAY,GAA0B,MAAM,CAAC,MAAM,CAAC;IAChE,MAAM,EAAE,eAAe;IACvB,QAAQ,EAAE,QAAQ;IAClB,UAAU,EAAE,EAAE;IACd,qBAAqB,EAAE,EAAE;CACzB,CAAC,CAAC;AAEH,MAAM,kBAAkB,GAAG,OAAC,CAAC,MAAM,CAAC;IACnC,KAAK,EAAE,OAAC,CAAC,IAAI,CAAC,CAAC,wBAAwB,CAAC,CAAC;IACzC,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE;IACrB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE;CACrB,CAAC,CAAC;AAGH,6BAAqC,SAAQ,KAAK;CAAG;;AAGrD,yBAAgC,MAAc,EAAE,KAAkB;IACjE,OAAO,IAAA,2CAAqB,EAAC,QAAA,YAAY,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;AAC/D,CAAC;AAMD,2BAAkC,MAAc,EAAE,KAAa,EAAE,aAA0B;IAC1F,MAAM,MAAM,GAAG,IAAA,6CAAuB,EAAC,QAAA,YAAY,EAAE,MAAM,EAAE,KAAK,EAAE,kBAAkB,CAAC,CAAC;IACxF,IAAI,CAAC,MAAM,IAAI,MAAM,CAAC,KAAK,KAAK,aAAa;QAAE,MAAM,IAAI,uBAAuB,EAAE,CAAC;AACpF,CAAC"}
1
+ {"version":3,"file":"action-token.js","sourceRoot":"","sources":["../../src/auth/action-token.ts"],"names":[],"mappings":";;;;;AAAA,6BAAwB;AAExB,+DAI+B;AAOlB,QAAA,aAAa,GAAG,CAAC,wBAAwB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