@linear/sdk 15.0.0 → 16.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-umd.js CHANGED
@@ -9,7 +9,7 @@
9
9
  var crypto__default = /*#__PURE__*/_interopDefaultLegacy(crypto);
10
10
 
11
11
  (function() {
12
- const env = {"npm_package_name":"@linear/sdk","npm_package_version":"15.0.0"};
12
+ const env = {"npm_package_name":"@linear/sdk","npm_package_version":"16.0.0"};
13
13
  try {
14
14
  if (process) {
15
15
  process.env = Object.assign({}, process.env);
@@ -1440,6 +1440,7 @@
1440
1440
  IntegrationService["JiraPersonal"] = "jiraPersonal";
1441
1441
  IntegrationService["Loom"] = "loom";
1442
1442
  IntegrationService["Notion"] = "notion";
1443
+ IntegrationService["Opsgenie"] = "opsgenie";
1443
1444
  IntegrationService["PagerDuty"] = "pagerDuty";
1444
1445
  IntegrationService["Sentry"] = "sentry";
1445
1446
  IntegrationService["Slack"] = "slack";
@@ -3692,20 +3693,18 @@
3692
3693
  },
3693
3694
  ],
3694
3695
  };
3695
- const PagerDutyScheduleInfoFragmentDoc = {
3696
+ const OpsgenieSettingsFragmentDoc = {
3696
3697
  kind: "Document",
3697
3698
  definitions: [
3698
3699
  {
3699
3700
  kind: "FragmentDefinition",
3700
- name: { kind: "Name", value: "PagerDutyScheduleInfo" },
3701
- typeCondition: { kind: "NamedType", name: { kind: "Name", value: "PagerDutyScheduleInfo" } },
3701
+ name: { kind: "Name", value: "OpsgenieSettings" },
3702
+ typeCondition: { kind: "NamedType", name: { kind: "Name", value: "OpsgenieSettings" } },
3702
3703
  selectionSet: {
3703
3704
  kind: "SelectionSet",
3704
3705
  selections: [
3705
3706
  { kind: "Field", name: { kind: "Name", value: "__typename" } },
3706
- { kind: "Field", name: { kind: "Name", value: "scheduleId" } },
3707
- { kind: "Field", name: { kind: "Name", value: "scheduleName" } },
3708
- { kind: "Field", name: { kind: "Name", value: "url" } },
3707
+ { kind: "Field", name: { kind: "Name", value: "apiFailedWithUnauthorizedErrorAt" } },
3709
3708
  ],
3710
3709
  },
3711
3710
  },
@@ -3722,14 +3721,7 @@
3722
3721
  kind: "SelectionSet",
3723
3722
  selections: [
3724
3723
  { kind: "Field", name: { kind: "Name", value: "__typename" } },
3725
- {
3726
- kind: "Field",
3727
- name: { kind: "Name", value: "scheduleMapping" },
3728
- selectionSet: {
3729
- kind: "SelectionSet",
3730
- selections: [{ kind: "FragmentSpread", name: { kind: "Name", value: "PagerDutyScheduleInfo" } }],
3731
- },
3732
- },
3724
+ { kind: "Field", name: { kind: "Name", value: "apiFailedWithUnauthorizedErrorAt" } },
3733
3725
  ],
3734
3726
  },
3735
3727
  },
@@ -3970,6 +3962,14 @@
3970
3962
  selections: [{ kind: "FragmentSpread", name: { kind: "Name", value: "NotionSettings" } }],
3971
3963
  },
3972
3964
  },
3965
+ {
3966
+ kind: "Field",
3967
+ name: { kind: "Name", value: "opsgenie" },
3968
+ selectionSet: {
3969
+ kind: "SelectionSet",
3970
+ selections: [{ kind: "FragmentSpread", name: { kind: "Name", value: "OpsgenieSettings" } }],
3971
+ },
3972
+ },
3973
3973
  {
3974
3974
  kind: "Field",
3975
3975
  name: { kind: "Name", value: "pagerDuty" },
@@ -9550,7 +9550,6 @@
9550
9550
  { kind: "Field", name: { kind: "Name", value: "slackNewIssue" } },
9551
9551
  { kind: "Field", name: { kind: "Name", value: "slackIssueStatuses" } },
9552
9552
  { kind: "Field", name: { kind: "Name", value: "triageEnabled" } },
9553
- { kind: "Field", name: { kind: "Name", value: "issueSortOrderDefaultToBottom" } },
9554
9553
  ],
