@productminds/article-events 4.1.0 → 5.1.1
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +11 -11
- package/lib/events/ExternalArticleEvent.d.ts +180 -156
- package/lib/events/ExternalArticleEvent.js +15 -2
- package/lib/events/InternalArticleEvent.d.ts +434 -168
- package/lib/events/InternalArticleEvent.js +1 -1
- package/package.json +20 -20
- package/lib/article-events/src/article-events.d.ts +0 -3
- package/lib/article-events/src/article-events.js +0 -10
- package/lib/article-events/src/cmd/write-json-schema.d.ts +0 -1
- package/lib/article-events/src/cmd/write-json-schema.js +0 -14
- package/lib/article-events/src/events/ExternalArticleEvent.d.ts +0 -418
- package/lib/article-events/src/events/ExternalArticleEvent.js +0 -19
- package/lib/article-events/src/events/InternalArticleEvent.d.ts +0 -546
- package/lib/article-events/src/events/InternalArticleEvent.js +0 -19
- package/lib/article-events/src/types/Article.d.ts +0 -47
- package/lib/article-events/src/types/Article.js +0 -41
- package/lib/article-events/src/utils/makeHelpers.d.ts +0 -15
- package/lib/article-events/src/utils/makeHelpers.js +0 -45
- package/lib/shared/schema.d.ts +0 -2
- package/lib/shared/schema.js +0 -5
@@ -34,198 +34,464 @@ export declare const InternalArticleEventSchema: Schema.Struct<{
|
|
34
34
|
}>;
|
35
35
|
declare const _default: {
|
36
36
|
decode: (u: unknown, overrideOptions?: import("@effect/schema/AST").ParseOptions) => import("effect/Either").Either<{
|
37
|
-
readonly
|
38
|
-
readonly
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
37
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
38
|
+
readonly payload: {
|
39
|
+
readonly article: {
|
40
|
+
readonly id: string;
|
41
|
+
readonly title: string;
|
42
|
+
readonly teaser: string;
|
43
|
+
readonly content: string;
|
44
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
45
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
46
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
47
|
+
readonly url: string;
|
48
|
+
readonly site: string;
|
49
|
+
readonly authors: readonly {
|
50
|
+
readonly name: string;
|
51
|
+
}[];
|
52
|
+
} & {
|
53
|
+
readonly tags: readonly ({
|
54
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
55
|
+
readonly extID: string;
|
56
|
+
readonly extSource: string;
|
57
|
+
} | {
|
58
|
+
readonly type: "CATEGORY";
|
59
|
+
readonly value: string;
|
60
|
+
} | {
|
61
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
62
|
+
readonly id: string;
|
63
|
+
})[];
|
64
|
+
};
|
65
|
+
readonly status: "NEW" | "UPDATED";
|
66
|
+
readonly source: "INTERNAL";
|
67
|
+
};
|
49
68
|
}, import("@effect/schema/ParseResult").ParseError>;
|
50
69
|
decodeExn: (u: unknown) => {
|
51
|
-
readonly
|
52
|
-
readonly
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
70
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
71
|
+
readonly payload: {
|
72
|
+
readonly article: {
|
73
|
+
readonly id: string;
|
74
|
+
readonly title: string;
|
75
|
+
readonly teaser: string;
|
76
|
+
readonly content: string;
|
77
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
78
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
79
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
80
|
+
readonly url: string;
|
81
|
+
readonly site: string;
|
82
|
+
readonly authors: readonly {
|
83
|
+
readonly name: string;
|
84
|
+
}[];
|
85
|
+
} & {
|
86
|
+
readonly tags: readonly ({
|
87
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
88
|
+
readonly extID: string;
|
89
|
+
readonly extSource: string;
|
90
|
+
} | {
|
91
|
+
readonly type: "CATEGORY";
|
92
|
+
readonly value: string;
|
93
|
+
} | {
|
94
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
95
|
+
readonly id: string;
|
96
|
+
})[];
|
97
|
+
};
|
98
|
+
readonly status: "NEW" | "UPDATED";
|
99
|
+
readonly source: "INTERNAL";
|
100
|
+
};
|
63
101
|
};
|
64
102
|
encode: (a: {
|
65
|
-
readonly
|
66
|
-
readonly
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
103
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
104
|
+
readonly payload: {
|
105
|
+
readonly article: {
|
106
|
+
readonly id: string;
|
107
|
+
readonly title: string;
|
108
|
+
readonly teaser: string;
|
109
|
+
readonly content: string;
|
110
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
111
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
112
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
113
|
+
readonly url: string;
|
114
|
+
readonly site: string;
|
115
|
+
readonly authors: readonly {
|
116
|
+
readonly name: string;
|
117
|
+
}[];
|
118
|
+
} & {
|
119
|
+
readonly tags: readonly ({
|
120
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
121
|
+
readonly extID: string;
|
122
|
+
readonly extSource: string;
|
123
|
+
} | {
|
124
|
+
readonly type: "CATEGORY";
|
125
|
+
readonly value: string;
|
126
|
+
} | {
|
127
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
128
|
+
readonly id: string;
|
129
|
+
})[];
|
130
|
+
};
|
131
|
+
readonly status: "NEW" | "UPDATED";
|
132
|
+
readonly source: "INTERNAL";
|
133
|
+
};
|
77
134
|
}, overrideOptions?: import("@effect/schema/AST").ParseOptions) => import("effect/Either").Either<{
|
78
|
-
readonly
|
79
|
-
readonly
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
135
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
136
|
+
readonly payload: {
|
137
|
+
readonly article: {
|
138
|
+
readonly id: string;
|
139
|
+
readonly title: string;
|
140
|
+
readonly teaser: string;
|
141
|
+
readonly content: string;
|
142
|
+
readonly publishedAt: string;
|
143
|
+
readonly updatedAt: string;
|
144
|
+
readonly retrievedAt: string;
|
145
|
+
readonly url: string;
|
146
|
+
readonly site: string;
|
147
|
+
readonly authors: readonly {
|
148
|
+
readonly name: string;
|
149
|
+
}[];
|
150
|
+
} & {
|
151
|
+
readonly tags: readonly ({
|
152
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
153
|
+
readonly extID: string;
|
154
|
+
readonly extSource: string;
|
155
|
+
} | {
|
156
|
+
readonly type: "CATEGORY";
|
157
|
+
readonly value: string;
|
158
|
+
} | {
|
159
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
160
|
+
readonly id: string;
|
161
|
+
})[];
|
162
|
+
};
|
163
|
+
readonly status: "NEW" | "UPDATED";
|
164
|
+
readonly source: "INTERNAL";
|
165
|
+
};
|
90
166
|
}, import("@effect/schema/ParseResult").ParseError>;
|
91
167
|
encodeExn: (event: {
|
92
|
-
readonly
|
93
|
-
readonly
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
168
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
169
|
+
readonly payload: {
|
170
|
+
readonly article: {
|
171
|
+
readonly id: string;
|
172
|
+
readonly title: string;
|
173
|
+
readonly teaser: string;
|
174
|
+
readonly content: string;
|
175
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
176
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
177
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
178
|
+
readonly url: string;
|
179
|
+
readonly site: string;
|
180
|
+
readonly authors: readonly {
|
181
|
+
readonly name: string;
|
182
|
+
}[];
|
183
|
+
} & {
|
184
|
+
readonly tags: readonly ({
|
185
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
186
|
+
readonly extID: string;
|
187
|
+
readonly extSource: string;
|
188
|
+
} | {
|
189
|
+
readonly type: "CATEGORY";
|
190
|
+
readonly value: string;
|
191
|
+
} | {
|
192
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
193
|
+
readonly id: string;
|
194
|
+
})[];
|
195
|
+
};
|
196
|
+
readonly status: "NEW" | "UPDATED";
|
197
|
+
readonly source: "INTERNAL";
|
198
|
+
};
|
104
199
|
}) => {
|
105
|
-
readonly
|
106
|
-
readonly
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
200
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
201
|
+
readonly payload: {
|
202
|
+
readonly article: {
|
203
|
+
readonly id: string;
|
204
|
+
readonly title: string;
|
205
|
+
readonly teaser: string;
|
206
|
+
readonly content: string;
|
207
|
+
readonly publishedAt: string;
|
208
|
+
readonly updatedAt: string;
|
209
|
+
readonly retrievedAt: string;
|
210
|
+
readonly url: string;
|
211
|
+
readonly site: string;
|
212
|
+
readonly authors: readonly {
|
213
|
+
readonly name: string;
|
214
|
+
}[];
|
215
|
+
} & {
|
216
|
+
readonly tags: readonly ({
|
217
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
218
|
+
readonly extID: string;
|
219
|
+
readonly extSource: string;
|
220
|
+
} | {
|
221
|
+
readonly type: "CATEGORY";
|
222
|
+
readonly value: string;
|
223
|
+
} | {
|
224
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
225
|
+
readonly id: string;
|
226
|
+
})[];
|
227
|
+
};
|
228
|
+
readonly status: "NEW" | "UPDATED";
|
229
|
+
readonly source: "INTERNAL";
|
230
|
+
};
|
117
231
|
};
|
118
232
|
fromString: (msg: string) => import("effect/Either").Either<{
|
119
|
-
readonly
|
120
|
-
readonly
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
233
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
234
|
+
readonly payload: {
|
235
|
+
readonly article: {
|
236
|
+
readonly id: string;
|
237
|
+
readonly title: string;
|
238
|
+
readonly teaser: string;
|
239
|
+
readonly content: string;
|
240
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
241
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
242
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
243
|
+
readonly url: string;
|
244
|
+
readonly site: string;
|
245
|
+
readonly authors: readonly {
|
246
|
+
readonly name: string;
|
247
|
+
}[];
|
248
|
+
} & {
|
249
|
+
readonly tags: readonly ({
|
250
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
251
|
+
readonly extID: string;
|
252
|
+
readonly extSource: string;
|
253
|
+
} | {
|
254
|
+
readonly type: "CATEGORY";
|
255
|
+
readonly value: string;
|
256
|
+
} | {
|
257
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
258
|
+
readonly id: string;
|
259
|
+
})[];
|
260
|
+
};
|
261
|
+
readonly status: "NEW" | "UPDATED";
|
262
|
+
readonly source: "INTERNAL";
|
263
|
+
};
|
131
264
|
}, import("@effect/schema/ParseResult").ParseError>;
|
132
265
|
fromBuffer: (msg: Buffer) => import("effect/Either").Either<{
|
133
|
-
readonly
|
134
|
-
readonly
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
266
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
267
|
+
readonly payload: {
|
268
|
+
readonly article: {
|
269
|
+
readonly id: string;
|
270
|
+
readonly title: string;
|
271
|
+
readonly teaser: string;
|
272
|
+
readonly content: string;
|
273
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
274
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
275
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
276
|
+
readonly url: string;
|
277
|
+
readonly site: string;
|
278
|
+
readonly authors: readonly {
|
279
|
+
readonly name: string;
|
280
|
+
}[];
|
281
|
+
} & {
|
282
|
+
readonly tags: readonly ({
|
283
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
284
|
+
readonly extID: string;
|
285
|
+
readonly extSource: string;
|
286
|
+
} | {
|
287
|
+
readonly type: "CATEGORY";
|
288
|
+
readonly value: string;
|
289
|
+
} | {
|
290
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
291
|
+
readonly id: string;
|
292
|
+
})[];
|
293
|
+
};
|
294
|
+
readonly status: "NEW" | "UPDATED";
|
295
|
+
readonly source: "INTERNAL";
|
296
|
+
};
|
145
297
|
}, import("@effect/schema/ParseResult").ParseError>;
|
146
298
|
fromStringExn: (msg: string) => {
|
147
|
-
readonly
|
148
|
-
readonly
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
299
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
300
|
+
readonly payload: {
|
301
|
+
readonly article: {
|
302
|
+
readonly id: string;
|
303
|
+
readonly title: string;
|
304
|
+
readonly teaser: string;
|
305
|
+
readonly content: string;
|
306
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
307
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
308
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
309
|
+
readonly url: string;
|
310
|
+
readonly site: string;
|
311
|
+
readonly authors: readonly {
|
312
|
+
readonly name: string;
|
313
|
+
}[];
|
314
|
+
} & {
|
315
|
+
readonly tags: readonly ({
|
316
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
317
|
+
readonly extID: string;
|
318
|
+
readonly extSource: string;
|
319
|
+
} | {
|
320
|
+
readonly type: "CATEGORY";
|
321
|
+
readonly value: string;
|
322
|
+
} | {
|
323
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
324
|
+
readonly id: string;
|
325
|
+
})[];
|
326
|
+
};
|
327
|
+
readonly status: "NEW" | "UPDATED";
|
328
|
+
readonly source: "INTERNAL";
|
329
|
+
};
|
159
330
|
};
|
160
331
|
fromBufferExn: (msg: Buffer) => {
|
161
|
-
readonly
|
162
|
-
readonly
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
332
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
333
|
+
readonly payload: {
|
334
|
+
readonly article: {
|
335
|
+
readonly id: string;
|
336
|
+
readonly title: string;
|
337
|
+
readonly teaser: string;
|
338
|
+
readonly content: string;
|
339
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
340
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
341
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
342
|
+
readonly url: string;
|
343
|
+
readonly site: string;
|
344
|
+
readonly authors: readonly {
|
345
|
+
readonly name: string;
|
346
|
+
}[];
|
347
|
+
} & {
|
348
|
+
readonly tags: readonly ({
|
349
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
350
|
+
readonly extID: string;
|
351
|
+
readonly extSource: string;
|
352
|
+
} | {
|
353
|
+
readonly type: "CATEGORY";
|
354
|
+
readonly value: string;
|
355
|
+
} | {
|
356
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
357
|
+
readonly id: string;
|
358
|
+
})[];
|
359
|
+
};
|
360
|
+
readonly status: "NEW" | "UPDATED";
|
361
|
+
readonly source: "INTERNAL";
|
362
|
+
};
|
173
363
|
};
|
174
364
|
toString: (event: {
|
175
|
-
readonly
|
176
|
-
readonly
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
365
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
366
|
+
readonly payload: {
|
367
|
+
readonly article: {
|
368
|
+
readonly id: string;
|
369
|
+
readonly title: string;
|
370
|
+
readonly teaser: string;
|
371
|
+
readonly content: string;
|
372
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
373
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
374
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
375
|
+
readonly url: string;
|
376
|
+
readonly site: string;
|
377
|
+
readonly authors: readonly {
|
378
|
+
readonly name: string;
|
379
|
+
}[];
|
380
|
+
} & {
|
381
|
+
readonly tags: readonly ({
|
382
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
383
|
+
readonly extID: string;
|
384
|
+
readonly extSource: string;
|
385
|
+
} | {
|
386
|
+
readonly type: "CATEGORY";
|
387
|
+
readonly value: string;
|
388
|
+
} | {
|
389
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
390
|
+
readonly id: string;
|
391
|
+
})[];
|
392
|
+
};
|
393
|
+
readonly status: "NEW" | "UPDATED";
|
394
|
+
readonly source: "INTERNAL";
|
395
|
+
};
|
187
396
|
}) => string;
|
188
397
|
toBuffer: (event: {
|
189
|
-
readonly
|
190
|
-
readonly
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
398
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
399
|
+
readonly payload: {
|
400
|
+
readonly article: {
|
401
|
+
readonly id: string;
|
402
|
+
readonly title: string;
|
403
|
+
readonly teaser: string;
|
404
|
+
readonly content: string;
|
405
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
406
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
407
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
408
|
+
readonly url: string;
|
409
|
+
readonly site: string;
|
410
|
+
readonly authors: readonly {
|
411
|
+
readonly name: string;
|
412
|
+
}[];
|
413
|
+
} & {
|
414
|
+
readonly tags: readonly ({
|
415
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
416
|
+
readonly extID: string;
|
417
|
+
readonly extSource: string;
|
418
|
+
} | {
|
419
|
+
readonly type: "CATEGORY";
|
420
|
+
readonly value: string;
|
421
|
+
} | {
|
422
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
423
|
+
readonly id: string;
|
424
|
+
})[];
|
425
|
+
};
|
426
|
+
readonly status: "NEW" | "UPDATED";
|
427
|
+
readonly source: "INTERNAL";
|
428
|
+
};
|
201
429
|
}) => Buffer;
|
202
430
|
toStringExn: (event: {
|
203
|
-
readonly
|
204
|
-
readonly
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
431
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
432
|
+
readonly payload: {
|
433
|
+
readonly article: {
|
434
|
+
readonly id: string;
|
435
|
+
readonly title: string;
|
436
|
+
readonly teaser: string;
|
437
|
+
readonly content: string;
|
438
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
439
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
440
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
441
|
+
readonly url: string;
|
442
|
+
readonly site: string;
|
443
|
+
readonly authors: readonly {
|
444
|
+
readonly name: string;
|
445
|
+
}[];
|
446
|
+
} & {
|
447
|
+
readonly tags: readonly ({
|
448
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
449
|
+
readonly extID: string;
|
450
|
+
readonly extSource: string;
|
451
|
+
} | {
|
452
|
+
readonly type: "CATEGORY";
|
453
|
+
readonly value: string;
|
454
|
+
} | {
|
455
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
456
|
+
readonly id: string;
|
457
|
+
})[];
|
458
|
+
};
|
459
|
+
readonly status: "NEW" | "UPDATED";
|
460
|
+
readonly source: "INTERNAL";
|
461
|
+
};
|
215
462
|
}) => string;
|
216
463
|
toBufferExn: (event: {
|
217
|
-
readonly
|
218
|
-
readonly
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
464
|
+
readonly kind: "INTERNAL_ARTICLE_EVENT";
|
465
|
+
readonly payload: {
|
466
|
+
readonly article: {
|
467
|
+
readonly id: string;
|
468
|
+
readonly title: string;
|
469
|
+
readonly teaser: string;
|
470
|
+
readonly content: string;
|
471
|
+
readonly publishedAt: import("effect/DateTime").Utc;
|
472
|
+
readonly updatedAt: import("effect/DateTime").Utc;
|
473
|
+
readonly retrievedAt: import("effect/DateTime").Utc;
|
474
|
+
readonly url: string;
|
475
|
+
readonly site: string;
|
476
|
+
readonly authors: readonly {
|
477
|
+
readonly name: string;
|
478
|
+
}[];
|
479
|
+
} & {
|
480
|
+
readonly tags: readonly ({
|
481
|
+
readonly type: "DRUPAL_EXTERNAL_ID";
|
482
|
+
readonly extID: string;
|
483
|
+
readonly extSource: string;
|
484
|
+
} | {
|
485
|
+
readonly type: "CATEGORY";
|
486
|
+
readonly value: string;
|
487
|
+
} | {
|
488
|
+
readonly type: "EXTERNAL_ARTICLE_REFERENCE";
|
489
|
+
readonly id: string;
|
490
|
+
})[];
|
491
|
+
};
|
492
|
+
readonly status: "NEW" | "UPDATED";
|
493
|
+
readonly source: "INTERNAL";
|
494
|
+
};
|
229
495
|
}) => Buffer;
|
230
496
|
Schema: Schema.Struct<{
|
231
497
|
kind: Schema.Literal<["INTERNAL_ARTICLE_EVENT"]>;
|
@@ -15,5 +15,5 @@ exports.InternalArticleEventSchema = schema_1.Schema.Struct({
|
|
15
15
|
source: schema_1.Schema.Literal('INTERNAL'),
|
16
16
|
}),
|
17
17
|
});
|
18
|
-
const helpers = (0, makeHelpers_1.makeHelpers)(
|
18
|
+
const helpers = (0, makeHelpers_1.makeHelpers)(exports.InternalArticleEventSchema);
|
19
19
|
exports.default = Object.assign({ Schema: exports.InternalArticleEventSchema }, helpers);
|