@cclabsnz/sf-core 0.1.1 → 0.1.3
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.
package/lib/schemas/index.d.ts
CHANGED
|
@@ -15,6 +15,15 @@ export interface CouplingGraphProvenance {
|
|
|
15
15
|
*/
|
|
16
16
|
evidenceTier: EvidenceTier | null;
|
|
17
17
|
}
|
|
18
|
+
/**
|
|
19
|
+
* Architectural layer of an object, ordered from the business core outwards.
|
|
20
|
+
*
|
|
21
|
+
* A real org's coupling graph is dominated by objects carrying no business process — identity,
|
|
22
|
+
* logging, custom metadata — because Apex references them constantly. The layer lets a consumer
|
|
23
|
+
* separate those without reimplementing the classifier, and without discarding them: on a
|
|
24
|
+
* production org, business-to-security was the second-heaviest relationship in the graph.
|
|
25
|
+
*/
|
|
26
|
+
export type ObjectLayer = 'integration' | 'configuration' | 'business' | 'content' | 'sharing' | 'security' | 'observability';
|
|
18
27
|
export interface CouplingGraphNode {
|
|
19
28
|
object: string;
|
|
20
29
|
custom: boolean;
|
|
@@ -24,18 +33,32 @@ export interface CouplingGraphNode {
|
|
|
24
33
|
approvals: number;
|
|
25
34
|
};
|
|
26
35
|
recordCount90d: number;
|
|
36
|
+
/** Optional for back-compatibility; current emitters always set it. */
|
|
37
|
+
layer?: ObjectLayer;
|
|
27
38
|
}
|
|
28
39
|
export interface CouplingComponentRef {
|
|
29
40
|
type: string;
|
|
30
41
|
name: string;
|
|
31
42
|
confidence: CouplingConfidence;
|
|
32
43
|
}
|
|
44
|
+
/**
|
|
45
|
+
* Which way a directional coupling runs, relative to the canonical `from`/`to` pair.
|
|
46
|
+
*
|
|
47
|
+
* Recorded as evidence *about* the pair rather than by reordering it, so a consumer that only
|
|
48
|
+
* cares about coupling is unaffected while one reconstructing process order can follow it.
|
|
49
|
+
*/
|
|
50
|
+
export type CouplingDirection = 'from-to' | 'to-from' | 'both';
|
|
33
51
|
export interface CouplingGraphEdge {
|
|
34
52
|
from: string;
|
|
35
53
|
to: string;
|
|
36
54
|
weight: number;
|
|
37
55
|
operations: CouplingOperation[];
|
|
38
56
|
components: CouplingComponentRef[];
|
|
57
|
+
/**
|
|
58
|
+
* Process order where a record-triggered flow or Apex trigger established it. Absent means
|
|
59
|
+
* no directional evidence was found, which is not the same as the coupling being undirected.
|
|
60
|
+
*/
|
|
61
|
+
direction?: CouplingDirection;
|
|
39
62
|
}
|
|
40
63
|
export interface CouplingGraph {
|
|
41
64
|
version: 1;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cclabsnz/sf-core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "Shared platform layer for CloudCounsel Salesforce sf plugins \u2014 API clients, org context, event log pull, report shell, and versioned IR schemas.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -32,6 +32,7 @@
|
|
|
32
32
|
"@jest/globals": "^29.7.0",
|
|
33
33
|
"@types/jest": "^29",
|
|
34
34
|
"@types/node": "^22",
|
|
35
|
+
"ajv": "^8",
|
|
35
36
|
"jest": "^29",
|
|
36
37
|
"ts-jest": "^29",
|
|
37
38
|
"ts-node": "^10.9.2",
|
|
@@ -99,6 +99,19 @@
|
|
|
99
99
|
"recordCount90d": {
|
|
100
100
|
"type": "integer",
|
|
101
101
|
"minimum": 0
|
|
102
|
+
},
|
|
103
|
+
"layer": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"enum": [
|
|
106
|
+
"integration",
|
|
107
|
+
"configuration",
|
|
108
|
+
"business",
|
|
109
|
+
"content",
|
|
110
|
+
"sharing",
|
|
111
|
+
"security",
|
|
112
|
+
"observability"
|
|
113
|
+
],
|
|
114
|
+
"description": "Architectural layer, ordered from the business core outwards. Optional for back-compatibility with documents emitted before the field existed; current emitters always set it."
|
|
102
115
|
}
|
|
103
116
|
}
|
|
104
117
|
}
|
|
@@ -164,6 +177,15 @@
|
|
|
164
177
|
}
|
|
165
178
|
}
|
|
166
179
|
}
|
|
180
|
+
},
|
|
181
|
+
"direction": {
|
|
182
|
+
"type": "string",
|
|
183
|
+
"enum": [
|
|
184
|
+
"from-to",
|
|
185
|
+
"to-from",
|
|
186
|
+
"both"
|
|
187
|
+
],
|
|
188
|
+
"description": "Process order, where a record-triggered flow or Apex trigger established it: which of the pair acts on the other. Absent means no directional evidence \u2014 not the same as undirected."
|
|
167
189
|
}
|
|
168
190
|
}
|
|
169
191
|
}
|