@useairfoil/producer-linear 0.0.2 → 0.0.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.
@@ -91,7 +91,6 @@ const layer$1 = (config) => Layer.effect(LinearClient)(make$1(config));
91
91
  const layerConfig$1 = (config) => Layer.unwrap(Config.unwrap(config).pipe(Effect.map(layer$1)));
92
92
  //#endregion
93
93
  //#region src/schemas/shared.ts
94
- const field = (fieldId, description) => Iceberg.field(fieldId, { description });
95
94
  const Timestamp = Schema.DateFromString;
96
95
  /** Decodes a GraphQL Int as bigint for an Iceberg long. */
97
96
  const Long = Schema.Int.pipe(Schema.decodeTo(Schema.BigInt, SchemaTransformation.transform({
@@ -106,42 +105,40 @@ const Ref = Schema.Struct({ id: Schema.String }).pipe(Schema.decodeTo(Schema.Str
106
105
  const OptionalRef = Schema.NullOr(Ref);
107
106
  const OptionalTimestamp = Schema.NullOr(Timestamp);
108
107
  const OptionalString = Schema.NullOr(Schema.String);
109
- const RefConnection = Schema.Struct({ nodes: Schema.Array(Schema.Struct({ id: Schema.String })) });
110
108
  /** Decodes connection nodes as IDs. The query must fetch any extra pages. */
111
- const RefList = (elementId) => RefConnection.pipe(Schema.decodeTo(Schema.Array(Schema.String.annotate({ fieldId: elementId })), SchemaTransformation.transform({
109
+ const RefList = Schema.Struct({ nodes: Schema.Array(Schema.Struct({ id: Schema.String })) }).pipe(Schema.decodeTo(Schema.Array(Schema.String), SchemaTransformation.transform({
112
110
  decode: (connection) => connection.nodes.map((node) => node.id),
113
111
  encode: (ids) => ({ nodes: ids.map((id) => ({ id })) })
114
112
  })));
115
- const list = (elementId, item) => Schema.Array(item.annotate({ fieldId: elementId }));
116
113
  /** Rows use updated_at as version; lifecycle webhooks use the webhook time. */
117
114
  const common = (object) => ({
118
- id: Schema.String.pipe(field(1, `${object} ID.`)),
119
- version: Schema.Date.pipe(field(2, `Time Linear last changed the ${object.toLowerCase()}.`)),
120
- created_at: Timestamp.pipe(field(3, `Time the ${object.toLowerCase()} was created.`)),
121
- updated_at: Timestamp.pipe(field(4, `Time the ${object.toLowerCase()} was last updated.`)),
122
- archived_at: Schema.NullOr(Timestamp).pipe(field(5, `Time the ${object.toLowerCase()} was archived or trashed.`))
115
+ id: Schema.String.pipe(Schema.annotateKey({ description: `${object} ID.` })),
116
+ version: Schema.Date.pipe(Schema.annotateKey({ description: `Time Linear last changed the ${object.toLowerCase()}.` })),
117
+ created_at: Timestamp.pipe(Schema.annotateKey({ description: `Time the ${object.toLowerCase()} was created.` })),
118
+ updated_at: Timestamp.pipe(Schema.annotateKey({ description: `Time the ${object.toLowerCase()} was last updated.` })),
119
+ archived_at: Schema.NullOr(Timestamp).pipe(Schema.annotateKey({ description: `Time the ${object.toLowerCase()} was archived or trashed.` }))
123
120
  });
124
- const deleted = (object) => Schema.optional(Schema.Boolean).pipe(field(6, `Whether the ${object} was deleted in Linear.`));
121
+ const deleted = (object) => Schema.optional(Schema.Boolean).pipe(Schema.annotateKey({ description: `Whether the ${object} was deleted in Linear.` }));
125
122
  //#endregion
126
123
  //#region src/schemas/comments.ts
127
124
  const CommentSchema = Schema.Struct({
128
125
  ...common("Comment"),
129
126
  _deleted: deleted("comment"),
130
- body: Schema.String.pipe(field(10, "Comment text in markdown.")),
131
- user_id: OptionalRef.pipe(field(11, "User who wrote the comment.")),
132
- external_user_id: OptionalRef.pipe(field(12, "External user who wrote the comment.")),
133
- issue_id: OptionalString.pipe(field(13, "Issue the comment is on.")),
134
- project_id: OptionalString.pipe(field(14, "Project the comment is on.")),
135
- project_update_id: OptionalString.pipe(field(15, "Project update the comment is on.")),
136
- initiative_id: OptionalString.pipe(field(16, "Initiative the comment is on.")),
137
- initiative_update_id: OptionalString.pipe(field(17, "Initiative update the comment is on.")),
138
- document_content_id: OptionalString.pipe(field(18, "Document content the comment is on.")),
139
- parent_id: OptionalString.pipe(field(19, "Comment this one replies to.")),
140
- quoted_text: OptionalString.pipe(field(20, "Text the comment quotes.")),
141
- edited_at: OptionalTimestamp.pipe(field(21, "Time the comment was last edited.")),
142
- resolved_at: OptionalTimestamp.pipe(field(22, "Time the thread was resolved.")),
143
- resolving_user_id: OptionalRef.pipe(field(23, "User who resolved the thread.")),
144
- url: Schema.String.pipe(field(24, "Comment URL."))
127
+ body: Schema.String.pipe(Schema.annotateKey({ description: "Comment text in markdown." })),
128
+ user_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who wrote the comment." })),
129
+ external_user_id: OptionalRef.pipe(Schema.annotateKey({ description: "External user who wrote the comment." })),
130
+ issue_id: OptionalString.pipe(Schema.annotateKey({ description: "Issue the comment is on." })),
131
+ project_id: OptionalString.pipe(Schema.annotateKey({ description: "Project the comment is on." })),
132
+ project_update_id: OptionalString.pipe(Schema.annotateKey({ description: "Project update the comment is on." })),
133
+ initiative_id: OptionalString.pipe(Schema.annotateKey({ description: "Initiative the comment is on." })),
134
+ initiative_update_id: OptionalString.pipe(Schema.annotateKey({ description: "Initiative update the comment is on." })),
135
+ document_content_id: OptionalString.pipe(Schema.annotateKey({ description: "Document content the comment is on." })),
136
+ parent_id: OptionalString.pipe(Schema.annotateKey({ description: "Comment this one replies to." })),
137
+ quoted_text: OptionalString.pipe(Schema.annotateKey({ description: "Text the comment quotes." })),
138
+ edited_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the comment was last edited." })),
139
+ resolved_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the thread was resolved." })),
140
+ resolving_user_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who resolved the thread." })),
141
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Comment URL." }))
145
142
  }).annotate({ description: "Linear comments on issues, projects, initiatives, and updates." }).pipe(Iceberg.identifier("id"));
146
143
  const CommentObjectSchema = CommentSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
147
144
  //#endregion
@@ -344,41 +341,41 @@ const makeComments = (client) => Resource.entity({
344
341
  const CustomerSchema = Schema.Struct({
345
342
  ...common("Customer"),
346
343
  _deleted: deleted("customer"),
347
- name: Schema.String.pipe(field(10, "Customer name.")),
348
- domains: list(101, Schema.String).pipe(field(11, "Email domains of the customer.")),
349
- external_ids: list(102, Schema.String).pipe(field(12, "IDs in other systems.")),
350
- logo_url: OptionalString.pipe(field(13, "Logo URL.")),
351
- owner_id: OptionalRef.pipe(field(14, "User who owns the customer.")),
352
- status_id: Ref.pipe(field(15, "Customer status.")),
353
- tier_id: OptionalRef.pipe(field(16, "Customer tier.")),
354
- revenue: Schema.NullOr(Long).pipe(field(17, "Annual revenue.")),
355
- size: Schema.NullOr(Schema.Finite).pipe(field(18, "Company size.")),
356
- approximate_need_count: Schema.Finite.pipe(field(19, "About how many requests it has.")),
357
- url: Schema.String.pipe(field(20, "Customer URL."))
344
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Customer name." })),
345
+ domains: Schema.Array(Schema.String).pipe(Schema.annotateKey({ description: "Email domains of the customer." })),
346
+ external_ids: Schema.Array(Schema.String).pipe(Schema.annotateKey({ description: "IDs in other systems." })),
347
+ logo_url: OptionalString.pipe(Schema.annotateKey({ description: "Logo URL." })),
348
+ owner_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who owns the customer." })),
349
+ status_id: Ref.pipe(Schema.annotateKey({ description: "Customer status." })),
350
+ tier_id: OptionalRef.pipe(Schema.annotateKey({ description: "Customer tier." })),
351
+ revenue: Schema.NullOr(Long).pipe(Schema.annotateKey({ description: "Annual revenue." })),
352
+ size: Schema.NullOr(Schema.Finite).pipe(Schema.annotateKey({ description: "Company size." })),
353
+ approximate_need_count: Schema.Finite.pipe(Schema.annotateKey({ description: "About how many requests it has." })),
354
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Customer URL." }))
358
355
  }).annotate({ description: "Linear customers." }).pipe(Iceberg.identifier("id"));
359
356
  const CustomerObjectSchema = CustomerSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
360
357
  const CustomerNeedSchema = Schema.Struct({
361
358
  ...common("Request"),
362
359
  _deleted: deleted("request"),
363
- customer_id: OptionalRef.pipe(field(10, "Customer.")),
364
- issue_id: OptionalRef.pipe(field(11, "Issue the request is linked to.")),
365
- project_id: OptionalRef.pipe(field(12, "Project the request is linked to.")),
366
- original_issue_id: OptionalRef.pipe(field(13, "Issue the request was first linked to.")),
367
- comment_id: OptionalRef.pipe(field(14, "Comment the request came from.")),
368
- attachment_id: OptionalRef.pipe(field(15, "Attachment the request came from.")),
369
- creator_id: OptionalRef.pipe(field(16, "User who added the request.")),
370
- body: OptionalString.pipe(field(17, "Request text in markdown.")),
371
- priority: Schema.Finite.pipe(field(18, "0 normal, 1 important.")),
372
- url: OptionalString.pipe(field(19, "Source URL."))
360
+ customer_id: OptionalRef.pipe(Schema.annotateKey({ description: "Customer." })),
361
+ issue_id: OptionalRef.pipe(Schema.annotateKey({ description: "Issue the request is linked to." })),
362
+ project_id: OptionalRef.pipe(Schema.annotateKey({ description: "Project the request is linked to." })),
363
+ original_issue_id: OptionalRef.pipe(Schema.annotateKey({ description: "Issue the request was first linked to." })),
364
+ comment_id: OptionalRef.pipe(Schema.annotateKey({ description: "Comment the request came from." })),
365
+ attachment_id: OptionalRef.pipe(Schema.annotateKey({ description: "Attachment the request came from." })),
366
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who added the request." })),
367
+ body: OptionalString.pipe(Schema.annotateKey({ description: "Request text in markdown." })),
368
+ priority: Schema.Finite.pipe(Schema.annotateKey({ description: "0 normal, 1 important." })),
369
+ url: OptionalString.pipe(Schema.annotateKey({ description: "Source URL." }))
373
370
  }).annotate({ description: "Linear customer requests, linked to issues or projects." }).pipe(Iceberg.identifier("id"));
374
371
  const CustomerNeedObjectSchema = CustomerNeedSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
375
372
  const levelFields$1 = (object) => ({
376
373
  ...common(object),
377
- name: Schema.String.pipe(field(10, "Name.")),
378
- display_name: Schema.String.pipe(field(11, "Name shown in Linear.")),
379
- description: OptionalString.pipe(field(12, "Description.")),
380
- color: Schema.String.pipe(field(13, "Color, as hex.")),
381
- position: Schema.Finite.pipe(field(14, "Order in the list."))
374
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Name." })),
375
+ display_name: Schema.String.pipe(Schema.annotateKey({ description: "Name shown in Linear." })),
376
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Description." })),
377
+ color: Schema.String.pipe(Schema.annotateKey({ description: "Color, as hex." })),
378
+ position: Schema.Finite.pipe(Schema.annotateKey({ description: "Order in the list." }))
382
379
  });
383
380
  const CustomerStatusSchema = Schema.Struct(levelFields$1("Status")).annotate({ description: "Linear customer statuses. Names the IDs in `customers.status_id`." }).pipe(Iceberg.identifier("id"));
384
381
  const CustomerStatusObjectSchema = CustomerStatusSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
@@ -472,21 +469,21 @@ const makeCustomerTiers = (client) => Resource.entity({
472
469
  const DocumentSchema = Schema.Struct({
473
470
  ...common("Document"),
474
471
  _deleted: deleted("document"),
475
- title: Schema.String.pipe(field(10, "Title.")),
476
- content: OptionalString.pipe(field(11, "Content in markdown.")),
477
- url: Schema.String.pipe(field(12, "Document URL.")),
478
- icon: OptionalString.pipe(field(13, "Icon.")),
479
- color: OptionalString.pipe(field(14, "Icon color.")),
480
- creator_id: OptionalRef.pipe(field(15, "User who made the document.")),
481
- updated_by_id: OptionalRef.pipe(field(16, "User who last changed the document.")),
482
- project_id: OptionalRef.pipe(field(17, "Project the document is in.")),
483
- initiative_id: OptionalRef.pipe(field(18, "Initiative the document is in.")),
484
- issue_id: OptionalRef.pipe(field(19, "Issue the document is in.")),
485
- cycle_id: OptionalRef.pipe(field(20, "Cycle the document is in.")),
486
- team_id: OptionalRef.pipe(field(21, "Team the document is in.")),
487
- parent_document_id: OptionalRef.pipe(field(22, "Parent document.")),
488
- hidden_at: OptionalTimestamp.pipe(field(23, "Time the document was hidden.")),
489
- trashed: Schema.NullOr(Schema.Boolean).pipe(field(24, "Whether the document is in the trash."))
472
+ title: Schema.String.pipe(Schema.annotateKey({ description: "Title." })),
473
+ content: OptionalString.pipe(Schema.annotateKey({ description: "Content in markdown." })),
474
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Document URL." })),
475
+ icon: OptionalString.pipe(Schema.annotateKey({ description: "Icon." })),
476
+ color: OptionalString.pipe(Schema.annotateKey({ description: "Icon color." })),
477
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the document." })),
478
+ updated_by_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who last changed the document." })),
479
+ project_id: OptionalRef.pipe(Schema.annotateKey({ description: "Project the document is in." })),
480
+ initiative_id: OptionalRef.pipe(Schema.annotateKey({ description: "Initiative the document is in." })),
481
+ issue_id: OptionalRef.pipe(Schema.annotateKey({ description: "Issue the document is in." })),
482
+ cycle_id: OptionalRef.pipe(Schema.annotateKey({ description: "Cycle the document is in." })),
483
+ team_id: OptionalRef.pipe(Schema.annotateKey({ description: "Team the document is in." })),
484
+ parent_document_id: OptionalRef.pipe(Schema.annotateKey({ description: "Parent document." })),
485
+ hidden_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the document was hidden." })),
486
+ trashed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the document is in the trash." }))
490
487
  }).annotate({ description: "Linear documents, including archived and trashed ones." }).pipe(Iceberg.identifier("id"));
491
488
  //#endregion
492
489
  //#region src/resources/documents.ts
@@ -520,64 +517,64 @@ const makeDocuments = (client) => Resource.entity({
520
517
  const InitiativeSchema = Schema.Struct({
521
518
  ...common("Initiative"),
522
519
  _deleted: deleted("initiative"),
523
- name: Schema.String.pipe(field(10, "Initiative name.")),
524
- description: OptionalString.pipe(field(11, "Short summary.")),
525
- content: OptionalString.pipe(field(12, "Initiative overview in markdown.")),
526
- url: Schema.String.pipe(field(13, "Initiative URL.")),
527
- icon: OptionalString.pipe(field(14, "Icon.")),
528
- color: OptionalString.pipe(field(15, "Color, as hex.")),
529
- status: Schema.String.pipe(field(16, "Status: Planned, Active, or Completed.")),
530
- health: OptionalString.pipe(field(17, "Health from the latest update.")),
531
- health_updated_at: OptionalTimestamp.pipe(field(18, "Time the health last changed.")),
532
- priority: Long.pipe(field(19, "0 none, 1 urgent, 2 high, 3 medium, 4 low.")),
533
- owner_id: OptionalRef.pipe(field(20, "Initiative owner.")),
534
- creator_id: OptionalRef.pipe(field(21, "User who made the initiative.")),
535
- parent_initiative_id: OptionalRef.pipe(field(22, "Parent initiative.")),
536
- target_date: OptionalString.pipe(field(23, "Target date, as YYYY-MM-DD.")),
537
- started_at: OptionalTimestamp.pipe(field(24, "Time the initiative started.")),
538
- completed_at: OptionalTimestamp.pipe(field(25, "Time the initiative was completed.")),
539
- canceled_at: OptionalTimestamp.pipe(field(26, "Time the initiative was canceled.")),
540
- label_ids: list(101, Schema.String).pipe(field(27, "Initiative labels.")),
541
- visibility: Schema.String.pipe(field(28, "Who can see the initiative.")),
542
- trashed: Schema.NullOr(Schema.Boolean).pipe(field(29, "Whether the initiative is in the trash."))
520
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Initiative name." })),
521
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Short summary." })),
522
+ content: OptionalString.pipe(Schema.annotateKey({ description: "Initiative overview in markdown." })),
523
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Initiative URL." })),
524
+ icon: OptionalString.pipe(Schema.annotateKey({ description: "Icon." })),
525
+ color: OptionalString.pipe(Schema.annotateKey({ description: "Color, as hex." })),
526
+ status: Schema.String.pipe(Schema.annotateKey({ description: "Status: Planned, Active, or Completed." })),
527
+ health: OptionalString.pipe(Schema.annotateKey({ description: "Health from the latest update." })),
528
+ health_updated_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the health last changed." })),
529
+ priority: Long.pipe(Schema.annotateKey({ description: "0 none, 1 urgent, 2 high, 3 medium, 4 low." })),
530
+ owner_id: OptionalRef.pipe(Schema.annotateKey({ description: "Initiative owner." })),
531
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the initiative." })),
532
+ parent_initiative_id: OptionalRef.pipe(Schema.annotateKey({ description: "Parent initiative." })),
533
+ target_date: OptionalString.pipe(Schema.annotateKey({ description: "Target date, as YYYY-MM-DD." })),
534
+ started_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the initiative started." })),
535
+ completed_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the initiative was completed." })),
536
+ canceled_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the initiative was canceled." })),
537
+ label_ids: Schema.Array(Schema.String).pipe(Schema.annotateKey({ description: "Initiative labels." })),
538
+ visibility: Schema.String.pipe(Schema.annotateKey({ description: "Who can see the initiative." })),
539
+ trashed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the initiative is in the trash." }))
543
540
  }).annotate({ description: "Linear initiatives, including archived and trashed ones." }).pipe(Iceberg.identifier("id"));
544
541
  const InitiativeObjectSchema = InitiativeSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
545
542
  const InitiativeUpdateSchema = Schema.Struct({
546
543
  ...common("Update"),
547
544
  _deleted: deleted("update"),
548
- initiative_id: Ref.pipe(field(10, "Initiative.")),
549
- user_id: Ref.pipe(field(11, "User who posted the update.")),
550
- body: Schema.String.pipe(field(12, "Update text in markdown.")),
551
- health: Schema.String.pipe(field(13, "Health: onTrack, atRisk, or offTrack.")),
552
- url: Schema.String.pipe(field(14, "Update URL.")),
553
- edited_at: OptionalTimestamp.pipe(field(15, "Time the update was last edited.")),
554
- comment_count: Long.pipe(field(16, "Comments on the update."))
545
+ initiative_id: Ref.pipe(Schema.annotateKey({ description: "Initiative." })),
546
+ user_id: Ref.pipe(Schema.annotateKey({ description: "User who posted the update." })),
547
+ body: Schema.String.pipe(Schema.annotateKey({ description: "Update text in markdown." })),
548
+ health: Schema.String.pipe(Schema.annotateKey({ description: "Health: onTrack, atRisk, or offTrack." })),
549
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Update URL." })),
550
+ edited_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the update was last edited." })),
551
+ comment_count: Long.pipe(Schema.annotateKey({ description: "Comments on the update." }))
555
552
  }).annotate({ description: "Linear initiative updates: status posts with a health." }).pipe(Iceberg.identifier("id"));
556
553
  const InitiativeUpdateObjectSchema = InitiativeUpdateSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
557
554
  const InitiativeLabelSchema = Schema.Struct({
558
555
  ...common("Label"),
559
- name: Schema.String.pipe(field(10, "Label name.")),
560
- description: OptionalString.pipe(field(11, "Label description.")),
561
- color: Schema.String.pipe(field(12, "Label color, as hex.")),
562
- is_group: Schema.Boolean.pipe(field(13, "Whether the label groups other labels.")),
563
- parent_id: OptionalRef.pipe(field(14, "Label group.")),
564
- creator_id: OptionalRef.pipe(field(15, "User who made the label.")),
565
- retired_at: OptionalTimestamp.pipe(field(16, "Time the label was retired."))
556
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Label name." })),
557
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Label description." })),
558
+ color: Schema.String.pipe(Schema.annotateKey({ description: "Label color, as hex." })),
559
+ is_group: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the label groups other labels." })),
560
+ parent_id: OptionalRef.pipe(Schema.annotateKey({ description: "Label group." })),
561
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the label." })),
562
+ retired_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the label was retired." }))
566
563
  }).annotate({ description: "Linear initiative labels. Names the IDs in `initiatives.label_ids`." }).pipe(Iceberg.identifier("id"));
567
564
  const InitiativeLabelObjectSchema = InitiativeLabelSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
568
565
  const InitiativeRelationSchema = Schema.Struct({
569
566
  ...common("Relation"),
570
- initiative_id: Ref.pipe(field(10, "Initiative the relation starts from.")),
571
- related_initiative_id: Ref.pipe(field(11, "Related initiative.")),
572
- sort_order: Schema.Finite.pipe(field(12, "Order.")),
573
- user_id: OptionalRef.pipe(field(13, "User who made the relation."))
567
+ initiative_id: Ref.pipe(Schema.annotateKey({ description: "Initiative the relation starts from." })),
568
+ related_initiative_id: Ref.pipe(Schema.annotateKey({ description: "Related initiative." })),
569
+ sort_order: Schema.Finite.pipe(Schema.annotateKey({ description: "Order." })),
570
+ user_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the relation." }))
574
571
  }).annotate({ description: "Linear initiative relations. Deleted relations aren't seen." }).pipe(Iceberg.identifier("id"));
575
572
  const InitiativeRelationObjectSchema = InitiativeRelationSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
576
573
  const InitiativeToProjectSchema = Schema.Struct({
577
574
  ...common("Link"),
578
- initiative_id: Ref.pipe(field(10, "Initiative.")),
579
- project_id: Ref.pipe(field(11, "Project.")),
580
- sort_order: Schema.String.pipe(field(12, "Order within the initiative."))
575
+ initiative_id: Ref.pipe(Schema.annotateKey({ description: "Initiative." })),
576
+ project_id: Ref.pipe(Schema.annotateKey({ description: "Project." })),
577
+ sort_order: Schema.String.pipe(Schema.annotateKey({ description: "Order within the initiative." }))
581
578
  }).annotate({ description: "Links between Linear initiatives and projects. Removed links aren't seen." }).pipe(Iceberg.identifier("id"));
582
579
  const InitiativeToProjectObjectSchema = InitiativeToProjectSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
583
580
  //#endregion
@@ -692,115 +689,115 @@ const makeInitiativeToProjects = (client) => Resource.entity({
692
689
  const IssueSchema = Schema.Struct({
693
690
  ...common("Issue"),
694
691
  _deleted: deleted("issue"),
695
- identifier: Schema.String.pipe(field(10, "Readable ID, such as ENG-123.")),
696
- number: Schema.Finite.pipe(field(11, "Issue number within its team.")),
697
- title: Schema.String.pipe(field(12, "Issue title.")),
698
- description: OptionalString.pipe(field(13, "Description in markdown.")),
699
- url: Schema.String.pipe(field(14, "Issue URL.")),
700
- branch_name: Schema.String.pipe(field(15, "Suggested Git branch name.")),
701
- priority: Schema.Finite.pipe(field(16, "0 none, 1 urgent, 2 high, 3 medium, 4 low.")),
702
- priority_label: Schema.String.pipe(field(17, "Priority name.")),
703
- estimate: Schema.NullOr(Schema.Finite).pipe(field(18, "Estimate, on the team's scale.")),
704
- due_date: OptionalString.pipe(field(19, "Due date, as YYYY-MM-DD.")),
705
- creator_id: OptionalRef.pipe(field(20, "User who created the issue.")),
706
- assignee_id: OptionalRef.pipe(field(21, "Assigned user.")),
707
- delegate_id: OptionalRef.pipe(field(22, "Agent user working on the issue.")),
708
- snoozed_by_id: OptionalRef.pipe(field(23, "User who snoozed the issue.")),
709
- state_id: Ref.pipe(field(24, "Workflow state.")),
710
- team_id: Ref.pipe(field(25, "Team the issue belongs to.")),
711
- project_id: OptionalRef.pipe(field(26, "Project.")),
712
- project_milestone_id: OptionalRef.pipe(field(27, "Project milestone.")),
713
- cycle_id: OptionalRef.pipe(field(28, "Cycle.")),
714
- parent_id: OptionalRef.pipe(field(29, "Parent issue.")),
715
- source_comment_id: OptionalRef.pipe(field(30, "Comment the issue was made from.")),
716
- external_user_creator_id: OptionalRef.pipe(field(31, "External user who created the issue through an integration.")),
717
- label_ids: list(101, Schema.String).pipe(field(32, "Labels.")),
718
- previous_identifiers: list(102, Schema.String).pipe(field(33, "Earlier readable IDs, from before the issue moved team.")),
719
- started_at: OptionalTimestamp.pipe(field(34, "Time the issue moved to a started state.")),
720
- completed_at: OptionalTimestamp.pipe(field(35, "Time the issue was completed.")),
721
- canceled_at: OptionalTimestamp.pipe(field(36, "Time the issue was canceled.")),
722
- started_triage_at: OptionalTimestamp.pipe(field(37, "Time the issue entered triage.")),
723
- triaged_at: OptionalTimestamp.pipe(field(38, "Time the issue left triage.")),
724
- auto_closed_at: OptionalTimestamp.pipe(field(39, "Time the issue was closed automatically.")),
725
- auto_archived_at: OptionalTimestamp.pipe(field(40, "Time the issue was archived automatically.")),
726
- added_to_cycle_at: OptionalTimestamp.pipe(field(41, "Time the issue was added to its cycle.")),
727
- added_to_project_at: OptionalTimestamp.pipe(field(42, "Time the issue was added to its project.")),
728
- added_to_team_at: OptionalTimestamp.pipe(field(43, "Time the issue was added to its team.")),
729
- snoozed_until_at: OptionalTimestamp.pipe(field(44, "Time the issue is snoozed until.")),
730
- sla_type: OptionalString.pipe(field(45, "SLA type.")),
731
- sla_started_at: OptionalTimestamp.pipe(field(46, "Time the SLA started.")),
732
- sla_breaches_at: OptionalTimestamp.pipe(field(47, "Time the SLA breaches.")),
733
- customer_ticket_count: Long.pipe(field(48, "Linked support tickets.")),
734
- integration_source_type: OptionalString.pipe(field(49, "Integration that created the issue.")),
735
- trashed: Schema.NullOr(Schema.Boolean).pipe(field(50, "Whether the issue is in the trash."))
692
+ identifier: Schema.String.pipe(Schema.annotateKey({ description: "Readable ID, such as ENG-123." })),
693
+ number: Schema.Finite.pipe(Schema.annotateKey({ description: "Issue number within its team." })),
694
+ title: Schema.String.pipe(Schema.annotateKey({ description: "Issue title." })),
695
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Description in markdown." })),
696
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Issue URL." })),
697
+ branch_name: Schema.String.pipe(Schema.annotateKey({ description: "Suggested Git branch name." })),
698
+ priority: Schema.Finite.pipe(Schema.annotateKey({ description: "0 none, 1 urgent, 2 high, 3 medium, 4 low." })),
699
+ priority_label: Schema.String.pipe(Schema.annotateKey({ description: "Priority name." })),
700
+ estimate: Schema.NullOr(Schema.Finite).pipe(Schema.annotateKey({ description: "Estimate, on the team's scale." })),
701
+ due_date: OptionalString.pipe(Schema.annotateKey({ description: "Due date, as YYYY-MM-DD." })),
702
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who created the issue." })),
703
+ assignee_id: OptionalRef.pipe(Schema.annotateKey({ description: "Assigned user." })),
704
+ delegate_id: OptionalRef.pipe(Schema.annotateKey({ description: "Agent user working on the issue." })),
705
+ snoozed_by_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who snoozed the issue." })),
706
+ state_id: Ref.pipe(Schema.annotateKey({ description: "Workflow state." })),
707
+ team_id: Ref.pipe(Schema.annotateKey({ description: "Team the issue belongs to." })),
708
+ project_id: OptionalRef.pipe(Schema.annotateKey({ description: "Project." })),
709
+ project_milestone_id: OptionalRef.pipe(Schema.annotateKey({ description: "Project milestone." })),
710
+ cycle_id: OptionalRef.pipe(Schema.annotateKey({ description: "Cycle." })),
711
+ parent_id: OptionalRef.pipe(Schema.annotateKey({ description: "Parent issue." })),
712
+ source_comment_id: OptionalRef.pipe(Schema.annotateKey({ description: "Comment the issue was made from." })),
713
+ external_user_creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "External user who created the issue through an integration." })),
714
+ label_ids: Schema.Array(Schema.String).pipe(Schema.annotateKey({ description: "Labels." })),
715
+ previous_identifiers: Schema.Array(Schema.String).pipe(Schema.annotateKey({ description: "Earlier readable IDs, from before the issue moved team." })),
716
+ started_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue moved to a started state." })),
717
+ completed_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue was completed." })),
718
+ canceled_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue was canceled." })),
719
+ started_triage_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue entered triage." })),
720
+ triaged_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue left triage." })),
721
+ auto_closed_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue was closed automatically." })),
722
+ auto_archived_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue was archived automatically." })),
723
+ added_to_cycle_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue was added to its cycle." })),
724
+ added_to_project_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue was added to its project." })),
725
+ added_to_team_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue was added to its team." })),
726
+ snoozed_until_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the issue is snoozed until." })),
727
+ sla_type: OptionalString.pipe(Schema.annotateKey({ description: "SLA type." })),
728
+ sla_started_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the SLA started." })),
729
+ sla_breaches_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the SLA breaches." })),
730
+ customer_ticket_count: Long.pipe(Schema.annotateKey({ description: "Linked support tickets." })),
731
+ integration_source_type: OptionalString.pipe(Schema.annotateKey({ description: "Integration that created the issue." })),
732
+ trashed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the issue is in the trash." }))
736
733
  }).annotate({ description: "Linear issues, including archived and trashed ones." }).pipe(Iceberg.identifier("id"));
737
734
  const IssueObjectSchema = IssueSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
738
735
  const IssueHistorySchema = Schema.Struct({
739
736
  ...common("History entry"),
740
- issue_id: Schema.String.pipe(field(10, "Issue that changed.")),
741
- actor_id: OptionalString.pipe(field(11, "User who made the change.")),
742
- from_state_id: OptionalString.pipe(field(12, "Workflow state before.")),
743
- to_state_id: OptionalString.pipe(field(13, "Workflow state after.")),
744
- from_assignee_id: OptionalString.pipe(field(14, "Assignee before.")),
745
- to_assignee_id: OptionalString.pipe(field(15, "Assignee after.")),
746
- from_cycle_id: OptionalString.pipe(field(16, "Cycle before.")),
747
- to_cycle_id: OptionalString.pipe(field(17, "Cycle after.")),
748
- from_project_id: OptionalString.pipe(field(18, "Project before.")),
749
- to_project_id: OptionalString.pipe(field(19, "Project after.")),
750
- from_parent_id: OptionalString.pipe(field(20, "Parent issue before.")),
751
- to_parent_id: OptionalString.pipe(field(21, "Parent issue after.")),
752
- from_team_id: OptionalString.pipe(field(22, "Team before.")),
753
- to_team_id: OptionalString.pipe(field(23, "Team after.")),
754
- from_priority: Schema.NullOr(Schema.Finite).pipe(field(24, "Priority before.")),
755
- to_priority: Schema.NullOr(Schema.Finite).pipe(field(25, "Priority after.")),
756
- from_estimate: Schema.NullOr(Schema.Finite).pipe(field(26, "Estimate before.")),
757
- to_estimate: Schema.NullOr(Schema.Finite).pipe(field(27, "Estimate after.")),
758
- from_due_date: OptionalString.pipe(field(28, "Due date before, as YYYY-MM-DD.")),
759
- to_due_date: OptionalString.pipe(field(29, "Due date after, as YYYY-MM-DD.")),
760
- from_title: OptionalString.pipe(field(30, "Title before.")),
761
- to_title: OptionalString.pipe(field(31, "Title after.")),
762
- added_label_ids: Schema.NullOr(list(101, Schema.String)).pipe(field(32, "Labels added.")),
763
- removed_label_ids: Schema.NullOr(list(102, Schema.String)).pipe(field(33, "Labels removed.")),
764
- attachment_id: OptionalString.pipe(field(34, "Attachment linked or unlinked.")),
765
- customer_need_id: OptionalString.pipe(field(35, "Customer request linked or unlinked.")),
766
- to_converted_project_id: OptionalString.pipe(field(36, "Project the issue became.")),
767
- updated_description: Schema.NullOr(Schema.Boolean).pipe(field(37, "Whether the description changed.")),
768
- archived: Schema.NullOr(Schema.Boolean).pipe(field(38, "Whether the issue was archived.")),
769
- trashed: Schema.NullOr(Schema.Boolean).pipe(field(39, "Whether the issue was trashed.")),
770
- auto_archived: Schema.NullOr(Schema.Boolean).pipe(field(40, "Whether the issue was archived automatically.")),
771
- auto_closed: Schema.NullOr(Schema.Boolean).pipe(field(41, "Whether the issue was closed automatically."))
737
+ issue_id: Schema.String.pipe(Schema.annotateKey({ description: "Issue that changed." })),
738
+ actor_id: OptionalString.pipe(Schema.annotateKey({ description: "User who made the change." })),
739
+ from_state_id: OptionalString.pipe(Schema.annotateKey({ description: "Workflow state before." })),
740
+ to_state_id: OptionalString.pipe(Schema.annotateKey({ description: "Workflow state after." })),
741
+ from_assignee_id: OptionalString.pipe(Schema.annotateKey({ description: "Assignee before." })),
742
+ to_assignee_id: OptionalString.pipe(Schema.annotateKey({ description: "Assignee after." })),
743
+ from_cycle_id: OptionalString.pipe(Schema.annotateKey({ description: "Cycle before." })),
744
+ to_cycle_id: OptionalString.pipe(Schema.annotateKey({ description: "Cycle after." })),
745
+ from_project_id: OptionalString.pipe(Schema.annotateKey({ description: "Project before." })),
746
+ to_project_id: OptionalString.pipe(Schema.annotateKey({ description: "Project after." })),
747
+ from_parent_id: OptionalString.pipe(Schema.annotateKey({ description: "Parent issue before." })),
748
+ to_parent_id: OptionalString.pipe(Schema.annotateKey({ description: "Parent issue after." })),
749
+ from_team_id: OptionalString.pipe(Schema.annotateKey({ description: "Team before." })),
750
+ to_team_id: OptionalString.pipe(Schema.annotateKey({ description: "Team after." })),
751
+ from_priority: Schema.NullOr(Schema.Finite).pipe(Schema.annotateKey({ description: "Priority before." })),
752
+ to_priority: Schema.NullOr(Schema.Finite).pipe(Schema.annotateKey({ description: "Priority after." })),
753
+ from_estimate: Schema.NullOr(Schema.Finite).pipe(Schema.annotateKey({ description: "Estimate before." })),
754
+ to_estimate: Schema.NullOr(Schema.Finite).pipe(Schema.annotateKey({ description: "Estimate after." })),
755
+ from_due_date: OptionalString.pipe(Schema.annotateKey({ description: "Due date before, as YYYY-MM-DD." })),
756
+ to_due_date: OptionalString.pipe(Schema.annotateKey({ description: "Due date after, as YYYY-MM-DD." })),
757
+ from_title: OptionalString.pipe(Schema.annotateKey({ description: "Title before." })),
758
+ to_title: OptionalString.pipe(Schema.annotateKey({ description: "Title after." })),
759
+ added_label_ids: Schema.NullOr(Schema.Array(Schema.String)).pipe(Schema.annotateKey({ description: "Labels added." })),
760
+ removed_label_ids: Schema.NullOr(Schema.Array(Schema.String)).pipe(Schema.annotateKey({ description: "Labels removed." })),
761
+ attachment_id: OptionalString.pipe(Schema.annotateKey({ description: "Attachment linked or unlinked." })),
762
+ customer_need_id: OptionalString.pipe(Schema.annotateKey({ description: "Customer request linked or unlinked." })),
763
+ to_converted_project_id: OptionalString.pipe(Schema.annotateKey({ description: "Project the issue became." })),
764
+ updated_description: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the description changed." })),
765
+ archived: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the issue was archived." })),
766
+ trashed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the issue was trashed." })),
767
+ auto_archived: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the issue was archived automatically." })),
768
+ auto_closed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the issue was closed automatically." }))
772
769
  }).annotate({ description: "Linear issue history. One row per change to an issue." }).pipe(Iceberg.identifier("id"));
773
770
  const IssueHistoryObjectSchema = IssueHistorySchema.mapFields((fields) => Struct.omit(fields, ["version", "issue_id"]));
774
771
  const IssueRelationSchema = Schema.Struct({
775
772
  ...common("Relation"),
776
- issue_id: Ref.pipe(field(10, "Issue the relation starts from.")),
777
- related_issue_id: Ref.pipe(field(11, "Related issue.")),
778
- type: Schema.String.pipe(field(12, "Relation type: blocks, duplicate, related, or similar."))
773
+ issue_id: Ref.pipe(Schema.annotateKey({ description: "Issue the relation starts from." })),
774
+ related_issue_id: Ref.pipe(Schema.annotateKey({ description: "Related issue." })),
775
+ type: Schema.String.pipe(Schema.annotateKey({ description: "Relation type: blocks, duplicate, related, or similar." }))
779
776
  }).annotate({ description: "Linear issue relations. Deleted relations aren't seen." }).pipe(Iceberg.identifier("id"));
780
777
  const IssueRelationObjectSchema = IssueRelationSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
781
778
  const AttachmentSchema = Schema.Struct({
782
779
  ...common("Attachment"),
783
780
  _deleted: deleted("attachment"),
784
- issue_id: Ref.pipe(field(10, "Issue the attachment is on.")),
785
- creator_id: OptionalRef.pipe(field(11, "User who added it.")),
786
- external_user_creator_id: OptionalRef.pipe(field(12, "External user who added it.")),
787
- title: Schema.String.pipe(field(13, "Title.")),
788
- subtitle: OptionalString.pipe(field(14, "Subtitle.")),
789
- url: Schema.String.pipe(field(15, "Linked URL, such as a pull request or ticket.")),
790
- source_type: OptionalString.pipe(field(16, "Source, such as github or zendesk."))
781
+ issue_id: Ref.pipe(Schema.annotateKey({ description: "Issue the attachment is on." })),
782
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who added it." })),
783
+ external_user_creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "External user who added it." })),
784
+ title: Schema.String.pipe(Schema.annotateKey({ description: "Title." })),
785
+ subtitle: OptionalString.pipe(Schema.annotateKey({ description: "Subtitle." })),
786
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Linked URL, such as a pull request or ticket." })),
787
+ source_type: OptionalString.pipe(Schema.annotateKey({ description: "Source, such as github or zendesk." }))
791
788
  }).annotate({ description: "Linear issue attachments: links to pull requests, tickets, and more." }).pipe(Iceberg.identifier("id"));
792
789
  const AttachmentObjectSchema = AttachmentSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
793
790
  const IssueLabelSchema = Schema.Struct({
794
791
  ...common("Label"),
795
792
  _deleted: deleted("label"),
796
- name: Schema.String.pipe(field(10, "Label name.")),
797
- description: OptionalString.pipe(field(11, "Label description.")),
798
- color: Schema.String.pipe(field(12, "Label color, as hex.")),
799
- is_group: Schema.Boolean.pipe(field(13, "Whether the label groups other labels.")),
800
- parent_id: OptionalRef.pipe(field(14, "Label group.")),
801
- team_id: OptionalRef.pipe(field(15, "Team, or null for a workspace label.")),
802
- creator_id: OptionalRef.pipe(field(16, "User who made the label.")),
803
- retired_at: OptionalTimestamp.pipe(field(17, "Time the label was retired."))
793
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Label name." })),
794
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Label description." })),
795
+ color: Schema.String.pipe(Schema.annotateKey({ description: "Label color, as hex." })),
796
+ is_group: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the label groups other labels." })),
797
+ parent_id: OptionalRef.pipe(Schema.annotateKey({ description: "Label group." })),
798
+ team_id: OptionalRef.pipe(Schema.annotateKey({ description: "Team, or null for a workspace label." })),
799
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the label." })),
800
+ retired_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the label was retired." }))
804
801
  }).annotate({ description: "Linear issue labels. Names the IDs in `issues.label_ids`." }).pipe(Iceberg.identifier("id"));
805
802
  const IssueLabelObjectSchema = IssueLabelSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
806
803
  //#endregion
@@ -983,88 +980,88 @@ const makeIssueLabels = (client) => Resource.entity({
983
980
  const ProjectSchema = Schema.Struct({
984
981
  ...common("Project"),
985
982
  _deleted: deleted("project"),
986
- name: Schema.String.pipe(field(10, "Project name.")),
987
- description: Schema.String.pipe(field(11, "Short summary.")),
988
- content: OptionalString.pipe(field(12, "Project overview in markdown.")),
989
- url: Schema.String.pipe(field(13, "Project URL.")),
990
- icon: OptionalString.pipe(field(14, "Icon.")),
991
- color: Schema.String.pipe(field(15, "Color, as hex.")),
992
- status_id: Ref.pipe(field(16, "Project status.")),
993
- priority: Long.pipe(field(17, "0 none, 1 urgent, 2 high, 3 medium, 4 low.")),
994
- priority_label: Schema.String.pipe(field(18, "Priority name.")),
995
- health: OptionalString.pipe(field(19, "Health from the latest update.")),
996
- health_updated_at: OptionalTimestamp.pipe(field(20, "Time the health last changed.")),
997
- progress: Schema.Finite.pipe(field(21, "Share of the scope completed, from 0 to 1.")),
998
- scope: Schema.Finite.pipe(field(22, "Total estimate of the project's issues.")),
999
- lead_id: OptionalRef.pipe(field(23, "Project lead.")),
1000
- creator_id: OptionalRef.pipe(field(24, "User who made the project.")),
1001
- converted_from_issue_id: OptionalRef.pipe(field(25, "Issue the project was made from.")),
1002
- start_date: OptionalString.pipe(field(26, "Start date, as YYYY-MM-DD.")),
1003
- target_date: OptionalString.pipe(field(27, "Target date, as YYYY-MM-DD.")),
1004
- started_at: OptionalTimestamp.pipe(field(28, "Time the project started.")),
1005
- completed_at: OptionalTimestamp.pipe(field(29, "Time the project was completed.")),
1006
- canceled_at: OptionalTimestamp.pipe(field(30, "Time the project was canceled.")),
1007
- auto_archived_at: OptionalTimestamp.pipe(field(31, "Time the project was archived automatically.")),
1008
- label_ids: list(101, Schema.String).pipe(field(32, "Project labels.")),
1009
- team_ids: RefList(102).pipe(field(33, "Teams the project belongs to. Reads up to 50.")),
1010
- member_ids: RefList(103).pipe(field(34, "Project members. Reads up to 100.")),
1011
- trashed: Schema.NullOr(Schema.Boolean).pipe(field(35, "Whether the project is in the trash."))
983
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Project name." })),
984
+ description: Schema.String.pipe(Schema.annotateKey({ description: "Short summary." })),
985
+ content: OptionalString.pipe(Schema.annotateKey({ description: "Project overview in markdown." })),
986
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Project URL." })),
987
+ icon: OptionalString.pipe(Schema.annotateKey({ description: "Icon." })),
988
+ color: Schema.String.pipe(Schema.annotateKey({ description: "Color, as hex." })),
989
+ status_id: Ref.pipe(Schema.annotateKey({ description: "Project status." })),
990
+ priority: Long.pipe(Schema.annotateKey({ description: "0 none, 1 urgent, 2 high, 3 medium, 4 low." })),
991
+ priority_label: Schema.String.pipe(Schema.annotateKey({ description: "Priority name." })),
992
+ health: OptionalString.pipe(Schema.annotateKey({ description: "Health from the latest update." })),
993
+ health_updated_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the health last changed." })),
994
+ progress: Schema.Finite.pipe(Schema.annotateKey({ description: "Share of the scope completed, from 0 to 1." })),
995
+ scope: Schema.Finite.pipe(Schema.annotateKey({ description: "Total estimate of the project's issues." })),
996
+ lead_id: OptionalRef.pipe(Schema.annotateKey({ description: "Project lead." })),
997
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the project." })),
998
+ converted_from_issue_id: OptionalRef.pipe(Schema.annotateKey({ description: "Issue the project was made from." })),
999
+ start_date: OptionalString.pipe(Schema.annotateKey({ description: "Start date, as YYYY-MM-DD." })),
1000
+ target_date: OptionalString.pipe(Schema.annotateKey({ description: "Target date, as YYYY-MM-DD." })),
1001
+ started_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the project started." })),
1002
+ completed_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the project was completed." })),
1003
+ canceled_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the project was canceled." })),
1004
+ auto_archived_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the project was archived automatically." })),
1005
+ label_ids: Schema.Array(Schema.String).pipe(Schema.annotateKey({ description: "Project labels." })),
1006
+ team_ids: RefList.pipe(Schema.annotateKey({ description: "Teams the project belongs to. Reads up to 50." })),
1007
+ member_ids: RefList.pipe(Schema.annotateKey({ description: "Project members. Reads up to 100." })),
1008
+ trashed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the project is in the trash." }))
1012
1009
  }).annotate({ description: "Linear projects, including archived and trashed ones." }).pipe(Iceberg.identifier("id"));
1013
1010
  const ProjectObjectSchema = ProjectSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
1014
1011
  const ProjectMilestoneSchema = Schema.Struct({
1015
1012
  ...common("Milestone"),
1016
- name: Schema.String.pipe(field(10, "Milestone name.")),
1017
- description: OptionalString.pipe(field(11, "Description in markdown.")),
1018
- project_id: Ref.pipe(field(12, "Project.")),
1019
- target_date: OptionalString.pipe(field(13, "Target date, as YYYY-MM-DD.")),
1020
- status: Schema.String.pipe(field(14, "Status: unstarted, next, overdue, or done.")),
1021
- progress: Schema.Finite.pipe(field(15, "Share of the scope completed, from 0 to 1.")),
1022
- sort_order: Schema.Finite.pipe(field(16, "Order within the project."))
1013
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Milestone name." })),
1014
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Description in markdown." })),
1015
+ project_id: Ref.pipe(Schema.annotateKey({ description: "Project." })),
1016
+ target_date: OptionalString.pipe(Schema.annotateKey({ description: "Target date, as YYYY-MM-DD." })),
1017
+ status: Schema.String.pipe(Schema.annotateKey({ description: "Status: unstarted, next, overdue, or done." })),
1018
+ progress: Schema.Finite.pipe(Schema.annotateKey({ description: "Share of the scope completed, from 0 to 1." })),
1019
+ sort_order: Schema.Finite.pipe(Schema.annotateKey({ description: "Order within the project." }))
1023
1020
  }).annotate({ description: "Linear project milestones. Deleted milestones aren't seen." }).pipe(Iceberg.identifier("id"));
1024
1021
  const ProjectMilestoneObjectSchema = ProjectMilestoneSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1025
1022
  const ProjectUpdateSchema = Schema.Struct({
1026
1023
  ...common("Update"),
1027
1024
  _deleted: deleted("update"),
1028
- project_id: Ref.pipe(field(10, "Project.")),
1029
- user_id: Ref.pipe(field(11, "User who posted the update.")),
1030
- body: Schema.String.pipe(field(12, "Update text in markdown.")),
1031
- health: Schema.String.pipe(field(13, "Health: onTrack, atRisk, or offTrack.")),
1032
- url: Schema.String.pipe(field(14, "Update URL.")),
1033
- edited_at: OptionalTimestamp.pipe(field(15, "Time the update was last edited.")),
1034
- comment_count: Long.pipe(field(16, "Comments on the update."))
1025
+ project_id: Ref.pipe(Schema.annotateKey({ description: "Project." })),
1026
+ user_id: Ref.pipe(Schema.annotateKey({ description: "User who posted the update." })),
1027
+ body: Schema.String.pipe(Schema.annotateKey({ description: "Update text in markdown." })),
1028
+ health: Schema.String.pipe(Schema.annotateKey({ description: "Health: onTrack, atRisk, or offTrack." })),
1029
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Update URL." })),
1030
+ edited_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the update was last edited." })),
1031
+ comment_count: Long.pipe(Schema.annotateKey({ description: "Comments on the update." }))
1035
1032
  }).annotate({ description: "Linear project updates: status posts with a health." }).pipe(Iceberg.identifier("id"));
1036
1033
  const ProjectUpdateObjectSchema = ProjectUpdateSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
1037
1034
  const ProjectStatusSchema = Schema.Struct({
1038
1035
  ...common("Status"),
1039
- name: Schema.String.pipe(field(10, "Status name.")),
1040
- type: Schema.String.pipe(field(11, "Status type: backlog, planned, started, paused, completed, or canceled.")),
1041
- color: Schema.String.pipe(field(12, "Color, as hex.")),
1042
- description: OptionalString.pipe(field(13, "Description.")),
1043
- position: Schema.Finite.pipe(field(14, "Order in the list."))
1036
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Status name." })),
1037
+ type: Schema.String.pipe(Schema.annotateKey({ description: "Status type: backlog, planned, started, paused, completed, or canceled." })),
1038
+ color: Schema.String.pipe(Schema.annotateKey({ description: "Color, as hex." })),
1039
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Description." })),
1040
+ position: Schema.Finite.pipe(Schema.annotateKey({ description: "Order in the list." }))
1044
1041
  }).annotate({ description: "Linear project statuses. Names the IDs in `projects.status_id`." }).pipe(Iceberg.identifier("id"));
1045
1042
  const ProjectStatusObjectSchema = ProjectStatusSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1046
1043
  const ProjectLabelSchema = Schema.Struct({
1047
1044
  ...common("Label"),
1048
1045
  _deleted: deleted("label"),
1049
- name: Schema.String.pipe(field(10, "Label name.")),
1050
- description: OptionalString.pipe(field(11, "Label description.")),
1051
- color: Schema.String.pipe(field(12, "Label color, as hex.")),
1052
- is_group: Schema.Boolean.pipe(field(13, "Whether the label groups other labels.")),
1053
- parent_id: OptionalRef.pipe(field(14, "Label group.")),
1054
- creator_id: OptionalRef.pipe(field(15, "User who made the label.")),
1055
- retired_at: OptionalTimestamp.pipe(field(16, "Time the label was retired."))
1046
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Label name." })),
1047
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Label description." })),
1048
+ color: Schema.String.pipe(Schema.annotateKey({ description: "Label color, as hex." })),
1049
+ is_group: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the label groups other labels." })),
1050
+ parent_id: OptionalRef.pipe(Schema.annotateKey({ description: "Label group." })),
1051
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the label." })),
1052
+ retired_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the label was retired." }))
1056
1053
  }).annotate({ description: "Linear project labels. Names the IDs in `projects.label_ids`." }).pipe(Iceberg.identifier("id"));
1057
1054
  const ProjectLabelObjectSchema = ProjectLabelSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
1058
1055
  const ProjectRelationSchema = Schema.Struct({
1059
1056
  ...common("Relation"),
1060
- type: Schema.String.pipe(field(10, "Relation type, such as dependency.")),
1061
- project_id: Ref.pipe(field(11, "Project the relation starts from.")),
1062
- project_milestone_id: OptionalRef.pipe(field(12, "Milestone the relation starts from.")),
1063
- anchor_type: Schema.String.pipe(field(13, "Which end of the project it starts from.")),
1064
- related_project_id: Ref.pipe(field(14, "Related project.")),
1065
- related_project_milestone_id: OptionalRef.pipe(field(15, "Related milestone.")),
1066
- related_anchor_type: Schema.String.pipe(field(16, "Which end of the related project.")),
1067
- user_id: OptionalRef.pipe(field(17, "User who made the relation."))
1057
+ type: Schema.String.pipe(Schema.annotateKey({ description: "Relation type, such as dependency." })),
1058
+ project_id: Ref.pipe(Schema.annotateKey({ description: "Project the relation starts from." })),
1059
+ project_milestone_id: OptionalRef.pipe(Schema.annotateKey({ description: "Milestone the relation starts from." })),
1060
+ anchor_type: Schema.String.pipe(Schema.annotateKey({ description: "Which end of the project it starts from." })),
1061
+ related_project_id: Ref.pipe(Schema.annotateKey({ description: "Related project." })),
1062
+ related_project_milestone_id: OptionalRef.pipe(Schema.annotateKey({ description: "Related milestone." })),
1063
+ related_anchor_type: Schema.String.pipe(Schema.annotateKey({ description: "Which end of the related project." })),
1064
+ user_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the relation." }))
1068
1065
  }).annotate({ description: "Linear project dependencies. Deleted relations aren't seen." }).pipe(Iceberg.identifier("id"));
1069
1066
  const ProjectRelationObjectSchema = ProjectRelationSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1070
1067
  //#endregion
@@ -1205,59 +1202,59 @@ const makeProjectRelations = (client) => Resource.entity({
1205
1202
  //#region src/schemas/releases.ts
1206
1203
  const ReleaseSchema = Schema.Struct({
1207
1204
  ...common("Release"),
1208
- name: Schema.String.pipe(field(10, "Release name.")),
1209
- description: OptionalString.pipe(field(11, "Description.")),
1210
- release_version: OptionalString.pipe(field(12, "Version, such as 1.2.0.")),
1211
- url: Schema.String.pipe(field(13, "Release URL.")),
1212
- commit_sha: OptionalString.pipe(field(14, "Commit SHA.")),
1213
- pipeline_id: Ref.pipe(field(15, "Release pipeline.")),
1214
- stage_id: Ref.pipe(field(16, "Release stage.")),
1215
- creator_id: OptionalRef.pipe(field(17, "User who made the release.")),
1216
- start_date: OptionalString.pipe(field(18, "Start date, as YYYY-MM-DD.")),
1217
- target_date: OptionalString.pipe(field(19, "Target date, as YYYY-MM-DD.")),
1218
- started_at: OptionalTimestamp.pipe(field(20, "Time the release started.")),
1219
- completed_at: OptionalTimestamp.pipe(field(21, "Time the release was completed.")),
1220
- canceled_at: OptionalTimestamp.pipe(field(22, "Time the release was canceled.")),
1221
- trashed: Schema.NullOr(Schema.Boolean).pipe(field(23, "Whether the release is in the trash."))
1205
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Release name." })),
1206
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Description." })),
1207
+ release_version: OptionalString.pipe(Schema.annotateKey({ description: "Version, such as 1.2.0." })),
1208
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Release URL." })),
1209
+ commit_sha: OptionalString.pipe(Schema.annotateKey({ description: "Commit SHA." })),
1210
+ pipeline_id: Ref.pipe(Schema.annotateKey({ description: "Release pipeline." })),
1211
+ stage_id: Ref.pipe(Schema.annotateKey({ description: "Release stage." })),
1212
+ creator_id: OptionalRef.pipe(Schema.annotateKey({ description: "User who made the release." })),
1213
+ start_date: OptionalString.pipe(Schema.annotateKey({ description: "Start date, as YYYY-MM-DD." })),
1214
+ target_date: OptionalString.pipe(Schema.annotateKey({ description: "Target date, as YYYY-MM-DD." })),
1215
+ started_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the release started." })),
1216
+ completed_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the release was completed." })),
1217
+ canceled_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the release was canceled." })),
1218
+ trashed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the release is in the trash." }))
1222
1219
  }).annotate({ description: "Linear releases. Needs the Business plan." }).pipe(Iceberg.identifier("id"));
1223
1220
  const ReleaseObjectSchema = ReleaseSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1224
1221
  const ReleaseNoteSchema = Schema.Struct({
1225
1222
  ...common("Release note"),
1226
- title: OptionalString.pipe(field(10, "Release note title.")),
1223
+ title: OptionalString.pipe(Schema.annotateKey({ description: "Release note title." })),
1227
1224
  content: Schema.NullOr(Schema.Struct({ content: OptionalString })).pipe(Schema.decodeTo(OptionalString, SchemaTransformation.transform({
1228
1225
  decode: (document) => document?.content ?? null,
1229
1226
  encode: (content) => content === null ? null : { content }
1230
- })), field(11, "Release note body in markdown.")),
1231
- url: Schema.String.pipe(field(12, "Release note URL.")),
1232
- pipeline_id: Ref.pipe(field(13, "Release pipeline.")),
1233
- release_ids: list(101, Ref).pipe(field(14, "Releases covered by the note."))
1227
+ })), Schema.annotateKey({ description: "Release note body in markdown." })),
1228
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Release note URL." })),
1229
+ pipeline_id: Ref.pipe(Schema.annotateKey({ description: "Release pipeline." })),
1230
+ release_ids: Schema.Array(Ref).pipe(Schema.annotateKey({ description: "Releases covered by the note." }))
1234
1231
  }).annotate({ description: "Linear release notes. Needs the Business plan." }).pipe(Iceberg.identifier("id"));
1235
1232
  const ReleaseNoteObjectSchema = ReleaseNoteSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1236
1233
  const ReleasePipelineSchema = Schema.Struct({
1237
1234
  ...common("Pipeline"),
1238
- name: Schema.String.pipe(field(10, "Pipeline name.")),
1239
- type: Schema.String.pipe(field(11, "Pipeline type.")),
1240
- is_production: Schema.Boolean.pipe(field(12, "Whether it releases to production.")),
1241
- url: Schema.String.pipe(field(13, "Pipeline URL.")),
1242
- include_path_patterns: list(101, Schema.String).pipe(field(14, "File paths that count toward the pipeline.")),
1243
- approximate_release_count: Long.pipe(field(15, "About how many releases it has.")),
1244
- trashed: Schema.NullOr(Schema.Boolean).pipe(field(16, "Whether the pipeline is in the trash."))
1235
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Pipeline name." })),
1236
+ type: Schema.String.pipe(Schema.annotateKey({ description: "Pipeline type." })),
1237
+ is_production: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether it releases to production." })),
1238
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Pipeline URL." })),
1239
+ include_path_patterns: Schema.Array(Schema.String).pipe(Schema.annotateKey({ description: "File paths that count toward the pipeline." })),
1240
+ approximate_release_count: Long.pipe(Schema.annotateKey({ description: "About how many releases it has." })),
1241
+ trashed: Schema.NullOr(Schema.Boolean).pipe(Schema.annotateKey({ description: "Whether the pipeline is in the trash." }))
1245
1242
  }).annotate({ description: "Linear release pipelines. Needs the Business plan." }).pipe(Iceberg.identifier("id"));
1246
1243
  const ReleasePipelineObjectSchema = ReleasePipelineSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1247
1244
  const ReleaseStageSchema = Schema.Struct({
1248
1245
  ...common("Stage"),
1249
- name: Schema.String.pipe(field(10, "Stage name.")),
1250
- type: Schema.String.pipe(field(11, "Stage type.")),
1251
- color: Schema.String.pipe(field(12, "Color, as hex.")),
1252
- position: Schema.Finite.pipe(field(13, "Order in the pipeline.")),
1253
- frozen: Schema.Boolean.pipe(field(14, "Whether the stage is frozen.")),
1254
- pipeline_id: Ref.pipe(field(15, "Release pipeline."))
1246
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Stage name." })),
1247
+ type: Schema.String.pipe(Schema.annotateKey({ description: "Stage type." })),
1248
+ color: Schema.String.pipe(Schema.annotateKey({ description: "Color, as hex." })),
1249
+ position: Schema.Finite.pipe(Schema.annotateKey({ description: "Order in the pipeline." })),
1250
+ frozen: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the stage is frozen." })),
1251
+ pipeline_id: Ref.pipe(Schema.annotateKey({ description: "Release pipeline." }))
1255
1252
  }).annotate({ description: "Linear release stages. Needs the Business plan." }).pipe(Iceberg.identifier("id"));
1256
1253
  const ReleaseStageObjectSchema = ReleaseStageSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1257
1254
  const IssueToReleaseSchema = Schema.Struct({
1258
1255
  ...common("Link"),
1259
- issue_id: Ref.pipe(field(10, "Issue.")),
1260
- release_id: Ref.pipe(field(11, "Release."))
1256
+ issue_id: Ref.pipe(Schema.annotateKey({ description: "Issue." })),
1257
+ release_id: Ref.pipe(Schema.annotateKey({ description: "Release." }))
1261
1258
  }).annotate({ description: "Links between Linear issues and releases. Needs the Business plan." }).pipe(Iceberg.identifier("id"));
1262
1259
  const IssueToReleaseObjectSchema = IssueToReleaseSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1263
1260
  //#endregion
@@ -1360,81 +1357,81 @@ const makeIssueToReleases = (client) => Resource.entity({
1360
1357
  //#region src/schemas/teams.ts
1361
1358
  const TeamSchema = Schema.Struct({
1362
1359
  ...common("Team"),
1363
- name: Schema.String.pipe(field(10, "Team name.")),
1364
- key: Schema.String.pipe(field(11, "Team key, used in issue IDs such as ENG-123.")),
1365
- display_name: Schema.String.pipe(field(12, "Name shown in Linear.")),
1366
- description: OptionalString.pipe(field(13, "Team description.")),
1367
- visibility: Schema.String.pipe(field(14, "Who can see the team.")),
1368
- parent_id: OptionalRef.pipe(field(15, "Parent team.")),
1369
- timezone: Schema.String.pipe(field(16, "Team timezone.")),
1370
- cycles_enabled: Schema.Boolean.pipe(field(17, "Whether the team uses cycles.")),
1371
- cycle_duration: Schema.Finite.pipe(field(18, "Cycle length in weeks.")),
1372
- cycle_cooldown_time: Schema.Finite.pipe(field(19, "Weeks between cycles.")),
1373
- cycle_start_day: Schema.Finite.pipe(field(20, "Day cycles start, 0 for Sunday.")),
1374
- triage_enabled: Schema.Boolean.pipe(field(21, "Whether the team uses triage.")),
1375
- issue_estimation_type: Schema.String.pipe(field(22, "Estimate scale.")),
1376
- default_issue_estimate: Schema.Finite.pipe(field(23, "Default estimate.")),
1377
- auto_archive_period: Schema.Finite.pipe(field(24, "Months before closed issues are archived.")),
1378
- auto_close_period: Schema.NullOr(Schema.Finite).pipe(field(25, "Months before stale issues are closed.")),
1379
- retired_at: OptionalTimestamp.pipe(field(26, "Time the team was retired."))
1360
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Team name." })),
1361
+ key: Schema.String.pipe(Schema.annotateKey({ description: "Team key, used in issue IDs such as ENG-123." })),
1362
+ display_name: Schema.String.pipe(Schema.annotateKey({ description: "Name shown in Linear." })),
1363
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Team description." })),
1364
+ visibility: Schema.String.pipe(Schema.annotateKey({ description: "Who can see the team." })),
1365
+ parent_id: OptionalRef.pipe(Schema.annotateKey({ description: "Parent team." })),
1366
+ timezone: Schema.String.pipe(Schema.annotateKey({ description: "Team timezone." })),
1367
+ cycles_enabled: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the team uses cycles." })),
1368
+ cycle_duration: Schema.Finite.pipe(Schema.annotateKey({ description: "Cycle length in weeks." })),
1369
+ cycle_cooldown_time: Schema.Finite.pipe(Schema.annotateKey({ description: "Weeks between cycles." })),
1370
+ cycle_start_day: Schema.Finite.pipe(Schema.annotateKey({ description: "Day cycles start, 0 for Sunday." })),
1371
+ triage_enabled: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the team uses triage." })),
1372
+ issue_estimation_type: Schema.String.pipe(Schema.annotateKey({ description: "Estimate scale." })),
1373
+ default_issue_estimate: Schema.Finite.pipe(Schema.annotateKey({ description: "Default estimate." })),
1374
+ auto_archive_period: Schema.Finite.pipe(Schema.annotateKey({ description: "Months before closed issues are archived." })),
1375
+ auto_close_period: Schema.NullOr(Schema.Finite).pipe(Schema.annotateKey({ description: "Months before stale issues are closed." })),
1376
+ retired_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the team was retired." }))
1380
1377
  }).annotate({ description: "Linear teams." }).pipe(Iceberg.identifier("id"));
1381
1378
  const TeamObjectSchema = TeamSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1382
1379
  const TeamMembershipSchema = Schema.Struct({
1383
1380
  ...common("Membership"),
1384
- team_id: Ref.pipe(field(10, "Team.")),
1385
- user_id: Ref.pipe(field(11, "User.")),
1386
- owner: Schema.Boolean.pipe(field(12, "Whether the user owns the team."))
1381
+ team_id: Ref.pipe(Schema.annotateKey({ description: "Team." })),
1382
+ user_id: Ref.pipe(Schema.annotateKey({ description: "User." })),
1383
+ owner: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the user owns the team." }))
1387
1384
  }).annotate({ description: "Linear team members. Removed members aren't seen." }).pipe(Iceberg.identifier("id"));
1388
1385
  const TeamMembershipObjectSchema = TeamMembershipSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1389
1386
  const WorkflowStateSchema = Schema.Struct({
1390
1387
  ...common("Workflow state"),
1391
- name: Schema.String.pipe(field(10, "State name.")),
1392
- type: Schema.String.pipe(field(11, "State type: triage, backlog, unstarted, started, completed, or canceled.")),
1393
- color: Schema.String.pipe(field(12, "State color, as hex.")),
1394
- description: OptionalString.pipe(field(13, "State description.")),
1395
- position: Schema.Finite.pipe(field(14, "Order within the team.")),
1396
- team_id: Ref.pipe(field(15, "Team."))
1388
+ name: Schema.String.pipe(Schema.annotateKey({ description: "State name." })),
1389
+ type: Schema.String.pipe(Schema.annotateKey({ description: "State type: triage, backlog, unstarted, started, completed, or canceled." })),
1390
+ color: Schema.String.pipe(Schema.annotateKey({ description: "State color, as hex." })),
1391
+ description: OptionalString.pipe(Schema.annotateKey({ description: "State description." })),
1392
+ position: Schema.Finite.pipe(Schema.annotateKey({ description: "Order within the team." })),
1393
+ team_id: Ref.pipe(Schema.annotateKey({ description: "Team." }))
1397
1394
  }).annotate({ description: "Linear workflow states. Names the IDs in `issues.state_id`." }).pipe(Iceberg.identifier("id"));
1398
1395
  const WorkflowStateObjectSchema = WorkflowStateSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1399
1396
  const UserSchema = Schema.Struct({
1400
1397
  ...common("User"),
1401
1398
  _deleted: deleted("user"),
1402
- name: Schema.String.pipe(field(10, "Full name.")),
1403
- display_name: Schema.String.pipe(field(11, "Display name.")),
1404
- email: Schema.String.pipe(field(12, "Email address.")),
1405
- avatar_url: OptionalString.pipe(field(13, "Avatar image URL.")),
1406
- title: OptionalString.pipe(field(14, "Job title.")),
1407
- timezone: OptionalString.pipe(field(15, "Timezone.")),
1408
- active: Schema.Boolean.pipe(field(16, "Whether the user is active.")),
1409
- admin: Schema.Boolean.pipe(field(17, "Whether the user is an admin.")),
1410
- owner: Schema.Boolean.pipe(field(18, "Whether the user owns the workspace.")),
1411
- guest: Schema.Boolean.pipe(field(19, "Whether the user is a guest.")),
1412
- app: Schema.Boolean.pipe(field(20, "Whether the user is an app or agent.")),
1413
- last_seen: OptionalTimestamp.pipe(field(21, "Time the user was last online.")),
1414
- url: Schema.String.pipe(field(22, "Profile URL."))
1399
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Full name." })),
1400
+ display_name: Schema.String.pipe(Schema.annotateKey({ description: "Display name." })),
1401
+ email: Schema.String.pipe(Schema.annotateKey({ description: "Email address." })),
1402
+ avatar_url: OptionalString.pipe(Schema.annotateKey({ description: "Avatar image URL." })),
1403
+ title: OptionalString.pipe(Schema.annotateKey({ description: "Job title." })),
1404
+ timezone: OptionalString.pipe(Schema.annotateKey({ description: "Timezone." })),
1405
+ active: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the user is active." })),
1406
+ admin: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the user is an admin." })),
1407
+ owner: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the user owns the workspace." })),
1408
+ guest: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the user is a guest." })),
1409
+ app: Schema.Boolean.pipe(Schema.annotateKey({ description: "Whether the user is an app or agent." })),
1410
+ last_seen: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the user was last online." })),
1411
+ url: Schema.String.pipe(Schema.annotateKey({ description: "Profile URL." }))
1415
1412
  }).annotate({ description: "Linear users." }).pipe(Iceberg.identifier("id"));
1416
1413
  const UserObjectSchema = UserSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
1417
1414
  const ExternalUserSchema = Schema.Struct({
1418
1415
  ...common("External user"),
1419
- name: Schema.String.pipe(field(10, "Name.")),
1420
- display_name: Schema.String.pipe(field(11, "Display name.")),
1421
- email: OptionalString.pipe(field(12, "Email address.")),
1422
- avatar_url: OptionalString.pipe(field(13, "Avatar image URL.")),
1423
- last_seen: OptionalTimestamp.pipe(field(14, "Time the user was last seen."))
1416
+ name: Schema.String.pipe(Schema.annotateKey({ description: "Name." })),
1417
+ display_name: Schema.String.pipe(Schema.annotateKey({ description: "Display name." })),
1418
+ email: OptionalString.pipe(Schema.annotateKey({ description: "Email address." })),
1419
+ avatar_url: OptionalString.pipe(Schema.annotateKey({ description: "Avatar image URL." })),
1420
+ last_seen: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the user was last seen." }))
1424
1421
  }).annotate({ description: "People from integrations, such as Slack, who create issues and comments." }).pipe(Iceberg.identifier("id"));
1425
1422
  const ExternalUserObjectSchema = ExternalUserSchema.mapFields((fields) => Struct.omit(fields, ["version"]));
1426
1423
  const CycleSchema = Schema.Struct({
1427
1424
  ...common("Cycle"),
1428
1425
  _deleted: deleted("cycle"),
1429
- number: Schema.Finite.pipe(field(10, "Cycle number within its team.")),
1430
- name: OptionalString.pipe(field(11, "Cycle name.")),
1431
- description: OptionalString.pipe(field(12, "Cycle description.")),
1432
- team_id: Ref.pipe(field(13, "Team.")),
1433
- starts_at: Timestamp.pipe(field(14, "Time the cycle starts.")),
1434
- ends_at: Timestamp.pipe(field(15, "Time the cycle ends.")),
1435
- completed_at: OptionalTimestamp.pipe(field(16, "Time the cycle was completed.")),
1436
- auto_archived_at: OptionalTimestamp.pipe(field(17, "Time the cycle was archived automatically.")),
1437
- progress: Schema.Finite.pipe(field(18, "Share of the scope completed, from 0 to 1."))
1426
+ number: Schema.Finite.pipe(Schema.annotateKey({ description: "Cycle number within its team." })),
1427
+ name: OptionalString.pipe(Schema.annotateKey({ description: "Cycle name." })),
1428
+ description: OptionalString.pipe(Schema.annotateKey({ description: "Cycle description." })),
1429
+ team_id: Ref.pipe(Schema.annotateKey({ description: "Team." })),
1430
+ starts_at: Timestamp.pipe(Schema.annotateKey({ description: "Time the cycle starts." })),
1431
+ ends_at: Timestamp.pipe(Schema.annotateKey({ description: "Time the cycle ends." })),
1432
+ completed_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the cycle was completed." })),
1433
+ auto_archived_at: OptionalTimestamp.pipe(Schema.annotateKey({ description: "Time the cycle was archived automatically." })),
1434
+ progress: Schema.Finite.pipe(Schema.annotateKey({ description: "Share of the scope completed, from 0 to 1." }))
1438
1435
  }).annotate({ description: "Linear cycles." }).pipe(Iceberg.identifier("id"));
1439
1436
  const CycleObjectSchema = CycleSchema.mapFields((fields) => Struct.omit(fields, ["version", "_deleted"]));
1440
1437
  //#endregion
@@ -1688,4 +1685,4 @@ const layerConfig = (config) => Layer.unwrap(Config.unwrap(config).pipe(Effect.m
1688
1685
  //#endregion
1689
1686
  export { InitiativeToProjectSchema as A, IssueHistorySchema as C, InitiativeLabelSchema as D, IssueSchema as E, CustomerStatusSchema as F, CustomerTierSchema as I, CommentSchema as L, DocumentSchema as M, CustomerNeedSchema as N, InitiativeRelationSchema as O, CustomerSchema as P, client_exports as R, AttachmentSchema as S, IssueRelationSchema as T, ProjectMilestoneSchema as _, CycleSchema as a, ProjectStatusSchema as b, TeamSchema as c, IssueToReleaseSchema as d, ReleaseNoteSchema as f, ProjectLabelSchema as g, ReleaseStageSchema as h, webhookPath as i, InitiativeUpdateSchema as j, InitiativeSchema as k, UserSchema as l, ReleaseSchema as m, connector_exports as n, ExternalUserSchema as o, ReleasePipelineSchema as p, layerConfig as r, TeamMembershipSchema as s, LinearConnector as t, WorkflowStateSchema as u, ProjectRelationSchema as v, IssueLabelSchema as w, ProjectUpdateSchema as x, ProjectSchema as y };
1690
1687
 
1691
- //# sourceMappingURL=src-Ci3_ltan.mjs.map
1688
+ //# sourceMappingURL=src-BbzySPR7.mjs.map