@eventcatalog/core 3.27.4 → 3.28.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.
@@ -37,7 +37,7 @@ var import_axios = __toESM(require("axios"), 1);
37
37
  var import_os = __toESM(require("os"), 1);
38
38
 
39
39
  // package.json
40
- var version = "3.27.4";
40
+ var version = "3.28.0";
41
41
 
42
42
  // src/constants.ts
43
43
  var VERSION = version;
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  raiseEvent
3
- } from "../chunk-OETTCEGA.js";
4
- import "../chunk-6WAVA45Z.js";
3
+ } from "../chunk-TG2M57NQ.js";
4
+ import "../chunk-PVWE6NFP.js";
5
5
  export {
6
6
  raiseEvent
7
7
  };
@@ -111,7 +111,7 @@ var import_axios = __toESM(require("axios"), 1);
111
111
  var import_os = __toESM(require("os"), 1);
112
112
 
113
113
  // package.json
114
- var version = "3.27.4";
114
+ var version = "3.28.0";
115
115
 
116
116
  // src/constants.ts
117
117
  var VERSION = version;
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  log_build_default
3
- } from "../chunk-JUTWHXQL.js";
4
- import "../chunk-OETTCEGA.js";
3
+ } from "../chunk-SVKRN4WR.js";
4
+ import "../chunk-TG2M57NQ.js";
5
5
  import "../chunk-4UVFXLPI.js";
6
- import "../chunk-6WAVA45Z.js";
6
+ import "../chunk-PVWE6NFP.js";
7
7
  import "../chunk-5T63CXKU.js";
8
8
  export {
9
9
  log_build_default as default
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  VERSION
3
- } from "./chunk-6WAVA45Z.js";
3
+ } from "./chunk-PVWE6NFP.js";
4
4
 
5
5
  // src/utils/cli-logger.ts
6
6
  import pc from "picocolors";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  logger
3
- } from "./chunk-ZVFDUX5L.js";
3
+ } from "./chunk-BLDIS6WQ.js";
4
4
  import {
5
5
  cleanup,
6
6
  getEventCatalogConfigFile
@@ -1,5 +1,5 @@
1
1
  // package.json
2
- var version = "3.27.4";
2
+ var version = "3.28.0";
3
3
 
4
4
  // src/constants.ts
5
5
  var VERSION = version;
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  raiseEvent
3
- } from "./chunk-OETTCEGA.js";
3
+ } from "./chunk-TG2M57NQ.js";
4
4
  import {
5
5
  countResources,
6
6
  serializeCounts
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  VERSION
3
- } from "./chunk-6WAVA45Z.js";
3
+ } from "./chunk-PVWE6NFP.js";
4
4
 
5
5
  // src/analytics/analytics.js
6
6
  import axios from "axios";
@@ -25,7 +25,7 @@ __export(constants_exports, {
25
25
  module.exports = __toCommonJS(constants_exports);
26
26
 
27
27
  // package.json
28
- var version = "3.27.4";
28
+ var version = "3.28.0";
29
29
 
30
30
  // src/constants.ts
31
31
  var VERSION = version;
package/dist/constants.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  VERSION
3
- } from "./chunk-6WAVA45Z.js";
3
+ } from "./chunk-PVWE6NFP.js";
4
4
  export {
5
5
  VERSION
6
6
  };
@@ -114,7 +114,7 @@ var verifyRequiredFieldsAreInCatalogConfigFile = async (projectDirectory) => {
114
114
  var import_picocolors = __toESM(require("picocolors"), 1);
115
115
 
116
116
  // package.json
117
- var version = "3.27.4";
117
+ var version = "3.28.0";
118
118
 
119
119
  // src/constants.ts
120
120
  var VERSION = version;
@@ -6,8 +6,8 @@ import {
6
6
  } from "./chunk-PLNJC7NZ.js";
7
7
  import {
8
8
  log_build_default
9
- } from "./chunk-JUTWHXQL.js";
10
- import "./chunk-OETTCEGA.js";
9
+ } from "./chunk-SVKRN4WR.js";
10
+ import "./chunk-TG2M57NQ.js";
11
11
  import "./chunk-4UVFXLPI.js";
