@attraccess/database-entities 1.10.0 → 1.11.0-beta.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 (111) hide show
  1. package/package.json +6 -1
  2. package/src/index.d.ts +1 -0
  3. package/src/lib/entities/attractap-credential-event.entity.d.ts +14 -0
  4. package/src/lib/entities/attractap-credential-event.entity.js +58 -0
  5. package/src/lib/entities/attractap-credential-event.entity.js.map +1 -0
  6. package/src/lib/entities/attractap-installation.entity.d.ts +12 -0
  7. package/src/lib/entities/attractap-installation.entity.js +45 -0
  8. package/src/lib/entities/attractap-installation.entity.js.map +1 -0
  9. package/src/lib/entities/attractap-secure-boot-key.entity.d.ts +21 -0
  10. package/src/lib/entities/attractap-secure-boot-key.entity.js +53 -0
  11. package/src/lib/entities/attractap-secure-boot-key.entity.js.map +1 -0
  12. package/src/lib/entities/attractap.entity.d.ts +11 -0
  13. package/src/lib/entities/attractap.entity.js +79 -0
  14. package/src/lib/entities/attractap.entity.js.map +1 -1
  15. package/src/lib/entities/attractapCrashReport.entity.js +2 -1
  16. package/src/lib/entities/attractapCrashReport.entity.js.map +1 -1
  17. package/src/lib/entities/billing-transaction-item.entity.d.ts +2 -0
  18. package/src/lib/entities/billing-transaction-item.entity.js +14 -0
  19. package/src/lib/entities/billing-transaction-item.entity.js.map +1 -1
  20. package/src/lib/entities/billing-transaction.entity.d.ts +2 -0
  21. package/src/lib/entities/billing-transaction.entity.js +13 -0
  22. package/src/lib/entities/billing-transaction.entity.js.map +1 -1
  23. package/src/lib/entities/csv-export-template.entity.d.ts +23 -0
  24. package/src/lib/entities/csv-export-template.entity.js +110 -0
  25. package/src/lib/entities/csv-export-template.entity.js.map +1 -0
  26. package/src/lib/entities/flow.entity.d.ts +19 -0
  27. package/src/lib/entities/flow.entity.js +62 -0
  28. package/src/lib/entities/flow.entity.js.map +1 -0
  29. package/src/lib/entities/nfcCardPendingChange.entity.d.ts +20 -0
  30. package/src/lib/entities/nfcCardPendingChange.entity.js +55 -0
  31. package/src/lib/entities/nfcCardPendingChange.entity.js.map +1 -0
  32. package/src/lib/entities/reader-ui-settings.entity.d.ts +32 -0
  33. package/src/lib/entities/reader-ui-settings.entity.js +101 -0
  34. package/src/lib/entities/reader-ui-settings.entity.js.map +1 -0
  35. package/src/lib/entities/resource-flow-node/companion-schemas.d.ts +15 -0
  36. package/src/lib/entities/resource-flow-node/companion-schemas.js +27 -0
  37. package/src/lib/entities/resource-flow-node/companion-schemas.js.map +1 -0
  38. package/src/lib/entities/resource-flow-node/external-effect-policy.d.ts +19 -0
  39. package/src/lib/entities/resource-flow-node/external-effect-policy.js +24 -0
  40. package/src/lib/entities/resource-flow-node/external-effect-policy.js.map +1 -0
  41. package/src/lib/entities/resource-flow-node/health-schemas.d.ts +18 -0
  42. package/src/lib/entities/resource-flow-node/health-schemas.js +34 -0
  43. package/src/lib/entities/resource-flow-node/health-schemas.js.map +1 -0
  44. package/src/lib/entities/resource-flow-node/http-schema.d.ts +25 -0
  45. package/src/lib/entities/resource-flow-node/http-schema.js +20 -0
  46. package/src/lib/entities/resource-flow-node/http-schema.js.map +1 -0
  47. package/src/lib/entities/resource-flow-node/metering-schemas.d.ts +27 -0
  48. package/src/lib/entities/resource-flow-node/metering-schemas.js +45 -0
  49. package/src/lib/entities/resource-flow-node/metering-schemas.js.map +1 -0
  50. package/src/lib/entities/resource-flow-node/mqtt-schemas.d.ts +33 -0
  51. package/src/lib/entities/resource-flow-node/mqtt-schemas.js +43 -0
  52. package/src/lib/entities/resource-flow-node/mqtt-schemas.js.map +1 -0
  53. package/src/lib/entities/resource-flow-node/node-type.d.ts +43 -0
  54. package/src/lib/entities/resource-flow-node/node-type.js +48 -0
  55. package/src/lib/entities/resource-flow-node/node-type.js.map +1 -0
  56. package/src/lib/entities/resource-flow-node/processing-schemas.d.ts +35 -0
  57. package/src/lib/entities/resource-flow-node/processing-schemas.js +32 -0
  58. package/src/lib/entities/resource-flow-node/processing-schemas.js.map +1 -0
  59. package/src/lib/entities/resource-flow-node/resource-schemas.d.ts +27 -0
  60. package/src/lib/entities/resource-flow-node/resource-schemas.js +44 -0
  61. package/src/lib/entities/resource-flow-node/resource-schemas.js.map +1 -0
  62. package/src/lib/entities/resource-flow-node/schema-registry.d.ts +179 -0
  63. package/src/lib/entities/resource-flow-node/schema-registry.js +80 -0
  64. package/src/lib/entities/resource-flow-node/schema-registry.js.map +1 -0
  65. package/src/lib/entities/resource-flow-node/variable-schemas.d.ts +38 -0
  66. package/src/lib/entities/resource-flow-node/variable-schemas.js +31 -0
  67. package/src/lib/entities/resource-flow-node/variable-schemas.js.map +1 -0
  68. package/src/lib/entities/resource-meter.entity.d.ts +12 -0
  69. package/src/lib/entities/resource-meter.entity.js +48 -0
  70. package/src/lib/entities/resource-meter.entity.js.map +1 -0
  71. package/src/lib/entities/resource-metering.entity.d.ts +69 -0
  72. package/src/lib/entities/resource-metering.entity.js +204 -0
  73. package/src/lib/entities/resource-metering.entity.js.map +1 -0
  74. package/src/lib/entities/resource-usage-lifecycle-attempt.entity.js +3 -1
  75. package/src/lib/entities/resource-usage-lifecycle-attempt.entity.js.map +1 -1
  76. package/src/lib/entities/resource.entity.d.ts +22 -21
  77. package/src/lib/entities/resource.entity.js +104 -93
  78. package/src/lib/entities/resource.entity.js.map +1 -1
  79. package/src/lib/entities/resourceFlowEdge.d.ts +5 -2
  80. package/src/lib/entities/resourceFlowEdge.js +28 -3
  81. package/src/lib/entities/resourceFlowEdge.js.map +1 -1
  82. package/src/lib/entities/resourceFlowNode.d.ts +18 -377
  83. package/src/lib/entities/resourceFlowNode.js +76 -310
  84. package/src/lib/entities/resourceFlowNode.js.map +1 -1
  85. package/src/lib/entities/resourceIntroduction.entity.js +1 -0
  86. package/src/lib/entities/resourceIntroduction.entity.js.map +1 -1
  87. package/src/lib/entities/resourceUsage.entity.d.ts +14 -9
  88. package/src/lib/entities/resourceUsage.entity.js +59 -50
  89. package/src/lib/entities/resourceUsage.entity.js.map +1 -1
  90. package/src/lib/entities/{nfcCard.entity.js → rfidCard.entity.js} +1 -1
  91. package/src/lib/entities/rfidCard.entity.js.map +1 -0
  92. package/src/lib/entities/session.entity.d.ts +6 -0
  93. package/src/lib/entities/session.entity.js +33 -1
  94. package/src/lib/entities/session.entity.js.map +1 -1
  95. package/src/lib/entities/ssoProvider.oidc.d.ts +7 -0
  96. package/src/lib/entities/ssoProvider.oidc.js +43 -1
  97. package/src/lib/entities/ssoProvider.oidc.js.map +1 -1
  98. package/src/lib/entities/ssoProvider.saml.d.ts +3 -0
  99. package/src/lib/entities/ssoProvider.saml.js +26 -0
  100. package/src/lib/entities/ssoProvider.saml.js.map +1 -1
  101. package/src/lib/entities/user.entity.d.ts +19 -18
  102. package/src/lib/entities/user.entity.js +75 -70
  103. package/src/lib/entities/user.entity.js.map +1 -1
  104. package/src/lib/entities-index.d.ts +138 -52
  105. package/src/lib/entities-index.js +321 -215
  106. package/src/lib/entities-index.js.map +1 -1
  107. package/src/lib/types/sso-session-context.d.ts +32 -0
  108. package/src/lib/types/sso-session-context.js +3 -0
  109. package/src/lib/types/sso-session-context.js.map +1 -0
  110. package/src/lib/entities/nfcCard.entity.js.map +0 -1
  111. /package/src/lib/entities/{nfcCard.entity.d.ts → rfidCard.entity.d.ts} +0 -0
