@linear/sdk 14.0.0 → 15.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index-cjs.js CHANGED
@@ -83504,12 +83504,24 @@ var OrganizationInviteStatus;
83504
83504
  OrganizationInviteStatus["Expired"] = "expired";
83505
83505
  OrganizationInviteStatus["Pending"] = "pending";
83506
83506
  })(OrganizationInviteStatus || (OrganizationInviteStatus = {}));
83507
+ /** How to treat NULL values, whether they should appear first or last */
83508
+ var PaginationNulls;
83509
+ (function (PaginationNulls) {
83510
+ PaginationNulls["First"] = "first";
83511
+ PaginationNulls["Last"] = "last";
83512
+ })(PaginationNulls || (PaginationNulls = {}));
83507
83513
  /** By which field should the pagination order by */
83508
83514
  var PaginationOrderBy;
83509
83515
  (function (PaginationOrderBy) {
83510
83516
  PaginationOrderBy["CreatedAt"] = "createdAt";
83511
83517
  PaginationOrderBy["UpdatedAt"] = "updatedAt";
83512
83518
  })(PaginationOrderBy || (PaginationOrderBy = {}));
83519
+ /** Whether to sort in ascending or descending order */
83520
+ var PaginationSortOrder;
83521
+ (function (PaginationSortOrder) {
83522
+ PaginationSortOrder["Ascending"] = "Ascending";
83523
+ PaginationSortOrder["Descending"] = "Descending";
83524
+ })(PaginationSortOrder || (PaginationSortOrder = {}));
83513
83525
  /** A type of project status. */
83514
83526
  var ProjectStatusType;
83515
83527
  (function (ProjectStatusType) {
@@ -85110,6 +85122,7 @@ const AuthOrganizationInviteFragmentDoc = {
85110
85122
  kind: "SelectionSet",
85111
85123
  selections: [
85112
85124
  { kind: "Field", name: { kind: "Name", value: "__typename" } },
85125
+ { kind: "Field", name: { kind: "Name", value: "expiresAt" } },
85113
85126
  { kind: "Field", name: { kind: "Name", value: "id" } },
85114
85127
  ],
85115
85128
  },
@@ -91436,6 +91449,14 @@ const TeamFragmentDoc = {
91436
91449
  selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
91437
91450
  },
91438
91451
  },
91452
+ {
91453
+ kind: "Field",
91454
+ name: { kind: "Name", value: "triageResponsibility" },
91455
+ selectionSet: {
91456
+ kind: "SelectionSet",
91457
+ selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
91458
+ },
91459
+ },
91439
91460
  { kind: "Field", name: { kind: "Name", value: "autoCloseStateId" } },
91440
91461
  { kind: "Field", name: { kind: "Name", value: "cycleCooldownTime" } },
91441
91462
  { kind: "Field", name: { kind: "Name", value: "cycleStartDay" } },
@@ -91875,7 +91896,6 @@ const TimeScheduleFragmentDoc = {
91875
91896
  { kind: "Field", name: { kind: "Name", value: "archivedAt" } },
91876
91897
  { kind: "Field", name: { kind: "Name", value: "createdAt" } },
91877
91898
  { kind: "Field", name: { kind: "Name", value: "id" } },
91878
- { kind: "Field", name: { kind: "Name", value: "error" } },
91879
91899
  ],
91880
91900
  },
91881
91901
  },
@@ -91939,6 +91959,23 @@ const TimeSchedulePayloadFragmentDoc = {
91939
91959
  },
91940
91960
  ],
91941
91961
  };
