@vev-software/atlas-contracts 0.1.3 → 0.1.4

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/dist/index.d.ts CHANGED
@@ -201,12 +201,19 @@ export interface Observation {
201
201
  * The public wire format a discovery scanner emits into Atlas: a batch of raw observations that
202
202
  * the private Atlas Enterprise reconciliation engine turns into catalogue assets.
203
203
  */
204
+ export interface ObservedRelationship {
205
+ fromObservedId: string;
206
+ toObservedId: string;
207
+ type: RelationshipType;
208
+ description?: string | null;
209
+ }
204
210
  export interface DiscoveryObservationBatch {
205
211
  contractVersion: typeof CONTRACT_VERSION;
206
212
  kind: "discovery-observation";
207
213
  source: ObservationSource;
208
214
  observedAt: string;
209
215
  observations: Observation[];
216
+ relationships?: ObservedRelationship[];
210
217
  }
211
218
  /** The layout format of a `Diagram`. */
212
219
  export type DiagramFormat = "atlas-layout";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vev-software/atlas-contracts",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "Public, versioned data model and interop contracts for VEV Atlas — the catalogue asset model plus manual relationships, tags and the landscape import/export document.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
@@ -31,9 +31,41 @@
31
31
  "description": "The raw observations in this batch. May be empty (a scan that saw nothing new).",
32
32
  "items": { "$ref": "#/$defs/Observation" },
33
33
  "default": []
34
+ },
35
+ "relationships": {
36
+ "type": "array",
37
+ "description": "Observed relationships between the things in this batch, referenced by their observedId — e.g. a foreign key (joins-on) or data-layer containment (part-of). Optional and defaults to empty, so a scanner that emits none stays valid. Held facts only; the private reconciler resolves the observedId endpoints to catalogue assets.",
38
+ "items": { "$ref": "#/$defs/ObservedRelationship" },
39
+ "default": []
34
40
  }
35
41
  },
36
42
  "$defs": {
43
+ "ObservedRelationship": {
44
+ "type": "object",
45
+ "description": "A relationship between two observed things, by observedId. NOT an Atlas relationship (no asset ids); the reconciler resolves endpoints and re-expresses it in the catalogue.",
46
+ "additionalProperties": false,
47
+ "required": ["fromObservedId", "toObservedId", "type"],
48
+ "properties": {
49
+ "fromObservedId": {
50
+ "type": "string",
51
+ "description": "The referencing observation's observedId.",
52
+ "minLength": 1,
53
+ "maxLength": 256
54
+ },
55
+ "toObservedId": {
56
+ "type": "string",
57
+ "description": "The referenced observation's observedId.",
58
+ "minLength": 1,
59
+ "maxLength": 256
60
+ },
61
+ "type": {
62
+ "type": "string",
63
+ "description": "The held relationship vocabulary. Mirrors relationship.schema.json.",
64
+ "enum": ["runs-on", "hosts", "connects-to", "depends-on", "part-of", "joins-on"]
65
+ },
66
+ "description": { "type": ["string", "null"], "maxLength": 1024 }
67
+ }
68
+ },
37
69
  "ObservationSource": {
38
70
  "type": "object",
39
71
  "description": "Which scanner produced the batch. The authoritative tenant binding is the authenticated machine-principal at ingestion (a Fabric concern), NOT this payload; 'tenantRef' is an optional, opaque hint only.",