@incident-io/sdk 2.24.0 → 2.25.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/GlossaryEntriesV2Api.d.ts +157 -0
  2. package/dist/cjs/apis/GlossaryEntriesV2Api.js +327 -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/GlossaryEntriesCreatePayloadV2.d.ts +38 -0
  6. package/dist/cjs/models/GlossaryEntriesCreatePayloadV2.js +56 -0
  7. package/dist/cjs/models/GlossaryEntriesCreateResultV2.d.ts +31 -0
  8. package/dist/cjs/models/GlossaryEntriesCreateResultV2.js +51 -0
  9. package/dist/cjs/models/GlossaryEntriesListResultV2.d.ts +36 -0
  10. package/dist/cjs/models/GlossaryEntriesListResultV2.js +54 -0
  11. package/dist/cjs/models/GlossaryEntriesShowResultV2.d.ts +31 -0
  12. package/dist/cjs/models/GlossaryEntriesShowResultV2.js +51 -0
  13. package/dist/cjs/models/GlossaryEntriesUpdatePayloadV2.d.ts +34 -0
  14. package/dist/cjs/models/GlossaryEntriesUpdatePayloadV2.js +54 -0
  15. package/dist/cjs/models/GlossaryEntriesUpdateRanksPayloadV2.d.ts +31 -0
  16. package/dist/cjs/models/GlossaryEntriesUpdateRanksPayloadV2.js +51 -0
  17. package/dist/cjs/models/GlossaryEntriesUpdateRanksResultV2.d.ts +31 -0
  18. package/dist/cjs/models/GlossaryEntriesUpdateRanksResultV2.js +51 -0
  19. package/dist/cjs/models/GlossaryEntriesUpdateResultV2.d.ts +31 -0
  20. package/dist/cjs/models/GlossaryEntriesUpdateResultV2.js +51 -0
  21. package/dist/cjs/models/GlossaryEntryRankUpdateV2.d.ts +34 -0
  22. package/dist/cjs/models/GlossaryEntryRankUpdateV2.js +54 -0
  23. package/dist/cjs/models/GlossaryEntryV2.d.ts +55 -0
  24. package/dist/cjs/models/GlossaryEntryV2.js +71 -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/GlossaryEntriesV2Api.d.ts +157 -0
  30. package/dist/esm/apis/GlossaryEntriesV2Api.js +290 -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/GlossaryEntriesCreatePayloadV2.d.ts +38 -0
  34. package/dist/esm/models/GlossaryEntriesCreatePayloadV2.js +49 -0
  35. package/dist/esm/models/GlossaryEntriesCreateResultV2.d.ts +31 -0
  36. package/dist/esm/models/GlossaryEntriesCreateResultV2.js +44 -0
  37. package/dist/esm/models/GlossaryEntriesListResultV2.d.ts +36 -0
  38. package/dist/esm/models/GlossaryEntriesListResultV2.js +47 -0
  39. package/dist/esm/models/GlossaryEntriesShowResultV2.d.ts +31 -0
  40. package/dist/esm/models/GlossaryEntriesShowResultV2.js +44 -0
  41. package/dist/esm/models/GlossaryEntriesUpdatePayloadV2.d.ts +34 -0
  42. package/dist/esm/models/GlossaryEntriesUpdatePayloadV2.js +47 -0
  43. package/dist/esm/models/GlossaryEntriesUpdateRanksPayloadV2.d.ts +31 -0
  44. package/dist/esm/models/GlossaryEntriesUpdateRanksPayloadV2.js +44 -0
  45. package/dist/esm/models/GlossaryEntriesUpdateRanksResultV2.d.ts +31 -0
  46. package/dist/esm/models/GlossaryEntriesUpdateRanksResultV2.js +44 -0
  47. package/dist/esm/models/GlossaryEntriesUpdateResultV2.d.ts +31 -0
  48. package/dist/esm/models/GlossaryEntriesUpdateResultV2.js +44 -0
  49. package/dist/esm/models/GlossaryEntryRankUpdateV2.d.ts +34 -0
  50. package/dist/esm/models/GlossaryEntryRankUpdateV2.js +47 -0
  51. package/dist/esm/models/GlossaryEntryV2.d.ts +55 -0
  52. package/dist/esm/models/GlossaryEntryV2.js +64 -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,157 @@
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 GlossaryEntriesCreatePayloadV2 } from '../models/GlossaryEntriesCreatePayloadV2.js';
14
+ import { type GlossaryEntriesCreateResultV2 } from '../models/GlossaryEntriesCreateResultV2.js';
15
+ import { type GlossaryEntriesListResultV2 } from '../models/GlossaryEntriesListResultV2.js';
16
+ import { type GlossaryEntriesShowResultV2 } from '../models/GlossaryEntriesShowResultV2.js';
17
+ import { type GlossaryEntriesUpdatePayloadV2 } from '../models/GlossaryEntriesUpdatePayloadV2.js';
18
+ import { type GlossaryEntriesUpdateRanksPayloadV2 } from '../models/GlossaryEntriesUpdateRanksPayloadV2.js';
19
+ import { type GlossaryEntriesUpdateRanksResultV2 } from '../models/GlossaryEntriesUpdateRanksResultV2.js';
20
+ import { type GlossaryEntriesUpdateResultV2 } from '../models/GlossaryEntriesUpdateResultV2.js';
21
+ export interface GlossaryEntriesV2CreateRequest {
22
+ /**
23
+ *
24
+ */
25
+ body: GlossaryEntriesCreatePayloadV2;
26
+ }
27
+ export interface GlossaryEntriesV2DestroyRequest {
28
+ /**
29
+ * Unique identifier for this glossary entry
30
+ */
31
+ id: string;
32
+ }
33
+ export interface GlossaryEntriesV2ListRequest {
34
+ /**
35
+ * Number of glossary entries to return per page
36
+ */
37
+ page_size?: number;
38
+ /**
39
+ * A glossary entry's ID. This endpoint returns entries after this one. Without search, that is later in rank order. With search, it is the next hit after this entry.
40
+ */
41
+ after?: string;
42
+ /**
43
+ * Filter to entries whose term or description contains this value (case-insensitive)
44
+ */
45
+ search?: string;
46
+ }
47
+ export interface GlossaryEntriesV2ShowRequest {
48
+ /**
49
+ * Unique identifier for this glossary entry
50
+ */
51
+ id: string;
52
+ }
53
+ export interface GlossaryEntriesV2UpdateRequest {
54
+ /**
55
+ * Unique identifier for this glossary entry
56
+ */
57
+ id: string;
58
+ /**
59
+ *
60
+ */
61
+ body: GlossaryEntriesUpdatePayloadV2;
62
+ }
63
+ export interface GlossaryEntriesV2UpdateRanksRequest {
64
+ /**
65
+ *
66
+ */
67
+ body: GlossaryEntriesUpdateRanksPayloadV2;
68
+ }
69
+ /**
70
+ *
71
+ */
72
+ export declare class GlossaryEntriesV2Api extends runtime.BaseAPI {
73
+ /**
74
+ * Creates request options for glossaryEntriesV2Create without sending the request
75
+ */
76
+ glossaryEntriesV2CreateRequestOpts(requestParameters: GlossaryEntriesV2CreateRequest): Promise<runtime.RequestOpts>;
77
+ /**
78
+ * Create a glossary entry. It is appended to the end of the glossary unless after names an existing entry to insert it after.
79
+ * Create Glossary Entries V2
80
+ */
81
+ glossaryEntriesV2CreateRaw(requestParameters: GlossaryEntriesV2CreateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GlossaryEntriesCreateResultV2>>;
82
+ /**
83
+ * Create a glossary entry. It is appended to the end of the glossary unless after names an existing entry to insert it after.
84
+ * Create Glossary Entries V2
85
+ */
86
+ glossaryEntriesV2Create(requestParameters: GlossaryEntriesV2CreateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GlossaryEntriesCreateResultV2>;
87
+ /**
88
+ * Creates request options for glossaryEntriesV2Destroy without sending the request
89
+ */
90
+ glossaryEntriesV2DestroyRequestOpts(requestParameters: GlossaryEntriesV2DestroyRequest): Promise<runtime.RequestOpts>;
91
+ /**
92
+ * Delete a glossary entry. The entry is archived, which frees its term so the same item can be added again later.
93
+ * Destroy Glossary Entries V2
94
+ */
95
+ glossaryEntriesV2DestroyRaw(requestParameters: GlossaryEntriesV2DestroyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
96
+ /**
97
+ * Delete a glossary entry. The entry is archived, which frees its term so the same item can be added again later.
98
+ * Destroy Glossary Entries V2
99
+ */
100
+ glossaryEntriesV2Destroy(requestParameters: GlossaryEntriesV2DestroyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
101
+ /**
102
+ * Creates request options for glossaryEntriesV2List without sending the request
103
+ */
104
+ glossaryEntriesV2ListRequestOpts(requestParameters: GlossaryEntriesV2ListRequest): Promise<runtime.RequestOpts>;
105
+ /**
106
+ * List glossary entries for this organisation, in rank order.
107
+ * List Glossary Entries V2
108
+ */
109
+ glossaryEntriesV2ListRaw(requestParameters: GlossaryEntriesV2ListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GlossaryEntriesListResultV2>>;
110
+ /**
111
+ * List glossary entries for this organisation, in rank order.
112
+ * List Glossary Entries V2
113
+ */
114
+ glossaryEntriesV2List(requestParameters?: GlossaryEntriesV2ListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GlossaryEntriesListResultV2>;
115
+ /**
116
+ * Creates request options for glossaryEntriesV2Show without sending the request
117
+ */
118
+ glossaryEntriesV2ShowRequestOpts(requestParameters: GlossaryEntriesV2ShowRequest): Promise<runtime.RequestOpts>;
119
+ /**
120
+ * Get a single glossary entry.
121
+ * Show Glossary Entries V2
122
+ */
123
+ glossaryEntriesV2ShowRaw(requestParameters: GlossaryEntriesV2ShowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GlossaryEntriesShowResultV2>>;
124
+ /**
125
+ * Get a single glossary entry.
126
+ * Show Glossary Entries V2
127
+ */
128
+ glossaryEntriesV2Show(requestParameters: GlossaryEntriesV2ShowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GlossaryEntriesShowResultV2>;
129
+ /**
130
+ * Creates request options for glossaryEntriesV2Update without sending the request
131
+ */
132
+ glossaryEntriesV2UpdateRequestOpts(requestParameters: GlossaryEntriesV2UpdateRequest): Promise<runtime.RequestOpts>;
133
+ /**
134
+ * Update a glossary entry\'s term or description. Rank is unchanged; use the reorder action for that.
135
+ * Update Glossary Entries V2
136
+ */
137
+ glossaryEntriesV2UpdateRaw(requestParameters: GlossaryEntriesV2UpdateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GlossaryEntriesUpdateResultV2>>;
138
+ /**
139
+ * Update a glossary entry\'s term or description. Rank is unchanged; use the reorder action for that.
140
+ * Update Glossary Entries V2
141
+ */
142
+ glossaryEntriesV2Update(requestParameters: GlossaryEntriesV2UpdateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GlossaryEntriesUpdateResultV2>;
143
+ /**
144
+ * Creates request options for glossaryEntriesV2UpdateRanks without sending the request
145
+ */
146
+ glossaryEntriesV2UpdateRanksRequestOpts(requestParameters: GlossaryEntriesV2UpdateRanksRequest): Promise<runtime.RequestOpts>;
147
+ /**
148
+ * Reorder glossary entries. Every live entry must be included exactly once.
149
+ * UpdateRanks Glossary Entries V2
150
+ */
151
+ glossaryEntriesV2UpdateRanksRaw(requestParameters: GlossaryEntriesV2UpdateRanksRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GlossaryEntriesUpdateRanksResultV2>>;
152
+ /**
153
+ * Reorder glossary entries. Every live entry must be included exactly once.
154
+ * UpdateRanks Glossary Entries V2
155
+ */
156
+ glossaryEntriesV2UpdateRanks(requestParameters: GlossaryEntriesV2UpdateRanksRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GlossaryEntriesUpdateRanksResultV2>;
157
+ }
@@ -0,0 +1,327 @@
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.GlossaryEntriesV2Api = void 0;
50
+ const runtime = __importStar(require("../runtime.js"));
51
+ const GlossaryEntriesCreatePayloadV2_js_1 = require("../models/GlossaryEntriesCreatePayloadV2.js");
52
+ const GlossaryEntriesCreateResultV2_js_1 = require("../models/GlossaryEntriesCreateResultV2.js");
53
+ const GlossaryEntriesListResultV2_js_1 = require("../models/GlossaryEntriesListResultV2.js");
54
+ const GlossaryEntriesShowResultV2_js_1 = require("../models/GlossaryEntriesShowResultV2.js");
55
+ const GlossaryEntriesUpdatePayloadV2_js_1 = require("../models/GlossaryEntriesUpdatePayloadV2.js");
56
+ const GlossaryEntriesUpdateRanksPayloadV2_js_1 = require("../models/GlossaryEntriesUpdateRanksPayloadV2.js");
57
+ const GlossaryEntriesUpdateRanksResultV2_js_1 = require("../models/GlossaryEntriesUpdateRanksResultV2.js");
58
+ const GlossaryEntriesUpdateResultV2_js_1 = require("../models/GlossaryEntriesUpdateResultV2.js");
59
+ /**
60
+ *
61
+ */
62
+ class GlossaryEntriesV2Api extends runtime.BaseAPI {
63
+ /**
64
+ * Creates request options for glossaryEntriesV2Create without sending the request
65
+ */
66
+ async glossaryEntriesV2CreateRequestOpts(requestParameters) {
67
+ if (requestParameters['body'] == null) {
68
+ throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling glossaryEntriesV2Create().');
69
+ }
70
+ const queryParameters = {};
71
+ const headerParameters = {};
72
+ headerParameters['Content-Type'] = 'application/json';
73
+ if (this.configuration && this.configuration.accessToken) {
74
+ const token = this.configuration.accessToken;
75
+ const tokenString = await token("BearerAuth", []);
76
+ if (tokenString) {
77
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
78
+ }
79
+ }
80
+ let urlPath = `/v2/glossary_entries`;
81
+ return {
82
+ path: urlPath,
83
+ method: 'POST',
84
+ headers: headerParameters,
85
+ query: queryParameters,
86
+ body: (0, GlossaryEntriesCreatePayloadV2_js_1.GlossaryEntriesCreatePayloadV2ToJSON)(requestParameters['body']),
87
+ };
88
+ }
89
+ /**
90
+ * Create a glossary entry. It is appended to the end of the glossary unless after names an existing entry to insert it after.
91
+ * Create Glossary Entries V2
92
+ */
93
+ async glossaryEntriesV2CreateRaw(requestParameters, initOverrides) {
94
+ const requestOptions = await this.glossaryEntriesV2CreateRequestOpts(requestParameters);
95
+ const response = await this.request(requestOptions, initOverrides);
96
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, GlossaryEntriesCreateResultV2_js_1.GlossaryEntriesCreateResultV2FromJSON)(jsonValue));
97
+ }
98
+ /**
99
+ * Create a glossary entry. It is appended to the end of the glossary unless after names an existing entry to insert it after.
100
+ * Create Glossary Entries V2
101
+ */
102
+ async glossaryEntriesV2Create(requestParameters, initOverrides) {
103
+ const response = await this.glossaryEntriesV2CreateRaw(requestParameters, initOverrides);
104
+ return await response.value();
105
+ }
106
+ /**
107
+ * Creates request options for glossaryEntriesV2Destroy without sending the request
108
+ */
109
+ async glossaryEntriesV2DestroyRequestOpts(requestParameters) {
110
+ if (requestParameters['id'] == null) {
111
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling glossaryEntriesV2Destroy().');
112
+ }
113
+ const queryParameters = {};
114
+ const headerParameters = {};
115
+ if (this.configuration && this.configuration.accessToken) {
116
+ const token = this.configuration.accessToken;
117
+ const tokenString = await token("BearerAuth", []);
118
+ if (tokenString) {
119
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
120
+ }
121
+ }
122
+ let urlPath = `/v2/glossary_entries/{id}`;
123
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
124
+ return {
125
+ path: urlPath,
126
+ method: 'DELETE',
127
+ headers: headerParameters,
128
+ query: queryParameters,
129
+ };
130
+ }
131
+ /**
132
+ * Delete a glossary entry. The entry is archived, which frees its term so the same item can be added again later.
133
+ * Destroy Glossary Entries V2
134
+ */
135
+ async glossaryEntriesV2DestroyRaw(requestParameters, initOverrides) {
136
+ const requestOptions = await this.glossaryEntriesV2DestroyRequestOpts(requestParameters);
137
+ const response = await this.request(requestOptions, initOverrides);
138
+ return new runtime.VoidApiResponse(response);
139
+ }
140
+ /**
141
+ * Delete a glossary entry. The entry is archived, which frees its term so the same item can be added again later.
142
+ * Destroy Glossary Entries V2
143
+ */
144
+ async glossaryEntriesV2Destroy(requestParameters, initOverrides) {
145
+ await this.glossaryEntriesV2DestroyRaw(requestParameters, initOverrides);
146
+ }
147
+ /**
148
+ * Creates request options for glossaryEntriesV2List without sending the request
149
+ */
150
+ async glossaryEntriesV2ListRequestOpts(requestParameters) {
151
+ const queryParameters = {};
152
+ if (requestParameters['page_size'] != null) {
153
+ queryParameters['page_size'] = requestParameters['page_size'];
154
+ }
155
+ if (requestParameters['after'] != null) {
156
+ queryParameters['after'] = requestParameters['after'];
157
+ }
158
+ if (requestParameters['search'] != null) {
159
+ queryParameters['search'] = requestParameters['search'];
160
+ }
161
+ const headerParameters = {};
162
+ if (this.configuration && this.configuration.accessToken) {
163
+ const token = this.configuration.accessToken;
164
+ const tokenString = await token("BearerAuth", []);
165
+ if (tokenString) {
166
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
167
+ }
168
+ }
169
+ let urlPath = `/v2/glossary_entries`;
170
+ return {
171
+ path: urlPath,
172
+ method: 'GET',
173
+ headers: headerParameters,
174
+ query: queryParameters,
175
+ };
176
+ }
177
+ /**
178
+ * List glossary entries for this organisation, in rank order.
179
+ * List Glossary Entries V2
180
+ */
181
+ async glossaryEntriesV2ListRaw(requestParameters, initOverrides) {
182
+ const requestOptions = await this.glossaryEntriesV2ListRequestOpts(requestParameters);
183
+ const response = await this.request(requestOptions, initOverrides);
184
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, GlossaryEntriesListResultV2_js_1.GlossaryEntriesListResultV2FromJSON)(jsonValue));
185
+ }
186
+ /**
187
+ * List glossary entries for this organisation, in rank order.
188
+ * List Glossary Entries V2
189
+ */
190
+ async glossaryEntriesV2List(requestParameters = {}, initOverrides) {
191
+ const response = await this.glossaryEntriesV2ListRaw(requestParameters, initOverrides);
192
+ return await response.value();
193
+ }
194
+ /**
195
+ * Creates request options for glossaryEntriesV2Show without sending the request
196
+ */
197
+ async glossaryEntriesV2ShowRequestOpts(requestParameters) {
198
+ if (requestParameters['id'] == null) {
199
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling glossaryEntriesV2Show().');
200
+ }
201
+ const queryParameters = {};
202
+ const headerParameters = {};
203
+ if (this.configuration && this.configuration.accessToken) {
204
+ const token = this.configuration.accessToken;
205
+ const tokenString = await token("BearerAuth", []);
206
+ if (tokenString) {
207
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
208
+ }
209
+ }
210
+ let urlPath = `/v2/glossary_entries/{id}`;
211
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
212
+ return {
213
+ path: urlPath,
214
+ method: 'GET',
215
+ headers: headerParameters,
216
+ query: queryParameters,
217
+ };
218
+ }
219
+ /**
220
+ * Get a single glossary entry.
221
+ * Show Glossary Entries V2
222
+ */
223
+ async glossaryEntriesV2ShowRaw(requestParameters, initOverrides) {
224
+ const requestOptions = await this.glossaryEntriesV2ShowRequestOpts(requestParameters);
225
+ const response = await this.request(requestOptions, initOverrides);
226
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, GlossaryEntriesShowResultV2_js_1.GlossaryEntriesShowResultV2FromJSON)(jsonValue));
227
+ }
228
+ /**
229
+ * Get a single glossary entry.
230
+ * Show Glossary Entries V2
231
+ */
232
+ async glossaryEntriesV2Show(requestParameters, initOverrides) {
233
+ const response = await this.glossaryEntriesV2ShowRaw(requestParameters, initOverrides);
234
+ return await response.value();
235
+ }
236
+ /**
237
+ * Creates request options for glossaryEntriesV2Update without sending the request
238
+ */
239
+ async glossaryEntriesV2UpdateRequestOpts(requestParameters) {
240
+ if (requestParameters['id'] == null) {
241
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling glossaryEntriesV2Update().');
242
+ }
243
+ if (requestParameters['body'] == null) {
244
+ throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling glossaryEntriesV2Update().');
245
+ }
246
+ const queryParameters = {};
247
+ const headerParameters = {};
248
+ headerParameters['Content-Type'] = 'application/json';
249
+ if (this.configuration && this.configuration.accessToken) {
250
+ const token = this.configuration.accessToken;
251
+ const tokenString = await token("BearerAuth", []);
252
+ if (tokenString) {
253
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
254
+ }
255
+ }
256
+ let urlPath = `/v2/glossary_entries/{id}`;
257
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
258
+ return {
259
+ path: urlPath,
260
+ method: 'PUT',
261
+ headers: headerParameters,
262
+ query: queryParameters,
263
+ body: (0, GlossaryEntriesUpdatePayloadV2_js_1.GlossaryEntriesUpdatePayloadV2ToJSON)(requestParameters['body']),
264
+ };
265
+ }
266
+ /**
267
+ * Update a glossary entry\'s term or description. Rank is unchanged; use the reorder action for that.
268
+ * Update Glossary Entries V2
269
+ */
270
+ async glossaryEntriesV2UpdateRaw(requestParameters, initOverrides) {
271
+ const requestOptions = await this.glossaryEntriesV2UpdateRequestOpts(requestParameters);
272
+ const response = await this.request(requestOptions, initOverrides);
273
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, GlossaryEntriesUpdateResultV2_js_1.GlossaryEntriesUpdateResultV2FromJSON)(jsonValue));
274
+ }
275
+ /**
276
+ * Update a glossary entry\'s term or description. Rank is unchanged; use the reorder action for that.
277
+ * Update Glossary Entries V2
278
+ */
279
+ async glossaryEntriesV2Update(requestParameters, initOverrides) {
280
+ const response = await this.glossaryEntriesV2UpdateRaw(requestParameters, initOverrides);
281
+ return await response.value();
282
+ }
283
+ /**
284
+ * Creates request options for glossaryEntriesV2UpdateRanks without sending the request
285
+ */
286
+ async glossaryEntriesV2UpdateRanksRequestOpts(requestParameters) {
287
+ if (requestParameters['body'] == null) {
288
+ throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling glossaryEntriesV2UpdateRanks().');
289
+ }
290
+ const queryParameters = {};
291
+ const headerParameters = {};
292
+ headerParameters['Content-Type'] = 'application/json';
293
+ if (this.configuration && this.configuration.accessToken) {
294
+ const token = this.configuration.accessToken;
295
+ const tokenString = await token("BearerAuth", []);
296
+ if (tokenString) {
297
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
298
+ }
299
+ }
300
+ let urlPath = `/v2/glossary_entries/actions/update_ranks`;
301
+ return {
302
+ path: urlPath,
303
+ method: 'PUT',
304
+ headers: headerParameters,
305
+ query: queryParameters,
306
+ body: (0, GlossaryEntriesUpdateRanksPayloadV2_js_1.GlossaryEntriesUpdateRanksPayloadV2ToJSON)(requestParameters['body']),
307
+ };
308
+ }
309
+ /**
310
+ * Reorder glossary entries. Every live entry must be included exactly once.
311
+ * UpdateRanks Glossary Entries V2
312
+ */
313
+ async glossaryEntriesV2UpdateRanksRaw(requestParameters, initOverrides) {
314
+ const requestOptions = await this.glossaryEntriesV2UpdateRanksRequestOpts(requestParameters);
315
+ const response = await this.request(requestOptions, initOverrides);
316
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, GlossaryEntriesUpdateRanksResultV2_js_1.GlossaryEntriesUpdateRanksResultV2FromJSON)(jsonValue));
317
+ }
318
+ /**
319
+ * Reorder glossary entries. Every live entry must be included exactly once.
320
+ * UpdateRanks Glossary Entries V2
321
+ */
322
+ async glossaryEntriesV2UpdateRanks(requestParameters, initOverrides) {
323
+ const response = await this.glossaryEntriesV2UpdateRanksRaw(requestParameters, initOverrides);
324
+ return await response.value();
325
+ }
326
+ }
327
+ exports.GlossaryEntriesV2Api = GlossaryEntriesV2Api;
@@ -23,6 +23,7 @@ export * from './EscalationPathTemplatesV2Api.js';
23
23
  export * from './EscalationsV2Api.js';
24
24
  export * from './FollowUpsV2Api.js';
25
25
  export * from './FollowUpsV3Api.js';
26
+ export * from './GlossaryEntriesV2Api.js';
26
27
  export * from './HeartbeatV2Api.js';
27
28
  export * from './IPAllowlistsV1Api.js';
28
29
  export * from './IncidentActivityLogEntriesV2Api.js';
@@ -41,6 +41,7 @@ __exportStar(require("./EscalationPathTemplatesV2Api.js"), exports);
41
41
  __exportStar(require("./EscalationsV2Api.js"), exports);
42
42
  __exportStar(require("./FollowUpsV2Api.js"), exports);
43
43
  __exportStar(require("./FollowUpsV3Api.js"), exports);
44
+ __exportStar(require("./GlossaryEntriesV2Api.js"), exports);
44
45
  __exportStar(require("./HeartbeatV2Api.js"), exports);
45
46
  __exportStar(require("./IPAllowlistsV1Api.js"), exports);
46
47
  __exportStar(require("./IncidentActivityLogEntriesV2Api.js"), exports);
@@ -0,0 +1,38 @@
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 GlossaryEntriesCreatePayloadV2
16
+ */
17
+ export interface GlossaryEntriesCreatePayloadV2 {
18
+ /**
19
+ * ID of a live glossary entry. The new entry is inserted immediately after it. Omit to append the entry to the end.
20
+ */
21
+ after?: string;
22
+ /**
23
+ * What the term means
24
+ */
25
+ description: string;
26
+ /**
27
+ * The term, for example an acronym or service name. Unique among live entries, ignoring case.
28
+ */
29
+ item: string;
30
+ }
31
+ /**
32
+ * Check if a given object implements the GlossaryEntriesCreatePayloadV2 interface.
33
+ */
34
+ export declare function instanceOfGlossaryEntriesCreatePayloadV2(value: object): value is GlossaryEntriesCreatePayloadV2;
35
+ export declare function GlossaryEntriesCreatePayloadV2FromJSON(json: any): GlossaryEntriesCreatePayloadV2;
36
+ export declare function GlossaryEntriesCreatePayloadV2FromJSONTyped(json: any, ignoreDiscriminator: boolean): GlossaryEntriesCreatePayloadV2;
37
+ export declare function GlossaryEntriesCreatePayloadV2ToJSON(json: any): GlossaryEntriesCreatePayloadV2;
38
+ export declare function GlossaryEntriesCreatePayloadV2ToJSONTyped(value?: GlossaryEntriesCreatePayloadV2 | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,56 @@
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.instanceOfGlossaryEntriesCreatePayloadV2 = instanceOfGlossaryEntriesCreatePayloadV2;
17
+ exports.GlossaryEntriesCreatePayloadV2FromJSON = GlossaryEntriesCreatePayloadV2FromJSON;
18
+ exports.GlossaryEntriesCreatePayloadV2FromJSONTyped = GlossaryEntriesCreatePayloadV2FromJSONTyped;
19
+ exports.GlossaryEntriesCreatePayloadV2ToJSON = GlossaryEntriesCreatePayloadV2ToJSON;
20
+ exports.GlossaryEntriesCreatePayloadV2ToJSONTyped = GlossaryEntriesCreatePayloadV2ToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the GlossaryEntriesCreatePayloadV2 interface.
23
+ */
24
+ function instanceOfGlossaryEntriesCreatePayloadV2(value) {
25
+ if (!('description' in value) || value['description'] === undefined)
26
+ return false;
27
+ if (!('item' in value) || value['item'] === undefined)
28
+ return false;
29
+ return true;
30
+ }
31
+ function GlossaryEntriesCreatePayloadV2FromJSON(json) {
32
+ return GlossaryEntriesCreatePayloadV2FromJSONTyped(json, false);
33
+ }
34
+ function GlossaryEntriesCreatePayloadV2FromJSONTyped(json, ignoreDiscriminator) {
35
+ if (json == null) {
36
+ return json;
37
+ }
38
+ return {
39
+ 'after': json['after'] == null ? undefined : json['after'],
40
+ 'description': json['description'],
41
+ 'item': json['item'],
42
+ };
43
+ }
44
+ function GlossaryEntriesCreatePayloadV2ToJSON(json) {
45
+ return GlossaryEntriesCreatePayloadV2ToJSONTyped(json, false);
46
+ }
47
+ function GlossaryEntriesCreatePayloadV2ToJSONTyped(value, ignoreDiscriminator = false) {
48
+ if (value == null) {
49
+ return value;
50
+ }
51
+ return {
52
+ 'after': value['after'],
53
+ 'description': value['description'],
54
+ 'item': value['item'],
55
+ };
56
+ }
@@ -0,0 +1,31 @@
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 { GlossaryEntryV2 } from './GlossaryEntryV2.js';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface GlossaryEntriesCreateResultV2
17
+ */
18
+ export interface GlossaryEntriesCreateResultV2 {
19
+ /**
20
+ *
21
+ */
22
+ glossary_entry: GlossaryEntryV2;
23
+ }
24
+ /**
25
+ * Check if a given object implements the GlossaryEntriesCreateResultV2 interface.
26
+ */
27
+ export declare function instanceOfGlossaryEntriesCreateResultV2(value: object): value is GlossaryEntriesCreateResultV2;
28
+ export declare function GlossaryEntriesCreateResultV2FromJSON(json: any): GlossaryEntriesCreateResultV2;
29
+ export declare function GlossaryEntriesCreateResultV2FromJSONTyped(json: any, ignoreDiscriminator: boolean): GlossaryEntriesCreateResultV2;
30
+ export declare function GlossaryEntriesCreateResultV2ToJSON(json: any): GlossaryEntriesCreateResultV2;
31
+ export declare function GlossaryEntriesCreateResultV2ToJSONTyped(value?: GlossaryEntriesCreateResultV2 | null, ignoreDiscriminator?: boolean): any;