@bli-cockpit/telemetry-core 0.1.8 → 0.1.9

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.
@@ -1,4 +1,16 @@
1
1
  import { z } from "zod";
2
+ export declare const WorktreeInventoryItemSchema: z.ZodObject<{
3
+ repo: z.ZodString;
4
+ repo_label: z.ZodOptional<z.ZodString>;
5
+ repo_fingerprint: z.ZodOptional<z.ZodString>;
6
+ repo_origin_url: z.ZodOptional<z.ZodString>;
7
+ head_sha: z.ZodOptional<z.ZodString>;
8
+ worktree_label: z.ZodOptional<z.ZodString>;
9
+ worktree_fingerprint: z.ZodString;
10
+ worktree_is_primary: z.ZodOptional<z.ZodBoolean>;
11
+ branch: z.ZodOptional<z.ZodString>;
12
+ }, z.core.$strict>;
13
+ export type WorktreeInventoryItem = z.infer<typeof WorktreeInventoryItemSchema>;
2
14
  export declare const TelemetryEventTypeSchema: z.ZodEnum<{
3
15
  session_started: "session_started";
4
16
  session_ended: "session_ended";
@@ -475,6 +487,17 @@ export declare const TelemetryIngestEnvelopeSchema: z.ZodObject<{
475
487
  work_context_id: z.ZodString;
476
488
  }, z.core.$strict>>;
477
489
  }, z.core.$strict>;
490
+ worktree_inventory: z.ZodDefault<z.ZodArray<z.ZodObject<{
491
+ repo: z.ZodString;
492
+ repo_label: z.ZodOptional<z.ZodString>;
493
+ repo_fingerprint: z.ZodOptional<z.ZodString>;
494
+ repo_origin_url: z.ZodOptional<z.ZodString>;
495
+ head_sha: z.ZodOptional<z.ZodString>;
496
+ worktree_label: z.ZodOptional<z.ZodString>;
497
+ worktree_fingerprint: z.ZodString;
498
+ worktree_is_primary: z.ZodOptional<z.ZodBoolean>;
499
+ branch: z.ZodOptional<z.ZodString>;
500
+ }, z.core.$strict>>>;
478
501
  events: z.ZodArray<z.ZodObject<{
479
502
  event_id: z.ZodString;
480
503
  event_type: z.ZodEnum<{
@@ -7,6 +7,19 @@ import { SourceScanResultSchema } from "./source-adapter.js";
7
7
  import { ExternalTraceSinkPointerSchema, NormalizedOtelTelemetrySchema, } from "./trace-sink.js";
8
8
  import { EvidenceCompletenessPayloadSchema } from "./evidence-completeness.js";
9
9
  import { LocalWorkContextSchema, TicketBindingCandidateSchema, } from "./work-context.js";
10
+ export const WorktreeInventoryItemSchema = z
11
+ .object({
12
+ repo: NonEmptyStringSchema,
13
+ repo_label: NonEmptyStringSchema.optional(),
14
+ repo_fingerprint: NonEmptyStringSchema.optional(),
15
+ repo_origin_url: NonEmptyStringSchema.optional(),
16
+ head_sha: NonEmptyStringSchema.optional(),
17
+ worktree_label: NonEmptyStringSchema.optional(),
18
+ worktree_fingerprint: NonEmptyStringSchema,
19
+ worktree_is_primary: z.boolean().optional(),
20
+ branch: NonEmptyStringSchema.optional(),
21
+ })
22
+ .strict();
10
23
  export const TelemetryEventTypeSchema = z.enum([
11
24
  "session_started",
12
25
  "session_ended",
@@ -83,6 +96,7 @@ export const TelemetryIngestEnvelopeSchema = z
83
96
  collector_version: NonEmptyStringSchema,
84
97
  session_reference: LocalUserSessionReferenceSchema,
85
98
  work_context: LocalWorkContextSchema,
99
+ worktree_inventory: z.array(WorktreeInventoryItemSchema).default([]),
86
100
  events: z.array(TelemetryIngestEventDtoSchema).min(1),
87
101
  source_scan_results: z.array(SourceScanResultSchema).default([]),
88
102
  })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bli-cockpit/telemetry-core",
3
- "version": "0.1.8",
3
+ "version": "0.1.9",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",