@thescaffold/ntx-apps-polylog 0.0.10

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 (246) hide show
  1. package/README.md +1 -0
  2. package/api/channel/channel.controller.d.ts +26 -0
  3. package/api/channel/channel.controller.js +49 -0
  4. package/api/channel/channel.controller.js.map +1 -0
  5. package/api/channel/channel.module.d.ts +2 -0
  6. package/api/channel/channel.module.js +30 -0
  7. package/api/channel/channel.module.js.map +1 -0
  8. package/api/channel/channel.service.d.ts +17 -0
  9. package/api/channel/channel.service.js +46 -0
  10. package/api/channel/channel.service.js.map +1 -0
  11. package/api/channel/dto/create-channel.dto.d.ts +14 -0
  12. package/api/channel/dto/create-channel.dto.js +79 -0
  13. package/api/channel/dto/create-channel.dto.js.map +1 -0
  14. package/api/channel/dto/update-channel.dto.d.ts +14 -0
  15. package/api/channel/dto/update-channel.dto.js +81 -0
  16. package/api/channel/dto/update-channel.dto.js.map +1 -0
  17. package/api/channel/entities/channel.entity.d.ts +20 -0
  18. package/api/channel/entities/channel.entity.js +126 -0
  19. package/api/channel/entities/channel.entity.js.map +1 -0
  20. package/api/channel/index.d.ts +6 -0
  21. package/api/channel/index.js +23 -0
  22. package/api/channel/index.js.map +1 -0
  23. package/api/event/dto/create-event.dto.d.ts +12 -0
  24. package/api/event/dto/create-event.dto.js +62 -0
  25. package/api/event/dto/create-event.dto.js.map +1 -0
  26. package/api/event/dto/update-event.dto.d.ts +12 -0
  27. package/api/event/dto/update-event.dto.js +68 -0
  28. package/api/event/dto/update-event.dto.js.map +1 -0
  29. package/api/event/entities/event.entity.d.ts +17 -0
  30. package/api/event/entities/event.entity.js +76 -0
  31. package/api/event/entities/event.entity.js.map +1 -0
  32. package/api/event/event.controller.d.ts +31 -0
  33. package/api/event/event.controller.js +77 -0
  34. package/api/event/event.controller.js.map +1 -0
  35. package/api/event/event.module.d.ts +4 -0
  36. package/api/event/event.module.js +33 -0
  37. package/api/event/event.module.js.map +1 -0
  38. package/api/event/event.service.d.ts +17 -0
  39. package/api/event/event.service.js +46 -0
  40. package/api/event/event.service.js.map +1 -0
  41. package/api/event/index.d.ts +6 -0
  42. package/api/event/index.js +23 -0
  43. package/api/event/index.js.map +1 -0
  44. package/api/event-log/dto/create-event-log.dto.d.ts +8 -0
  45. package/api/event-log/dto/create-event-log.dto.js +48 -0
  46. package/api/event-log/dto/create-event-log.dto.js.map +1 -0
  47. package/api/event-log/dto/update-event-log.dto.d.ts +8 -0
  48. package/api/event-log/dto/update-event-log.dto.js +49 -0
  49. package/api/event-log/dto/update-event-log.dto.js.map +1 -0
  50. package/api/event-log/entities/event-log.entity.d.ts +11 -0
  51. package/api/event-log/entities/event-log.entity.js +54 -0
  52. package/api/event-log/entities/event-log.entity.js.map +1 -0
  53. package/api/event-log/event-log.controller.d.ts +28 -0
  54. package/api/event-log/event-log.controller.js +66 -0
  55. package/api/event-log/event-log.controller.js.map +1 -0
  56. package/api/event-log/event-log.module.d.ts +4 -0
  57. package/api/event-log/event-log.module.js +33 -0
  58. package/api/event-log/event-log.module.js.map +1 -0
  59. package/api/event-log/event-log.service.d.ts +17 -0
  60. package/api/event-log/event-log.service.js +48 -0
  61. package/api/event-log/event-log.service.js.map +1 -0
  62. package/api/event-log/index.d.ts +6 -0
  63. package/api/event-log/index.js +23 -0
  64. package/api/event-log/index.js.map +1 -0
  65. package/api/sink/dto/create-sink.dto.d.ts +13 -0
  66. package/api/sink/dto/create-sink.dto.js +71 -0
  67. package/api/sink/dto/create-sink.dto.js.map +1 -0
  68. package/api/sink/dto/update-sink.dto.d.ts +12 -0
  69. package/api/sink/dto/update-sink.dto.js +68 -0
  70. package/api/sink/dto/update-sink.dto.js.map +1 -0
  71. package/api/sink/entities/sink.entity.d.ts +19 -0
  72. package/api/sink/entities/sink.entity.js +135 -0
  73. package/api/sink/entities/sink.entity.js.map +1 -0
  74. package/api/sink/index.d.ts +6 -0
  75. package/api/sink/index.js +23 -0
  76. package/api/sink/index.js.map +1 -0
  77. package/api/sink/sink.controller.d.ts +25 -0
  78. package/api/sink/sink.controller.js +47 -0
  79. package/api/sink/sink.controller.js.map +1 -0
  80. package/api/sink/sink.module.d.ts +2 -0
  81. package/api/sink/sink.module.js +27 -0
  82. package/api/sink/sink.module.js.map +1 -0
  83. package/api/sink/sink.service.d.ts +17 -0
  84. package/api/sink/sink.service.js +46 -0
  85. package/api/sink/sink.service.js.map +1 -0
  86. package/api/sink-type/dto/create-sink-type.dto.d.ts +14 -0
  87. package/api/sink-type/dto/create-sink-type.dto.js +79 -0
  88. package/api/sink-type/dto/create-sink-type.dto.js.map +1 -0
  89. package/api/sink-type/dto/update-sink-type.dto.d.ts +14 -0
  90. package/api/sink-type/dto/update-sink-type.dto.js +81 -0
  91. package/api/sink-type/dto/update-sink-type.dto.js.map +1 -0
  92. package/api/sink-type/entities/sink-type.entity.d.ts +16 -0
  93. package/api/sink-type/entities/sink-type.entity.js +80 -0
  94. package/api/sink-type/entities/sink-type.entity.js.map +1 -0
  95. package/api/sink-type/index.d.ts +6 -0
  96. package/api/sink-type/index.js +23 -0
  97. package/api/sink-type/index.js.map +1 -0
  98. package/api/sink-type/sink-type.controller.d.ts +21 -0
  99. package/api/sink-type/sink-type.controller.js +40 -0
  100. package/api/sink-type/sink-type.controller.js.map +1 -0
  101. package/api/sink-type/sink-type.module.d.ts +2 -0
  102. package/api/sink-type/sink-type.module.js +27 -0
  103. package/api/sink-type/sink-type.module.js.map +1 -0
  104. package/api/sink-type/sink-type.service.d.ts +13 -0
  105. package/api/sink-type/sink-type.service.js +46 -0
  106. package/api/sink-type/sink-type.service.js.map +1 -0
  107. package/api/source/dto/create-source.dto.d.ts +12 -0
  108. package/api/source/dto/create-source.dto.js +65 -0
  109. package/api/source/dto/create-source.dto.js.map +1 -0
  110. package/api/source/dto/update-source.dto.d.ts +12 -0
  111. package/api/source/dto/update-source.dto.js +68 -0
  112. package/api/source/dto/update-source.dto.js.map +1 -0
  113. package/api/source/entities/source.entity.d.ts +19 -0
  114. package/api/source/entities/source.entity.js +83 -0
  115. package/api/source/entities/source.entity.js.map +1 -0
  116. package/api/source/index.d.ts +6 -0
  117. package/api/source/index.js +23 -0
  118. package/api/source/index.js.map +1 -0
  119. package/api/source/source.controller.d.ts +24 -0
  120. package/api/source/source.controller.js +46 -0
  121. package/api/source/source.controller.js.map +1 -0
  122. package/api/source/source.module.d.ts +2 -0
  123. package/api/source/source.module.js +30 -0
  124. package/api/source/source.module.js.map +1 -0
  125. package/api/source/source.service.d.ts +17 -0
  126. package/api/source/source.service.js +46 -0
  127. package/api/source/source.service.js.map +1 -0
  128. package/api/source-type/dto/create-source-type.dto.d.ts +14 -0
  129. package/api/source-type/dto/create-source-type.dto.js +79 -0
  130. package/api/source-type/dto/create-source-type.dto.js.map +1 -0
  131. package/api/source-type/dto/update-source-type.dto.d.ts +14 -0
  132. package/api/source-type/dto/update-source-type.dto.js +81 -0
  133. package/api/source-type/dto/update-source-type.dto.js.map +1 -0
  134. package/api/source-type/entities/source-type.entity.d.ts +16 -0
  135. package/api/source-type/entities/source-type.entity.js +80 -0
  136. package/api/source-type/entities/source-type.entity.js.map +1 -0
  137. package/api/source-type/index.d.ts +6 -0
  138. package/api/source-type/index.js +23 -0
  139. package/api/source-type/index.js.map +1 -0
  140. package/api/source-type/source-type.controller.d.ts +21 -0
  141. package/api/source-type/source-type.controller.js +40 -0
  142. package/api/source-type/source-type.controller.js.map +1 -0
  143. package/api/source-type/source-type.module.d.ts +2 -0
  144. package/api/source-type/source-type.module.js +27 -0
  145. package/api/source-type/source-type.module.js.map +1 -0
  146. package/api/source-type/source-type.service.d.ts +13 -0
  147. package/api/source-type/source-type.service.js +46 -0
  148. package/api/source-type/source-type.service.js.map +1 -0
  149. package/app.config.d.ts +38 -0
  150. package/app.config.js +48 -0
  151. package/app.config.js.map +1 -0
  152. package/app.controller.d.ts +133 -0
  153. package/app.controller.js +265 -0
  154. package/app.controller.js.map +1 -0
  155. package/app.dto.d.ts +66 -0
  156. package/app.dto.js +288 -0
  157. package/app.dto.js.map +1 -0
  158. package/app.module.d.ts +2 -0
  159. package/app.module.js +74 -0
  160. package/app.module.js.map +1 -0
  161. package/app.service.d.ts +34 -0
  162. package/app.service.js +330 -0
  163. package/app.service.js.map +1 -0
  164. package/index.d.ts +31 -0
  165. package/index.js +80 -0
  166. package/index.js.map +1 -0
  167. package/migrations/1750186475187-Channels.d.ts +5 -0
  168. package/migrations/1750186475187-Channels.js +48 -0
  169. package/migrations/1750186475187-Channels.js.map +1 -0
  170. package/migrations/1750186475261-EventLogs.d.ts +5 -0
  171. package/migrations/1750186475261-EventLogs.js +33 -0
  172. package/migrations/1750186475261-EventLogs.js.map +1 -0
  173. package/migrations/1750186475329-Events.d.ts +5 -0
  174. package/migrations/1750186475329-Events.js +47 -0
  175. package/migrations/1750186475329-Events.js.map +1 -0
  176. package/migrations/1750186475466-Sinks.d.ts +5 -0
  177. package/migrations/1750186475466-Sinks.js +46 -0
  178. package/migrations/1750186475466-Sinks.js.map +1 -0
  179. package/migrations/1750186475532-SinkTypes.d.ts +5 -0
  180. package/migrations/1750186475532-SinkTypes.js +39 -0
  181. package/migrations/1750186475532-SinkTypes.js.map +1 -0
  182. package/migrations/1750186475601-Sources.d.ts +5 -0
  183. package/migrations/1750186475601-Sources.js +46 -0
  184. package/migrations/1750186475601-Sources.js.map +1 -0
  185. package/migrations/1750186475675-SourceTypes.d.ts +5 -0
  186. package/migrations/1750186475675-SourceTypes.js +39 -0
  187. package/migrations/1750186475675-SourceTypes.js.map +1 -0
  188. package/migrations/1750186762829-SourceTypeData.d.ts +5 -0
  189. package/migrations/1750186762829-SourceTypeData.js +85 -0
  190. package/migrations/1750186762829-SourceTypeData.js.map +1 -0
  191. package/migrations/1750186762911-SinkTypeData.d.ts +5 -0
  192. package/migrations/1750186762911-SinkTypeData.js +34 -0
  193. package/migrations/1750186762911-SinkTypeData.js.map +1 -0
  194. package/migrations/1750186762995-SinkData.d.ts +5 -0
  195. package/migrations/1750186762995-SinkData.js +34 -0
  196. package/migrations/1750186762995-SinkData.js.map +1 -0
  197. package/migrations/1750186763062-ChannelData.d.ts +5 -0
  198. package/migrations/1750186763062-ChannelData.js +43 -0
  199. package/migrations/1750186763062-ChannelData.js.map +1 -0
  200. package/migrations/1750186763130-SourceData.d.ts +5 -0
  201. package/migrations/1750186763130-SourceData.js +29 -0
  202. package/migrations/1750186763130-SourceData.js.map +1 -0
  203. package/migrations/index.d.ts +2 -0
  204. package/migrations/index.js +30 -0
  205. package/migrations/index.js.map +1 -0
  206. package/package.json +18 -0
  207. package/pkg/middleware/auth.middleware.d.ts +13 -0
  208. package/pkg/middleware/auth.middleware.js +70 -0
  209. package/pkg/middleware/auth.middleware.js.map +1 -0
  210. package/pkg/pipeline/index.d.ts +3 -0
  211. package/pkg/pipeline/index.js +20 -0
  212. package/pkg/pipeline/index.js.map +1 -0
  213. package/pkg/pipeline/pipeline.module.d.ts +2 -0
  214. package/pkg/pipeline/pipeline.module.js +33 -0
  215. package/pkg/pipeline/pipeline.module.js.map +1 -0
  216. package/pkg/pipeline/pipeline.service.d.ts +40 -0
  217. package/pkg/pipeline/pipeline.service.js +203 -0
  218. package/pkg/pipeline/pipeline.service.js.map +1 -0
  219. package/pkg/pipeline/xformer.service.d.ts +3 -0
  220. package/pkg/pipeline/xformer.service.js +19 -0
  221. package/pkg/pipeline/xformer.service.js.map +1 -0
  222. package/pkg/sinks/at.sms.sink.d.ts +4 -0
  223. package/pkg/sinks/at.sms.sink.js +18 -0
  224. package/pkg/sinks/at.sms.sink.js.map +1 -0
  225. package/pkg/sinks/form.sink.d.ts +7 -0
  226. package/pkg/sinks/form.sink.js +26 -0
  227. package/pkg/sinks/form.sink.js.map +1 -0
  228. package/pkg/sinks/index.d.ts +7 -0
  229. package/pkg/sinks/index.js +18 -0
  230. package/pkg/sinks/index.js.map +1 -0
  231. package/pkg/sinks/mailchimp.email.sink.d.ts +8 -0
  232. package/pkg/sinks/mailchimp.email.sink.js +40 -0
  233. package/pkg/sinks/mailchimp.email.sink.js.map +1 -0
  234. package/pkg/sinks/mailgun.email.sink.d.ts +8 -0
  235. package/pkg/sinks/mailgun.email.sink.js +40 -0
  236. package/pkg/sinks/mailgun.email.sink.js.map +1 -0
  237. package/pkg/sinks/sendgrid.email.sink.d.ts +8 -0
  238. package/pkg/sinks/sendgrid.email.sink.js +49 -0
  239. package/pkg/sinks/sendgrid.email.sink.js.map +1 -0
  240. package/pkg/sinks/sink.contract.d.ts +10 -0
  241. package/pkg/sinks/sink.contract.js +3 -0
  242. package/pkg/sinks/sink.contract.js.map +1 -0
  243. package/pkg/sinks/webhook.sink.d.ts +9 -0
  244. package/pkg/sinks/webhook.sink.js +67 -0
  245. package/pkg/sinks/webhook.sink.js.map +1 -0
  246. package/tsconfig.lib.tsbuildinfo +1 -0
