@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.
- package/LICENSE.txt +201 -0
- package/dist/index.mjs +1 -1
- package/dist/main.mjs +6 -4
- package/dist/main.mjs.map +1 -1
- package/dist/{src-Ci3_ltan.mjs → src-BbzySPR7.mjs} +343 -346
- package/dist/src-BbzySPR7.mjs.map +1 -0
- package/package.json +17 -17
- package/src/create-table.ts +6 -1
- package/src/main.ts +8 -2
- package/src/schemas/comments.ts +36 -16
- package/src/schemas/customers.ts +43 -27
- package/src/schemas/documents.ts +24 -16
- package/src/schemas/initiatives.ts +79 -43
- package/src/schemas/issues.ts +179 -97
- package/src/schemas/projects.ts +118 -62
- package/src/schemas/releases.ts +58 -45
- package/src/schemas/shared.ts +25 -23
- package/src/schemas/teams.ts +87 -54
- package/src/start.ts +2 -2
- package/dist/src-Ci3_ltan.mjs.map +0 -1
|
@@ -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 = (
|
|
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(
|
|
119
|
-
version: Schema.Date.pipe(
|
|
120
|
-
created_at: Timestamp.pipe(
|
|
121
|
-
updated_at: Timestamp.pipe(
|
|
122
|
-
archived_at: Schema.NullOr(Timestamp).pipe(
|
|
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(
|
|
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(
|
|
131
|
-
user_id: OptionalRef.pipe(
|
|
132
|
-
external_user_id: OptionalRef.pipe(
|
|
133
|
-
issue_id: OptionalString.pipe(
|
|
134
|
-
project_id: OptionalString.pipe(
|
|
135
|
-
project_update_id: OptionalString.pipe(
|
|
136
|
-
initiative_id: OptionalString.pipe(
|
|
137
|
-
initiative_update_id: OptionalString.pipe(
|
|
138
|
-
document_content_id: OptionalString.pipe(
|
|
139
|
-
parent_id: OptionalString.pipe(
|
|
140
|
-
quoted_text: OptionalString.pipe(
|
|
141
|
-
edited_at: OptionalTimestamp.pipe(
|
|
142
|
-
resolved_at: OptionalTimestamp.pipe(
|
|
143
|
-
resolving_user_id: OptionalRef.pipe(
|
|
144
|
-
url: Schema.String.pipe(
|
|
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(
|
|
348
|
-
domains:
|
|
349
|
-
external_ids:
|
|
350
|
-
logo_url: OptionalString.pipe(
|
|
351
|
-
owner_id: OptionalRef.pipe(
|
|
352
|
-
status_id: Ref.pipe(
|
|
353
|
-
tier_id: OptionalRef.pipe(
|
|
354
|
-
revenue: Schema.NullOr(Long).pipe(
|
|
355
|
-
size: Schema.NullOr(Schema.Finite).pipe(
|
|
356
|
-
approximate_need_count: Schema.Finite.pipe(
|
|
357
|
-
url: Schema.String.pipe(
|
|
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(
|
|
364
|
-
issue_id: OptionalRef.pipe(
|
|
365
|
-
project_id: OptionalRef.pipe(
|
|
366
|
-
original_issue_id: OptionalRef.pipe(
|
|
367
|
-
comment_id: OptionalRef.pipe(
|
|
368
|
-
attachment_id: OptionalRef.pipe(
|
|
369
|
-
creator_id: OptionalRef.pipe(
|
|
370
|
-
body: OptionalString.pipe(
|
|
371
|
-
priority: Schema.Finite.pipe(
|
|
372
|
-
url: OptionalString.pipe(
|
|
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(
|
|
378
|
-
display_name: Schema.String.pipe(
|
|
379
|
-
description: OptionalString.pipe(
|
|
380
|
-
color: Schema.String.pipe(
|
|
381
|
-
position: Schema.Finite.pipe(
|
|
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(
|
|
476
|
-
content: OptionalString.pipe(
|
|
477
|
-
url: Schema.String.pipe(
|
|
478
|
-
icon: OptionalString.pipe(
|
|
479
|
-
color: OptionalString.pipe(
|
|
480
|
-
creator_id: OptionalRef.pipe(
|
|
481
|
-
updated_by_id: OptionalRef.pipe(
|
|
482
|
-
project_id: OptionalRef.pipe(
|
|
483
|
-
initiative_id: OptionalRef.pipe(
|
|
484
|
-
issue_id: OptionalRef.pipe(
|
|
485
|
-
cycle_id: OptionalRef.pipe(
|
|
486
|
-
team_id: OptionalRef.pipe(
|
|
487
|
-
parent_document_id: OptionalRef.pipe(
|
|
488
|
-
hidden_at: OptionalTimestamp.pipe(
|
|
489
|
-
trashed: Schema.NullOr(Schema.Boolean).pipe(
|
|
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(
|
|
524
|
-
description: OptionalString.pipe(
|
|
525
|
-
content: OptionalString.pipe(
|
|
526
|
-
url: Schema.String.pipe(
|
|
527
|
-
icon: OptionalString.pipe(
|
|
528
|
-
color: OptionalString.pipe(
|
|
529
|
-
status: Schema.String.pipe(
|
|
530
|
-
health: OptionalString.pipe(
|
|
531
|
-
health_updated_at: OptionalTimestamp.pipe(
|
|
532
|
-
priority: Long.pipe(
|
|
533
|
-
owner_id: OptionalRef.pipe(
|
|
534
|
-
creator_id: OptionalRef.pipe(
|
|
535
|
-
parent_initiative_id: OptionalRef.pipe(
|
|
536
|
-
target_date: OptionalString.pipe(
|
|
537
|
-
started_at: OptionalTimestamp.pipe(
|
|
538
|
-
completed_at: OptionalTimestamp.pipe(
|
|
539
|
-
canceled_at: OptionalTimestamp.pipe(
|
|
540
|
-
label_ids:
|
|
541
|
-
visibility: Schema.String.pipe(
|
|
542
|
-
trashed: Schema.NullOr(Schema.Boolean).pipe(
|
|
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(
|
|
549
|
-
user_id: Ref.pipe(
|
|
550
|
-
body: Schema.String.pipe(
|
|
551
|
-
health: Schema.String.pipe(
|
|
552
|
-
url: Schema.String.pipe(
|
|
553
|
-
edited_at: OptionalTimestamp.pipe(
|
|
554
|
-
comment_count: Long.pipe(
|
|
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(
|
|
560
|
-
description: OptionalString.pipe(
|
|
561
|
-
color: Schema.String.pipe(
|
|
562
|
-
is_group: Schema.Boolean.pipe(
|
|
563
|
-
parent_id: OptionalRef.pipe(
|
|
564
|
-
creator_id: OptionalRef.pipe(
|
|
565
|
-
retired_at: OptionalTimestamp.pipe(
|
|
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(
|
|
571
|
-
related_initiative_id: Ref.pipe(
|
|
572
|
-
sort_order: Schema.Finite.pipe(
|
|
573
|
-
user_id: OptionalRef.pipe(
|
|
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(
|
|
579
|
-
project_id: Ref.pipe(
|
|
580
|
-
sort_order: Schema.String.pipe(
|
|
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(
|
|
696
|
-
number: Schema.Finite.pipe(
|
|
697
|
-
title: Schema.String.pipe(
|
|
698
|
-
description: OptionalString.pipe(
|
|
699
|
-
url: Schema.String.pipe(
|
|
700
|
-
branch_name: Schema.String.pipe(
|
|
701
|
-
priority: Schema.Finite.pipe(
|
|
702
|
-
priority_label: Schema.String.pipe(
|
|
703
|
-
estimate: Schema.NullOr(Schema.Finite).pipe(
|
|
704
|
-
due_date: OptionalString.pipe(
|
|
705
|
-
creator_id: OptionalRef.pipe(
|
|
706
|
-
assignee_id: OptionalRef.pipe(
|
|
707
|
-
delegate_id: OptionalRef.pipe(
|
|
708
|
-
snoozed_by_id: OptionalRef.pipe(
|
|
709
|
-
state_id: Ref.pipe(
|
|
710
|
-
team_id: Ref.pipe(
|
|
711
|
-
project_id: OptionalRef.pipe(
|
|
712
|
-
project_milestone_id: OptionalRef.pipe(
|
|
713
|
-
cycle_id: OptionalRef.pipe(
|
|
714
|
-
parent_id: OptionalRef.pipe(
|
|
715
|
-
source_comment_id: OptionalRef.pipe(
|
|
716
|
-
external_user_creator_id: OptionalRef.pipe(
|
|
717
|
-
label_ids:
|
|
718
|
-
previous_identifiers:
|
|
719
|
-
started_at: OptionalTimestamp.pipe(
|
|
720
|
-
completed_at: OptionalTimestamp.pipe(
|
|
721
|
-
canceled_at: OptionalTimestamp.pipe(
|
|
722
|
-
started_triage_at: OptionalTimestamp.pipe(
|
|
723
|
-
triaged_at: OptionalTimestamp.pipe(
|
|
724
|
-
auto_closed_at: OptionalTimestamp.pipe(
|
|
725
|
-
auto_archived_at: OptionalTimestamp.pipe(
|
|
726
|
-
added_to_cycle_at: OptionalTimestamp.pipe(
|
|
727
|
-
added_to_project_at: OptionalTimestamp.pipe(
|
|
728
|
-
added_to_team_at: OptionalTimestamp.pipe(
|
|
729
|
-
snoozed_until_at: OptionalTimestamp.pipe(
|
|
730
|
-
sla_type: OptionalString.pipe(
|
|
731
|
-
sla_started_at: OptionalTimestamp.pipe(
|
|
732
|
-
sla_breaches_at: OptionalTimestamp.pipe(
|
|
733
|
-
customer_ticket_count: Long.pipe(
|
|
734
|
-
integration_source_type: OptionalString.pipe(
|
|
735
|
-
trashed: Schema.NullOr(Schema.Boolean).pipe(
|
|
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(
|
|
741
|
-
actor_id: OptionalString.pipe(
|
|
742
|
-
from_state_id: OptionalString.pipe(
|
|
743
|
-
to_state_id: OptionalString.pipe(
|
|
744
|
-
from_assignee_id: OptionalString.pipe(
|
|
745
|
-
to_assignee_id: OptionalString.pipe(
|
|
746
|
-
from_cycle_id: OptionalString.pipe(
|
|
747
|
-
to_cycle_id: OptionalString.pipe(
|
|
748
|
-
from_project_id: OptionalString.pipe(
|
|
749
|
-
to_project_id: OptionalString.pipe(
|
|
750
|
-
from_parent_id: OptionalString.pipe(
|
|
751
|
-
to_parent_id: OptionalString.pipe(
|
|
752
|
-
from_team_id: OptionalString.pipe(
|
|
753
|
-
to_team_id: OptionalString.pipe(
|
|
754
|
-
from_priority: Schema.NullOr(Schema.Finite).pipe(
|
|
755
|
-
to_priority: Schema.NullOr(Schema.Finite).pipe(
|
|
756
|
-
from_estimate: Schema.NullOr(Schema.Finite).pipe(
|
|
757
|
-
to_estimate: Schema.NullOr(Schema.Finite).pipe(
|
|
758
|
-
from_due_date: OptionalString.pipe(
|
|
759
|
-
to_due_date: OptionalString.pipe(
|
|
760
|
-
from_title: OptionalString.pipe(
|
|
761
|
-
to_title: OptionalString.pipe(
|
|
762
|
-
added_label_ids: Schema.NullOr(
|
|
763
|
-
removed_label_ids: Schema.NullOr(
|
|
764
|
-
attachment_id: OptionalString.pipe(
|
|
765
|
-
customer_need_id: OptionalString.pipe(
|
|
766
|
-
to_converted_project_id: OptionalString.pipe(
|
|
767
|
-
updated_description: Schema.NullOr(Schema.Boolean).pipe(
|
|
768
|
-
archived: Schema.NullOr(Schema.Boolean).pipe(
|
|
769
|
-
trashed: Schema.NullOr(Schema.Boolean).pipe(
|
|
770
|
-
auto_archived: Schema.NullOr(Schema.Boolean).pipe(
|
|
771
|
-
auto_closed: Schema.NullOr(Schema.Boolean).pipe(
|
|
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(
|
|
777
|
-
related_issue_id: Ref.pipe(
|
|
778
|
-
type: Schema.String.pipe(
|
|
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(
|
|
785
|
-
creator_id: OptionalRef.pipe(
|
|
786
|
-
external_user_creator_id: OptionalRef.pipe(
|
|
787
|
-
title: Schema.String.pipe(
|
|
788
|
-
subtitle: OptionalString.pipe(
|
|
789
|
-
url: Schema.String.pipe(
|
|
790
|
-
source_type: OptionalString.pipe(
|
|
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(
|
|
797
|
-
description: OptionalString.pipe(
|
|
798
|
-
color: Schema.String.pipe(
|
|
799
|
-
is_group: Schema.Boolean.pipe(
|
|
800
|
-
parent_id: OptionalRef.pipe(
|
|
801
|
-
team_id: OptionalRef.pipe(
|
|
802
|
-
creator_id: OptionalRef.pipe(
|
|
803
|
-
retired_at: OptionalTimestamp.pipe(
|
|
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(
|
|
987
|
-
description: Schema.String.pipe(
|
|
988
|
-
content: OptionalString.pipe(
|
|
989
|
-
url: Schema.String.pipe(
|
|
990
|
-
icon: OptionalString.pipe(
|
|
991
|
-
color: Schema.String.pipe(
|
|
992
|
-
status_id: Ref.pipe(
|
|
993
|
-
priority: Long.pipe(
|
|
994
|
-
priority_label: Schema.String.pipe(
|
|
995
|
-
health: OptionalString.pipe(
|
|
996
|
-
health_updated_at: OptionalTimestamp.pipe(
|
|
997
|
-
progress: Schema.Finite.pipe(
|
|
998
|
-
scope: Schema.Finite.pipe(
|
|
999
|
-
lead_id: OptionalRef.pipe(
|
|
1000
|
-
creator_id: OptionalRef.pipe(
|
|
1001
|
-
converted_from_issue_id: OptionalRef.pipe(
|
|
1002
|
-
start_date: OptionalString.pipe(
|
|
1003
|
-
target_date: OptionalString.pipe(
|
|
1004
|
-
started_at: OptionalTimestamp.pipe(
|
|
1005
|
-
completed_at: OptionalTimestamp.pipe(
|
|
1006
|
-
canceled_at: OptionalTimestamp.pipe(
|
|
1007
|
-
auto_archived_at: OptionalTimestamp.pipe(
|
|
1008
|
-
label_ids:
|
|
1009
|
-
team_ids: RefList
|
|
1010
|
-
member_ids: RefList
|
|
1011
|
-
trashed: Schema.NullOr(Schema.Boolean).pipe(
|
|
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(
|
|
1017
|
-
description: OptionalString.pipe(
|
|
1018
|
-
project_id: Ref.pipe(
|
|
1019
|
-
target_date: OptionalString.pipe(
|
|
1020
|
-
status: Schema.String.pipe(
|
|
1021
|
-
progress: Schema.Finite.pipe(
|
|
1022
|
-
sort_order: Schema.Finite.pipe(
|
|
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(
|
|
1029
|
-
user_id: Ref.pipe(
|
|
1030
|
-
body: Schema.String.pipe(
|
|
1031
|
-
health: Schema.String.pipe(
|
|
1032
|
-
url: Schema.String.pipe(
|
|
1033
|
-
edited_at: OptionalTimestamp.pipe(
|
|
1034
|
-
comment_count: Long.pipe(
|
|
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(
|
|
1040
|
-
type: Schema.String.pipe(
|
|
1041
|
-
color: Schema.String.pipe(
|
|
1042
|
-
description: OptionalString.pipe(
|
|
1043
|
-
position: Schema.Finite.pipe(
|
|
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(
|
|
1050
|
-
description: OptionalString.pipe(
|
|
1051
|
-
color: Schema.String.pipe(
|
|
1052
|
-
is_group: Schema.Boolean.pipe(
|
|
1053
|
-
parent_id: OptionalRef.pipe(
|
|
1054
|
-
creator_id: OptionalRef.pipe(
|
|
1055
|
-
retired_at: OptionalTimestamp.pipe(
|
|
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(
|
|
1061
|
-
project_id: Ref.pipe(
|
|
1062
|
-
project_milestone_id: OptionalRef.pipe(
|
|
1063
|
-
anchor_type: Schema.String.pipe(
|
|
1064
|
-
related_project_id: Ref.pipe(
|
|
1065
|
-
related_project_milestone_id: OptionalRef.pipe(
|
|
1066
|
-
related_anchor_type: Schema.String.pipe(
|
|
1067
|
-
user_id: OptionalRef.pipe(
|
|
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(
|
|
1209
|
-
description: OptionalString.pipe(
|
|
1210
|
-
release_version: OptionalString.pipe(
|
|
1211
|
-
url: Schema.String.pipe(
|
|
1212
|
-
commit_sha: OptionalString.pipe(
|
|
1213
|
-
pipeline_id: Ref.pipe(
|
|
1214
|
-
stage_id: Ref.pipe(
|
|
1215
|
-
creator_id: OptionalRef.pipe(
|
|
1216
|
-
start_date: OptionalString.pipe(
|
|
1217
|
-
target_date: OptionalString.pipe(
|
|
1218
|
-
started_at: OptionalTimestamp.pipe(
|
|
1219
|
-
completed_at: OptionalTimestamp.pipe(
|
|
1220
|
-
canceled_at: OptionalTimestamp.pipe(
|
|
1221
|
-
trashed: Schema.NullOr(Schema.Boolean).pipe(
|
|
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(
|
|
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
|
-
})),
|
|
1231
|
-
url: Schema.String.pipe(
|
|
1232
|
-
pipeline_id: Ref.pipe(
|
|
1233
|
-
release_ids:
|
|
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(
|
|
1239
|
-
type: Schema.String.pipe(
|
|
1240
|
-
is_production: Schema.Boolean.pipe(
|
|
1241
|
-
url: Schema.String.pipe(
|
|
1242
|
-
include_path_patterns:
|
|
1243
|
-
approximate_release_count: Long.pipe(
|
|
1244
|
-
trashed: Schema.NullOr(Schema.Boolean).pipe(
|
|
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(
|
|
1250
|
-
type: Schema.String.pipe(
|
|
1251
|
-
color: Schema.String.pipe(
|
|
1252
|
-
position: Schema.Finite.pipe(
|
|
1253
|
-
frozen: Schema.Boolean.pipe(
|
|
1254
|
-
pipeline_id: Ref.pipe(
|
|
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(
|
|
1260
|
-
release_id: Ref.pipe(
|
|
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(
|
|
1364
|
-
key: Schema.String.pipe(
|
|
1365
|
-
display_name: Schema.String.pipe(
|
|
1366
|
-
description: OptionalString.pipe(
|
|
1367
|
-
visibility: Schema.String.pipe(
|
|
1368
|
-
parent_id: OptionalRef.pipe(
|
|
1369
|
-
timezone: Schema.String.pipe(
|
|
1370
|
-
cycles_enabled: Schema.Boolean.pipe(
|
|
1371
|
-
cycle_duration: Schema.Finite.pipe(
|
|
1372
|
-
cycle_cooldown_time: Schema.Finite.pipe(
|
|
1373
|
-
cycle_start_day: Schema.Finite.pipe(
|
|
1374
|
-
triage_enabled: Schema.Boolean.pipe(
|
|
1375
|
-
issue_estimation_type: Schema.String.pipe(
|
|
1376
|
-
default_issue_estimate: Schema.Finite.pipe(
|
|
1377
|
-
auto_archive_period: Schema.Finite.pipe(
|
|
1378
|
-
auto_close_period: Schema.NullOr(Schema.Finite).pipe(
|
|
1379
|
-
retired_at: OptionalTimestamp.pipe(
|
|
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(
|
|
1385
|
-
user_id: Ref.pipe(
|
|
1386
|
-
owner: Schema.Boolean.pipe(
|
|
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(
|
|
1392
|
-
type: Schema.String.pipe(
|
|
1393
|
-
color: Schema.String.pipe(
|
|
1394
|
-
description: OptionalString.pipe(
|
|
1395
|
-
position: Schema.Finite.pipe(
|
|
1396
|
-
team_id: Ref.pipe(
|
|
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(
|
|
1403
|
-
display_name: Schema.String.pipe(
|
|
1404
|
-
email: Schema.String.pipe(
|
|
1405
|
-
avatar_url: OptionalString.pipe(
|
|
1406
|
-
title: OptionalString.pipe(
|
|
1407
|
-
timezone: OptionalString.pipe(
|
|
1408
|
-
active: Schema.Boolean.pipe(
|
|
1409
|
-
admin: Schema.Boolean.pipe(
|
|
1410
|
-
owner: Schema.Boolean.pipe(
|
|
1411
|
-
guest: Schema.Boolean.pipe(
|
|
1412
|
-
app: Schema.Boolean.pipe(
|
|
1413
|
-
last_seen: OptionalTimestamp.pipe(
|
|
1414
|
-
url: Schema.String.pipe(
|
|
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(
|
|
1420
|
-
display_name: Schema.String.pipe(
|
|
1421
|
-
email: OptionalString.pipe(
|
|
1422
|
-
avatar_url: OptionalString.pipe(
|
|
1423
|
-
last_seen: OptionalTimestamp.pipe(
|
|
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(
|
|
1430
|
-
name: OptionalString.pipe(
|
|
1431
|
-
description: OptionalString.pipe(
|
|
1432
|
-
team_id: Ref.pipe(
|
|
1433
|
-
starts_at: Timestamp.pipe(
|
|
1434
|
-
ends_at: Timestamp.pipe(
|
|
1435
|
-
completed_at: OptionalTimestamp.pipe(
|
|
1436
|
-
auto_archived_at: OptionalTimestamp.pipe(
|
|
1437
|
-
progress: Schema.Finite.pipe(
|
|
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-
|
|
1688
|
+
//# sourceMappingURL=src-BbzySPR7.mjs.map
|