91962
+ const TriageResponsibilityManualSelectionFragmentDoc = {
91963
+ kind: "Document",
91964
+ definitions: [
91965
+ {
91966
+ kind: "FragmentDefinition",
91967
+ name: { kind: "Name", value: "TriageResponsibilityManualSelection" },
91968
+ typeCondition: { kind: "NamedType", name: { kind: "Name", value: "TriageResponsibilityManualSelection" } },
91969
+ selectionSet: {
91970
+ kind: "SelectionSet",
91971
+ selections: [
91972
+ { kind: "Field", name: { kind: "Name", value: "__typename" } },
91973
+ { kind: "Field", name: { kind: "Name", value: "userIds" } },
91974
+ ],
91975
+ },
91976
+ },
91977
+ ],
91978
+ };
91942
91979
  const TriageResponsibilityFragmentDoc = {
91943
91980
  kind: "Document",
91944
91981
  definitions: [
@@ -91950,14 +91987,14 @@ const TriageResponsibilityFragmentDoc = {
91950
91987
  kind: "SelectionSet",
91951
91988
  selections: [
91952
91989
  { kind: "Field", name: { kind: "Name", value: "__typename" } },
91953
- { kind: "Field", name: { kind: "Name", value: "schedule" } },
91954
- { kind: "Field", name: { kind: "Name", value: "manualSelection" } },
91955
91990
  {
91956
91991
  kind: "Field",
91957
- name: { kind: "Name", value: "integration" },
91992
+ name: { kind: "Name", value: "manualSelection" },
91958
91993
  selectionSet: {
91959
91994
  kind: "SelectionSet",
91960
- selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
91995
+ selections: [
91996
+ { kind: "FragmentSpread", name: { kind: "Name", value: "TriageResponsibilityManualSelection" } },
91997
+ ],
91961
91998
  },
91962
91999
  },
91963
92000
  { kind: "Field", name: { kind: "Name", value: "updatedAt" } },
@@ -91980,6 +92017,14 @@ const TriageResponsibilityFragmentDoc = {
91980
92017
  },
91981
92018
  },
91982
92019
  { kind: "Field", name: { kind: "Name", value: "id" } },
92020
+ {
92021
+ kind: "Field",
92022
+ name: { kind: "Name", value: "currentUser" },
92023
+ selectionSet: {
92024
+ kind: "SelectionSet",
92025
+ selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
92026
+ },
92027
+ },
91983
92028
  ],
91984
92029
  },
91985
92030
  },
@@ -92017,6 +92062,32 @@ const TriageResponsibilityConnectionFragmentDoc = {
92017
92062
  },
92018
92063
  ],
92019
92064
  };
92065
+ const TriageResponsibilityPayloadFragmentDoc = {
92066
+ kind: "Document",
92067
+ definitions: [
92068
+ {
92069
+ kind: "FragmentDefinition",
92070
+ name: { kind: "Name", value: "TriageResponsibilityPayload" },
92071
+ typeCondition: { kind: "NamedType", name: { kind: "Name", value: "TriageResponsibilityPayload" } },
92072
+ selectionSet: {
92073
+ kind: "SelectionSet",
92074
+ selections: [
92075
+ { kind: "Field", name: { kind: "Name", value: "__typename" } },
92076
+ { kind: "Field", name: { kind: "Name", value: "lastSyncId" } },
92077
+ { kind: "Field", name: { kind: "Name", value: "success" } },
92078
+ {
92079
+ kind: "Field",
92080
+ name: { kind: "Name", value: "triageResponsibility" },
92081
+ selectionSet: {
92082
+ kind: "SelectionSet",
92083
+ selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
92084
+ },
92085
+ },
92086
+ ],
92087
+ },
92088
+ },
92089
+ ],
92090
+ };
92020
92091
  const UploadFileHeaderFragmentDoc = {
92021
92092
  kind: "Document",
92022
92093
  definitions: [
@@ -99571,6 +99642,14 @@ const IssuesDocument = {
99571
99642
  variable: { kind: "Variable", name: { kind: "Name", value: "orderBy" } },
99572
99643
  type: { kind: "NamedType", name: { kind: "Name", value: "PaginationOrderBy" } },
99573
99644
  },
99645
+ {
99646
+ kind: "VariableDefinition",
99647
+ variable: { kind: "Variable", name: { kind: "Name", value: "sort" } },
99648
+ type: {
99649
+ kind: "ListType",
99650
+ type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "IssueSortInput" } } },
99651
+ },
99652
+ },
99574
99653
  ],
99575
99654
  selectionSet: {
99576
99655
  kind: "SelectionSet",
@@ -99614,6 +99693,11 @@ const IssuesDocument = {
99614
99693
  name: { kind: "Name", value: "orderBy" },
99615
99694
  value: { kind: "Variable", name: { kind: "Name", value: "orderBy" } },
99616
99695
  },
99696
+ {
99697
+ kind: "Argument",
99698
+ name: { kind: "Name", value: "sort" },
99699
+ value: { kind: "Variable", name: { kind: "Name", value: "sort" } },
99700
+ },
99617
99701
  ],