package/app.dto.js ADDED
@@ -0,0 +1,288 @@
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 __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.UpsertRootSinkDto = exports.UpsertRootSourceDto = exports.UpdateConfigDto = exports.SetConfigDto = exports.SinkDto = exports.SinkTypeDto = exports.SourceDto = exports.SourceTypeDto = exports.VisibilityType = void 0;
13
+ const swagger_1 = require("@nestjs/swagger");
14
+ const ntx_core_1 = require("@thescaffold/ntx-core");
15
+ const class_transformer_1 = require("class-transformer");
16
+ const class_validator_1 = require("class-validator");
17
+ const app_config_1 = require("./app.config");
18
+ var VisibilityType;
19
+ (function (VisibilityType) {
20
+ VisibilityType["Public"] = "public";
21
+ VisibilityType["Private"] = "private";
22
+ })(VisibilityType || (exports.VisibilityType = VisibilityType = {}));
23
+ class SourceTypeDto {
24
+ }
25
+ exports.SourceTypeDto = SourceTypeDto;
26
+ __decorate([
27
+ (0, class_validator_1.IsString)(),
28
+ (0, swagger_1.ApiProperty)(),
29
+ __metadata("design:type", String)
30
+ ], SourceTypeDto.prototype, "key", void 0);
31
+ class SourceDto {
32
+ }
33
+ exports.SourceDto = SourceDto;
34
+ __decorate([
35
+ (0, class_validator_1.IsUUID)(),
36
+ (0, class_validator_1.IsOptional)(),
37
+ (0, swagger_1.ApiPropertyOptional)(),
38
+ __metadata("design:type", String)
39
+ ], SourceDto.prototype, "id", void 0);
40
+ __decorate([
41
+ (0, class_validator_1.IsEnum)(ntx_core_1.CategoryType),
42
+ (0, swagger_1.ApiProperty)(),
43
+ __metadata("design:type", String)
44
+ ], SourceDto.prototype, "category", void 0);
45
+ __decorate([
46
+ (0, class_validator_1.IsString)(),
47
+ (0, class_validator_1.IsOptional)(),
48
+ (0, swagger_1.ApiPropertyOptional)(),
49
+ __metadata("design:type", String)
50
+ ], SourceDto.prototype, "key", void 0);
51
+ __decorate([
52
+ (0, class_validator_1.IsString)(),
53
+ (0, class_validator_1.IsOptional)(),
54
+ (0, swagger_1.ApiPropertyOptional)(),
55
+ __metadata("design:type", String)
56
+ ], SourceDto.prototype, "visibility", void 0);
57
+ __decorate([
58
+ (0, class_validator_1.IsString)(),
59
+ (0, swagger_1.ApiProperty)(),
60
+ __metadata("design:type", String)
61
+ ], SourceDto.prototype, "name", void 0);
62
+ __decorate([
63
+ (0, class_validator_1.IsString)(),
64
+ (0, class_validator_1.IsOptional)(),
65
+ (0, swagger_1.ApiPropertyOptional)(),
66
+ __metadata("design:type", String)
67
+ ], SourceDto.prototype, "desc", void 0);
68
+ __decorate([
69
+ (0, class_validator_1.IsString)(),
70
+ (0, class_validator_1.IsOptional)(),
71
+ (0, swagger_1.ApiPropertyOptional)(),
72
+ __metadata("design:type", String)
73
+ ], SourceDto.prototype, "detail", void 0);
74
+ __decorate([
75
+ (0, class_validator_1.IsObject)(),
76
+ (0, class_validator_1.IsOptional)(),
77
+ (0, swagger_1.ApiPropertyOptional)(),
78
+ __metadata("design:type", Object)
79
+ ], SourceDto.prototype, "meta", void 0);
80
+ __decorate([
81
+ (0, class_validator_1.IsEnum)(app_config_1.SourceStatusType),
82
+ (0, swagger_1.ApiProperty)(),
83
+ __metadata("design:type", String)
84
+ ], SourceDto.prototype, "status", void 0);
85
+ class SinkTypeDto {
86
+ }
87
+ exports.SinkTypeDto = SinkTypeDto;
88
+ __decorate([
89
+ (0, class_validator_1.IsString)(),
90
+ (0, swagger_1.ApiProperty)(),
91
+ __metadata("design:type", String)
92
+ ], SinkTypeDto.prototype, "key", void 0);
93
+ class SinkDto {
94
+ }
95
+ exports.SinkDto = SinkDto;
96
+ __decorate([
97
+ (0, class_validator_1.IsUUID)(),
98
+ (0, class_validator_1.IsOptional)(),
99
+ (0, swagger_1.ApiPropertyOptional)(),
100
+ __metadata("design:type", String)
101
+ ], SinkDto.prototype, "id", void 0);
102
+ __decorate([
103
+ (0, class_validator_1.IsEnum)(ntx_core_1.CategoryType),
104
+ (0, swagger_1.ApiProperty)(),
105
+ __metadata("design:type", String)
106
+ ], SinkDto.prototype, "category", void 0);
107
+ __decorate([
108
+ (0, class_validator_1.IsString)(),
109
+ (0, class_validator_1.IsOptional)(),
110
+ (0, swagger_1.ApiPropertyOptional)(),
111
+ __metadata("design:type", String)
112
+ ], SinkDto.prototype, "key", void 0);
113
+ __decorate([
114
+ (0, class_validator_1.IsString)(),
115
+ (0, class_validator_1.IsOptional)(),
116
+ (0, swagger_1.ApiPropertyOptional)(),
117
+ __metadata("design:type", String)
118
+ ], SinkDto.prototype, "visibility", void 0);
119
+ __decorate([
120
+ (0, class_validator_1.IsString)(),
121
+ (0, swagger_1.ApiProperty)(),
122
+ __metadata("design:type", String)
123
+ ], SinkDto.prototype, "name", void 0);
124
+ __decorate([
125
+ (0, class_validator_1.IsString)(),
126
+ (0, class_validator_1.IsOptional)(),
127
+ (0, swagger_1.ApiPropertyOptional)(),
128
+ __metadata("design:type", String)
129
+ ], SinkDto.prototype, "desc", void 0);
130
+ __decorate([
131
+ (0, class_validator_1.IsString)(),
132
+ (0, class_validator_1.IsOptional)(),
133
+ (0, swagger_1.ApiPropertyOptional)(),
134
+ __metadata("design:type", String)
135
+ ], SinkDto.prototype, "detail", void 0);
136
+ __decorate([
137
+ (0, class_validator_1.IsObject)(),
138
+ (0, class_validator_1.IsOptional)(),
139
+ (0, swagger_1.ApiPropertyOptional)(),
140
+ __metadata("design:type", Object)
141
+ ], SinkDto.prototype, "meta", void 0);
142
+ class SetConfigDto {
143
+ }
144
+ exports.SetConfigDto = SetConfigDto;
145
+ __decorate([
146
+ (0, class_validator_1.IsUUID)(),
147
+ (0, swagger_1.ApiProperty)(),
148
+ __metadata("design:type", String)
149
+ ], SetConfigDto.prototype, "userId", void 0);
150
+ __decorate([
151
+ (0, class_validator_1.IsString)(),
152
+ (0, swagger_1.ApiProperty)(),
153
+ __metadata("design:type", String)
154
+ ], SetConfigDto.prototype, "clientId", void 0);
155
+ __decorate([
156
+ (0, class_validator_1.IsUUID)(),
157
+ (0, swagger_1.ApiProperty)(),
158
+ __metadata("design:type", String)
159
+ ], SetConfigDto.prototype, "workspaceId", void 0);
160
+ __decorate([
161
+ (0, class_validator_1.ValidateNested)(),
162
+ (0, class_transformer_1.Type)(() => SourceTypeDto),
163
+ __metadata("design:type", SourceTypeDto)
164
+ ], SetConfigDto.prototype, "sourceType", void 0);
165
+ __decorate([
166
+ (0, class_validator_1.ValidateNested)(),
167
+ (0, class_transformer_1.Type)(() => SourceDto),
168
+ __metadata("design:type", SourceDto)
169
+ ], SetConfigDto.prototype, "source", void 0);
170
+ __decorate([
171
+ (0, class_validator_1.ValidateNested)(),
172
+ (0, class_transformer_1.Type)(() => SinkTypeDto),
173
+ __metadata("design:type", SinkTypeDto)
174
+ ], SetConfigDto.prototype, "sinkType", void 0);
175
+ __decorate([
176
+ (0, class_validator_1.ValidateNested)(),
177
+ (0, class_transformer_1.Type)(() => SinkDto),
178
+ __metadata("design:type", SinkDto)
179
+ ], SetConfigDto.prototype, "sink", void 0);
180
+ __decorate([
181
+ (0, class_validator_1.IsString)(),
182
+ (0, class_validator_1.IsOptional)(),
183
+ (0, swagger_1.ApiPropertyOptional)(),
184
+ __metadata("design:type", String)
185
+ ], SetConfigDto.prototype, "type", void 0);
186
+ __decorate([
187
+ (0, class_validator_1.IsEnum)(ntx_core_1.CategoryType),
188
+ (0, swagger_1.ApiProperty)(),
189
+ __metadata("design:type", String)
190
+ ], SetConfigDto.prototype, "category", void 0);
191
+ __decorate([
192
+ (0, class_validator_1.IsString)(),
193
+ (0, class_validator_1.IsOptional)(),
194
+ (0, swagger_1.ApiPropertyOptional)(),
195
+ __metadata("design:type", String)
196
+ ], SetConfigDto.prototype, "key", void 0);
197
+ __decorate([
198
+ (0, class_validator_1.IsString)(),
199
+ (0, class_validator_1.IsOptional)(),
200
+ (0, swagger_1.ApiPropertyOptional)(),
201
+ __metadata("design:type", String)
202
+ ], SetConfigDto.prototype, "visibility", void 0);
203
+ class UpdateConfigDto {
204
+ }
205
+ exports.UpdateConfigDto = UpdateConfigDto;
206
+ __decorate([
207
+ (0, class_validator_1.IsEnum)(app_config_1.SourceStatusType),
208
+ (0, swagger_1.ApiProperty)(),
209
+ __metadata("design:type", String)
210
+ ], UpdateConfigDto.prototype, "status", void 0);
211
+ class UpsertRootSourceDto {
212
+ }
213
+ exports.UpsertRootSourceDto = UpsertRootSourceDto;
214
+ __decorate([
215
+ (0, class_validator_1.IsUUID)(),
216
+ (0, class_validator_1.IsOptional)(),
217
+ (0, swagger_1.ApiPropertyOptional)(),
218
+ __metadata("design:type", String)
219
+ ], UpsertRootSourceDto.prototype, "id", void 0);
220
+ __decorate([
221
+ (0, class_validator_1.IsEnum)(ntx_core_1.CategoryType),
222
+ (0, swagger_1.ApiProperty)(),
223
+ __metadata("design:type", String)
224
+ ], UpsertRootSourceDto.prototype, "category", void 0);
225
+ __decorate([
226
+ (0, class_validator_1.IsString)(),
227
+ (0, class_validator_1.IsOptional)(),
228
+ (0, swagger_1.ApiPropertyOptional)(),
229
+ __metadata("design:type", String)
230
+ ], UpsertRootSourceDto.prototype, "key", void 0);
231
+ __decorate([
232
+ (0, class_validator_1.IsString)(),
233
+ (0, class_validator_1.IsOptional)(),
234
+ (0, swagger_1.ApiPropertyOptional)(),
235
+ __metadata("design:type", String)
236
+ ], UpsertRootSourceDto.prototype, "visibility", void 0);
237
+ __decorate([
238
+ (0, class_validator_1.IsString)(),
239
+ (0, swagger_1.ApiProperty)(),
240
+ __metadata("design:type", String)
241
+ ], UpsertRootSourceDto.prototype, "typeKey", void 0);
242
+ __decorate([
243
+ (0, class_validator_1.IsString)(),
244
+ (0, swagger_1.ApiProperty)(),
245
+ __metadata("design:type", String)
246
+ ], UpsertRootSourceDto.prototype, "name", void 0);
247
+ __decorate([
248
+ (0, class_validator_1.IsString)(),
249
+ (0, class_validator_1.IsOptional)(),
250
+ (0, swagger_1.ApiPropertyOptional)(),
251
+ __metadata("design:type", String)
252
+ ], UpsertRootSourceDto.prototype, "desc", void 0);
253
+ __decorate([
254
+ (0, class_validator_1.IsObject)(),
255
+ (0, class_validator_1.IsOptional)(),
256
+ (0, swagger_1.ApiPropertyOptional)(),
257
+ __metadata("design:type", Object)
258
+ ], UpsertRootSourceDto.prototype, "meta", void 0);
259
+ __decorate([
260
+ (0, class_validator_1.IsString)(),
261
+ (0, class_validator_1.IsOptional)(),
262
+ (0, swagger_1.ApiPropertyOptional)(),
263
+ __metadata("design:type", String)
264
+ ], UpsertRootSourceDto.prototype, "status", void 0);
265
+ class UpsertRootSinkDto {
266
+ }
267
+ exports.UpsertRootSinkDto = UpsertRootSinkDto;
268
+ __decorate([
269
+ (0, class_validator_1.IsEnum)(ntx_core_1.CategoryType),
270
+ (0, swagger_1.ApiProperty)(),
271
+ __metadata("design:type", String)
272
+ ], UpsertRootSinkDto.prototype, "category", void 0);
273
+ __decorate([
274
+ (0, class_validator_1.IsString)(),
275
+ (0, swagger_1.ApiProperty)(),
276
+ __metadata("design:type", String)
277
+ ], UpsertRootSinkDto.prototype, "type", void 0);
278
+ __decorate([
279
+ (0, class_validator_1.ValidateNested)(),
280
+ (0, class_transformer_1.Type)(() => SinkTypeDto),
281
+ __metadata("design:type", SinkTypeDto)
282
+ ], UpsertRootSinkDto.prototype, "sinkType", void 0);
283
+ __decorate([
284
+ (0, class_validator_1.ValidateNested)(),
285
+ (0, class_transformer_1.Type)(() => SinkDto),
286
+ __metadata("design:type", SinkDto)
287
+ ], UpsertRootSinkDto.prototype, "sink", void 0);
288
+ //# sourceMappingURL=app.dto.js.map
package/app.dto.js.map ADDED
@@ -0,0 +1 @@
1
+ {"version":3,"file":"app.dto.js","sourceRoot":"","sources":["../../../libs/polylog/src/app.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAAmE;AACnE,oDAAqD;AACrD,yDAAyC;AACzC,qDAOyB;AACzB,6CAAgD;AAEhD,IAAY,cAGX;AAHD,WAAY,cAAc;IACxB,mCAAiB,CAAA;IACjB,qCAAmB,CAAA;AACrB,CAAC,EAHW,cAAc,8BAAd,cAAc,QAGzB;AAED,MAAa,aAAa;CAIzB;AAJD,sCAIC;AADC;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,qBAAW,GAAE;;0CACF;AAGd,MAAa,SAAS;CA0CrB;AA1CD,8BA0CC;AAtCC;IAHC,IAAA,wBAAM,GAAE;IACR,IAAA,4BAAU,GAAE;IACZ,IAAA,6BAAmB,GAAE;;qCACV;AAIZ;IAFC,IAAA,wBAAM,EAAC,uBAAY,CAAC;IACpB,IAAA,qBAAW,GAAE;;2CAC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,EAAC,GAAG,EAAE,CAAC,OAAO,CAAC;8BACd,OAAO;+CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare class AppModule {
2
+ }
package/app.module.js ADDED
@@ -0,0 +1,74 @@
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
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.AppModule = void 0;
10
+ const common_1 = require("@nestjs/common");
11
+ const core_1 = require("@nestjs/core");
12
+ const ntx_core_1 = require("@thescaffold/ntx-core");
13
+ const channel_1 = require("./api/channel");
14
+ const event_1 = require("./api/event");
15
+ const event_log_1 = require("./api/event-log");
16
+ const sink_1 = require("./api/sink");
17
+ const sink_type_1 = require("./api/sink-type");
18
+ const source_1 = require("./api/source");
19
+ const source_type_1 = require("./api/source-type");
20
+ const app_controller_1 = require("./app.controller");
21
+ const app_service_1 = require("./app.service");
22
+ const pipeline_1 = require("./pkg/pipeline");
23
+ let AppModule = class AppModule {
24
+ };
25
+ exports.AppModule = AppModule;
26
+ exports.AppModule = AppModule = __decorate([
27
+ (0, common_1.Module)({
28
+ imports: [
29
+ ntx_core_1.ServicesModule,
30
+ channel_1.ChannelModule,
31
+ sink_1.SinkModule,
32
+ source_1.SourceModule,
33
+ sink_type_1.SinkTypeModule,
34
+ source_type_1.SourceTypeModule,
35
+ event_1.EventModule.register(),
36
+ event_log_1.EventLogModule.register(),
37
+ pipeline_1.PipelineModule,
38
+ core_1.RouterModule.register([
39
+ {
40
+ path: 'apps/polylog',
41
+ module: channel_1.ChannelModule,
42
+ },
43
+ {
44
+ path: 'apps/polylog',
45
+ module: sink_1.SinkModule,
46
+ },
47
+ {
48
+ path: 'apps/polylog',
49
+ module: source_1.SourceModule,
50
+ },
51
+ {
52
+ path: 'apps/polylog',
53
+ module: sink_type_1.SinkTypeModule,
54
+ },
55
+ {
56
+ path: 'apps/polylog',
57
+ module: source_type_1.SourceTypeModule,
58
+ },
59
+ {
60
+ path: 'apps/polylog',
61
+ module: event_1.EventModule,
62
+ },
63
+ {
64
+ path: 'apps/polylog',
65
+ module: event_log_1.EventLogModule,
66
+ },
67
+ ]),
68
+ ],
69
+ controllers: [app_controller_1.AppController],
70
+ providers: [app_service_1.AppService],
71
+ exports: [app_service_1.AppService, pipeline_1.PipelineModule],
72
+ })
73
+ ], AppModule);
74
+ //# sourceMappingURL=app.module.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"app.module.js","sourceRoot":"","sources":["../../../libs/polylog/src/app.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAwC;AACxC,uCAA4C;AAC5C,oDAAuD;AACvD,2CAA8C;AAC9C,uCAA0C;AAC1C,+CAAiD;AACjD,qCAAwC;AACxC,+CAAiD;AACjD,yCAA4C;AAC5C,mDAAqD;AACrD,qDAAiD;AACjD,+CAA2C;AAC3C,6CAAgD;AAmDzC,IAAM,SAAS,GAAf,MAAM,SAAS;CAAG,CAAA;AAAZ,8BAAS;oBAAT,SAAS;IAjDrB,IAAA,eAAM,EAAC;QACN,OAAO,EAAE;YACP,yBAAc;YAEd,uBAAa;YACb,iBAAU;YACV,qBAAY;YACZ,0BAAc;YACd,8BAAgB;YAEhB,mBAAW,CAAC,QAAQ,EAAS;YAC7B,0BAAc,CAAC,QAAQ,EAAS;YAChC,yBAAc;YAEd,mBAAY,CAAC,QAAQ,CAAC;gBACpB;oBACE,IAAI,EAAE,cAAc;oBACpB,MAAM,EAAE,uBAAa;iBACtB;gBACD;oBACE,IAAI,EAAE,cAAc;oBACpB,MAAM,EAAE,iBAAU;iBACnB;gBACD;oBACE,IAAI,EAAE,cAAc;oBACpB,MAAM,EAAE,qBAAY;iBACrB;gBACD;oBACE,IAAI,EAAE,cAAc;oBACpB,MAAM,EAAE,0BAAc;iBACvB;gBACD;oBACE,IAAI,EAAE,cAAc;oBACpB,MAAM,EAAE,8BAAgB;iBACzB;gBACD;oBACE,IAAI,EAAE,cAAc;oBACpB,MAAM,EAAE,mBAAW;iBACpB;gBACD;oBACE,IAAI,EAAE,cAAc;oBACpB,MAAM,EAAE,0BAAc;iBACvB;aACF,CAAC;SACH;QACD,WAAW,EAAE,CAAC,8BAAa,CAAC;QAC5B,SAAS,EAAE,CAAC,wBAAU,CAAC;QACvB,OAAO,EAAE,CAAC,wBAAU,EAAE,yBAAc,CAAC;KACtC,CAAC;GACW,SAAS,CAAG"}
@@ -0,0 +1,34 @@
1
+ import { ConfigService } from '@nestjs/config';
2
+ import { CategoryType, EventEntityType, ItemDto, Items, LanguageService, MediaService } from '@thescaffold/ntx-core';
3
+ import { DataSource } from 'typeorm';
4
+ import { Channel } from './api/channel/entities/channel.entity';
5
+ import { Source } from './api/source/entities/source.entity';
6
+ import { SetConfigDto, UpdateConfigDto, UpsertRootSinkDto, UpsertRootSourceDto } from './app.dto';
7
+ import { PipelineService } from './pkg/pipeline/pipeline.service';
8
+ export declare class AppService {
9
+ private readonly configService;
10
+ private readonly languageService;
11
+ protected readonly mediaService: MediaService;
12
+ protected readonly dataSource: DataSource;
13
+ protected readonly pipelineService: PipelineService;
14
+ private readonly sourceRepository;
15
+ private readonly sinkRepository;
16
+ private readonly channelRepository;
17
+ private readonly sinkTypeRepository;
18
+ private readonly sourceTypeRepository;
19
+ constructor(configService: ConfigService, languageService: LanguageService, mediaService: MediaService, dataSource: DataSource, pipelineService: PipelineService);
20
+ getHello(): string;
21
+ ingestBatch(payload: Items, context?: any): Promise<boolean>;
22
+ ingest(item: ItemDto, context?: any): Promise<boolean>;
23
+ ingestSourceAlt(payload: any, id: string, properties: any, context?: any): Promise<boolean>;
24
+ ingestSource(payload: any, id: string, properties: any, context?: any): Promise<boolean>;
25
+ ingestChannel(payload: any, id: string, properties: any, context?: any): Promise<boolean>;
26
+ setConfig(payload: SetConfigDto, context?: any): Promise<Channel>;
27
+ getConfig(userId: string, clientId: string, workspaceId: string, entityId: string, entityName: EventEntityType, type: string, category: CategoryType, context?: any): Promise<Channel[]>;
28
+ updateConfig(id: string, payload: UpdateConfigDto, context?: any): Promise<{
29
+ id: string;
30
+ }>;
31
+ createRootSource(payload: UpsertRootSourceDto): Promise<Source>;
32
+ createRootSink(payload: UpsertRootSinkDto): Promise<Channel>;
33
+ private generateDottedStringVariations;
34
+ }