@incident-io/sdk 2.9.0 → 2.10.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.
Files changed (57) hide show
  1. package/dist/cjs/apis/IncidentFormsV3Api.d.ts +131 -0
  2. package/dist/cjs/apis/IncidentFormsV3Api.js +279 -0
  3. package/dist/cjs/apis/index.d.ts +1 -0
  4. package/dist/cjs/apis/index.js +1 -0
  5. package/dist/cjs/models/IncidentFormLifecycleElementConfigV3.d.ts +30 -0
  6. package/dist/cjs/models/IncidentFormLifecycleElementConfigV3.js +48 -0
  7. package/dist/cjs/models/IncidentFormLifecycleElementPayloadV3.d.ts +115 -0
  8. package/dist/cjs/models/IncidentFormLifecycleElementPayloadV3.js +110 -0
  9. package/dist/cjs/models/IncidentFormLifecycleElementV3.d.ts +115 -0
  10. package/dist/cjs/models/IncidentFormLifecycleElementV3.js +110 -0
  11. package/dist/cjs/models/IncidentFormV3.d.ts +68 -0
  12. package/dist/cjs/models/IncidentFormV3.js +85 -0
  13. package/dist/cjs/models/IncidentFormsCreatePayloadV3.d.ts +56 -0
  14. package/dist/cjs/models/IncidentFormsCreatePayloadV3.js +72 -0
  15. package/dist/cjs/models/IncidentFormsCreateResultV3.d.ts +31 -0
  16. package/dist/cjs/models/IncidentFormsCreateResultV3.js +51 -0
  17. package/dist/cjs/models/IncidentFormsListResultV3.d.ts +36 -0
  18. package/dist/cjs/models/IncidentFormsListResultV3.js +56 -0
  19. package/dist/cjs/models/IncidentFormsShowResultV3.d.ts +31 -0
  20. package/dist/cjs/models/IncidentFormsShowResultV3.js +51 -0
  21. package/dist/cjs/models/IncidentFormsUpdatePayloadV3.d.ts +56 -0
  22. package/dist/cjs/models/IncidentFormsUpdatePayloadV3.js +72 -0
  23. package/dist/cjs/models/IncidentFormsUpdateResultV3.d.ts +31 -0
  24. package/dist/cjs/models/IncidentFormsUpdateResultV3.js +51 -0
  25. package/dist/cjs/models/index.d.ts +10 -0
  26. package/dist/cjs/models/index.js +10 -0
  27. package/dist/cjs/version.d.ts +1 -1
  28. package/dist/cjs/version.js +1 -1
  29. package/dist/esm/apis/IncidentFormsV3Api.d.ts +131 -0
  30. package/dist/esm/apis/IncidentFormsV3Api.js +242 -0
  31. package/dist/esm/apis/index.d.ts +1 -0
  32. package/dist/esm/apis/index.js +1 -0
  33. package/dist/esm/models/IncidentFormLifecycleElementConfigV3.d.ts +30 -0
  34. package/dist/esm/models/IncidentFormLifecycleElementConfigV3.js +41 -0
  35. package/dist/esm/models/IncidentFormLifecycleElementPayloadV3.d.ts +115 -0
  36. package/dist/esm/models/IncidentFormLifecycleElementPayloadV3.js +102 -0
  37. package/dist/esm/models/IncidentFormLifecycleElementV3.d.ts +115 -0
  38. package/dist/esm/models/IncidentFormLifecycleElementV3.js +102 -0
  39. package/dist/esm/models/IncidentFormV3.d.ts +68 -0
  40. package/dist/esm/models/IncidentFormV3.js +77 -0
  41. package/dist/esm/models/IncidentFormsCreatePayloadV3.d.ts +56 -0
  42. package/dist/esm/models/IncidentFormsCreatePayloadV3.js +64 -0
  43. package/dist/esm/models/IncidentFormsCreateResultV3.d.ts +31 -0
  44. package/dist/esm/models/IncidentFormsCreateResultV3.js +44 -0
  45. package/dist/esm/models/IncidentFormsListResultV3.d.ts +36 -0
  46. package/dist/esm/models/IncidentFormsListResultV3.js +49 -0
  47. package/dist/esm/models/IncidentFormsShowResultV3.d.ts +31 -0
  48. package/dist/esm/models/IncidentFormsShowResultV3.js +44 -0
  49. package/dist/esm/models/IncidentFormsUpdatePayloadV3.d.ts +56 -0
  50. package/dist/esm/models/IncidentFormsUpdatePayloadV3.js +64 -0
  51. package/dist/esm/models/IncidentFormsUpdateResultV3.d.ts +31 -0
  52. package/dist/esm/models/IncidentFormsUpdateResultV3.js +44 -0
  53. package/dist/esm/models/index.d.ts +10 -0
  54. package/dist/esm/models/index.js +10 -0
  55. package/dist/esm/version.d.ts +1 -1
  56. package/dist/esm/version.js +1 -1
  57. package/package.json +1 -1