12
12
  import {
13
13
  runMigrations
@@ -22,13 +22,13 @@ import {
22
22
  } from "./chunk-3KXCGYET.js";
23
23
  import {
24
24
  generate
25
- } from "./chunk-FWBVRDMX.js";
25
+ } from "./chunk-LZGOYFMC.js";
26
26
  import {
27
27
  logger
28
- } from "./chunk-ZVFDUX5L.js";
28
+ } from "./chunk-BLDIS6WQ.js";
29
29
  import {
30
30
  VERSION
31
- } from "./chunk-6WAVA45Z.js";
31
+ } from "./chunk-PVWE6NFP.js";
32
32
  import {
33
33
  getEventCatalogConfigFile,
34
34
  verifyRequiredFieldsAreInCatalogConfigFile
package/dist/generate.cjs CHANGED
@@ -78,7 +78,7 @@ var getEventCatalogConfigFile = async (projectDirectory) => {
78
78
  var import_picocolors = __toESM(require("picocolors"), 1);
79
79
 
80
80
  // package.json
81
- var version = "3.27.4";
81
+ var version = "3.28.0";
82
82
 
83
83
  // src/constants.ts
84
84
  var VERSION = version;
package/dist/generate.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  generate
3
- } from "./chunk-FWBVRDMX.js";
4
- import "./chunk-ZVFDUX5L.js";
5
- import "./chunk-6WAVA45Z.js";
3
+ } from "./chunk-LZGOYFMC.js";
4
+ import "./chunk-BLDIS6WQ.js";
5
+ import "./chunk-PVWE6NFP.js";
6
6
  import "./chunk-5T63CXKU.js";
7
7
  export {
8
8
  generate
@@ -36,7 +36,7 @@ module.exports = __toCommonJS(cli_logger_exports);
36
36
  var import_picocolors = __toESM(require("picocolors"), 1);
37
37
 
38
38
  // package.json
39
- var version = "3.27.4";
39
+ var version = "3.28.0";
40
40
 
41
41
  // src/constants.ts
42
42
  var VERSION = version;
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  logger
3
- } from "../chunk-ZVFDUX5L.js";
4
- import "../chunk-6WAVA45Z.js";
3
+ } from "../chunk-BLDIS6WQ.js";
4
+ import "../chunk-PVWE6NFP.js";
5
5
  export {
6
6
  logger
7
7
  };
@@ -22,6 +22,7 @@ export type CollectionType =
22
22
  | 'commands'
23
23
  | 'queries'
24
24
  | 'services'
25
+ | 'external-systems'
25
26
  | 'domains'
26
27
  | 'flows'
27
28
  | 'containers'
