@company-semantics/contracts 13.3.0 → 13.4.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@company-semantics/contracts",
3
- "version": "13.3.0",
3
+ "version": "13.4.0",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
@@ -1,3 +1,3 @@
1
1
  // AUTO-GENERATED — do not edit. Run pnpm generate:spec-hash to regenerate.
2
- export const SPEC_HASH = '4dd221ddc8fd' as const;
3
- export const SPEC_HASH_FULL = '4dd221ddc8fd1a1ff75153543db47c0e2c5a667d1f428e855026a035cdc3b3c6' as const;
2
+ export const SPEC_HASH = '5961c9041966' as const;
3
+ export const SPEC_HASH_FULL = '5961c9041966a739d90bd6f60228167aeccf4c1f28d37a28a924499eb452acd0' as const;
@@ -3843,6 +3843,20 @@ export interface components {
3843
3843
  requiredScope?: string;
3844
3844
  };
3845
3845
  };
3846
+ companyMd?: {
3847
+ transferOwnership: {
3848
+ /** @enum {string} */
3849
+ state: "allowed" | "blocked";
3850
+ requiredScope?: string;
3851
+ };
3852
+ };
3853
+ workItem?: {
3854
+ transferOwnership: {
3855
+ /** @enum {string} */
3856
+ state: "allowed" | "blocked";
3857
+ requiredScope?: string;
3858
+ };
3859
+ };
3846
3860
  };
3847
3861
  };
3848
3862
  CompanyMdListResponse: {
@@ -19,6 +19,10 @@ export type {
19
19
  CompanyMdContextBankResponse,
20
20
  } from "./schemas";
21
21
 
22
+ // Work item response schema (PRD-00763)
23
+ export { WorkItemDetailResponseSchema } from "./schemas";
24
+ export type { WorkItemDetailResponse } from "./schemas";
25
+
22
26
  // Drive response schemas (PRD-00448)
23
27
  export {
24
28
  DriveFileListResponseSchema,
@@ -102,6 +102,35 @@ export const CompanyMdDocResponseSchema = z.object({
102
102
  updatedAt: z.string(),
103
103
  });
104
104
 
105
+ // ---------------------------------------------------------------------------
106
+ // Work Item HTTP Response Schema
107
+ // ---------------------------------------------------------------------------
108
+
109
+ /**
110
+ * Response for GET /api/work-items/:id
111
+ *
112
+ * Models the work-item detail shape the backend returns (id, kind, title,
113
+ * markdown body, free-form metadata, timestamps). Hand-written and independent
114
+ * of the generated OpenAPI surface; the backend adapts to this schema
115
+ * (PRD-00760).
116
+ */
117
+ export const WorkItemDetailResponseSchema = z.object({
118
+ id: z.string(),
119
+ kind: z.enum(["meeting", "comm", "doc"]),
120
+ title: z.string(),
121
+ content: z.string(),
122
+ /**
123
+ * When `true`, `content` is the redacted empty body (`''`) returned to a
124
+ * metadata-only (meta-tier) viewer who administers the work item but may not
125
+ * read its body (ADR-BE-245). Omitted/`false` on the normal full-content
126
+ * path. Keeping it optional preserves back-compat for full-content readers.
127
+ */
128
+ contentRedacted: z.boolean().optional(),
129
+ metadata: z.record(z.string(), z.unknown()),
130
+ createdAt: z.string(),
131
+ updatedAt: z.string(),
132
+ });
133
+
105
134
  // ---------------------------------------------------------------------------
106
135
  // Company.md Sharing Sub-schemas
107
136
  // ---------------------------------------------------------------------------
@@ -207,6 +236,9 @@ export type CompanyMdShareResponse = z.infer<
207
236
  export type CompanyMdContextBankResponse = z.infer<
208
237
  typeof CompanyMdContextBankResponseSchema
209
238
  >;
239
+ export type WorkItemDetailResponse = z.infer<
240
+ typeof WorkItemDetailResponseSchema
241
+ >;
210
242
  export type DriveFileListResponse = z.infer<typeof DriveFileListResponseSchema>;
211
243
  export type DriveFileContentResponse = z.infer<
212
244
  typeof DriveFileContentResponseSchema
@@ -16,6 +16,8 @@ export {
16
16
  RecordingEventSchema,
17
17
  TranscriptionSessionGrantSchema,
18
18
  MeetingMetadataProjectionSchema,
19
+ MeetingExportFormatSchema,
20
+ MeetingExportResponseSchema,
19
21
  } from "./schemas";
20
22
 
21
23
  export type {
@@ -31,4 +33,6 @@ export type {
31
33
  RecordingEvent,
32
34
  TranscriptionSessionGrant,
33
35
  MeetingMetadataProjection,
36
+ MeetingExportFormat,
37
+ MeetingExportResponse,
34
38
  } from "./schemas";
@@ -291,3 +291,50 @@ export const MeetingMetadataProjectionSchema = z
291
291
  export type MeetingMetadataProjection = z.infer<
292
292
  typeof MeetingMetadataProjectionSchema
293
293
  >;
294
+
295
+ // =============================================================================
296
+ // Meeting export response (HTTP read model)
297
+ // =============================================================================
298
+
299
+ /**
300
+ * Export format the backend renders a finalized meeting transcript into.
301
+ * `markdown`/`text` are prose bodies; `vtt`/`srt` are timed-caption formats;
302
+ * `json` is the structured segment payload.
303
+ */
304
+ export const MeetingExportFormatSchema = z
305
+ .enum(["markdown", "text", "vtt", "srt", "json"])
306
+ .meta({
307
+ description: "Rendered export format for a finalized meeting transcript.",
308
+ });
309
+ export type MeetingExportFormat = z.infer<typeof MeetingExportFormatSchema>;
310
+
311
+ /**
312
+ * Response for the meeting-export endpoint. Models the rendered export the
313
+ * backend returns for a finalized recording: the chosen `format`, the rendered
314
+ * `content` body, and the `segments` the export was assembled from. Hand-written
315
+ * and independent of the generated OpenAPI surface; the backend adapts to this
316
+ * schema (PRD-00763).
317
+ *
318
+ * Mirrors the meta-tier redaction contract of `WorkItemDetailResponseSchema`
319
+ * and `CompanyMdDocResponseSchema`.
320
+ */
321
+ export const MeetingExportResponseSchema = z
322
+ .object({
323
+ recordingId: RecordingIdSchema,
324
+ format: MeetingExportFormatSchema,
325
+ content: z.string(),
326
+ /**
327
+ * When `true`, `content` is the redacted empty body (`''`) returned to a
328
+ * metadata-only (meta-tier) viewer who administers the meeting but may not
329
+ * read its transcript body (ADR-BE-245). Omitted/`false` on the normal
330
+ * full-content path. Keeping it optional preserves back-compat for
331
+ * full-content readers.
332
+ */
333
+ contentRedacted: z.boolean().optional(),
334
+ segments: z.array(SourceSegmentSchema),
335
+ })
336
+ .meta({
337
+ description:
338
+ "Rendered meeting-transcript export (format, content, segments) with optional meta-tier redaction flag.",
339
+ });
340
+ export type MeetingExportResponse = z.infer<typeof MeetingExportResponseSchema>;