@@ -0,0 +1,110 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CsvExportTemplate = exports.CsvExportTemplateColumn = exports.CsvExportTemplateColumnType = exports.CsvExportType = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const typeorm_1 = require("typeorm");
6
+ const swagger_1 = require("@nestjs/swagger");
7
+ var CsvExportType;
8
+ (function (CsvExportType) {
9
+ CsvExportType["RESOURCE_USAGE_HOURS"] = "resourceUsageHours";
10
+ CsvExportType["BILLING_TRANSACTIONS"] = "billingTransactions";
11
+ CsvExportType["RESOURCE_HOURS_SUMMARY"] = "resourceHoursSummary";
12
+ })(CsvExportType || (exports.CsvExportType = CsvExportType = {}));
13
+ var CsvExportTemplateColumnType;
14
+ (function (CsvExportTemplateColumnType) {
15
+ CsvExportTemplateColumnType["FIELD"] = "field";
16
+ CsvExportTemplateColumnType["CONSTANT"] = "constant";
17
+ })(CsvExportTemplateColumnType || (exports.CsvExportTemplateColumnType = CsvExportTemplateColumnType = {}));
18
+ class CsvExportTemplateColumn {
19
+ }
20
+ exports.CsvExportTemplateColumn = CsvExportTemplateColumn;
21
+ tslib_1.__decorate([
22
+ (0, swagger_1.ApiProperty)({
23
+ description: 'Whether this column outputs a data field or a constant value',
24
+ enum: CsvExportTemplateColumnType,
25
+ enumName: 'CsvExportTemplateColumnType',
26
+ example: CsvExportTemplateColumnType.FIELD,
27
+ }),
28
+ tslib_1.__metadata("design:type", String)
29
+ ], CsvExportTemplateColumn.prototype, "type", void 0);
30
+ tslib_1.__decorate([
31
+ (0, swagger_1.ApiProperty)({
32
+ description: "The header written to the first CSV row. Empty means: use the field's default label.",
33
+ example: 'Machine',
34
+ maxLength: 255,
35
+ }),
36
+ tslib_1.__metadata("design:type", String)
37
+ ], CsvExportTemplateColumn.prototype, "header", void 0);
38
+ tslib_1.__decorate([
39
+ (0, swagger_1.ApiProperty)({
40
+ description: 'The key of the data field to output (only for type "field"). Field keys are stable identifiers, they are persisted and must not be renamed.',
41
+ example: 'resourceName',
42
+ required: false,
43
+ nullable: true,
44
+ maxLength: 255,
45
+ }),
46
+ tslib_1.__metadata("design:type", String)
47
+ ], CsvExportTemplateColumn.prototype, "fieldKey", void 0);
48
+ tslib_1.__decorate([
49
+ (0, swagger_1.ApiProperty)({
50
+ description: 'The constant value written to every row (only for type "constant", may be an empty string)',
51
+ example: 'makerspace-bocholt',
52
+ required: false,
53
+ nullable: true,
54
+ maxLength: 1024,
55
+ }),
56
+ tslib_1.__metadata("design:type", String)
57
+ ], CsvExportTemplateColumn.prototype, "value", void 0);
58
+ let CsvExportTemplate = class CsvExportTemplate {
59
+ };
60
+ exports.CsvExportTemplate = CsvExportTemplate;
61
+ tslib_1.__decorate([
62
+ (0, typeorm_1.PrimaryGeneratedColumn)(),
63
+ (0, swagger_1.ApiProperty)({
64
+ description: 'The unique identifier of the CSV export template',
65
+ example: 1,
66
+ }),
67
+ tslib_1.__metadata("design:type", Number)
68
+ ], CsvExportTemplate.prototype, "id", void 0);
69
+ tslib_1.__decorate([
70
+ (0, typeorm_1.Column)({ type: 'text' }),
71
+ (0, swagger_1.ApiProperty)({
72
+ description: 'The display name of the template (unique per export type)',
73
+ example: 'Accounting upload',
74
+ maxLength: 120,
75
+ }),
76
+ tslib_1.__metadata("design:type", String)
77
+ ], CsvExportTemplate.prototype, "name", void 0);
78
+ tslib_1.__decorate([
79
+ (0, typeorm_1.Column)({ type: 'text' }),
80
+ (0, swagger_1.ApiProperty)({
81
+ description: 'The export type this template applies to',
82
+ enum: CsvExportType,
83
+ enumName: 'CsvExportType',
84
+ example: CsvExportType.RESOURCE_USAGE_HOURS,
85
+ }),
86
+ tslib_1.__metadata("design:type", String)
87
+ ], CsvExportTemplate.prototype, "exportType", void 0);
88
+ tslib_1.__decorate([
89
+ (0, typeorm_1.Column)({ type: 'json' }),
90
+ (0, swagger_1.ApiProperty)({
91
+ description: 'The ordered column configuration of the template',
92
+ type: [CsvExportTemplateColumn],
93
+ }),
94
+ tslib_1.__metadata("design:type", Array)
95
+ ], CsvExportTemplate.prototype, "columns", void 0);
96
+ tslib_1.__decorate([
97
+ (0, typeorm_1.CreateDateColumn)(),
98
+ (0, swagger_1.ApiProperty)({ description: 'When the template was created' }),
99
+ tslib_1.__metadata("design:type", Date)
100
+ ], CsvExportTemplate.prototype, "createdAt", void 0);
101
+ tslib_1.__decorate([
102
+ (0, typeorm_1.UpdateDateColumn)(),
103
+ (0, swagger_1.ApiProperty)({ description: 'When the template was last updated' }),
104
+ tslib_1.__metadata("design:type", Date)
105
+ ], CsvExportTemplate.prototype, "updatedAt", void 0);
106
+ exports.CsvExportTemplate = CsvExportTemplate = tslib_1.__decorate([
107
+ (0, typeorm_1.Entity)(),
108
+ (0, typeorm_1.Unique)('csv_export_template_name_per_type', ['exportType', 'name'])
109
+ ], CsvExportTemplate);
110
+ //# sourceMappingURL=csv-export-template.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"csv-export-template.entity.js","sourceRoot":"","sources":["../../../../../../libs/database-entities/src/lib/entities/csv-export-template.entity.ts"],"names":[],"mappings":";;;;AAAA,qCAA6G;AAC7G,6CAA8C;AAE9C,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,4DAA2C,CAAA;IAC3C,6DAA4C,CAAA;IAC5C,gEAA+C,CAAA;AACjD,CAAC,EAJW,aAAa,6BAAb,aAAa,QAIxB;AAED,IAAY,2BAGX;AAHD,WAAY,2BAA2B;IACrC,8CAAe,CAAA;IACf,oDAAqB,CAAA;AACvB,CAAC,EAHW,2BAA2B,2CAA3B,2BAA2B,QAGtC;AAED,MAAa,uBAAuB;CAkCnC;AAlCD,0DAkCC;AA3BC;IANC,IAAA,qBAAW,EAAC;QACX,WAAW,EAAE,8DAA8D;QAC3E,IAAI,EAAE,2BAA2B;QACjC,QAAQ,EAAE,6BAA6B;QACvC,OAAO,EAAE,2BAA2B,CAAC,KAAK;KAC3C,CAAC;;qDACiC;AAOnC;IALC,IAAA,qBAAW,EAAC;QACX,WAAW,EAAE,sFAAsF;QACnG,OAAO,EAAE,SAAS;QAClB,SAAS,EAAE,GAAG;KACf,CAAC;;uDACc;AAUhB;IARC,IAAA,qBAAW,EAAC;QACX,WAAW,EACT,6IAA6I;QAC/I,OAAO,EAAE,cAAc;QACvB,QAAQ,EAAE,KAAK;QACf,QAAQ,EAAE,IAAI;QACd,SAAS,EAAE,GAAG;KACf,CAAC;;yDACuB;AASzB;IAPC,IAAA,qBAAW,EAAC;QACX,WAAW,EAAE,4FAA4F;QACzG,OAAO,EAAE,oBAAoB;QAC7B,QAAQ,EAAE,KAAK;QACf,QAAQ,EAAE,IAAI;QACd,SAAS,EAAE,IAAI;KAChB,CAAC;;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
+ import { ResourceFlowEdge } from './resourceFlowEdge';
3
+ /** Which kind of flow an owner is: bound to one resource, or reacting to events of every resource. */
4
+ export type FlowScope = 'resource' | 'global';
5
+ /**
6
+ * A named flow that is not tied to one resource. Its nodes and edges point here through `flowId`
7
+ * (with `resourceId` NULL); resource flows keep using `resourceId` alone.
8
+ */
9
+ export declare class Flow {
10
+ id: number;
11
+ name: string;
12
+ description: string | null;
13
+ enabled: boolean;
14
+ scope: FlowScope;
15
+ createdAt: Date;
16
+ updatedAt: Date;
17
+ nodes: ResourceFlowNode[];
18
+ edges: ResourceFlowEdge[];
19
+ }
@@ -0,0 +1,62 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Flow = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const typeorm_1 = require("typeorm");
6
+ const swagger_1 = require("@nestjs/swagger");
7
+ const resourceFlowNode_1 = require("./resourceFlowNode");
8
+ const resourceFlowEdge_1 = require("./resourceFlowEdge");
9
+ /**
10
+ * A named flow that is not tied to one resource. Its nodes and edges point here through `flowId`
11
+ * (with `resourceId` NULL); resource flows keep using `resourceId` alone.
12
+ */
13
+ let Flow = class Flow {
14
+ };
15
+ exports.Flow = Flow;
16
+ tslib_1.__decorate([
17
+ (0, typeorm_1.PrimaryGeneratedColumn)(),
18
+ (0, swagger_1.ApiProperty)({ description: 'The unique identifier of the flow', example: 1 }),
19
+ tslib_1.__metadata("design:type", Number)
20
+ ], Flow.prototype, "id", void 0);
21
+ tslib_1.__decorate([
22
+ (0, typeorm_1.Column)({ type: 'varchar' }),
23
+ (0, swagger_1.ApiProperty)({ description: 'The name of the flow', example: 'Notify on starts' }),
24
+ tslib_1.__metadata("design:type", String)
25
+ ], Flow.prototype, "name", void 0);
26
+ tslib_1.__decorate([
27
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
28
+ (0, swagger_1.ApiProperty)({ description: 'Optional description of what the flow does', nullable: true, type: String }),
29
+ tslib_1.__metadata("design:type", String)
30
+ ], Flow.prototype, "description", void 0);
31
+ tslib_1.__decorate([
32
+ (0, typeorm_1.Column)({ type: 'boolean', default: true }),
33
+ (0, swagger_1.ApiProperty)({ description: 'Disabled flows never run', example: true }),
34
+ tslib_1.__metadata("design:type", Boolean)
35
+ ], Flow.prototype, "enabled", void 0);
36
+ tslib_1.__decorate([
37
+ (0, typeorm_1.Column)({ type: 'varchar', default: 'global' }),
38
+ (0, swagger_1.ApiProperty)({ description: 'The kind of flow', enum: ['resource', 'global'], example: 'global' }),
39
+ tslib_1.__metadata("design:type", String)
40
+ ], Flow.prototype, "scope", void 0);
41
+ tslib_1.__decorate([
42
+ (0, typeorm_1.CreateDateColumn)(),
43
+ (0, swagger_1.ApiProperty)({ type: String, format: 'date-time' }),
44
+ tslib_1.__metadata("design:type", Date)
45
+ ], Flow.prototype, "createdAt", void 0);
46
+ tslib_1.__decorate([
47
+ (0, typeorm_1.UpdateDateColumn)(),
48
+ (0, swagger_1.ApiProperty)({ type: String, format: 'date-time' }),
49
+ tslib_1.__metadata("design:type", Date)
50
+ ], Flow.prototype, "updatedAt", void 0);
51
+ tslib_1.__decorate([
52
+ (0, typeorm_1.OneToMany)(() => resourceFlowNode_1.ResourceFlowNode, (node) => node.flow),
53
+ tslib_1.__metadata("design:type", Array)
54
+ ], Flow.prototype, "nodes", void 0);
55
+ tslib_1.__decorate([
56
+ (0, typeorm_1.OneToMany)(() => resourceFlowEdge_1.ResourceFlowEdge, (edge) => edge.flow),
57
+ tslib_1.__metadata("design:type", Array)
58
+ ], Flow.prototype, "edges", void 0);
59
+ exports.Flow = Flow = tslib_1.__decorate([
60
+ (0, typeorm_1.Entity)()
61
+ ], Flow);
62
+ //# sourceMappingURL=flow.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"flow.entity.js","sourceRoot":"","sources":["../../../../../../libs/database-entities/src/lib/entities/flow.entity.ts"],"names":[],"mappings":";;;;AAAA,qCAAgH;AAChH,6CAA8C;AAC9C,yDAAsD;A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C,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC;sCACvC,IAAI;uCAAC;AAGjB;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,mCAAgB,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC;;mCAC5B;AAG3B;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,mCAAgB,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC;;mCAC5B;eAjChB,IAAI;IADhB,IAAA,gBAAM,GAAE;GACI,IAAI,CAkChB"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * A card key change the server started but has not seen confirmed yet. Written before the first
3
+ * command that changes a key reaches the card, so a tap after an interruption (card pulled, reader
4
+ * offline, API restart) can finish the work: authenticate with the recorded key (enroll) or with the
5
+ * factory key (reset). The key is stored encrypted like NFCCard.key.
6
+ */
7
+ export declare class NFCCardPendingChange {
8
+ id: number;
9
+ uid: string;
10
+ kind: 'enroll' | 'reset';
11
+ /** Enroll: the user the card is being enrolled for. */
12
+ userId: number | null;
13
+ /** Reset: the card record that is being wiped. */
14
+ cardId: number | null;
15
+ keyNo: number;
16
+ /** Enroll: the new key being written (encrypted). Reset: empty. */
17
+ key: string | null;
18
+ actorId: number | null;
19
+ createdAt: Date;
20
+ }
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.NFCCardPendingChange = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const typeorm_1 = require("typeorm");
6
+ /**
7
+ * A card key change the server started but has not seen confirmed yet. Written before the first
8
+ * command that changes a key reaches the card, so a tap after an interruption (card pulled, reader
9
+ * offline, API restart) can finish the work: authenticate with the recorded key (enroll) or with the
10
+ * factory key (reset). The key is stored encrypted like NFCCard.key.
11
+ */
12
+ let NFCCardPendingChange = class NFCCardPendingChange {
13
+ };
14
+ exports.NFCCardPendingChange = NFCCardPendingChange;
15
+ tslib_1.__decorate([
16
+ (0, typeorm_1.PrimaryGeneratedColumn)(),
17
+ tslib_1.__metadata("design:type", Number)
18
+ ], NFCCardPendingChange.prototype, "id", void 0);
19
+ tslib_1.__decorate([
20
+ (0, typeorm_1.Index)('IDX_nfc_card_pending_change_uid'),
21
+ (0, typeorm_1.Column)({ type: 'text', nullable: false }),
22
+ tslib_1.__metadata("design:type", String)
23
+ ], NFCCardPendingChange.prototype, "uid", void 0);
24
+ tslib_1.__decorate([
25
+ (0, typeorm_1.Column)({ type: 'varchar', length: 16, nullable: false }),
26
+ tslib_1.__metadata("design:type", String)
27
+ ], NFCCardPendingChange.prototype, "kind", void 0);
28
+ tslib_1.__decorate([
29
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
30
+ tslib_1.__metadata("design:type", Number)
31
+ ], NFCCardPendingChange.prototype, "userId", void 0);
32
+ tslib_1.__decorate([
33
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
34
+ tslib_1.__metadata("design:type", Number)
35
+ ], NFCCardPendingChange.prototype, "cardId", void 0);
36
+ tslib_1.__decorate([
37
+ (0, typeorm_1.Column)({ type: 'integer', nullable: false }),
38
+ tslib_1.__metadata("design:type", Number)
39
+ ], NFCCardPendingChange.prototype, "keyNo", void 0);
40
+ tslib_1.__decorate([
41
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
42
+ tslib_1.__metadata("design:type", String)
43
+ ], NFCCardPendingChange.prototype, "key", void 0);
44
+ tslib_1.__decorate([
45
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
46
+ tslib_1.__metadata("design:type", Number)
47
+ ], NFCCardPendingChange.prototype, "actorId", void 0);
48
+ tslib_1.__decorate([
49
+ (0, typeorm_1.CreateDateColumn)(),
50
+ tslib_1.__metadata("design:type", Date)
51
+ ], NFCCardPendingChange.prototype, "createdAt", void 0);
52
+ exports.NFCCardPendingChange = NFCCardPendingChange = tslib_1.__decorate([
53
+ (0, typeorm_1.Entity)()
54
+ ], NFCCardPendingChange);
55
+ //# sourceMappingURL=nfcCardPendingChange.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nfcCardPendingChange.entity.js","sourceRoot":"","sources":["../../../../../../libs/database-entities/src/lib/entities/nfcCardPendingChange.entity.ts"],"names":[],"mappings":";;;;AAAA,qCAA0F;AAE1F;;;;;GAKG;AAEI,IAAM,oBAAoB,GAA1B,MAAM,oBAAoB;CA+BhC,CAAA;AA/BY,oDAAoB;AAE/B;IADC,IAAA,gCAAsB,GAAE;;gDACb;AAIZ;IAFC,IAAA,eAAK,EAAC,iCAAiC,CAAC;IACxC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;iDAC7B;AAGb;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;kDAC/B;AAI1B;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oDACrB;AAIvB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oDACrB;AAGvB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;mDAC9B;AAIf;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACrB;AAGpB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;qDACpB;AAGxB;IADC,IAAA,0BAAgB,GAAE;sCACP,IAAI;uDAAC;+BA9BN,oBAAoB;IADhC,IAAA,gBAAM,GAAE;GACI,oBAAoB,CA+BhC"}
@@ -0,0 +1,32 @@
1
+ /** Per-resource reader UI settings (ATT-1187). `noScreenPolicy` null means "use the plugin default". */
2
+ export declare class ReaderUiResourceSettings {
3
+ resourceId: number;
4
+ noScreenPolicy: 'block' | 'card-confirm' | 'allow-with-warning' | null;
5
+ }
6
+ /** Per (resource, plugin) widget toggle and hook failure policy. */
7
+ export declare class ReaderUiPluginSettings {
8
+ resourceId: number;
9
+ plugin: string;
10
+ widgetsEnabled: boolean;
11
+ hookFailurePolicy: 'fail-closed' | 'fail-open';
12
+ }
13
+ /** Per-reader plugin widget toggle. */
14
+ export declare class ReaderUiReaderSettings {
15
+ readerId: number;
16
+ widgetsEnabled: boolean;
17
+ }
18
+ export type ReaderUiAlertKind = 'breaker-open' | 'load-failure' | 'crash-loop' | 'time-zone-conflict';
19
+ /**
20
+ * Host-owned admin alert: open circuit breaker, ACCESS_HOOKS load failure, reader crash-loop suspension or plugins
21
+ * disagreeing on a reader's time zone.
22
+ */
23
+ export declare class ReaderUiAlert {
24
+ id: number;
25
+ kind: ReaderUiAlertKind;
26
+ plugin: string | null;
27
+ readerId: number | null;
28
+ message: string;
29
+ createdAt: Date;
30
+ clearedAt: Date | null;
31
+ clearedByUserId: number | null;
32
+ }
@@ -0,0 +1,101 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ReaderUiAlert = exports.ReaderUiReaderSettings = exports.ReaderUiPluginSettings = exports.ReaderUiResourceSettings = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const typeorm_1 = require("typeorm");
6
+ /** Per-resource reader UI settings (ATT-1187). `noScreenPolicy` null means "use the plugin default". */
7
+ let ReaderUiResourceSettings = class ReaderUiResourceSettings {
8
+ };
9
+ exports.ReaderUiResourceSettings = ReaderUiResourceSettings;
10
+ tslib_1.__decorate([
11
+ (0, typeorm_1.PrimaryColumn)({ type: 'integer' }),
12
+ tslib_1.__metadata("design:type", Number)
13
+ ], ReaderUiResourceSettings.prototype, "resourceId", void 0);
14
+ tslib_1.__decorate([
15
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
16
+ tslib_1.__metadata("design:type", String)
17
+ ], ReaderUiResourceSettings.prototype, "noScreenPolicy", void 0);
18
+ exports.ReaderUiResourceSettings = ReaderUiResourceSettings = tslib_1.__decorate([
19
+ (0, typeorm_1.Entity)('reader_ui_resource_settings')
20
+ ], ReaderUiResourceSettings);
21
+ /** Per (resource, plugin) widget toggle and hook failure policy. */
22
+ let ReaderUiPluginSettings = class ReaderUiPluginSettings {
23
+ };
24
+ exports.ReaderUiPluginSettings = ReaderUiPluginSettings;
25
+ tslib_1.__decorate([
26
+ (0, typeorm_1.PrimaryColumn)({ type: 'integer' }),
27
+ tslib_1.__metadata("design:type", Number)
28
+ ], ReaderUiPluginSettings.prototype, "resourceId", void 0);
29
+ tslib_1.__decorate([
30
+ (0, typeorm_1.PrimaryColumn)({ type: 'text' }),
31
+ tslib_1.__metadata("design:type", String)
32
+ ], ReaderUiPluginSettings.prototype, "plugin", void 0);
33
+ tslib_1.__decorate([
34
+ (0, typeorm_1.Column)({ type: 'boolean', default: true }),
35
+ tslib_1.__metadata("design:type", Boolean)
36
+ ], ReaderUiPluginSettings.prototype, "widgetsEnabled", void 0);
37
+ tslib_1.__decorate([
38
+ (0, typeorm_1.Column)({ type: 'text', default: 'fail-closed' }),
39
+ tslib_1.__metadata("design:type", String)
40
+ ], ReaderUiPluginSettings.prototype, "hookFailurePolicy", void 0);
41
+ exports.ReaderUiPluginSettings = ReaderUiPluginSettings = tslib_1.__decorate([
42
+ (0, typeorm_1.Entity)('reader_ui_plugin_settings')
43
+ ], ReaderUiPluginSettings);
44
+ /** Per-reader plugin widget toggle. */
45
+ let ReaderUiReaderSettings = class ReaderUiReaderSettings {
46
+ };
47
+ exports.ReaderUiReaderSettings = ReaderUiReaderSettings;
48
+ tslib_1.__decorate([
49
+ (0, typeorm_1.PrimaryColumn)({ type: 'integer' }),
50
+ tslib_1.__metadata("design:type", Number)
51
+ ], ReaderUiReaderSettings.prototype, "readerId", void 0);
52
+ tslib_1.__decorate([
53
+ (0, typeorm_1.Column)({ type: 'boolean', default: true }),
54
+ tslib_1.__metadata("design:type", Boolean)
55
+ ], ReaderUiReaderSettings.prototype, "widgetsEnabled", void 0);
56
+ exports.ReaderUiReaderSettings = ReaderUiReaderSettings = tslib_1.__decorate([
57
+ (0, typeorm_1.Entity)('reader_ui_reader_settings')
58
+ ], ReaderUiReaderSettings);
59
+ /**
60
+ * Host-owned admin alert: open circuit breaker, ACCESS_HOOKS load failure, reader crash-loop suspension or plugins
61
+ * disagreeing on a reader's time zone.
62
+ */
63
+ let ReaderUiAlert = class ReaderUiAlert {
64
+ };
65
+ exports.ReaderUiAlert = ReaderUiAlert;
66
+ tslib_1.__decorate([
67
+ (0, typeorm_1.PrimaryGeneratedColumn)(),
68
+ tslib_1.__metadata("design:type", Number)
69
+ ], ReaderUiAlert.prototype, "id", void 0);
70
+ tslib_1.__decorate([
71
+ (0, typeorm_1.Column)({ type: 'text' }),
72
+ tslib_1.__metadata("design:type", String)
73
+ ], ReaderUiAlert.prototype, "kind", void 0);
74
+ tslib_1.__decorate([
75
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
76
+ tslib_1.__metadata("design:type", String)
77
+ ], ReaderUiAlert.prototype, "plugin", void 0);
78
+ tslib_1.__decorate([
79
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
80
+ tslib_1.__metadata("design:type", Number)
81
+ ], ReaderUiAlert.prototype, "readerId", void 0);
82
+ tslib_1.__decorate([
83
+ (0, typeorm_1.Column)({ type: 'text' }),
84
+ tslib_1.__metadata("design:type", String)
85
+ ], ReaderUiAlert.prototype, "message", void 0);
86
+ tslib_1.__decorate([
87
+ (0, typeorm_1.CreateDateColumn)({ type: 'datetime' }),
88
+ tslib_1.__metadata("design:type", Date)
89
+ ], ReaderUiAlert.prototype, "createdAt", void 0);
90
+ tslib_1.__decorate([
91
+ (0, typeorm_1.Column)({ type: 'datetime', nullable: true }),
92
+ tslib_1.__metadata("design:type", Date)
93
+ ], ReaderUiAlert.prototype, "clearedAt", void 0);
94
+ tslib_1.__decorate([
95
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
96
+ tslib_1.__metadata("design:type", Number)
97
+ ], ReaderUiAlert.prototype, "clearedByUserId", void 0);
98
+ exports.ReaderUiAlert = ReaderUiAlert = tslib_1.__decorate([
99
+ (0, typeorm_1.Entity)('reader_ui_alert')
100
+ ], ReaderUiAlert);
101
+ //# sourceMappingURL=reader-ui-settings.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reader-ui-settings.entity.js","sourceRoot":"","sources":["../../../../../../libs/database-entities/src/lib/entities/reader-ui-settings.entity.ts"],"names":[],"mappings":";;;;AAAA,qCAAkG;AAElG,wGAAwG;AAEjG,IAAM,wBAAwB,GAA9B,MAAM,wBAAwB;CAMpC,CAAA;AANY,4DAAwB;AAEnC;IADC,IAAA,uBAAa,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;;4DACf;AAGpB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gEAC+B;mCAL7D,wBAAwB;IADpC,IAAA,gBAAM,EAAC,6BAA6B,CAAC;GACzB,wBAAwB,CAMpC;AAED,oEAAoE;AAE7D,IAAM,sBAAsB,GAA5B,MAAM,sBAAsB;CAYlC,CAAA;AAZY,wDAAsB;AAEjC;IADC,IAAA,uBAAa,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;;0DACf;AAGpB;IADC,IAAA,uBAAa,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;sDAChB;AAGhB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;8DAClB;AAGzB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO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Aa;IADzB,IAAA,gBAAM,EAAC,iBAAiB,CAAC;GACb,aAAa,CAwBzB"}
@@ -0,0 +1,15 @@
1
+ import { z } from 'zod';
2
+ export declare const CompanionLockNodeDataSchema: z.ZodObject<{
3
+ deviceId: z.ZodNumber;
4
+ }, z.core.$strip>;
5
+ export declare const CompanionIdleActiveNodeDataSchema: z.ZodObject<{
6
+ deviceId: z.ZodNumber;
7
+ }, z.core.$strip>;
8
+ export declare const CompanionForegroundAppNodeDataSchema: z.ZodObject<{
9
+ deviceId: z.ZodNumber;
10
+ }, z.core.$strip>;
11
+ export declare const CompanionUsbDeviceNodeDataSchema: z.ZodObject<{
12
+ deviceId: z.ZodNumber;
13
+ vendorId: z.ZodOptional<z.ZodNumber>;
14
+ productId: z.ZodOptional<z.ZodNumber>;
15
+ }, z.core.$strip>;
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CompanionUsbDeviceNodeDataSchema = exports.CompanionForegroundAppNodeDataSchema = exports.CompanionIdleActiveNodeDataSchema = exports.CompanionLockNodeDataSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ const CompanionDeviceIdSchema = zod_1.z.number().int().positive().meta({
6
+ selectFromEntity: 'companionDevice',
7
+ entityProperty: 'id',
8
+ });
9
+ exports.CompanionLockNodeDataSchema = zod_1.z.object({
10
+ deviceId: CompanionDeviceIdSchema,
11
+ });
12
+ exports.CompanionIdleActiveNodeDataSchema = zod_1.z.object({
13
+ deviceId: CompanionDeviceIdSchema,
14
+ });
15
+ exports.CompanionForegroundAppNodeDataSchema = zod_1.z.object({
16
+ deviceId: CompanionDeviceIdSchema,
17
+ });
18
+ exports.CompanionUsbDeviceNodeDataSchema = zod_1.z.object({
19
+ deviceId: CompanionDeviceIdSchema,
20
+ vendorId: zod_1.z.number().int().optional().meta({
21
+ helpText: 'Optional USB vendor ID filter (decimal). Leave empty to match any vendor.',
22
+ }),
23
+ productId: zod_1.z.number().int().optional().meta({
24
+ helpText: 'Optional USB product ID filter (decimal). Leave empty to match any product.',
25
+ }),
26
+ });
27
+ //# sourceMappingURL=companion-schemas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"companion-schemas.js","sourceRoot":"","sources":["../../../../../../../libs/database-entities/src/lib/entities/resource-flow-node/companion-schemas.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAExB,MAAM,uBAAuB,GAAG,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,IAAI,CAAC;IAC/D,gBAAgB,EAAE,iBAAiB;IACnC,cAAc,EAAE,IAAI;CACrB,CAAC,CAAC;AAEU,QAAA,2BAA2B,GAAG,OAAC,CAAC,MAAM,CAAC;IAClD,QAAQ,EAAE,uBAAuB;CAClC,CAAC,CAAC;AAEU,QAAA,iCAAiC,GAAG,OAAC,CAAC,MAAM,CAAC;IACxD,QAAQ,EAAE,uBAAuB;CAClC,CAAC,CAAC;AAEU,QAAA,oCAAoC,GAAG,OAAC,CAAC,MAAM,CAAC;IAC3D,QAAQ,EAAE,uBAAuB;CAClC,CAAC,CAAC;AAEU,QAAA,gCAAgC,GAAG,OAAC,CAAC,MAAM,CAAC;IACvD,QAAQ,EAAE,uBAAuB;IACjC,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,IAAI,CAAC;QACzC,QAAQ,EAAE,2EAA2E;KACtF,CAAC;IACF,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,IAAI,CAAC;QAC1C,QAAQ,EAAE,6EAA6E;KACxF,CAAC;CACH,CAAC,CAAC"}
@@ -0,0 +1,19 @@
1
+ import { z } from 'zod';
2
+ export declare const ExternalEffectFailureBehaviorSchema: z.ZodDefault<z.ZodEnum<{
3
+ "fail-flow": "fail-flow";
4
+ "failure-output": "failure-output";
5
+ "log-and-continue": "log-and-continue";
6
+ }>>;
7
+ export declare const ExternalEffectPolicySchema: z.ZodObject<{
8
+ failureBehavior: z.ZodDefault<z.ZodEnum<{
9
+ "fail-flow": "fail-flow";
10
+ "failure-output": "failure-output";
11
+ "log-and-continue": "log-and-continue";
12
+ }>>;
13
+ }, z.core.$strip>;
14
+ export type ExternalEffectFailureBehavior = z.infer<typeof ExternalEffectFailureBehaviorSchema>;
15
+ export declare const AcknowledgementTimeoutSecondsSchema: z.ZodOptional<z.ZodNumber>;
16
+ export declare const CompletionBehaviorSchema: z.ZodDefault<z.ZodEnum<{
17
+ dispatch: "dispatch";
18
+ acknowledged: "acknowledged";
19
+ }>>;
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CompletionBehaviorSchema = exports.AcknowledgementTimeoutSecondsSchema = exports.ExternalEffectPolicySchema = exports.ExternalEffectFailureBehaviorSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.ExternalEffectFailureBehaviorSchema = zod_1.z
6
+ .enum(['fail-flow', 'failure-output', 'log-and-continue'])
7
+ .default('log-and-continue')
8
+ .meta({
9
+ helpText: 'fail-flow aborts the triggering operation, failure-output routes the error through the failure handle, and log-and-continue records the error and continues normally.',
10
+ });
11
+ exports.ExternalEffectPolicySchema = zod_1.z.object({
12
+ failureBehavior: exports.ExternalEffectFailureBehaviorSchema,
13
+ });
14
+ exports.AcknowledgementTimeoutSecondsSchema = zod_1.z
15
+ .number()
16
+ .int()
17
+ .positive()
18
+ .max(2147483, 'Timeout exceeds the supported timer limit')
19
+ .optional()
20
+ .meta({
21
+ helpText: 'Maximum time to wait for an acknowledgement, in seconds. Leave empty to use the integration default.',
22
+ });
23
+ exports.CompletionBehaviorSchema = zod_1.z.enum(['dispatch', 'acknowledged']).default('acknowledged');
24
+ //# sourceMappingURL=external-effect-policy.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"external-effect-policy.js","sourceRoot":"","sources":["../../../../../../../libs/database-entities/src/lib/entities/resource-flow-node/external-effect-policy.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,mCAAmC,GAAG,OAAC;KACjD,IAAI,CAAC,CAAC,WAAW,EAAE,gBAAgB,EAAE,kBAAkB,CAAC,CAAC;KACzD,OAAO,CAAC,kBAAkB,CAAC;KAC3B,IAAI,CAAC;IACJ,QAAQ,EACN,uKAAuK;CAC1K,CAAC,CAAC;AAEQ,QAAA,0BAA0B,GAAG,OAAC,CAAC,MAAM,CAAC;IACjD,eAAe,EAAE,2CAAmC;CACrD,CAAC,CAAC;AAIU,QAAA,mCAAmC,GAAG,OAAC;KACjD,MAAM,EAAE;KACR,GAAG,EAAE;KACL,QAAQ,EAAE;KACV,GAAG,CAAC,OAAS,EAAE,2CAA2C,CAAC;KAC3D,QAAQ,EAAE;KACV,IAAI,CAAC;IACJ,QAAQ,EAAE,sGAAsG;CACjH,CAAC,CAAC;AAEQ,QAAA,wBAAwB,GAAG,OAAC,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC"}
@@ -0,0 +1,18 @@
1
+ import { z } from 'zod';
2
+ export declare const HealthStateOptionEnum: z.ZodEnum<{
3
+ healthy: "healthy";
4
+ unhealthy: "unhealthy";
5
+ }>;
6
+ export declare const ResourceHealthHeartbeatNodeDataSchema: z.ZodObject<{
7
+ identifier: z.ZodDefault<z.ZodOptional<z.ZodString>>;
8
+ timeoutSeconds: z.ZodNumber;
9
+ unhealthyReason: z.ZodDefault<z.ZodOptional<z.ZodString>>;
10
+ }, z.core.$strip>;
11
+ export declare const ResourceHealthSetNodeDataSchema: z.ZodObject<{
12
+ identifier: z.ZodDefault<z.ZodOptional<z.ZodString>>;
13
+ status: z.ZodEnum<{
14
+ healthy: "healthy";
15
+ unhealthy: "unhealthy";
16
+ }>;
17
+ reason: z.ZodDefault<z.ZodOptional<z.ZodString>>;
18
+ }, z.core.$strip>;
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ResourceHealthSetNodeDataSchema = exports.ResourceHealthHeartbeatNodeDataSchema = exports.HealthStateOptionEnum = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.HealthStateOptionEnum = zod_1.z.enum(['healthy', 'unhealthy']);
6
+ exports.ResourceHealthHeartbeatNodeDataSchema = zod_1.z.object({
7
+ identifier: zod_1.z.string().optional().default('').meta({
8
+ helpText: 'Optional label identifying which subsystem reports this heartbeat (e.g. "ir-bridge"). Leave empty for the resource default.',
9
+ }),
10
+ timeoutSeconds: zod_1.z
11
+ .number()
12
+ .int()
13
+ .positive()
14
+ .describe('If no heartbeat is received within this many seconds, the resource is marked unhealthy'),
15
+ unhealthyReason: zod_1.z.string().optional().default('').meta({
16
+ helpText: 'Reason recorded when the heartbeat times out (e.g. "no heartbeat received")',
17
+ }),
18
+ });
19
+ exports.ResourceHealthSetNodeDataSchema = zod_1.z.object({
20
+ identifier: zod_1.z.string().optional().default('').meta({
21
+ overrideWithInput: 'health.identifier',
22
+ helpText: 'Optional label identifying which subsystem this state refers to (e.g. "ir-bridge"). Overridable via payload path "health.identifier".',
23
+ }),
24
+ status: exports.HealthStateOptionEnum.meta({
25
+ overrideWithInput: 'health.status',
26
+ helpText: 'Static status for this node. Overridable via payload path "health.status" (must be "healthy" or "unhealthy").',
27
+ }),
28
+ reason: zod_1.z.string().optional().default('').meta({
29
+ overrideWithInput: 'health.reason',
30
+ helpText: 'Optional reason shown to users when unhealthy. Templates allowed. Overridable via payload path "health.reason".',
31
+ stringVariant: 'multiline',
32
+ }),
33
+ });
34
+ //# sourceMappingURL=health-schemas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"health-schemas.js","sourceRoot":"","sources":["../../../../../../../libs/database-entities/src/lib/entities/resource-flow-node/health-schemas.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,qBAAqB,GAAG,OAAC,CAA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+ PUT: "PUT";
8
+ PATCH: "PATCH";
9
+ DELETE: "DELETE";
10
+ HEAD: "HEAD";
11
+ OPTIONS: "OPTIONS";
12
+ }>;
13
+ headers: z.ZodDefault<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>>;
14
+ body: z.ZodDefault<z.ZodOptional<z.ZodString>>;
15
+ timeoutSeconds: z.ZodOptional<z.ZodNumber>;
16
+ completionBehavior: z.ZodDefault<z.ZodEnum<{
17
+ dispatch: "dispatch";
18
+ acknowledged: "acknowledged";
19
+ }>>;
20
+ failureBehavior: z.ZodDefault<z.ZodEnum<{
21
+ "fail-flow": "fail-flow";
22
+ "failure-output": "failure-output";
23
+ "log-and-continue": "log-and-continue";
24
+ }>>;
25
+ }, z.core.$strip>;
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.HttpRequestNodeDataSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ const external_effect_policy_1 = require("./external-effect-policy");
6
+ exports.HttpRequestNodeDataSchema = zod_1.z
7
+ .object({
8
+ url: zod_1.z.string().url('Invalid URL format'),
9
+ method: zod_1.z.enum(['GET', 'POST', 'PUT', 'PATCH', 'DELETE', 'HEAD', 'OPTIONS']),
10
+ headers: zod_1.z.record(zod_1.z.string(), zod_1.z.string()).optional().default({}),
11
+ body: zod_1.z.string().optional().default('').meta({
12
+ stringVariant: 'multiline',
13
+ }),
14
+ timeoutSeconds: external_effect_policy_1.AcknowledgementTimeoutSecondsSchema,
15
+ completionBehavior: external_effect_policy_1.CompletionBehaviorSchema.meta({
16
+ helpText: 'Dispatch continues after the HTTP request is initiated. Acknowledged waits for the HTTP response.',
17
+ }),
18
+ })
19
+ .extend(external_effect_policy_1.ExternalEffectPolicySchema.shape);
20
+ //# sourceMappingURL=http-schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"http-schema.js","sourceRoot":"","sources":["../../../../../../../libs/database-entities/src/lib/entities/resource-flow-node/http-schema.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,qEAIkC;AAErB,QAAA,yBAAyB,GAAG,OAAC;KACvC,MAAM,CAAC;IACN,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,oBAAoB,CAAC;IACzC,MAAM,EAAE,OAAC,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,CAAC,CAAC;IAC5E,OAAO,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,MAAM,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;IAChE,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC;QAC3C,aAAa,EAAE,WAAW;KAC3B,CAAC;IACF,cAAc,EAAE,4DAAmC;IACnD,kBAAkB,EAAE,iDAAwB,CAAC,IAAI,CAAC;QAChD,QAAQ,EAAE,mGAAmG;KAC9G,CAAC;CACH,CAAC;KACD,MAAM,CAAC,mDAA0B,CAAC,KAAK,CAAC,CAAC"}