@@ -104,7 +104,10 @@ const createActionsColumn = (collectionType: CollectionType, tableConfiguration:
104
104
  const item = info.row.original;
105
105
  const href = buildUrl(`/docs/${item.collection}/${item.data.id}/${item.data.version}`);
106
106
  const nodeKey = `${item.collection}-${item.data.id}-${item.data.version}`;
107
- const badgeLabel = collectionType.charAt(0).toUpperCase() + collectionType.slice(1, -1);
107
+ const badgeLabel =
108
+ collectionType === 'external-systems'
109
+ ? 'External System'
110
+ : collectionType.charAt(0).toUpperCase() + collectionType.slice(1, -1);
108
111
 
109
112
  return (
110
113
  <div className="flex items-center gap-0.5">
@@ -612,6 +615,7 @@ export const getDiscoverColumns = (collectionType: CollectionType, tableConfigur
612
615
  case 'queries':
613
616
  return getQueryColumns(tableConfiguration);
614
617
  case 'services':
618
+ case 'external-systems':
615
619
  return getServiceColumns(tableConfiguration);
616
620
  case 'domains':
617
621
  return getDomainColumns(tableConfiguration);
@@ -456,6 +456,7 @@ const services = defineCollection({
456
456
  writesTo: z.array(pointer).optional(),
457
457
  readsFrom: z.array(pointer).optional(),
458
458
  flows: z.array(pointer).optional(),
459
+ externalSystem: z.boolean().optional(),
459
460
  detailsPanel: z
460
461
  .object({
461
462
  domains: detailPanelPropertySchema.optional(),
@@ -13,14 +13,28 @@ export class Page extends HybridPage {
13
13
  const { getServices } = await import('@utils/collections/services');
14
14
  const { getDataProducts } = await import('@utils/collections/data-products');
15
15
 
16
+ const getInternalServices = async () => (await getServices()).filter((s) => !s.data.externalSystem);
17
+ const getExternalServices = async () => (await getServices()).filter((s) => s.data.externalSystem);
18
+
16
19
  const loaders = {
17
20
  ...pageDataLoader,
18
21
  flows: getFlows,
19
- services: getServices,
22
+ services: getInternalServices,
23
+ 'external-systems': getExternalServices,
20
24
  'data-products': getDataProducts,
21
25
  };
22
26
 
23
- const itemTypes = ['events', 'commands', 'queries', 'domains', 'services', 'flows', 'containers', 'data-products'] as const;
27
+ const itemTypes = [
28
+ 'events',
29
+ 'commands',
30
+ 'queries',
31
+ 'domains',
32
+ 'services',
33
+ 'external-systems',
34
+ 'flows',
35
+ 'containers',
36
+ 'data-products',
37
+ ] as const;
24
38
  const allItems = await Promise.all(itemTypes.map((type) => loaders[type]()));
25
39
 
26
40
  return allItems.flatMap((items, index) => ({
@@ -45,10 +59,14 @@ export class Page extends HybridPage {
45
59
  const { getServices } = await import('@utils/collections/services');
46
60
  const { getDataProducts } = await import('@utils/collections/data-products');
47
61
 
62
+ const getInternalServices = async () => (await getServices()).filter((s) => !s.data.externalSystem);
63
+ const getExternalServices = async () => (await getServices()).filter((s) => s.data.externalSystem);
64
+
48
65
  const loaders = {
49
66
  ...pageDataLoader,
50
67
  flows: getFlows,
51
- services: getServices,
68
+ services: getInternalServices,
69
+ 'external-systems': getExternalServices,
52
70
  'data-products': getDataProducts,
53
71
  };
54
72
 
@@ -1,5 +1,12 @@
1
1
  ---
2
- import { QueueListIcon, RectangleGroupIcon, BoltIcon, ChatBubbleLeftIcon, CubeIcon } from '@heroicons/react/24/outline';
2
+ import {
3
+ QueueListIcon,
4
+ RectangleGroupIcon,
5
+ BoltIcon,
6
+ ChatBubbleLeftIcon,
7
+ CubeIcon,
8
+ GlobeAltIcon,
9
+ } from '@heroicons/react/24/outline';
3
10
  import ServerIcon from '@heroicons/react/24/outline/ServerIcon';
4
11
  import { MagnifyingGlassIcon } from '@heroicons/react/20/solid';
5
12
  import { DatabaseIcon } from 'lucide-react';
@@ -30,6 +37,8 @@ const events = await getEvents();
30
37
  const queries = await getQueries();
31
38
  const commands = await getCommands();
32
39
  const services = await getServices();
40
+ const internalServices = services.filter((s) => !s.data.externalSystem);
41
+ const externalServices = services.filter((s) => s.data.externalSystem);
33
42
  const domains = await getDomains({ getAllVersions: false });
34
43
  const flows = await getFlows();
35
44
  const containers = await getContainers();
@@ -96,6 +105,16 @@ const typeConfig: Record<
96
105
  { id: 'isDeprecated', label: 'Is Deprecated' },
97
106
  ],
98
107
  },
108
+ 'external-systems': {
109
+ label: 'External Systems',
110
+ propertyOptions: [
111
+ { id: 'hasSpecifications', label: 'Has Specifications' },
112
+ { id: 'hasOwners', label: 'Has Owners' },
113
+ { id: 'hasRepository', label: 'Has Repository' },
114
+ { id: 'hasDataDependencies', label: 'Has Data Dependencies' },
115
+ { id: 'isDeprecated', label: 'Is Deprecated' },
116
+ ],
117
+ },
99
118
  flows: {
100
119
  label: 'Flows',
101
120
  propertyOptions: [
@@ -125,8 +144,10 @@ const typeConfig: Record<
125
144
 
126
145
  const currentTypeConfig = typeConfig[type] || typeConfig.events;
127
146
 
147
+ // External systems reuse the user's `services.tableConfiguration` so customisations apply to both tabs
148
+ const tableConfigurationKey = type === 'external-systems' ? 'services' : type;
128
149
  // @ts-ignore
129
- const tableConfiguration = config[type as keyof typeof config]?.tableConfiguration ?? { columns: {} };
150
+ const tableConfiguration = config[tableConfigurationKey as keyof typeof config]?.tableConfiguration ?? { columns: {} };
130
151
 
131
152
  const tabs = [
132
153
  {
@@ -139,13 +160,22 @@ const tabs = [
139
160
  visible: domains.length > 0,
140
161
  },
141
162
  {
142
- label: `Services (${services.length})`,
163
+ label: `Services (${internalServices.length})`,
143
164
  href: buildUrl('/discover/services'),
144
165
  isActive: type === 'services',
145
166
  icon: ServerIcon,
146
167
  activeColor: 'pink',
147
- enabled: services.length > 0,
148
- visible: services.length > 0,
168
+ enabled: internalServices.length > 0,
169
+ visible: internalServices.length > 0,
170
+ },
171
+ {
172
+ label: `External Systems (${externalServices.length})`,
173
+ href: buildUrl('/discover/external-systems'),
174
+ isActive: type === 'external-systems',
175
+ icon: GlobeAltIcon,
176
+ activeColor: 'purple',
177
+ enabled: externalServices.length > 0,
178
+ visible: externalServices.length > 0,
149
179
  },
150
180
  {
151
181
  label: `Data (${containers.length})`,
@@ -278,23 +308,24 @@ const allSubdomainIds = new Set(
278
308
  domains.flatMap((d: any) => (d.data?.domains || []).map((sd: any) => sd.data?.id || sd.id)).filter(Boolean)
279
309
  );
280
310
 
281
- // For services, enrich with domain information
282
- const enrichedData =
283
- type === 'services'
284
- ? await Promise.all(
285
- data.map(async (service: any) => {
286
- const serviceDomains = await getDomainsForService(service);
287
- return {
288
- ...service,
289
- enrichedDomains: serviceDomains.map((d: any) => ({
290
- id: d.data.id,
291
- name: d.data.name,
292
- version: d.data.version,
293
- })),
294
- };
295
- })
296
- )
297
- : data;
311
+ const isServiceLike = type === 'services' || type === 'external-systems';
312
+
313
+ // For services and external systems, enrich with domain information
314
+ const enrichedData = isServiceLike
315
+ ? await Promise.all(
316
+ data.map(async (service: any) => {
317
+ const serviceDomains = await getDomainsForService(service);
318
+ return {
319
+ ...service,
320
+ enrichedDomains: serviceDomains.map((d: any) => ({
321
+ id: d.data.id,
322
+ name: d.data.name,
323
+ version: d.data.version,
324
+ })),
325
+ };
326
+ })
327
+ )
328
+ : data;
298
329
 
299
330
  const tableData = enrichedData.map((d: any) => ({
300
331
  collection: d.collection,
@@ -303,10 +334,10 @@ const tableData = enrichedData.map((d: any) => ({
303
334
  hasServices: type === 'domains' ? (d.data?.services || []).length > 0 : false,
304
335
  isSubdomain: type === 'domains' ? allSubdomainIds.has(d.data.id) : false,
305
336
  // Service-specific properties
306
- domains: type === 'services' ? d.enrichedDomains : undefined,
307
- hasSpecifications: type === 'services' ? hasSpecifications(d) : false,
308
- hasRepository: type === 'services' ? !!d.data?.repository?.url : false,
309
- hasDataDependencies: type === 'services' ? (d.data?.writesTo || []).length > 0 || (d.data?.readsFrom || []).length > 0 : false,
337
+ domains: isServiceLike ? d.enrichedDomains : undefined,
338
+ hasSpecifications: isServiceLike ? hasSpecifications(d) : false,
339
+ hasRepository: isServiceLike ? !!d.data?.repository?.url : false,
340
+ hasDataDependencies: isServiceLike ? (d.data?.writesTo || []).length > 0 || (d.data?.readsFrom || []).length > 0 : false,
310
341
  // Data-product-specific properties
311
342
  hasInputs: type === 'data-products' ? (d.data?.inputs || []).length > 0 : false,
312
343
  hasOutputs: type === 'data-products' ? (d.data?.outputs || []).length > 0 : false,
@@ -371,8 +402,8 @@ const uniqueDomains = domains.map((d) => ({
371
402
  version: d.data.version,
372
403
  }));
373
404
 
374
- // Show domains filter only for services
375
- const showDomainsFilter = type === 'services';
405
+ // Show domains filter only for services and external systems
406
+ const showDomainsFilter = isServiceLike;
376
407
 
377
408
  const title = `${currentTypeConfig.label} (${data.length})`;
378
409
  ---
@@ -16,8 +16,11 @@ import { pluralizeMessageType } from '@utils/collections/messages';
16
16
  import { getSpecificationsForDomain } from '@utils/collections/domains';
17
17
 
18
18
  export const buildDomainNode = (domain: CollectionEntry<'domains'>, owners: any[], context: ResourceGroupContext): NavNode => {
19
- const servicesInDomain = domain.data.services || [];
19
+ const allServicesInDomain = domain.data.services || [];
20
+ const servicesInDomain = allServicesInDomain.filter((service) => !(service as any).data?.externalSystem);
21
+ const externalSystemsInDomain = allServicesInDomain.filter((service) => (service as any).data?.externalSystem);
20
22
  const renderServices = servicesInDomain.length > 0 && shouldRenderSideBarSection(domain, 'services');
23
+ const renderExternalSystems = externalSystemsInDomain.length > 0 && shouldRenderSideBarSection(domain, 'services');
21
24
 
22
25
  const dataProductsInDomain = domain.data['data-products'] || [];
23
26
  const renderDataProducts = dataProductsInDomain.length > 0 && shouldRenderSideBarSection(domain, 'data-products');
@@ -179,6 +182,12 @@ export const buildDomainNode = (domain: CollectionEntry<'domains'>, owners: any[
179
182
  icon: 'Server',
180
183
  pages: servicesInDomain.map((service) => `service:${(service as any).data.id}:${(service as any).data.version}`),
181
184
  },
185
+ renderExternalSystems && {
186
+ type: 'group',
187
+ title: 'External Integrations',
188
+ icon: 'Globe',
189
+ pages: externalSystemsInDomain.map((service) => `service:${(service as any).data.id}:${(service as any).data.version}`),
190
+ },
182
191
  renderDataProducts && {
183
192
  type: 'group',
184
193
  title: 'Data Products',
@@ -63,10 +63,12 @@ export const buildServiceNode = (
63
63
  const diagramNavItems = buildDiagramNavItems(serviceDiagrams, context.diagrams);
64
64
  const hasDiagrams = diagramNavItems.length > 0;
65
65
 
66
+ const isExternalSystem = !!service.data.externalSystem;
67
+
66
68
  return {
67
69
  type: 'item',
68
70
  title: service.data.name,
69
- badge: 'Service',
71
+ badge: isExternalSystem ? 'External System' : 'Service',
70
72
  summary: service.data.summary,
71
73
  pages: [
72
74
  buildQuickReferenceSection(
@@ -374,11 +374,21 @@ export const getNestedSideBarData = async (): Promise<NavigationData> => {
374
374
  pages: domains.map((domain) => `domain:${domain.data.id}:${domain.data.version}`),
375
375
  });
376
376
 
377
- const servicesList = createLeaf(services, {
377
+ const internalServices = services.filter((service) => !service.data.externalSystem);
378
+ const externalServices = services.filter((service) => service.data.externalSystem);
379
+
380
+ const servicesList = createLeaf(internalServices, {
378
381
  type: 'item',
379
382
  title: 'Services',
380
383
  icon: 'Server',
381
- pages: services.map((service) => `service:${service.data.id}:${service.data.version}`),
384
+ pages: internalServices.map((service) => `service:${service.data.id}:${service.data.version}`),
385
+ });
386
+
387
+ const externalSystemsList = createLeaf(externalServices, {
388
+ type: 'item',
389
+ title: 'External Systems',
390
+ icon: 'Globe',
391
+ pages: externalServices.map((service) => `service:${service.data.id}:${service.data.version}`),
382
392
  });
383
393
 
384
394
  const eventsList = createLeaf(events, {
@@ -480,6 +490,7 @@ export const getNestedSideBarData = async (): Promise<NavigationData> => {
480
490
  const allChildrenKeys = [
481
491
  'list:domains',
482
492
  'list:services',
493
+ 'list:external-systems',
483
494
  'list:messages',
484
495
  'list:channels',
485
496
  'list:flows',
@@ -491,6 +502,7 @@ export const getNestedSideBarData = async (): Promise<NavigationData> => {
491
502
  const allChildrenNodes = [
492
503
  domainsList,
493
504
  servicesList,
505
+ externalSystemsList,
494
506
  messagesList,
495
507
  channelList,
496
508
  flowsList,
@@ -515,6 +527,7 @@ export const getNestedSideBarData = async (): Promise<NavigationData> => {
515
527
  const allNodes: Record<string, NavNode> = {
516
528
  ...(domainsList ? { 'list:domains': domainsList } : {}),
517
529
  ...(servicesList ? { 'list:services': servicesList } : {}),
530
+ ...(externalSystemsList ? { 'list:external-systems': externalSystemsList } : {}),
518
531
  ...(eventsList ? { 'list:events': eventsList } : {}),
519
532
  ...(commandsList ? { 'list:commands': commandsList } : {}),
520
533
  ...(queriesList ? { 'list:queries': queriesList } : {}),
package/package.json CHANGED
@@ -7,7 +7,7 @@
7
7
  },
8
8
  "license": "SEE LICENSE IN LICENSE",
9
9
  "type": "module",
10
- "version": "3.27.4",
10
+ "version": "3.28.0",
11
11
  "publishConfig": {
12
12
  "access": "public"
13
13
  },
@@ -103,9 +103,9 @@
103
103
  "update-notifier": "^7.3.1",
104
104
  "uuid": "^10.0.0",
105
105
  "zod": "^4.3.6",
106
- "@eventcatalog/linter": "1.0.20",
107
- "@eventcatalog/visualiser": "^3.17.1",
108
- "@eventcatalog/sdk": "2.19.0"
106
+ "@eventcatalog/visualiser": "^3.18.0",
107
+ "@eventcatalog/sdk": "2.20.0",
108
+ "@eventcatalog/linter": "1.0.21"
109
109
  },
110
110
  "devDependencies": {
111
111
  "@astrojs/check": "^0.9.8",