@@ -0,0 +1,131 @@
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 IncidentFormsCreatePayloadV3 } from '../models/IncidentFormsCreatePayloadV3.js';
14
+ import { type IncidentFormsCreateResultV3 } from '../models/IncidentFormsCreateResultV3.js';
15
+ import { type IncidentFormsListResultV3 } from '../models/IncidentFormsListResultV3.js';
16
+ import { type IncidentFormsShowResultV3 } from '../models/IncidentFormsShowResultV3.js';
17
+ import { type IncidentFormsUpdatePayloadV3 } from '../models/IncidentFormsUpdatePayloadV3.js';
18
+ import { type IncidentFormsUpdateResultV3 } from '../models/IncidentFormsUpdateResultV3.js';
19
+ export interface IncidentFormsV3CreateRequest {
20
+ /**
21
+ *
22
+ */
23
+ body: IncidentFormsCreatePayloadV3;
24
+ }
25
+ export interface IncidentFormsV3DeleteRequest {
26
+ /**
27
+ * Unique identifier for this incident form
28
+ */
29
+ id: string;
30
+ }
31
+ export interface IncidentFormsV3ListRequest {
32
+ /**
33
+ * Integer number of records to return
34
+ */
35
+ page_size?: number;
36
+ /**
37
+ * An incident form's ID. This endpoint will return a list of forms after this ID in relation to the API response order.
38
+ */
39
+ after?: string;
40
+ }
41
+ export interface IncidentFormsV3ShowRequest {
42
+ /**
43
+ * Unique identifier for this incident form
44
+ */
45
+ id: string;
46
+ }
47
+ export interface IncidentFormsV3UpdateRequest {
48
+ /**
49
+ * Unique identifier of the incident form
50
+ */
51
+ id: string;
52
+ /**
53
+ *
54
+ */
55
+ body: IncidentFormsUpdatePayloadV3;
56
+ }
57
+ /**
58
+ *
59
+ */
60
+ export declare class IncidentFormsV3Api extends runtime.BaseAPI {
61
+ /**
62
+ * Creates request options for incidentFormsV3Create without sending the request
63
+ */
64
+ incidentFormsV3CreateRequestOpts(requestParameters: IncidentFormsV3CreateRequest): Promise<runtime.RequestOpts>;
65
+ /**
66
+ * Create an incident form for an incident type. A form that already exists for that form type and incident type is rejected.
67
+ * Create Incident Forms V3
68
+ */
69
+ incidentFormsV3CreateRaw(requestParameters: IncidentFormsV3CreateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IncidentFormsCreateResultV3>>;
70
+ /**
71
+ * Create an incident form for an incident type. A form that already exists for that form type and incident type is rejected.
72
+ * Create Incident Forms V3
73
+ */
74
+ incidentFormsV3Create(requestParameters: IncidentFormsV3CreateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IncidentFormsCreateResultV3>;
75
+ /**
76
+ * Creates request options for incidentFormsV3Delete without sending the request
77
+ */
78
+ incidentFormsV3DeleteRequestOpts(requestParameters: IncidentFormsV3DeleteRequest): Promise<runtime.RequestOpts>;
79
+ /**
80
+ * Archive an incident form. The organisation\'s default form of a type cannot be archived.
81
+ * Delete Incident Forms V3
82
+ */
83
+ incidentFormsV3DeleteRaw(requestParameters: IncidentFormsV3DeleteRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
84
+ /**
85
+ * Archive an incident form. The organisation\'s default form of a type cannot be archived.
86
+ * Delete Incident Forms V3
87
+ */
88
+ incidentFormsV3Delete(requestParameters: IncidentFormsV3DeleteRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
89
+ /**
90
+ * Creates request options for incidentFormsV3List without sending the request
91
+ */
92
+ incidentFormsV3ListRequestOpts(requestParameters: IncidentFormsV3ListRequest): Promise<runtime.RequestOpts>;
93
+ /**
94
+ * List incident forms for your account, including their elements and expressions.
95
+ * List Incident Forms V3
96
+ */
97
+ incidentFormsV3ListRaw(requestParameters: IncidentFormsV3ListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IncidentFormsListResultV3>>;
98
+ /**
99
+ * List incident forms for your account, including their elements and expressions.
100
+ * List Incident Forms V3
101
+ */
102
+ incidentFormsV3List(requestParameters?: IncidentFormsV3ListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IncidentFormsListResultV3>;
103
+ /**
104
+ * Creates request options for incidentFormsV3Show without sending the request
105
+ */
106
+ incidentFormsV3ShowRequestOpts(requestParameters: IncidentFormsV3ShowRequest): Promise<runtime.RequestOpts>;
107
+ /**
108
+ * Get a single incident form, including its elements and expressions.
109
+ * Show Incident Forms V3
110
+ */
111
+ incidentFormsV3ShowRaw(requestParameters: IncidentFormsV3ShowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IncidentFormsShowResultV3>>;
112
+ /**
113
+ * Get a single incident form, including its elements and expressions.
114
+ * Show Incident Forms V3
115
+ */
116
+ incidentFormsV3Show(requestParameters: IncidentFormsV3ShowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IncidentFormsShowResultV3>;
117
+ /**
118
+ * Creates request options for incidentFormsV3Update without sending the request
119
+ */
120
+ incidentFormsV3UpdateRequestOpts(requestParameters: IncidentFormsV3UpdateRequest): Promise<runtime.RequestOpts>;
121
+ /**
122
+ * Replace an incident form, including its elements and expressions.
123
+ * Update Incident Forms V3
124
+ */
125
+ incidentFormsV3UpdateRaw(requestParameters: IncidentFormsV3UpdateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IncidentFormsUpdateResultV3>>;
126
+ /**
127
+ * Replace an incident form, including its elements and expressions.
128
+ * Update Incident Forms V3
129
+ */
130
+ incidentFormsV3Update(requestParameters: IncidentFormsV3UpdateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IncidentFormsUpdateResultV3>;
131
+ }
@@ -0,0 +1,279 @@
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.IncidentFormsV3Api = void 0;
50
+ const runtime = __importStar(require("../runtime.js"));
51
+ const IncidentFormsCreatePayloadV3_js_1 = require("../models/IncidentFormsCreatePayloadV3.js");
52
+ const IncidentFormsCreateResultV3_js_1 = require("../models/IncidentFormsCreateResultV3.js");
53
+ const IncidentFormsListResultV3_js_1 = require("../models/IncidentFormsListResultV3.js");
54
+ const IncidentFormsShowResultV3_js_1 = require("../models/IncidentFormsShowResultV3.js");
55
+ const IncidentFormsUpdatePayloadV3_js_1 = require("../models/IncidentFormsUpdatePayloadV3.js");
56
+ const IncidentFormsUpdateResultV3_js_1 = require("../models/IncidentFormsUpdateResultV3.js");
57
+ /**
58
+ *
59
+ */
60
+ class IncidentFormsV3Api extends runtime.BaseAPI {
61
+ /**
62
+ * Creates request options for incidentFormsV3Create without sending the request
63
+ */
64
+ async incidentFormsV3CreateRequestOpts(requestParameters) {
65
+ if (requestParameters['body'] == null) {
66
+ throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling incidentFormsV3Create().');
67
+ }
68
+ const queryParameters = {};
69
+ const headerParameters = {};
70
+ headerParameters['Content-Type'] = 'application/json';
71
+ if (this.configuration && this.configuration.accessToken) {
72
+ const token = this.configuration.accessToken;
73
+ const tokenString = await token("BearerAuth", []);
74
+ if (tokenString) {
75
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
76
+ }
77
+ }
78
+ let urlPath = `/v3/incident_forms`;
79
+ return {
80
+ path: urlPath,
81
+ method: 'POST',
82
+ headers: headerParameters,
83
+ query: queryParameters,
84
+ body: (0, IncidentFormsCreatePayloadV3_js_1.IncidentFormsCreatePayloadV3ToJSON)(requestParameters['body']),
85
+ };
86
+ }
87
+ /**
88
+ * Create an incident form for an incident type. A form that already exists for that form type and incident type is rejected.
89
+ * Create Incident Forms V3
90
+ */
91
+ async incidentFormsV3CreateRaw(requestParameters, initOverrides) {
92
+ const requestOptions = await this.incidentFormsV3CreateRequestOpts(requestParameters);
93
+ const response = await this.request(requestOptions, initOverrides);
94
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, IncidentFormsCreateResultV3_js_1.IncidentFormsCreateResultV3FromJSON)(jsonValue));
95
+ }
96
+ /**
97
+ * Create an incident form for an incident type. A form that already exists for that form type and incident type is rejected.
98
+ * Create Incident Forms V3
99
+ */
100
+ async incidentFormsV3Create(requestParameters, initOverrides) {
101
+ const response = await this.incidentFormsV3CreateRaw(requestParameters, initOverrides);
102
+ return await response.value();
103
+ }
104
+ /**
105
+ * Creates request options for incidentFormsV3Delete without sending the request
106
+ */
107
+ async incidentFormsV3DeleteRequestOpts(requestParameters) {
108
+ if (requestParameters['id'] == null) {
109
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling incidentFormsV3Delete().');
110
+ }
111
+ const queryParameters = {};
112
+ const headerParameters = {};
113
+ if (this.configuration && this.configuration.accessToken) {
114
+ const token = this.configuration.accessToken;
115
+ const tokenString = await token("BearerAuth", []);
116
+ if (tokenString) {
117
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
118
+ }
119
+ }
120
+ let urlPath = `/v3/incident_forms/{id}`;
121
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
122
+ return {
123
+ path: urlPath,
124
+ method: 'DELETE',
125
+ headers: headerParameters,
126
+ query: queryParameters,
127
+ };
128
+ }
129
+ /**
130
+ * Archive an incident form. The organisation\'s default form of a type cannot be archived.
131
+ * Delete Incident Forms V3
132
+ */
133
+ async incidentFormsV3DeleteRaw(requestParameters, initOverrides) {
134
+ const requestOptions = await this.incidentFormsV3DeleteRequestOpts(requestParameters);
135
+ const response = await this.request(requestOptions, initOverrides);
136
+ return new runtime.VoidApiResponse(response);
137
+ }
138
+ /**
139
+ * Archive an incident form. The organisation\'s default form of a type cannot be archived.
140
+ * Delete Incident Forms V3
141
+ */
142
+ async incidentFormsV3Delete(requestParameters, initOverrides) {
143
+ await this.incidentFormsV3DeleteRaw(requestParameters, initOverrides);
144
+ }
145
+ /**
146
+ * Creates request options for incidentFormsV3List without sending the request
147
+ */
148
+ async incidentFormsV3ListRequestOpts(requestParameters) {
149
+ const queryParameters = {};
150
+ if (requestParameters['page_size'] != null) {
151
+ queryParameters['page_size'] = requestParameters['page_size'];
152
+ }
153
+ if (requestParameters['after'] != null) {
154
+ queryParameters['after'] = requestParameters['after'];
155
+ }
156
+ const headerParameters = {};
157
+ if (this.configuration && this.configuration.accessToken) {
158
+ const token = this.configuration.accessToken;
159
+ const tokenString = await token("BearerAuth", []);
160
+ if (tokenString) {
161
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
162
+ }
163
+ }
164
+ let urlPath = `/v3/incident_forms`;
165
+ return {
166
+ path: urlPath,
167
+ method: 'GET',
168
+ headers: headerParameters,
169
+ query: queryParameters,
170
+ };
171
+ }
172
+ /**
173
+ * List incident forms for your account, including their elements and expressions.
174
+ * List Incident Forms V3
175
+ */
176
+ async incidentFormsV3ListRaw(requestParameters, initOverrides) {
177
+ const requestOptions = await this.incidentFormsV3ListRequestOpts(requestParameters);
178
+ const response = await this.request(requestOptions, initOverrides);
179
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, IncidentFormsListResultV3_js_1.IncidentFormsListResultV3FromJSON)(jsonValue));
180
+ }
181
+ /**
182
+ * List incident forms for your account, including their elements and expressions.
183
+ * List Incident Forms V3
184
+ */
185
+ async incidentFormsV3List(requestParameters = {}, initOverrides) {
186
+ const response = await this.incidentFormsV3ListRaw(requestParameters, initOverrides);
187
+ return await response.value();
188
+ }
189
+ /**
190
+ * Creates request options for incidentFormsV3Show without sending the request
191
+ */
192
+ async incidentFormsV3ShowRequestOpts(requestParameters) {
193
+ if (requestParameters['id'] == null) {
194
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling incidentFormsV3Show().');
195
+ }
196
+ const queryParameters = {};
197
+ const headerParameters = {};
198
+ if (this.configuration && this.configuration.accessToken) {
199
+ const token = this.configuration.accessToken;
200
+ const tokenString = await token("BearerAuth", []);
201
+ if (tokenString) {
202
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
203
+ }
204
+ }
205
+ let urlPath = `/v3/incident_forms/{id}`;
206
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
207
+ return {
208
+ path: urlPath,
209
+ method: 'GET',
210
+ headers: headerParameters,
211
+ query: queryParameters,
212
+ };
213
+ }
214
+ /**
215
+ * Get a single incident form, including its elements and expressions.
216
+ * Show Incident Forms V3
217
+ */
218
+ async incidentFormsV3ShowRaw(requestParameters, initOverrides) {
219
+ const requestOptions = await this.incidentFormsV3ShowRequestOpts(requestParameters);
220
+ const response = await this.request(requestOptions, initOverrides);
221
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, IncidentFormsShowResultV3_js_1.IncidentFormsShowResultV3FromJSON)(jsonValue));
222
+ }
223
+ /**
224
+ * Get a single incident form, including its elements and expressions.
225
+ * Show Incident Forms V3
226
+ */
227
+ async incidentFormsV3Show(requestParameters, initOverrides) {
228
+ const response = await this.incidentFormsV3ShowRaw(requestParameters, initOverrides);
229
+ return await response.value();
230
+ }
231
+ /**
232
+ * Creates request options for incidentFormsV3Update without sending the request
233
+ */
234
+ async incidentFormsV3UpdateRequestOpts(requestParameters) {
235
+ if (requestParameters['id'] == null) {
236
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling incidentFormsV3Update().');
237
+ }
238
+ if (requestParameters['body'] == null) {
239
+ throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling incidentFormsV3Update().');
240
+ }
241
+ const queryParameters = {};
242
+ const headerParameters = {};
243
+ headerParameters['Content-Type'] = 'application/json';
244
+ if (this.configuration && this.configuration.accessToken) {
245
+ const token = this.configuration.accessToken;
246
+ const tokenString = await token("BearerAuth", []);
247
+ if (tokenString) {
248
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
249
+ }
250
+ }
251
+ let urlPath = `/v3/incident_forms/{id}`;
252
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
253
+ return {
254
+ path: urlPath,
255
+ method: 'PUT',
256
+ headers: headerParameters,
257
+ query: queryParameters,
258
+ body: (0, IncidentFormsUpdatePayloadV3_js_1.IncidentFormsUpdatePayloadV3ToJSON)(requestParameters['body']),
259
+ };
260
+ }
261
+ /**
262
+ * Replace an incident form, including its elements and expressions.
263
+ * Update Incident Forms V3
264
+ */
265
+ async incidentFormsV3UpdateRaw(requestParameters, initOverrides) {
266
+ const requestOptions = await this.incidentFormsV3UpdateRequestOpts(requestParameters);
267
+ const response = await this.request(requestOptions, initOverrides);
268
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, IncidentFormsUpdateResultV3_js_1.IncidentFormsUpdateResultV3FromJSON)(jsonValue));
269
+ }
270
+ /**
271
+ * Replace an incident form, including its elements and expressions.
272
+ * Update Incident Forms V3
273
+ */
274
+ async incidentFormsV3Update(requestParameters, initOverrides) {
275
+ const response = await this.incidentFormsV3UpdateRaw(requestParameters, initOverrides);
276
+ return await response.value();
277
+ }
278
+ }
279
+ exports.IncidentFormsV3Api = IncidentFormsV3Api;
@@ -27,6 +27,7 @@ export * from './HeartbeatV2Api.js';
27
27
  export * from './IPAllowlistsV1Api.js';
28
28
  export * from './IncidentActivityLogEntriesV2Api.js';
29
29
  export * from './IncidentAttachmentsV1Api.js';
30
+ export * from './IncidentFormsV3Api.js';
30
31
  export * from './IncidentMembershipsV1Api.js';
31
32
  export * from './IncidentParticipantWorkloadsV2Api.js';
32
33
  export * from './IncidentParticipantsV2Api.js';
@@ -45,6 +45,7 @@ __exportStar(require("./HeartbeatV2Api.js"), exports);
45
45
  __exportStar(require("./IPAllowlistsV1Api.js"), exports);
46
46
  __exportStar(require("./IncidentActivityLogEntriesV2Api.js"), exports);
47
47
  __exportStar(require("./IncidentAttachmentsV1Api.js"), exports);
48
+ __exportStar(require("./IncidentFormsV3Api.js"), exports);
48
49
  __exportStar(require("./IncidentMembershipsV1Api.js"), exports);
49
50
  __exportStar(require("./IncidentParticipantWorkloadsV2Api.js"), exports);
50
51
  __exportStar(require("./IncidentParticipantsV2Api.js"), exports);
@@ -0,0 +1,30 @@
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 IncidentFormLifecycleElementConfigV3
16
+ */
17
+ export interface IncidentFormLifecycleElementConfigV3 {
18
+ /**
19
+ * Whether the free-text comment must be filled in, for anyone giving investigation feedback
20
+ */
21
+ require_comment?: boolean;
22
+ }
23
+ /**
24
+ * Check if a given object implements the IncidentFormLifecycleElementConfigV3 interface.
25
+ */
26
+ export declare function instanceOfIncidentFormLifecycleElementConfigV3(value: object): value is IncidentFormLifecycleElementConfigV3;
27
+ export declare function IncidentFormLifecycleElementConfigV3FromJSON(json: any): IncidentFormLifecycleElementConfigV3;
28
+ export declare function IncidentFormLifecycleElementConfigV3FromJSONTyped(json: any, ignoreDiscriminator: boolean): IncidentFormLifecycleElementConfigV3;
29
+ export declare function IncidentFormLifecycleElementConfigV3ToJSON(json: any): IncidentFormLifecycleElementConfigV3;
30
+ export declare function IncidentFormLifecycleElementConfigV3ToJSONTyped(value?: IncidentFormLifecycleElementConfigV3 | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,48 @@
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.instanceOfIncidentFormLifecycleElementConfigV3 = instanceOfIncidentFormLifecycleElementConfigV3;
17
+ exports.IncidentFormLifecycleElementConfigV3FromJSON = IncidentFormLifecycleElementConfigV3FromJSON;
18
+ exports.IncidentFormLifecycleElementConfigV3FromJSONTyped = IncidentFormLifecycleElementConfigV3FromJSONTyped;
19
+ exports.IncidentFormLifecycleElementConfigV3ToJSON = IncidentFormLifecycleElementConfigV3ToJSON;
20
+ exports.IncidentFormLifecycleElementConfigV3ToJSONTyped = IncidentFormLifecycleElementConfigV3ToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the IncidentFormLifecycleElementConfigV3 interface.
23
+ */
24
+ function instanceOfIncidentFormLifecycleElementConfigV3(value) {
25
+ return true;
26
+ }
27
+ function IncidentFormLifecycleElementConfigV3FromJSON(json) {
28
+ return IncidentFormLifecycleElementConfigV3FromJSONTyped(json, false);
29
+ }
30
+ function IncidentFormLifecycleElementConfigV3FromJSONTyped(json, ignoreDiscriminator) {
31
+ if (json == null) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'require_comment': json['require_comment'] == null ? undefined : json['require_comment'],
36
+ };
37
+ }
38
+ function IncidentFormLifecycleElementConfigV3ToJSON(json) {
39
+ return IncidentFormLifecycleElementConfigV3ToJSONTyped(json, false);
40
+ }
41
+ function IncidentFormLifecycleElementConfigV3ToJSONTyped(value, ignoreDiscriminator = false) {
42
+ if (value == null) {
43
+ return value;
44
+ }
45
+ return {
46
+ 'require_comment': value['require_comment'],
47
+ };
48
+ }
@@ -0,0 +1,115 @@
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 { IncidentFormLifecycleElementConfigV3 } from './IncidentFormLifecycleElementConfigV3.js';
13
+ import type { EngineParamBindingPayloadV3 } from './EngineParamBindingPayloadV3.js';
14
+ import type { ConditionGroupPayloadV3 } from './ConditionGroupPayloadV3.js';
15
+ /**
16
+ *
17
+ * @export
18
+ * @interface IncidentFormLifecycleElementPayloadV3
19
+ */
20
+ export interface IncidentFormLifecycleElementPayloadV3 {
21
+ /**
22
+ * Whether the user can explicitly choose no value. Only meaningful for custom field elements.
23
+ */
24
+ can_select_no_value?: boolean;
25
+ /**
26
+ *
27
+ */
28
+ config?: IncidentFormLifecycleElementConfigV3;
29
+ /**
30
+ * The custom field this element edits. Set only when element_type is custom_field.
31
+ */
32
+ custom_field_id?: string;
33
+ /**
34
+ *
35
+ */
36
+ default_value?: EngineParamBindingPayloadV3;
37
+ /**
38
+ * Description shown beside this element, as markdown
39
+ */
40
+ description?: string;
41
+ /**
42
+ * What this element captures
43
+ */
44
+ element_type: IncidentFormLifecycleElementPayloadV3ElementTypeEnum;
45
+ /**
46
+ * Identifier of an existing divider or text element. Omit when adding an element.
47
+ */
48
+ id?: string;
49
+ /**
50
+ * The incident role this element assigns. Set only when element_type is incident_role.
51
+ */
52
+ incident_role_id?: string;
53
+ /**
54
+ * The incident timestamp this element sets. Set only when element_type is timestamp.
55
+ */
56
+ incident_timestamp_id?: string;
57
+ /**
58
+ * Placeholder text shown in the empty field
59
+ */
60
+ placeholder?: string;
61
+ /**
62
+ * When this element must be filled in
63
+ */
64
+ required_if?: IncidentFormLifecycleElementPayloadV3RequiredIfEnum;
65
+ /**
66
+ * Condition groups that make this element required. Used when required_if is check_engine_config.
67
+ */
68
+ required_if_condition_groups?: Array<ConditionGroupPayloadV3>;
69
+ /**
70
+ * The element is shown when any of these condition groups match. Unset means it is always shown.
71
+ */
72
+ show_if_condition_groups?: Array<ConditionGroupPayloadV3>;
73
+ }
74
+ /**
75
+ * @export
76
+ */
77
+ export declare const IncidentFormLifecycleElementPayloadV3ElementTypeEnum: {
78
+ readonly Name: "name";
79
+ readonly Status: "status";
80
+ readonly Severity: "severity";
81
+ readonly IncidentRole: "incident_role";
82
+ readonly IncidentType: "incident_type";
83
+ readonly Summary: "summary";
84
+ readonly CustomField: "custom_field";
85
+ readonly Timestamp: "timestamp";
86
+ readonly UpdateMessage: "update_message";
87
+ readonly NextUpdateIn: "next_update_in";
88
+ readonly Triage: "triage";
89
+ readonly Visibility: "visibility";
90
+ readonly Divider: "divider";
91
+ readonly Text: "text";
92
+ readonly IncidentAttachments: "incident_attachments";
93
+ readonly SlackChannel: "slack_channel";
94
+ readonly AnnounceRetroIncident: "announce_retro_incident";
95
+ readonly EnterPostIncidentFlow: "enter_post_incident_flow";
96
+ readonly InvestigationFeedback: "investigation_feedback";
97
+ };
98
+ export type IncidentFormLifecycleElementPayloadV3ElementTypeEnum = typeof IncidentFormLifecycleElementPayloadV3ElementTypeEnum[keyof typeof IncidentFormLifecycleElementPayloadV3ElementTypeEnum];
99
+ /**
100
+ * @export
101
+ */
102
+ export declare const IncidentFormLifecycleElementPayloadV3RequiredIfEnum: {
103
+ readonly CheckEngineConfig: "check_engine_config";
104
+ readonly AlwaysRequire: "always_require";
105
+ readonly NeverRequire: "never_require";
106
+ };
107
+ export type IncidentFormLifecycleElementPayloadV3RequiredIfEnum = typeof IncidentFormLifecycleElementPayloadV3RequiredIfEnum[keyof typeof IncidentFormLifecycleElementPayloadV3RequiredIfEnum];
108
+ /**
109
+ * Check if a given object implements the IncidentFormLifecycleElementPayloadV3 interface.
110
+ */
111
+ export declare function instanceOfIncidentFormLifecycleElementPayloadV3(value: object): value is IncidentFormLifecycleElementPayloadV3;
112
+ export declare function IncidentFormLifecycleElementPayloadV3FromJSON(json: any): IncidentFormLifecycleElementPayloadV3;
113
+ export declare function IncidentFormLifecycleElementPayloadV3FromJSONTyped(json: any, ignoreDiscriminator: boolean): IncidentFormLifecycleElementPayloadV3;
114
+ export declare function IncidentFormLifecycleElementPayloadV3ToJSON(json: any): IncidentFormLifecycleElementPayloadV3;
115
+ export declare function IncidentFormLifecycleElementPayloadV3ToJSONTyped(value?: IncidentFormLifecycleElementPayloadV3 | null, ignoreDiscriminator?: boolean): any;