@incident-io/sdk 1.2.0 → 2.1.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/cjs/apis/IncidentTeamMembershipsV1Api.d.ts +60 -0
- package/dist/cjs/apis/IncidentTeamMembershipsV1Api.js +144 -0
- package/dist/cjs/apis/SchedulesV2Api.d.ts +2 -2
- package/dist/cjs/apis/SchedulesV2Api.js +2 -2
- package/dist/cjs/apis/index.d.ts +1 -0
- package/dist/cjs/apis/index.js +1 -0
- package/dist/cjs/models/AuditLogsOnCallNotificationPauseResumedV1.d.ts +58 -0
- package/dist/cjs/models/AuditLogsOnCallNotificationPauseResumedV1.js +79 -0
- package/dist/cjs/models/IncidentTeamMembershipV1.d.ts +47 -0
- package/dist/cjs/models/IncidentTeamMembershipV1.js +68 -0
- package/dist/cjs/models/IncidentTeamMembershipsCreatePayloadV1.d.ts +34 -0
- package/dist/cjs/models/IncidentTeamMembershipsCreatePayloadV1.js +54 -0
- package/dist/cjs/models/IncidentTeamMembershipsCreateResultV1.d.ts +31 -0
- package/dist/cjs/models/IncidentTeamMembershipsCreateResultV1.js +51 -0
- package/dist/cjs/models/IncidentTeamMembershipsRevokePayloadV1.d.ts +34 -0
- package/dist/cjs/models/IncidentTeamMembershipsRevokePayloadV1.js +54 -0
- package/dist/cjs/models/IncidentTeamV1.d.ts +34 -0
- package/dist/cjs/models/IncidentTeamV1.js +54 -0
- package/dist/cjs/models/ScheduleEntryV2.d.ts +4 -9
- package/dist/cjs/models/ScheduleEntryV2.js +0 -2
- package/dist/cjs/models/index.d.ts +6 -0
- package/dist/cjs/models/index.js +6 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/apis/IncidentTeamMembershipsV1Api.d.ts +60 -0
- package/dist/esm/apis/IncidentTeamMembershipsV1Api.js +107 -0
- package/dist/esm/apis/SchedulesV2Api.d.ts +2 -2
- package/dist/esm/apis/SchedulesV2Api.js +2 -2
- package/dist/esm/apis/index.d.ts +1 -0
- package/dist/esm/apis/index.js +1 -0
- package/dist/esm/models/AuditLogsOnCallNotificationPauseResumedV1.d.ts +58 -0
- package/dist/esm/models/AuditLogsOnCallNotificationPauseResumedV1.js +72 -0
- package/dist/esm/models/IncidentTeamMembershipV1.d.ts +47 -0
- package/dist/esm/models/IncidentTeamMembershipV1.js +61 -0
- package/dist/esm/models/IncidentTeamMembershipsCreatePayloadV1.d.ts +34 -0
- package/dist/esm/models/IncidentTeamMembershipsCreatePayloadV1.js +47 -0
- package/dist/esm/models/IncidentTeamMembershipsCreateResultV1.d.ts +31 -0
- package/dist/esm/models/IncidentTeamMembershipsCreateResultV1.js +44 -0
- package/dist/esm/models/IncidentTeamMembershipsRevokePayloadV1.d.ts +34 -0
- package/dist/esm/models/IncidentTeamMembershipsRevokePayloadV1.js +47 -0
- package/dist/esm/models/IncidentTeamV1.d.ts +34 -0
- package/dist/esm/models/IncidentTeamV1.js +47 -0
- package/dist/esm/models/ScheduleEntryV2.d.ts +4 -9
- package/dist/esm/models/ScheduleEntryV2.js +0 -2
- package/dist/esm/models/index.d.ts +6 -0
- package/dist/esm/models/index.js +6 -0
- package/dist/esm/version.d.ts +1 -1
- package/dist/esm/version.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* incident.io
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import * as runtime from '../runtime.js';
|
|
13
|
+
import { type IncidentTeamMembershipsCreatePayloadV1 } from '../models/IncidentTeamMembershipsCreatePayloadV1.js';
|
|
14
|
+
import { type IncidentTeamMembershipsCreateResultV1 } from '../models/IncidentTeamMembershipsCreateResultV1.js';
|
|
15
|
+
import { type IncidentTeamMembershipsRevokePayloadV1 } from '../models/IncidentTeamMembershipsRevokePayloadV1.js';
|
|
16
|
+
export interface IncidentTeamMembershipsV1CreateRequest {
|
|
17
|
+
/**
|
|
18
|
+
*
|
|
19
|
+
*/
|
|
20
|
+
body: IncidentTeamMembershipsCreatePayloadV1;
|
|
21
|
+
}
|
|
22
|
+
export interface IncidentTeamMembershipsV1RevokeRequest {
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
*/
|
|
26
|
+
body: IncidentTeamMembershipsRevokePayloadV1;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
export declare class IncidentTeamMembershipsV1Api extends runtime.BaseAPI {
|
|
32
|
+
/**
|
|
33
|
+
* Creates request options for incidentTeamMembershipsV1Create without sending the request
|
|
34
|
+
*/
|
|
35
|
+
incidentTeamMembershipsV1CreateRequestOpts(requestParameters: IncidentTeamMembershipsV1CreateRequest): Promise<runtime.RequestOpts>;
|
|
36
|
+
/**
|
|
37
|
+
* Grants a team access to a private incident
|
|
38
|
+
* Create Incident Team Memberships V1
|
|
39
|
+
*/
|
|
40
|
+
incidentTeamMembershipsV1CreateRaw(requestParameters: IncidentTeamMembershipsV1CreateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IncidentTeamMembershipsCreateResultV1>>;
|
|
41
|
+
/**
|
|
42
|
+
* Grants a team access to a private incident
|
|
43
|
+
* Create Incident Team Memberships V1
|
|
44
|
+
*/
|
|
45
|
+
incidentTeamMembershipsV1Create(requestParameters: IncidentTeamMembershipsV1CreateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IncidentTeamMembershipsCreateResultV1>;
|
|
46
|
+
/**
|
|
47
|
+
* Creates request options for incidentTeamMembershipsV1Revoke without sending the request
|
|
48
|
+
*/
|
|
49
|
+
incidentTeamMembershipsV1RevokeRequestOpts(requestParameters: IncidentTeamMembershipsV1RevokeRequest): Promise<runtime.RequestOpts>;
|
|
50
|
+
/**
|
|
51
|
+
* Revoke a team\'s access to a private incident. Members who only had access through this team lose it too; directly-added members and members still covered by another team keep theirs.
|
|
52
|
+
* Revoke Incident Team Memberships V1
|
|
53
|
+
*/
|
|
54
|
+
incidentTeamMembershipsV1RevokeRaw(requestParameters: IncidentTeamMembershipsV1RevokeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
55
|
+
/**
|
|
56
|
+
* Revoke a team\'s access to a private incident. Members who only had access through this team lose it too; directly-added members and members still covered by another team keep theirs.
|
|
57
|
+
* Revoke Incident Team Memberships V1
|
|
58
|
+
*/
|
|
59
|
+
incidentTeamMembershipsV1Revoke(requestParameters: IncidentTeamMembershipsV1RevokeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
60
|
+
}
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* incident.io
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
16
|
+
if (k2 === undefined) k2 = k;
|
|
17
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
18
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
19
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
20
|
+
}
|
|
21
|
+
Object.defineProperty(o, k2, desc);
|
|
22
|
+
}) : (function(o, m, k, k2) {
|
|
23
|
+
if (k2 === undefined) k2 = k;
|
|
24
|
+
o[k2] = m[k];
|
|
25
|
+
}));
|
|
26
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
27
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
28
|
+
}) : function(o, v) {
|
|
29
|
+
o["default"] = v;
|
|
30
|
+
});
|
|
31
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
32
|
+
var ownKeys = function(o) {
|
|
33
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
34
|
+
var ar = [];
|
|
35
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
36
|
+
return ar;
|
|
37
|
+
};
|
|
38
|
+
return ownKeys(o);
|
|
39
|
+
};
|
|
40
|
+
return function (mod) {
|
|
41
|
+
if (mod && mod.__esModule) return mod;
|
|
42
|
+
var result = {};
|
|
43
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
44
|
+
__setModuleDefault(result, mod);
|
|
45
|
+
return result;
|
|
46
|
+
};
|
|
47
|
+
})();
|
|
48
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
49
|
+
exports.IncidentTeamMembershipsV1Api = void 0;
|
|
50
|
+
const runtime = __importStar(require("../runtime.js"));
|
|
51
|
+
const IncidentTeamMembershipsCreatePayloadV1_js_1 = require("../models/IncidentTeamMembershipsCreatePayloadV1.js");
|
|
52
|
+
const IncidentTeamMembershipsCreateResultV1_js_1 = require("../models/IncidentTeamMembershipsCreateResultV1.js");
|
|
53
|
+
const IncidentTeamMembershipsRevokePayloadV1_js_1 = require("../models/IncidentTeamMembershipsRevokePayloadV1.js");
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
*/
|
|
57
|
+
class IncidentTeamMembershipsV1Api extends runtime.BaseAPI {
|
|
58
|
+
/**
|
|
59
|
+
* Creates request options for incidentTeamMembershipsV1Create without sending the request
|
|
60
|
+
*/
|
|
61
|
+
async incidentTeamMembershipsV1CreateRequestOpts(requestParameters) {
|
|
62
|
+
if (requestParameters['body'] == null) {
|
|
63
|
+
throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling incidentTeamMembershipsV1Create().');
|
|
64
|
+
}
|
|
65
|
+
const queryParameters = {};
|
|
66
|
+
const headerParameters = {};
|
|
67
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
68
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
69
|
+
const token = this.configuration.accessToken;
|
|
70
|
+
const tokenString = await token("BearerAuth", []);
|
|
71
|
+
if (tokenString) {
|
|
72
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
let urlPath = `/v1/incident_team_memberships`;
|
|
76
|
+
return {
|
|
77
|
+
path: urlPath,
|
|
78
|
+
method: 'POST',
|
|
79
|
+
headers: headerParameters,
|
|
80
|
+
query: queryParameters,
|
|
81
|
+
body: (0, IncidentTeamMembershipsCreatePayloadV1_js_1.IncidentTeamMembershipsCreatePayloadV1ToJSON)(requestParameters['body']),
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Grants a team access to a private incident
|
|
86
|
+
* Create Incident Team Memberships V1
|
|
87
|
+
*/
|
|
88
|
+
async incidentTeamMembershipsV1CreateRaw(requestParameters, initOverrides) {
|
|
89
|
+
const requestOptions = await this.incidentTeamMembershipsV1CreateRequestOpts(requestParameters);
|
|
90
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
91
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, IncidentTeamMembershipsCreateResultV1_js_1.IncidentTeamMembershipsCreateResultV1FromJSON)(jsonValue));
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Grants a team access to a private incident
|
|
95
|
+
* Create Incident Team Memberships V1
|
|
96
|
+
*/
|
|
97
|
+
async incidentTeamMembershipsV1Create(requestParameters, initOverrides) {
|
|
98
|
+
const response = await this.incidentTeamMembershipsV1CreateRaw(requestParameters, initOverrides);
|
|
99
|
+
return await response.value();
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Creates request options for incidentTeamMembershipsV1Revoke without sending the request
|
|
103
|
+
*/
|
|
104
|
+
async incidentTeamMembershipsV1RevokeRequestOpts(requestParameters) {
|
|
105
|
+
if (requestParameters['body'] == null) {
|
|
106
|
+
throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling incidentTeamMembershipsV1Revoke().');
|
|
107
|
+
}
|
|
108
|
+
const queryParameters = {};
|
|
109
|
+
const headerParameters = {};
|
|
110
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
111
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
112
|
+
const token = this.configuration.accessToken;
|
|
113
|
+
const tokenString = await token("BearerAuth", []);
|
|
114
|
+
if (tokenString) {
|
|
115
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
let urlPath = `/v1/incident_team_memberships/actions/revoke`;
|
|
119
|
+
return {
|
|
120
|
+
path: urlPath,
|
|
121
|
+
method: 'POST',
|
|
122
|
+
headers: headerParameters,
|
|
123
|
+
query: queryParameters,
|
|
124
|
+
body: (0, IncidentTeamMembershipsRevokePayloadV1_js_1.IncidentTeamMembershipsRevokePayloadV1ToJSON)(requestParameters['body']),
|
|
125
|
+
};
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* Revoke a team\'s access to a private incident. Members who only had access through this team lose it too; directly-added members and members still covered by another team keep theirs.
|
|
129
|
+
* Revoke Incident Team Memberships V1
|
|
130
|
+
*/
|
|
131
|
+
async incidentTeamMembershipsV1RevokeRaw(requestParameters, initOverrides) {
|
|
132
|
+
const requestOptions = await this.incidentTeamMembershipsV1RevokeRequestOpts(requestParameters);
|
|
133
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
134
|
+
return new runtime.VoidApiResponse(response);
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Revoke a team\'s access to a private incident. Members who only had access through this team lose it too; directly-added members and members still covered by another team keep theirs.
|
|
138
|
+
* Revoke Incident Team Memberships V1
|
|
139
|
+
*/
|
|
140
|
+
async incidentTeamMembershipsV1Revoke(requestParameters, initOverrides) {
|
|
141
|
+
await this.incidentTeamMembershipsV1RevokeRaw(requestParameters, initOverrides);
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
exports.IncidentTeamMembershipsV1Api = IncidentTeamMembershipsV1Api;
|
|
@@ -390,12 +390,12 @@ export declare class SchedulesV2Api extends runtime.BaseAPI {
|
|
|
390
390
|
*/
|
|
391
391
|
schedulesV2ListScheduleEntriesRequestOpts(requestParameters: SchedulesV2ListScheduleEntriesRequest): Promise<runtime.RequestOpts>;
|
|
392
392
|
/**
|
|
393
|
-
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id`
|
|
393
|
+
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id` it belongs to. Schedules can be made up of multiple rotations (for example, a primary and a secondary rotation) and each rotation can have several layers, and we return entries for every rotation and layer on the schedule. The endpoint returns all entries that overlap with the given window. If no window is provided we default to a sensible range starting from now. ## Pagination Responses are paginated. When more entries are available than fit on a single page, the response includes a `pagination_meta` block with two fields: - `after_url` — a fully-formed URL for the next page. The simplest way to paginate is to keep following this URL until it is no longer present. - `after` — an opaque cursor token. To fetch the next page manually, re-issue the request with `entry_window_start` set to this value and `entry_window_end` left unchanged from the original request. Treat the token as opaque — do not parse or modify it. Keep paginating until `pagination_meta` is absent from the response, at which point you have received every entry in the window.
|
|
394
394
|
* ListScheduleEntries Schedules V2
|
|
395
395
|
*/
|
|
396
396
|
schedulesV2ListScheduleEntriesRaw(requestParameters: SchedulesV2ListScheduleEntriesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SchedulesListScheduleEntriesResultV2>>;
|
|
397
397
|
/**
|
|
398
|
-
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id`
|
|
398
|
+
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id` it belongs to. Schedules can be made up of multiple rotations (for example, a primary and a secondary rotation) and each rotation can have several layers, and we return entries for every rotation and layer on the schedule. The endpoint returns all entries that overlap with the given window. If no window is provided we default to a sensible range starting from now. ## Pagination Responses are paginated. When more entries are available than fit on a single page, the response includes a `pagination_meta` block with two fields: - `after_url` — a fully-formed URL for the next page. The simplest way to paginate is to keep following this URL until it is no longer present. - `after` — an opaque cursor token. To fetch the next page manually, re-issue the request with `entry_window_start` set to this value and `entry_window_end` left unchanged from the original request. Treat the token as opaque — do not parse or modify it. Keep paginating until `pagination_meta` is absent from the response, at which point you have received every entry in the window.
|
|
399
399
|
* ListScheduleEntries Schedules V2
|
|
400
400
|
*/
|
|
401
401
|
schedulesV2ListScheduleEntries(requestParameters: SchedulesV2ListScheduleEntriesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SchedulesListScheduleEntriesResultV2>;
|
|
@@ -563,7 +563,7 @@ class SchedulesV2Api extends runtime.BaseAPI {
|
|
|
563
563
|
};
|
|
564
564
|
}
|
|
565
565
|
/**
|
|
566
|
-
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id`
|
|
566
|
+
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id` it belongs to. Schedules can be made up of multiple rotations (for example, a primary and a secondary rotation) and each rotation can have several layers, and we return entries for every rotation and layer on the schedule. The endpoint returns all entries that overlap with the given window. If no window is provided we default to a sensible range starting from now. ## Pagination Responses are paginated. When more entries are available than fit on a single page, the response includes a `pagination_meta` block with two fields: - `after_url` — a fully-formed URL for the next page. The simplest way to paginate is to keep following this URL until it is no longer present. - `after` — an opaque cursor token. To fetch the next page manually, re-issue the request with `entry_window_start` set to this value and `entry_window_end` left unchanged from the original request. Treat the token as opaque — do not parse or modify it. Keep paginating until `pagination_meta` is absent from the response, at which point you have received every entry in the window.
|
|
567
567
|
* ListScheduleEntries Schedules V2
|
|
568
568
|
*/
|
|
569
569
|
async schedulesV2ListScheduleEntriesRaw(requestParameters, initOverrides) {
|
|
@@ -572,7 +572,7 @@ class SchedulesV2Api extends runtime.BaseAPI {
|
|
|
572
572
|
return new runtime.JSONApiResponse(response, (jsonValue) => (0, SchedulesListScheduleEntriesResultV2_js_1.SchedulesListScheduleEntriesResultV2FromJSON)(jsonValue));
|
|
573
573
|
}
|
|
574
574
|
/**
|
|
575
|
-
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id`
|
|
575
|
+
* List the schedule entries for a schedule over a window of time. Use this endpoint to find out who is on-call for a schedule, either right now or at any point in the future. Common uses include: - Building a calendar or timeline view of who is on-call. - Looking up who was on-call at a particular moment (for example, when an incident fired). - Exporting upcoming shifts into another system, such as a payroll or scheduling tool. The response groups entries into three lists: `scheduled` (the entries the rotation rules produce, before any overrides), `overrides` (any one-off overrides that apply in the window) and `final` (the effective schedule after overrides have been merged in — this is normally the list you want). Each entry includes the `rotation_id` it belongs to. Schedules can be made up of multiple rotations (for example, a primary and a secondary rotation) and each rotation can have several layers, and we return entries for every rotation and layer on the schedule. The endpoint returns all entries that overlap with the given window. If no window is provided we default to a sensible range starting from now. ## Pagination Responses are paginated. When more entries are available than fit on a single page, the response includes a `pagination_meta` block with two fields: - `after_url` — a fully-formed URL for the next page. The simplest way to paginate is to keep following this URL until it is no longer present. - `after` — an opaque cursor token. To fetch the next page manually, re-issue the request with `entry_window_start` set to this value and `entry_window_end` left unchanged from the original request. Treat the token as opaque — do not parse or modify it. Keep paginating until `pagination_meta` is absent from the response, at which point you have received every entry in the window.
|
|
576
576
|
* ListScheduleEntries Schedules V2
|
|
577
577
|
*/
|
|
578
578
|
async schedulesV2ListScheduleEntries(requestParameters, initOverrides) {
|
package/dist/cjs/apis/index.d.ts
CHANGED
|
@@ -34,6 +34,7 @@ export * from './IncidentRelationshipsV1Api.js';
|
|
|
34
34
|
export * from './IncidentRolesV1Api.js';
|
|
35
35
|
export * from './IncidentRolesV2Api.js';
|
|
36
36
|
export * from './IncidentStatusesV1Api.js';
|
|
37
|
+
export * from './IncidentTeamMembershipsV1Api.js';
|
|
37
38
|
export * from './IncidentTemplatesV1Api.js';
|
|
38
39
|
export * from './IncidentTimelineItemsV2Api.js';
|
|
39
40
|
export * from './IncidentTimestampsV2Api.js';
|
package/dist/cjs/apis/index.js
CHANGED
|
@@ -52,6 +52,7 @@ __exportStar(require("./IncidentRelationshipsV1Api.js"), exports);
|
|
|
52
52
|
__exportStar(require("./IncidentRolesV1Api.js"), exports);
|
|
53
53
|
__exportStar(require("./IncidentRolesV2Api.js"), exports);
|
|
54
54
|
__exportStar(require("./IncidentStatusesV1Api.js"), exports);
|
|
55
|
+
__exportStar(require("./IncidentTeamMembershipsV1Api.js"), exports);
|
|
55
56
|
__exportStar(require("./IncidentTemplatesV1Api.js"), exports);
|
|
56
57
|
__exportStar(require("./IncidentTimelineItemsV2Api.js"), exports);
|
|
57
58
|
__exportStar(require("./IncidentTimestampsV2Api.js"), exports);
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* incident.io
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { AuditLogActorV2 } from './AuditLogActorV2.js';
|
|
13
|
+
import type { AuditLogOnCallNotificationPauseMetadataV2 } from './AuditLogOnCallNotificationPauseMetadataV2.js';
|
|
14
|
+
import type { AuditLogEntryContextV2 } from './AuditLogEntryContextV2.js';
|
|
15
|
+
import type { AuditLogTargetV2 } from './AuditLogTargetV2.js';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface AuditLogsOnCallNotificationPauseResumedV1
|
|
20
|
+
*/
|
|
21
|
+
export interface AuditLogsOnCallNotificationPauseResumedV1 {
|
|
22
|
+
/**
|
|
23
|
+
* The type of log entry that this is
|
|
24
|
+
*/
|
|
25
|
+
action: string;
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
*/
|
|
29
|
+
actor: AuditLogActorV2;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
*/
|
|
33
|
+
context: AuditLogEntryContextV2;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
*/
|
|
37
|
+
metadata: AuditLogOnCallNotificationPauseMetadataV2;
|
|
38
|
+
/**
|
|
39
|
+
* When the entry occurred
|
|
40
|
+
*/
|
|
41
|
+
occurred_at: Date;
|
|
42
|
+
/**
|
|
43
|
+
* The custom field that was created
|
|
44
|
+
*/
|
|
45
|
+
targets: Array<AuditLogTargetV2>;
|
|
46
|
+
/**
|
|
47
|
+
* Which version the event is
|
|
48
|
+
*/
|
|
49
|
+
version: number;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Check if a given object implements the AuditLogsOnCallNotificationPauseResumedV1 interface.
|
|
53
|
+
*/
|
|
54
|
+
export declare function instanceOfAuditLogsOnCallNotificationPauseResumedV1(value: object): value is AuditLogsOnCallNotificationPauseResumedV1;
|
|
55
|
+
export declare function AuditLogsOnCallNotificationPauseResumedV1FromJSON(json: any): AuditLogsOnCallNotificationPauseResumedV1;
|
|
56
|
+
export declare function AuditLogsOnCallNotificationPauseResumedV1FromJSONTyped(json: any, ignoreDiscriminator: boolean): AuditLogsOnCallNotificationPauseResumedV1;
|
|
57
|
+
export declare function AuditLogsOnCallNotificationPauseResumedV1ToJSON(json: any): AuditLogsOnCallNotificationPauseResumedV1;
|
|
58
|
+
export declare function AuditLogsOnCallNotificationPauseResumedV1ToJSONTyped(value?: AuditLogsOnCallNotificationPauseResumedV1 | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* incident.io
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfAuditLogsOnCallNotificationPauseResumedV1 = instanceOfAuditLogsOnCallNotificationPauseResumedV1;
|
|
17
|
+
exports.AuditLogsOnCallNotificationPauseResumedV1FromJSON = AuditLogsOnCallNotificationPauseResumedV1FromJSON;
|
|
18
|
+
exports.AuditLogsOnCallNotificationPauseResumedV1FromJSONTyped = AuditLogsOnCallNotificationPauseResumedV1FromJSONTyped;
|
|
19
|
+
exports.AuditLogsOnCallNotificationPauseResumedV1ToJSON = AuditLogsOnCallNotificationPauseResumedV1ToJSON;
|
|
20
|
+
exports.AuditLogsOnCallNotificationPauseResumedV1ToJSONTyped = AuditLogsOnCallNotificationPauseResumedV1ToJSONTyped;
|
|
21
|
+
const runtime_js_1 = require("../runtime.js");
|
|
22
|
+
const AuditLogActorV2_js_1 = require("./AuditLogActorV2.js");
|
|
23
|
+
const AuditLogOnCallNotificationPauseMetadataV2_js_1 = require("./AuditLogOnCallNotificationPauseMetadataV2.js");
|
|
24
|
+
const AuditLogEntryContextV2_js_1 = require("./AuditLogEntryContextV2.js");
|
|
25
|
+
const AuditLogTargetV2_js_1 = require("./AuditLogTargetV2.js");
|
|
26
|
+
/**
|
|
27
|
+
* Check if a given object implements the AuditLogsOnCallNotificationPauseResumedV1 interface.
|
|
28
|
+
*/
|
|
29
|
+
function instanceOfAuditLogsOnCallNotificationPauseResumedV1(value) {
|
|
30
|
+
if (!('action' in value) || value['action'] === undefined)
|
|
31
|
+
return false;
|
|
32
|
+
if (!('actor' in value) || value['actor'] === undefined)
|
|
33
|
+
return false;
|
|
34
|
+
if (!('context' in value) || value['context'] === undefined)
|
|
35
|
+
return false;
|
|
36
|
+
if (!('metadata' in value) || value['metadata'] === undefined)
|
|
37
|
+
return false;
|
|
38
|
+
if (!('occurred_at' in value) || value['occurred_at'] === undefined)
|
|
39
|
+
return false;
|
|
40
|
+
if (!('targets' in value) || value['targets'] === undefined)
|
|
41
|
+
return false;
|
|
42
|
+
if (!('version' in value) || value['version'] === undefined)
|
|
43
|
+
return false;
|
|
44
|
+
return true;
|
|
45
|
+
}
|
|
46
|
+
function AuditLogsOnCallNotificationPauseResumedV1FromJSON(json) {
|
|
47
|
+
return AuditLogsOnCallNotificationPauseResumedV1FromJSONTyped(json, false);
|
|
48
|
+
}
|
|
49
|
+
function AuditLogsOnCallNotificationPauseResumedV1FromJSONTyped(json, ignoreDiscriminator) {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
'action': json['action'],
|
|
55
|
+
'actor': (0, AuditLogActorV2_js_1.AuditLogActorV2FromJSON)(json['actor']),
|
|
56
|
+
'context': (0, AuditLogEntryContextV2_js_1.AuditLogEntryContextV2FromJSON)(json['context']),
|
|
57
|
+
'metadata': (0, AuditLogOnCallNotificationPauseMetadataV2_js_1.AuditLogOnCallNotificationPauseMetadataV2FromJSON)(json['metadata']),
|
|
58
|
+
'occurred_at': (json['occurred_at'] == null ? json['occurred_at'] : (0, runtime_js_1.parseDateTime)(json['occurred_at'])),
|
|
59
|
+
'targets': (json['targets'].map(AuditLogTargetV2_js_1.AuditLogTargetV2FromJSON)),
|
|
60
|
+
'version': json['version'],
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
function AuditLogsOnCallNotificationPauseResumedV1ToJSON(json) {
|
|
64
|
+
return AuditLogsOnCallNotificationPauseResumedV1ToJSONTyped(json, false);
|
|
65
|
+
}
|
|
66
|
+
function AuditLogsOnCallNotificationPauseResumedV1ToJSONTyped(value, ignoreDiscriminator = false) {
|
|
67
|
+
if (value == null) {
|
|
68
|
+
return value;
|
|
69
|
+
}
|
|
70
|
+
return {
|
|
71
|
+
'action': value['action'],
|
|
72
|
+
'actor': (0, AuditLogActorV2_js_1.AuditLogActorV2ToJSON)(value['actor']),
|
|
73
|
+
'context': (0, AuditLogEntryContextV2_js_1.AuditLogEntryContextV2ToJSON)(value['context']),
|
|
74
|
+
'metadata': (0, AuditLogOnCallNotificationPauseMetadataV2_js_1.AuditLogOnCallNotificationPauseMetadataV2ToJSON)(value['metadata']),
|
|
75
|
+
'occurred_at': value['occurred_at'] == null ? value['occurred_at'] : (0, runtime_js_1.serializeDateTime)(value['occurred_at']),
|
|
76
|
+
'targets': (value['targets'].map(AuditLogTargetV2_js_1.AuditLogTargetV2ToJSON)),
|
|
77
|
+
'version': value['version'],
|
|
78
|
+
};
|
|
79
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* incident.io
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { IncidentTeamV1 } from './IncidentTeamV1.js';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface IncidentTeamMembershipV1
|
|
17
|
+
*/
|
|
18
|
+
export interface IncidentTeamMembershipV1 {
|
|
19
|
+
/**
|
|
20
|
+
* When the team membership was created
|
|
21
|
+
*/
|
|
22
|
+
created_at: Date;
|
|
23
|
+
/**
|
|
24
|
+
* Unique identifier of this incident team membership
|
|
25
|
+
*/
|
|
26
|
+
id: string;
|
|
27
|
+
/**
|
|
28
|
+
* Unique identifier of the incident
|
|
29
|
+
*/
|
|
30
|
+
incident_id: string;
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
*/
|
|
34
|
+
team: IncidentTeamV1;
|
|
35
|
+
/**
|
|
36
|
+
* When the team membership was last updated
|
|
37
|
+
*/
|
|
38
|
+
updated_at: Date;
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Check if a given object implements the IncidentTeamMembershipV1 interface.
|
|
42
|
+
*/
|
|
43
|
+
export declare function instanceOfIncidentTeamMembershipV1(value: object): value is IncidentTeamMembershipV1;
|
|
44
|
+
export declare function IncidentTeamMembershipV1FromJSON(json: any): IncidentTeamMembershipV1;
|
|
45
|
+
export declare function IncidentTeamMembershipV1FromJSONTyped(json: any, ignoreDiscriminator: boolean): IncidentTeamMembershipV1;
|
|
46
|
+
export declare function IncidentTeamMembershipV1ToJSON(json: any): IncidentTeamMembershipV1;
|
|
47
|
+
export declare function IncidentTeamMembershipV1ToJSONTyped(value?: IncidentTeamMembershipV1 | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* incident.io
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfIncidentTeamMembershipV1 = instanceOfIncidentTeamMembershipV1;
|
|
17
|
+
exports.IncidentTeamMembershipV1FromJSON = IncidentTeamMembershipV1FromJSON;
|
|
18
|
+
exports.IncidentTeamMembershipV1FromJSONTyped = IncidentTeamMembershipV1FromJSONTyped;
|
|
19
|
+
exports.IncidentTeamMembershipV1ToJSON = IncidentTeamMembershipV1ToJSON;
|
|
20
|
+
exports.IncidentTeamMembershipV1ToJSONTyped = IncidentTeamMembershipV1ToJSONTyped;
|
|
21
|
+
const runtime_js_1 = require("../runtime.js");
|
|
22
|
+
const IncidentTeamV1_js_1 = require("./IncidentTeamV1.js");
|
|
23
|
+
/**
|
|
24
|
+
* Check if a given object implements the IncidentTeamMembershipV1 interface.
|
|
25
|
+
*/
|
|
26
|
+
function instanceOfIncidentTeamMembershipV1(value) {
|
|
27
|
+
if (!('created_at' in value) || value['created_at'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
if (!('incident_id' in value) || value['incident_id'] === undefined)
|
|
32
|
+
return false;
|
|
33
|
+
if (!('team' in value) || value['team'] === undefined)
|
|
34
|
+
return false;
|
|
35
|
+
if (!('updated_at' in value) || value['updated_at'] === undefined)
|
|
36
|
+
return false;
|
|
37
|
+
return true;
|
|
38
|
+
}
|
|
39
|
+
function IncidentTeamMembershipV1FromJSON(json) {
|
|
40
|
+
return IncidentTeamMembershipV1FromJSONTyped(json, false);
|
|
41
|
+
}
|
|
42
|
+
function IncidentTeamMembershipV1FromJSONTyped(json, ignoreDiscriminator) {
|
|
43
|
+
if (json == null) {
|
|
44
|
+
return json;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
'created_at': (json['created_at'] == null ? json['created_at'] : (0, runtime_js_1.parseDateTime)(json['created_at'])),
|
|
48
|
+
'id': json['id'],
|
|
49
|
+
'incident_id': json['incident_id'],
|
|
50
|
+
'team': (0, IncidentTeamV1_js_1.IncidentTeamV1FromJSON)(json['team']),
|
|
51
|
+
'updated_at': (json['updated_at'] == null ? json['updated_at'] : (0, runtime_js_1.parseDateTime)(json['updated_at'])),
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
function IncidentTeamMembershipV1ToJSON(json) {
|
|
55
|
+
return IncidentTeamMembershipV1ToJSONTyped(json, false);
|
|
56
|
+
}
|
|
57
|
+
function IncidentTeamMembershipV1ToJSONTyped(value, ignoreDiscriminator = false) {
|
|
58
|
+
if (value == null) {
|
|
59
|
+
return value;
|
|
60
|
+
}
|
|
61
|
+
return {
|
|
62
|
+
'created_at': value['created_at'] == null ? value['created_at'] : (0, runtime_js_1.serializeDateTime)(value['created_at']),
|
|
63
|
+
'id': value['id'],
|
|
64
|
+
'incident_id': value['incident_id'],
|
|
65
|
+
'team': (0, IncidentTeamV1_js_1.IncidentTeamV1ToJSON)(value['team']),
|
|
66
|
+
'updated_at': value['updated_at'] == null ? value['updated_at'] : (0, runtime_js_1.serializeDateTime)(value['updated_at']),
|
|
67
|
+
};
|
|
68
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* incident.io
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface IncidentTeamMembershipsCreatePayloadV1
|
|
16
|
+
*/
|
|
17
|
+
export interface IncidentTeamMembershipsCreatePayloadV1 {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
*/
|
|
21
|
+
incident_id: string;
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
*/
|
|
25
|
+
team_id: string;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Check if a given object implements the IncidentTeamMembershipsCreatePayloadV1 interface.
|
|
29
|
+
*/
|
|
30
|
+
export declare function instanceOfIncidentTeamMembershipsCreatePayloadV1(value: object): value is IncidentTeamMembershipsCreatePayloadV1;
|
|
31
|
+
export declare function IncidentTeamMembershipsCreatePayloadV1FromJSON(json: any): IncidentTeamMembershipsCreatePayloadV1;
|
|
32
|
+
export declare function IncidentTeamMembershipsCreatePayloadV1FromJSONTyped(json: any, ignoreDiscriminator: boolean): IncidentTeamMembershipsCreatePayloadV1;
|
|
33
|
+
export declare function IncidentTeamMembershipsCreatePayloadV1ToJSON(json: any): IncidentTeamMembershipsCreatePayloadV1;
|
|
34
|
+
export declare function IncidentTeamMembershipsCreatePayloadV1ToJSONTyped(value?: IncidentTeamMembershipsCreatePayloadV1 | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* incident.io
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfIncidentTeamMembershipsCreatePayloadV1 = instanceOfIncidentTeamMembershipsCreatePayloadV1;
|
|
17
|
+
exports.IncidentTeamMembershipsCreatePayloadV1FromJSON = IncidentTeamMembershipsCreatePayloadV1FromJSON;
|
|
18
|
+
exports.IncidentTeamMembershipsCreatePayloadV1FromJSONTyped = IncidentTeamMembershipsCreatePayloadV1FromJSONTyped;
|
|
19
|
+
exports.IncidentTeamMembershipsCreatePayloadV1ToJSON = IncidentTeamMembershipsCreatePayloadV1ToJSON;
|
|
20
|
+
exports.IncidentTeamMembershipsCreatePayloadV1ToJSONTyped = IncidentTeamMembershipsCreatePayloadV1ToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the IncidentTeamMembershipsCreatePayloadV1 interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfIncidentTeamMembershipsCreatePayloadV1(value) {
|
|
25
|
+
if (!('incident_id' in value) || value['incident_id'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('team_id' in value) || value['team_id'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
return true;
|
|
30
|
+
}
|
|
31
|
+
function IncidentTeamMembershipsCreatePayloadV1FromJSON(json) {
|
|
32
|
+
return IncidentTeamMembershipsCreatePayloadV1FromJSONTyped(json, false);
|
|
33
|
+
}
|
|
34
|
+
function IncidentTeamMembershipsCreatePayloadV1FromJSONTyped(json, ignoreDiscriminator) {
|
|
35
|
+
if (json == null) {
|
|
36
|
+
return json;
|
|
37
|
+
}
|
|
38
|
+
return {
|
|
39
|
+
'incident_id': json['incident_id'],
|
|
40
|
+
'team_id': json['team_id'],
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
function IncidentTeamMembershipsCreatePayloadV1ToJSON(json) {
|
|
44
|
+
return IncidentTeamMembershipsCreatePayloadV1ToJSONTyped(json, false);
|
|
45
|
+
}
|
|
46
|
+
function IncidentTeamMembershipsCreatePayloadV1ToJSONTyped(value, ignoreDiscriminator = false) {
|
|
47
|
+
if (value == null) {
|
|
48
|
+
return value;
|
|
49
|
+
}
|
|
50
|
+
return {
|
|
51
|
+
'incident_id': value['incident_id'],
|
|
52
|
+
'team_id': value['team_id'],
|
|
53
|
+
};
|
|
54
|
+
}
|