9555
9554
  },
9556
9555
  },
@@ -15770,6 +15769,11 @@
15770
15769
  operation: "query",
15771
15770
  name: { kind: "Name", value: "issueFilterSuggestion" },
15772
15771
  variableDefinitions: [
15772
+ {
15773
+ kind: "VariableDefinition",
15774
+ variable: { kind: "Variable", name: { kind: "Name", value: "projectId" } },
15775
+ type: { kind: "NamedType", name: { kind: "Name", value: "String" } },
15776
+ },
15773
15777
  {
15774
15778
  kind: "VariableDefinition",
15775
15779
  variable: { kind: "Variable", name: { kind: "Name", value: "prompt" } },
@@ -15783,6 +15787,11 @@
15783
15787
  kind: "Field",
15784
15788
  name: { kind: "Name", value: "issueFilterSuggestion" },
15785
15789
  arguments: [
15790
+ {
15791
+ kind: "Argument",
15792
+ name: { kind: "Name", value: "projectId" },
15793
+ value: { kind: "Variable", name: { kind: "Name", value: "projectId" } },
15794
+ },
15786
15795
  {
15787
15796
  kind: "Argument",
15788
15797
  name: { kind: "Name", value: "prompt" },
@@ -34675,7 +34684,7 @@
34675
34684
  JiraSettingsFragmentDoc: JiraSettingsFragmentDoc,
34676
34685
  JiraPersonalSettingsFragmentDoc: JiraPersonalSettingsFragmentDoc,
34677
34686
  NotionSettingsFragmentDoc: NotionSettingsFragmentDoc,
34678
- PagerDutyScheduleInfoFragmentDoc: PagerDutyScheduleInfoFragmentDoc,
34687
+ OpsgenieSettingsFragmentDoc: OpsgenieSettingsFragmentDoc,
34679
34688
  PagerDutySettingsFragmentDoc: PagerDutySettingsFragmentDoc,
34680
34689
  SentrySettingsFragmentDoc: SentrySettingsFragmentDoc,
34681
34690
  SlackSettingsFragmentDoc: SlackSettingsFragmentDoc,
@@ -37571,6 +37580,7 @@
37571
37580
  this.jira = data.jira ? new JiraSettings(request, data.jira) : undefined;
37572
37581
  this.jiraPersonal = data.jiraPersonal ? new JiraPersonalSettings(request, data.jiraPersonal) : undefined;
37573
37582
  this.notion = data.notion ? new NotionSettings(request, data.notion) : undefined;
37583
+ this.opsgenie = data.opsgenie ? new OpsgenieSettings(request, data.opsgenie) : undefined;
37574
37584
  this.pagerDuty = data.pagerDuty ? new PagerDutySettings(request, data.pagerDuty) : undefined;
37575
37585
  this.sentry = data.sentry ? new SentrySettings(request, data.sentry) : undefined;
37576
37586
  this.slack = data.slack ? new SlackSettings(request, data.slack) : undefined;
@@ -39133,6 +39143,19 @@
39133
39143
  this.user = new AuthUser(request, data.user);
39134
39144
  }
39135
39145
  }
39146
+ /**
39147
+ * Opsgenie specific settings.
39148
+ *
39149
+ * @param request - function to call the graphql client
39150
+ * @param data - L.OpsgenieSettingsFragment response data
39151
+ */
39152
+ class OpsgenieSettings extends Request {
39153
+ constructor(request, data) {
39154
+ var _a;
39155
+ super(request);
39156
+ this.apiFailedWithUnauthorizedErrorAt = (_a = parseDate(data.apiFailedWithUnauthorizedErrorAt)) !== null && _a !== void 0 ? _a : new Date();
39157
+ }
39158
+ }
39136
39159
  /**
39137
39160
  * An organization. Organizations are root-level objects that contain user accounts and teams.
39138
39161
  *
@@ -39407,20 +39430,6 @@
39407
39430
  this.startCursor = (_b = data.startCursor) !== null && _b !== void 0 ? _b : undefined;
39408
39431
  }
39409
39432
  }
39410
- /**
39411
- * Metadata about a PagerDuty schedule.
39412
- *
39413
- * @param request - function to call the graphql client
39414
- * @param data - L.PagerDutyScheduleInfoFragment response data
39415
- */
39416
- class PagerDutyScheduleInfo extends Request {
39417
- constructor(request, data) {
39418
- super(request);
39419
- this.scheduleId = data.scheduleId;
39420
- this.scheduleName = data.scheduleName;
39421
- this.url = data.url;
39422
- }
39423
- }
39424
39433
  /**
39425
39434
  * PagerDuty specific settings.
39426
39435
  *
@@ -39429,8 +39438,9 @@
39429
39438
  */
39430
39439
  class PagerDutySettings extends Request {
39431
39440
  constructor(request, data) {
39441
+ var _a;
39432
39442
  super(request);
39433
- this.scheduleMapping = data.scheduleMapping.map(node => new PagerDutyScheduleInfo(request, node));
39443
+ this.apiFailedWithUnauthorizedErrorAt = (_a = parseDate(data.apiFailedWithUnauthorizedErrorAt)) !== null && _a !== void 0 ? _a : new Date();
39434
39444
  }
39435
39445
  }
39436
39446
  /**
@@ -40704,7 +40714,6 @@
40704
40714
  this.issueEstimationExtended = data.issueEstimationExtended;
40705
40715
  this.issueEstimationType = data.issueEstimationType;
40706
40716
  this.issueOrderingNoPriorityFirst = data.issueOrderingNoPriorityFirst;
40707
- this.issueSortOrderDefaultToBottom = data.issueSortOrderDefaultToBottom;
40708
40717
  this.key = data.key;
40709
40718
  this.name = data.name;
40710
40719
  this.private = data.private;
@@ -42868,13 +42877,12 @@
42868
42877
  * Call the IssueFilterSuggestion query and return a IssueFilterSuggestionPayload
42869
42878
  *
42870
42879
  * @param prompt - required prompt to pass to issueFilterSuggestion
42880
+ * @param variables - variables without 'prompt' to pass into the IssueFilterSuggestionQuery
42871
42881
  * @returns parsed response from IssueFilterSuggestionQuery
42872
42882
  */
42873
- fetch(prompt) {
42883
+ fetch(prompt, variables) {
42874
42884
  return __awaiter(this, void 0, void 0, function* () {
42875
- const response = yield this._request(IssueFilterSuggestionDocument, {
42876
- prompt,
42877
- });
42885
+ const response = yield this._request(IssueFilterSuggestionDocument, Object.assign({ prompt }, variables));
42878
42886
  const data = response.issueFilterSuggestion;
42879
42887
  return new IssueFilterSuggestionPayload(this._request, data);
42880
42888
  });
@@ -51798,10 +51806,11 @@
51798
51806
  * Suggests filters for an issue view based on a text prompt.
51799
51807
  *
51800
51808
  * @param prompt - required prompt to pass to issueFilterSuggestion
51809
+ * @param variables - variables without 'prompt' to pass into the IssueFilterSuggestionQuery
51801
51810
  * @returns IssueFilterSuggestionPayload
51802
51811
  */
51803
- issueFilterSuggestion(prompt) {
51804
- return new IssueFilterSuggestionQuery(this._request).fetch(prompt);
51812
+ issueFilterSuggestion(prompt, variables) {
51813
+ return new IssueFilterSuggestionQuery(this._request).fetch(prompt, variables);
51805
51814
  }
51806
51815
  /**
51807
51816
  * Checks a CSV file validity against a specific import service.
@@ -54744,6 +54753,7 @@
54744
54753
  exports.OauthClientApprovalNotification = OauthClientApprovalNotification;
54745
54754
  exports.OauthClientConnection = OauthClientConnection;
54746
54755
  exports.OauthToken = OauthToken;
54756
+ exports.OpsgenieSettings = OpsgenieSettings;
54747
54757
  exports.Organization = Organization;
54748
54758
  exports.OrganizationCancelDeletePayload = OrganizationCancelDeletePayload;
54749
54759
  exports.OrganizationDeleteChallengeMutation = OrganizationDeleteChallengeMutation;
@@ -54769,7 +54779,6 @@
54769
54779
  exports.Organization_UsersQuery = Organization_UsersQuery;
54770
54780
  exports.OtherLinearError = OtherLinearError;
54771
54781
  exports.PageInfo = PageInfo;
54772
- exports.PagerDutyScheduleInfo = PagerDutyScheduleInfo;
54773
54782
  exports.PagerDutySettings = PagerDutySettings;
54774
54783
  exports.PaidSubscription = PaidSubscription;
54775
54784
  exports.Project = Project;