99618
99702
  selectionSet: {
99619
99703
  kind: "SelectionSet",
@@ -116541,7 +116625,9 @@ var _generated_documents = /*#__PURE__*/Object.freeze({
116541
116625
  get OAuthClientApprovalStatus () { return OAuthClientApprovalStatus; },
116542
116626
  get OrganizationDomainAuthType () { return OrganizationDomainAuthType; },
116543
116627
  get OrganizationInviteStatus () { return OrganizationInviteStatus; },
116628
+ get PaginationNulls () { return PaginationNulls; },
116544
116629
  get PaginationOrderBy () { return PaginationOrderBy; },
116630
+ get PaginationSortOrder () { return PaginationSortOrder; },
116545
116631
  get ProjectStatusType () { return ProjectStatusType; },
116546
116632
  get ProjectTab () { return ProjectTab; },
116547
116633
  get ProjectUpdateHealthType () { return ProjectUpdateHealthType; },
@@ -116799,8 +116885,10 @@ var _generated_documents = /*#__PURE__*/Object.freeze({
116799
116885
  TimeScheduleFragmentDoc: TimeScheduleFragmentDoc,
116800
116886
  TimeScheduleConnectionFragmentDoc: TimeScheduleConnectionFragmentDoc,
116801
116887
  TimeSchedulePayloadFragmentDoc: TimeSchedulePayloadFragmentDoc,
116888
+ TriageResponsibilityManualSelectionFragmentDoc: TriageResponsibilityManualSelectionFragmentDoc,
116802
116889
  TriageResponsibilityFragmentDoc: TriageResponsibilityFragmentDoc,
116803
116890
  TriageResponsibilityConnectionFragmentDoc: TriageResponsibilityConnectionFragmentDoc,
116891
+ TriageResponsibilityPayloadFragmentDoc: TriageResponsibilityPayloadFragmentDoc,
116804
116892
  UploadFileHeaderFragmentDoc: UploadFileHeaderFragmentDoc,
116805
116893
  UploadFileFragmentDoc: UploadFileFragmentDoc,
116806
116894
  UploadPayloadFragmentDoc: UploadPayloadFragmentDoc,
@@ -117797,7 +117885,9 @@ class AuthOrganizationDomain extends Request {
117797
117885
  */
117798
117886
  class AuthOrganizationInvite extends Request {
117799
117887
  constructor(request, data) {
117888
+ var _a;
117800
117889
  super(request);
117890
+ this.expiresAt = (_a = parseDate(data.expiresAt)) !== null && _a !== void 0 ? _a : undefined;
117801
117891
  this.id = data.id;
117802
117892
  }
117803
117893
  }
@@ -123109,18 +123199,17 @@ class TemplatePayload extends Request {
123109
123199
  */
123110
123200
  class TimeSchedule extends Request {
123111
123201
  constructor(request, data) {
123112
- var _a, _b, _c, _d, _e, _f, _g;
123202
+ var _a, _b, _c, _d, _e, _f;
123113
123203
  super(request);
123114
123204
  this.archivedAt = (_a = parseDate(data.archivedAt)) !== null && _a !== void 0 ? _a : undefined;
123115
123205
  this.createdAt = (_b = parseDate(data.createdAt)) !== null && _b !== void 0 ? _b : new Date();
123116
- this.error = (_c = data.error) !== null && _c !== void 0 ? _c : undefined;
123117
- this.externalId = (_d = data.externalId) !== null && _d !== void 0 ? _d : undefined;
123118
- this.externalUrl = (_e = data.externalUrl) !== null && _e !== void 0 ? _e : undefined;
123206
+ this.externalId = (_c = data.externalId) !== null && _c !== void 0 ? _c : undefined;
123207
+ this.externalUrl = (_d = data.externalUrl) !== null && _d !== void 0 ? _d : undefined;
123119
123208
  this.id = data.id;
123120
123209
  this.name = data.name;
123121
- this.updatedAt = (_f = parseDate(data.updatedAt)) !== null && _f !== void 0 ? _f : new Date();
123210
+ this.updatedAt = (_e = parseDate(data.updatedAt)) !== null && _e !== void 0 ? _e : new Date();
123122
123211
  this.entries = data.entries.map(node => new TimeScheduleEntry(request, node));
123123
- this._integration = (_g = data.integration) !== null && _g !== void 0 ? _g : undefined;
123212
+ this._integration = (_f = data.integration) !== null && _f !== void 0 ? _f : undefined;
123124
123213
  }
123125
123214
  /** The identifier of the Linear integration populating the schedule. */
123126
123215
  get integration() {
@@ -123181,20 +123270,22 @@ class TimeSchedulePayload extends Request {
123181
123270
  */
123182
123271
  class TriageResponsibility extends Request {
123183
123272
  constructor(request, data) {
123184
- var _a, _b, _c, _d, _e;
123273
+ var _a, _b, _c, _d;
123185
123274
  super(request);
123186
123275
  this.archivedAt = (_a = parseDate(data.archivedAt)) !== null && _a !== void 0 ? _a : undefined;
123187
123276
  this.createdAt = (_b = parseDate(data.createdAt)) !== null && _b !== void 0 ? _b : new Date();
123188
123277
  this.id = data.id;
123189
- this.manualSelection = (_c = data.manualSelection) !== null && _c !== void 0 ? _c : undefined;
123190
- this.schedule = (_d = data.schedule) !== null && _d !== void 0 ? _d : undefined;
123191
- this.updatedAt = (_e = parseDate(data.updatedAt)) !== null && _e !== void 0 ? _e : new Date();
123192
- this._integration = data.integration;
123278
+ this.updatedAt = (_c = parseDate(data.updatedAt)) !== null && _c !== void 0 ? _c : new Date();
123279
+ this.manualSelection = data.manualSelection
123280
+ ? new TriageResponsibilityManualSelection(request, data.manualSelection)
123281
+ : undefined;
123282
+ this._currentUser = (_d = data.currentUser) !== null && _d !== void 0 ? _d : undefined;
123193
123283
  this._team = data.team;
123194
123284
  }
123195
- /** The integration used for scheduling. */
123196
- get integration() {
123197
- return new IntegrationQuery(this._request).fetch(this._integration.id);
123285
+ /** The user currently responsible for triage. */
123286
+ get currentUser() {
123287
+ var _a, _b;
123288
+ return ((_a = this._currentUser) === null || _a === void 0 ? void 0 : _a.id) ? new UserQuery(this._request).fetch((_b = this._currentUser) === null || _b === void 0 ? void 0 : _b.id) : undefined;
123198
123289
  }
123199
123290
  /** The team to which the triage responsibility belongs to. */
123200
123291
  get team() {
@@ -123213,6 +123304,31 @@ class TriageResponsibilityConnection extends Connection {
123213
123304
  super(request, fetch, data.nodes.map(node => new TriageResponsibility(request, node)), new PageInfo(request, data.pageInfo));
123214
123305
  }
123215
123306
  }
123307
+ /**
123308
+ * TriageResponsibilityManualSelection model
123309
+ *
123310
+ * @param request - function to call the graphql client
123311
+ * @param data - L.TriageResponsibilityManualSelectionFragment response data
123312
+ */
123313
+ class TriageResponsibilityManualSelection extends Request {
123314
+ constructor(request, data) {
123315
+ super(request);
123316
+ this.userIds = data.userIds;
123317
+ }
123318
+ }
123319
+ /**
123320
+ * TriageResponsibilityPayload model
123321
+ *
123322
+ * @param request - function to call the graphql client
123323
+ * @param data - L.TriageResponsibilityPayloadFragment response data
123324
+ */
123325
+ class TriageResponsibilityPayload extends Request {
123326
+ constructor(request, data) {
123327
+ super(request);
123328
+ this.lastSyncId = data.lastSyncId;
123329
+ this.success = data.success;
123330
+ }
123331
+ }
123216
123332
  /**
123217
123333
  * Object representing Google Cloud upload policy, plus additional data.
123218
123334
  *
@@ -136806,6 +136922,8 @@ exports.TimeScheduleEntry = TimeScheduleEntry;
136806
136922
  exports.TimeSchedulePayload = TimeSchedulePayload;
136807
136923
  exports.TriageResponsibility = TriageResponsibility;
136808
136924
  exports.TriageResponsibilityConnection = TriageResponsibilityConnection;
136925
+ exports.TriageResponsibilityManualSelection = TriageResponsibilityManualSelection;
136926
+ exports.TriageResponsibilityPayload = TriageResponsibilityPayload;
136809
136927
  exports.UnarchiveIssueMutation = UnarchiveIssueMutation;
136810
136928
  exports.UnarchiveNotificationMutation = UnarchiveNotificationMutation;
136811
136929
  exports.UnarchiveProjectMutation = UnarchiveProjectMutation;