@createiq/backend 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js ADDED
@@ -0,0 +1,4233 @@
1
+ // client/core/ApiError.ts
2
+ var ApiError = class extends Error {
3
+ url;
4
+ status;
5
+ statusText;
6
+ body;
7
+ request;
8
+ constructor(request2, response, message) {
9
+ super(message);
10
+ this.name = "ApiError";
11
+ this.url = response.url;
12
+ this.status = response.status;
13
+ this.statusText = response.statusText;
14
+ this.body = response.body;
15
+ this.request = request2;
16
+ }
17
+ };
18
+
19
+ // client/core/CancelablePromise.ts
20
+ var CancelError = class extends Error {
21
+ constructor(message) {
22
+ super(message);
23
+ this.name = "CancelError";
24
+ }
25
+ get isCancelled() {
26
+ return true;
27
+ }
28
+ };
29
+ var CancelablePromise = class {
30
+ _isResolved;
31
+ _isRejected;
32
+ _isCancelled;
33
+ cancelHandlers;
34
+ promise;
35
+ _resolve;
36
+ _reject;
37
+ constructor(executor) {
38
+ this._isResolved = false;
39
+ this._isRejected = false;
40
+ this._isCancelled = false;
41
+ this.cancelHandlers = [];
42
+ this.promise = new Promise((resolve2, reject) => {
43
+ this._resolve = resolve2;
44
+ this._reject = reject;
45
+ const onResolve = (value) => {
46
+ if (this._isResolved || this._isRejected || this._isCancelled) {
47
+ return;
48
+ }
49
+ this._isResolved = true;
50
+ if (this._resolve) this._resolve(value);
51
+ };
52
+ const onReject = (reason) => {
53
+ if (this._isResolved || this._isRejected || this._isCancelled) {
54
+ return;
55
+ }
56
+ this._isRejected = true;
57
+ if (this._reject) this._reject(reason);
58
+ };
59
+ const onCancel = (cancelHandler) => {
60
+ if (this._isResolved || this._isRejected || this._isCancelled) {
61
+ return;
62
+ }
63
+ this.cancelHandlers.push(cancelHandler);
64
+ };
65
+ Object.defineProperty(onCancel, "isResolved", {
66
+ get: () => this._isResolved
67
+ });
68
+ Object.defineProperty(onCancel, "isRejected", {
69
+ get: () => this._isRejected
70
+ });
71
+ Object.defineProperty(onCancel, "isCancelled", {
72
+ get: () => this._isCancelled
73
+ });
74
+ return executor(onResolve, onReject, onCancel);
75
+ });
76
+ }
77
+ get [Symbol.toStringTag]() {
78
+ return "Cancellable Promise";
79
+ }
80
+ then(onFulfilled, onRejected) {
81
+ return this.promise.then(onFulfilled, onRejected);
82
+ }
83
+ catch(onRejected) {
84
+ return this.promise.catch(onRejected);
85
+ }
86
+ finally(onFinally) {
87
+ return this.promise.finally(onFinally);
88
+ }
89
+ cancel() {
90
+ if (this._isResolved || this._isRejected || this._isCancelled) {
91
+ return;
92
+ }
93
+ this._isCancelled = true;
94
+ if (this.cancelHandlers.length) {
95
+ try {
96
+ for (const cancelHandler of this.cancelHandlers) {
97
+ cancelHandler();
98
+ }
99
+ } catch (error) {
100
+ console.warn("Cancellation threw an error", error);
101
+ return;
102
+ }
103
+ }
104
+ this.cancelHandlers.length = 0;
105
+ if (this._reject) this._reject(new CancelError("Request aborted"));
106
+ }
107
+ get isCancelled() {
108
+ return this._isCancelled;
109
+ }
110
+ };
111
+
112
+ // client/core/OpenAPI.ts
113
+ var Interceptors = class {
114
+ _fns;
115
+ constructor() {
116
+ this._fns = [];
117
+ }
118
+ eject(fn) {
119
+ const index = this._fns.indexOf(fn);
120
+ if (index !== -1) {
121
+ this._fns = [...this._fns.slice(0, index), ...this._fns.slice(index + 1)];
122
+ }
123
+ }
124
+ use(fn) {
125
+ this._fns = [...this._fns, fn];
126
+ }
127
+ };
128
+ var OpenAPI = {
129
+ BASE: "",
130
+ CREDENTIALS: "include",
131
+ ENCODE_PATH: void 0,
132
+ HEADERS: void 0,
133
+ PASSWORD: void 0,
134
+ TOKEN: void 0,
135
+ USERNAME: void 0,
136
+ VERSION: "1.1",
137
+ WITH_CREDENTIALS: false,
138
+ interceptors: {
139
+ request: new Interceptors(),
140
+ response: new Interceptors()
141
+ }
142
+ };
143
+
144
+ // client/core/request.ts
145
+ var isString = (value) => {
146
+ return typeof value === "string";
147
+ };
148
+ var isStringWithValue = (value) => {
149
+ return isString(value) && value !== "";
150
+ };
151
+ var isBlob = (value) => {
152
+ return value instanceof Blob;
153
+ };
154
+ var isFormData = (value) => {
155
+ return value instanceof FormData;
156
+ };
157
+ var base64 = (str) => {
158
+ try {
159
+ return btoa(str);
160
+ } catch (err) {
161
+ return Buffer.from(str).toString("base64");
162
+ }
163
+ };
164
+ var getQueryString = (params) => {
165
+ const qs = [];
166
+ const append = (key, value) => {
167
+ qs.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);
168
+ };
169
+ const encodePair = (key, value) => {
170
+ if (value === void 0 || value === null) {
171
+ return;
172
+ }
173
+ if (value instanceof Date) {
174
+ append(key, value.toISOString());
175
+ } else if (Array.isArray(value)) {
176
+ value.forEach((v) => encodePair(key, v));
177
+ } else if (typeof value === "object") {
178
+ Object.entries(value).forEach(([k, v]) => encodePair(`${key}[${k}]`, v));
179
+ } else {
180
+ append(key, value);
181
+ }
182
+ };
183
+ Object.entries(params).forEach(([key, value]) => encodePair(key, value));
184
+ return qs.length ? `?${qs.join("&")}` : "";
185
+ };
186
+ var getUrl = (config, options) => {
187
+ const encoder = config.ENCODE_PATH || encodeURI;
188
+ const path = options.url.replace("{api-version}", config.VERSION).replace(/{(.*?)}/g, (substring, group) => {
189
+ if (options.path?.hasOwnProperty(group)) {
190
+ return encoder(String(options.path[group]));
191
+ }
192
+ return substring;
193
+ });
194
+ const url = config.BASE + path;
195
+ return options.query ? url + getQueryString(options.query) : url;
196
+ };
197
+ var getFormData = (options) => {
198
+ if (options.formData) {
199
+ const formData = new FormData();
200
+ const process = (key, value) => {
201
+ if (isString(value) || isBlob(value)) {
202
+ formData.append(key, value);
203
+ } else {
204
+ formData.append(key, JSON.stringify(value));
205
+ }
206
+ };
207
+ Object.entries(options.formData).filter(([, value]) => value !== void 0 && value !== null).forEach(([key, value]) => {
208
+ if (Array.isArray(value)) {
209
+ value.forEach((v) => process(key, v));
210
+ } else {
211
+ process(key, value);
212
+ }
213
+ });
214
+ return formData;
215
+ }
216
+ return void 0;
217
+ };
218
+ var resolve = async (options, resolver) => {
219
+ if (typeof resolver === "function") {
220
+ return resolver(options);
221
+ }
222
+ return resolver;
223
+ };
224
+ var getHeaders = async (config, options) => {
225
+ const [token, username, password, additionalHeaders] = await Promise.all([
226
+ // @ts-ignore
227
+ resolve(options, config.TOKEN),
228
+ // @ts-ignore
229
+ resolve(options, config.USERNAME),
230
+ // @ts-ignore
231
+ resolve(options, config.PASSWORD),
232
+ // @ts-ignore
233
+ resolve(options, config.HEADERS)
234
+ ]);
235
+ const headers = Object.entries({
236
+ Accept: "application/json",
237
+ ...additionalHeaders,
238
+ ...options.headers
239
+ }).filter(([, value]) => value !== void 0 && value !== null).reduce((headers2, [key, value]) => ({
240
+ ...headers2,
241
+ [key]: String(value)
242
+ }), {});
243
+ if (isStringWithValue(token)) {
244
+ headers["Authorization"] = `Bearer ${token}`;
245
+ }
246
+ if (isStringWithValue(username) && isStringWithValue(password)) {
247
+ const credentials = base64(`${username}:${password}`);
248
+ headers["Authorization"] = `Basic ${credentials}`;
249
+ }
250
+ if (options.body !== void 0) {
251
+ if (options.mediaType) {
252
+ headers["Content-Type"] = options.mediaType;
253
+ } else if (isBlob(options.body)) {
254
+ headers["Content-Type"] = options.body.type || "application/octet-stream";
255
+ } else if (isString(options.body)) {
256
+ headers["Content-Type"] = "text/plain";
257
+ } else if (!isFormData(options.body)) {
258
+ headers["Content-Type"] = "application/json";
259
+ }
260
+ }
261
+ return new Headers(headers);
262
+ };
263
+ var getRequestBody = (options) => {
264
+ if (options.body !== void 0) {
265
+ if (options.mediaType?.includes("application/json") || options.mediaType?.includes("+json")) {
266
+ return JSON.stringify(options.body);
267
+ } else if (isString(options.body) || isBlob(options.body) || isFormData(options.body)) {
268
+ return options.body;
269
+ } else {
270
+ return JSON.stringify(options.body);
271
+ }
272
+ }
273
+ return void 0;
274
+ };
275
+ var sendRequest = async (config, options, url, body, formData, headers, onCancel) => {
276
+ const controller = new AbortController();
277
+ let request2 = {
278
+ headers,
279
+ body: body ?? formData,
280
+ method: options.method,
281
+ signal: controller.signal
282
+ };
283
+ if (config.WITH_CREDENTIALS) {
284
+ request2.credentials = config.CREDENTIALS;
285
+ }
286
+ for (const fn of config.interceptors.request._fns) {
287
+ request2 = await fn(request2);
288
+ }
289
+ onCancel(() => controller.abort());
290
+ return await fetch(url, request2);
291
+ };
292
+ var getResponseHeader = (response, responseHeader) => {
293
+ if (responseHeader) {
294
+ const content = response.headers.get(responseHeader);
295
+ if (isString(content)) {
296
+ return content;
297
+ }
298
+ }
299
+ return void 0;
300
+ };
301
+ var getResponseBody = async (response) => {
302
+ if (response.status !== 204) {
303
+ try {
304
+ const contentType = response.headers.get("Content-Type");
305
+ if (contentType) {
306
+ const binaryTypes = ["application/octet-stream", "application/pdf", "application/zip", "audio/", "image/", "video/"];
307
+ if (contentType.includes("application/json") || contentType.includes("+json")) {
308
+ return await response.json();
309
+ } else if (binaryTypes.some((type) => contentType.includes(type))) {
310
+ return await response.blob();
311
+ } else if (contentType.includes("multipart/form-data")) {
312
+ return await response.formData();
313
+ } else if (contentType.includes("text/")) {
314
+ return await response.text();
315
+ }
316
+ }
317
+ } catch (error) {
318
+ console.error(error);
319
+ }
320
+ }
321
+ return void 0;
322
+ };
323
+ var catchErrorCodes = (options, result) => {
324
+ const errors = {
325
+ 400: "Bad Request",
326
+ 401: "Unauthorized",
327
+ 402: "Payment Required",
328
+ 403: "Forbidden",
329
+ 404: "Not Found",
330
+ 405: "Method Not Allowed",
331
+ 406: "Not Acceptable",
332
+ 407: "Proxy Authentication Required",
333
+ 408: "Request Timeout",
334
+ 409: "Conflict",
335
+ 410: "Gone",
336
+ 411: "Length Required",
337
+ 412: "Precondition Failed",
338
+ 413: "Payload Too Large",
339
+ 414: "URI Too Long",
340
+ 415: "Unsupported Media Type",
341
+ 416: "Range Not Satisfiable",
342
+ 417: "Expectation Failed",
343
+ 418: "Im a teapot",
344
+ 421: "Misdirected Request",
345
+ 422: "Unprocessable Content",
346
+ 423: "Locked",
347
+ 424: "Failed Dependency",
348
+ 425: "Too Early",
349
+ 426: "Upgrade Required",
350
+ 428: "Precondition Required",
351
+ 429: "Too Many Requests",
352
+ 431: "Request Header Fields Too Large",
353
+ 451: "Unavailable For Legal Reasons",
354
+ 500: "Internal Server Error",
355
+ 501: "Not Implemented",
356
+ 502: "Bad Gateway",
357
+ 503: "Service Unavailable",
358
+ 504: "Gateway Timeout",
359
+ 505: "HTTP Version Not Supported",
360
+ 506: "Variant Also Negotiates",
361
+ 507: "Insufficient Storage",
362
+ 508: "Loop Detected",
363
+ 510: "Not Extended",
364
+ 511: "Network Authentication Required",
365
+ ...options.errors
366
+ };
367
+ const error = errors[result.status];
368
+ if (error) {
369
+ throw new ApiError(options, result, error);
370
+ }
371
+ if (!result.ok) {
372
+ const errorStatus = result.status ?? "unknown";
373
+ const errorStatusText = result.statusText ?? "unknown";
374
+ const errorBody = (() => {
375
+ try {
376
+ return JSON.stringify(result.body, null, 2);
377
+ } catch (e) {
378
+ return void 0;
379
+ }
380
+ })();
381
+ throw new ApiError(
382
+ options,
383
+ result,
384
+ `Generic Error: status: ${errorStatus}; status text: ${errorStatusText}; body: ${errorBody}`
385
+ );
386
+ }
387
+ };
388
+ var request = (config, options) => {
389
+ return new CancelablePromise(async (resolve2, reject, onCancel) => {
390
+ try {
391
+ const url = getUrl(config, options);
392
+ const formData = getFormData(options);
393
+ const body = getRequestBody(options);
394
+ const headers = await getHeaders(config, options);
395
+ if (!onCancel.isCancelled) {
396
+ let response = await sendRequest(config, options, url, body, formData, headers, onCancel);
397
+ for (const fn of config.interceptors.response._fns) {
398
+ response = await fn(response);
399
+ }
400
+ const responseBody = await getResponseBody(response);
401
+ const responseHeader = getResponseHeader(response, options.responseHeader);
402
+ let transformedBody = responseBody;
403
+ if (options.responseTransformer && response.ok) {
404
+ transformedBody = await options.responseTransformer(responseBody);
405
+ }
406
+ const result = {
407
+ url,
408
+ ok: response.ok,
409
+ status: response.status,
410
+ statusText: response.statusText,
411
+ body: responseHeader ?? transformedBody
412
+ };
413
+ catchErrorCodes(options, result);
414
+ resolve2(result.body);
415
+ }
416
+ } catch (error) {
417
+ reject(error);
418
+ }
419
+ });
420
+ };
421
+
422
+ // client/sdk.gen.ts
423
+ var authPing = () => {
424
+ return request(OpenAPI, {
425
+ method: "GET",
426
+ url: "/api/v1/authPing",
427
+ errors: {
428
+ 401: "Your access token is not valid, or needs refreshing"
429
+ }
430
+ });
431
+ };
432
+ var version = () => {
433
+ return request(OpenAPI, {
434
+ method: "GET",
435
+ url: "/api/v1/version"
436
+ });
437
+ };
438
+ var accountSummary = () => {
439
+ return request(OpenAPI, {
440
+ method: "GET",
441
+ url: "/api/v1/account",
442
+ errors: {
443
+ 400: "Account does not exist"
444
+ }
445
+ });
446
+ };
447
+ var getSsoConfig = () => {
448
+ return request(OpenAPI, {
449
+ method: "GET",
450
+ url: "/api/v1/account/sso"
451
+ });
452
+ };
453
+ var getSecurityContext = () => {
454
+ return request(OpenAPI, {
455
+ method: "GET",
456
+ url: "/api/v1/user/context"
457
+ });
458
+ };
459
+ var sendChaserEmail = (data) => {
460
+ return request(OpenAPI, {
461
+ method: "POST",
462
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/sendChaserEmail",
463
+ path: {
464
+ subAccountId: data.subAccountId,
465
+ negotiationId: data.negotiationId
466
+ },
467
+ errors: {
468
+ 400: "Invalid negotiation state or trying to send the email too soon",
469
+ 404: "Negotiation or Sub-Account not found"
470
+ }
471
+ });
472
+ };
473
+ var unsubscribe = (data) => {
474
+ return request(OpenAPI, {
475
+ method: "POST",
476
+ url: "/api/v1/negotiations/{negotiationId}/muteNotifications",
477
+ path: {
478
+ negotiationId: data.negotiationId
479
+ },
480
+ body: data.requestBody,
481
+ mediaType: "application/json",
482
+ errors: {
483
+ 400: "The hash provided cannot be verified",
484
+ 404: "Negotiation not found"
485
+ }
486
+ });
487
+ };
488
+ var getProfile = () => {
489
+ return request(OpenAPI, {
490
+ method: "GET",
491
+ url: "/api/v1/user/profile"
492
+ });
493
+ };
494
+ var getSettings = () => {
495
+ return request(OpenAPI, {
496
+ method: "GET",
497
+ url: "/api/v1/account/settings",
498
+ errors: {
499
+ 404: "Account not found"
500
+ }
501
+ });
502
+ };
503
+ var deleteEntity = (data) => {
504
+ return request(OpenAPI, {
505
+ method: "DELETE",
506
+ url: "/api/v1/account/entity/{entityId}",
507
+ path: {
508
+ entityId: data.entityId
509
+ },
510
+ errors: {
511
+ 409: "Entity cannot be deleted as it is in use"
512
+ }
513
+ });
514
+ };
515
+ var getUsers = (data) => {
516
+ return request(OpenAPI, {
517
+ method: "GET",
518
+ url: "/api/v1/subaccount/{subAccountId}/users",
519
+ path: {
520
+ subAccountId: data.subAccountId
521
+ },
522
+ query: {
523
+ includeSuperManagers: data.includeSuperManagers,
524
+ includeAdvisors: data.includeAdvisors
525
+ },
526
+ errors: {
527
+ 404: "Sub-account not found"
528
+ }
529
+ });
530
+ };
531
+ var getUsersForPicker = (data) => {
532
+ return request(OpenAPI, {
533
+ method: "GET",
534
+ url: "/api/v1/subaccount/{subAccountId}/usersForPicker",
535
+ path: {
536
+ subAccountId: data.subAccountId
537
+ },
538
+ query: {
539
+ includeSuperManagers: data.includeSuperManagers,
540
+ includeAdvisors: data.includeAdvisors
541
+ },
542
+ errors: {
543
+ 404: "Sub-account not found"
544
+ }
545
+ });
546
+ };
547
+ var listEntities = (data = {}) => {
548
+ return request(OpenAPI, {
549
+ method: "GET",
550
+ url: "/api/v1/account/entities",
551
+ query: {
552
+ query: data.query
553
+ }
554
+ });
555
+ };
556
+ var getCompanyByEntityId = (data) => {
557
+ return request(OpenAPI, {
558
+ method: "GET",
559
+ url: "/api/v1/entity/{entityId}",
560
+ path: {
561
+ entityId: data.entityId
562
+ },
563
+ errors: {
564
+ 404: "Company not found"
565
+ }
566
+ });
567
+ };
568
+ var searchEntity = (data) => {
569
+ return request(OpenAPI, {
570
+ method: "GET",
571
+ url: "/api/v1/entity",
572
+ query: {
573
+ search: data.search
574
+ }
575
+ });
576
+ };
577
+ var validateEntities = (data) => {
578
+ return request(OpenAPI, {
579
+ method: "POST",
580
+ url: "/api/v1/entity/validate",
581
+ body: data.requestBody,
582
+ mediaType: "application/json"
583
+ });
584
+ };
585
+ var createPreset = (data) => {
586
+ return request(OpenAPI, {
587
+ method: "POST",
588
+ url: "/api/v1/subAccounts/{subAccountId}/presets",
589
+ path: {
590
+ subAccountId: data.subAccountId
591
+ },
592
+ body: data.requestBody,
593
+ mediaType: "application/json",
594
+ errors: {
595
+ 404: "Schema not found"
596
+ }
597
+ });
598
+ };
599
+ var listAllPresetsForSubAccountV1 = (data) => {
600
+ return request(OpenAPI, {
601
+ method: "GET",
602
+ url: "/api/v1/subAccounts/{subAccountId}/presets",
603
+ path: {
604
+ subAccountId: data.subAccountId
605
+ },
606
+ query: {
607
+ pageIndex: data.pageIndex,
608
+ pageSize: data.pageSize,
609
+ orderBy: data.orderBy,
610
+ orderDirection: data.orderDirection,
611
+ filterApproved: data.filterApproved,
612
+ advisorRelationshipId: data.advisorRelationshipId,
613
+ accessibleToAdvisor: data.accessibleToAdvisor,
614
+ filterStage2: data.filterStage2,
615
+ query: data.query
616
+ }
617
+ });
618
+ };
619
+ var deletePreset = (data) => {
620
+ return request(OpenAPI, {
621
+ method: "DELETE",
622
+ url: "/api/v1/presets/{presetId}",
623
+ path: {
624
+ presetId: data.presetId
625
+ }
626
+ });
627
+ };
628
+ var getPreset = (data) => {
629
+ return request(OpenAPI, {
630
+ method: "GET",
631
+ url: "/api/v1/presets/{presetId}",
632
+ path: {
633
+ presetId: data.presetId
634
+ }
635
+ });
636
+ };
637
+ var presetEditAnswers = (data) => {
638
+ return request(OpenAPI, {
639
+ method: "PUT",
640
+ url: "/api/v1/presets/{presetId}/answers",
641
+ path: {
642
+ presetId: data.presetId
643
+ },
644
+ body: data.requestBody,
645
+ mediaType: "application/json",
646
+ errors: {
647
+ 404: "Preset or election not found"
648
+ }
649
+ });
650
+ };
651
+ var presetGetMultipleNestedAnswers = (data) => {
652
+ return request(OpenAPI, {
653
+ method: "POST",
654
+ url: "/api/v1/presets/{presetId}/answers/nested/bulk",
655
+ path: {
656
+ presetId: data.presetId
657
+ },
658
+ body: data.requestBody,
659
+ mediaType: "application/json",
660
+ errors: {
661
+ 400: "Too many nested answers IDs passed",
662
+ 404: "Preset not found"
663
+ }
664
+ });
665
+ };
666
+ var presetSetMultipleNestedAnswers = (data) => {
667
+ return request(OpenAPI, {
668
+ method: "PUT",
669
+ url: "/api/v1/presets/{presetId}/answers/nested/bulk",
670
+ path: {
671
+ presetId: data.presetId
672
+ },
673
+ body: data.requestBody,
674
+ mediaType: "application/json",
675
+ errors: {
676
+ 400: "Too many nested answers IDs passed",
677
+ 404: "Preset not found"
678
+ }
679
+ });
680
+ };
681
+ var presetGetNestedAnswers = (data) => {
682
+ return request(OpenAPI, {
683
+ method: "GET",
684
+ url: "/api/v1/presets/{presetId}/answers/nested/{nestedAnswersId}",
685
+ path: {
686
+ presetId: data.presetId,
687
+ nestedAnswersId: data.nestedAnswersId
688
+ },
689
+ errors: {
690
+ 404: "Preset not found"
691
+ }
692
+ });
693
+ };
694
+ var presetSetNestedAnswers = (data) => {
695
+ return request(OpenAPI, {
696
+ method: "PUT",
697
+ url: "/api/v1/presets/{presetId}/answers/nested/{nestedAnswersId}",
698
+ path: {
699
+ presetId: data.presetId,
700
+ nestedAnswersId: data.nestedAnswersId
701
+ },
702
+ body: data.requestBody,
703
+ mediaType: "application/json",
704
+ errors: {
705
+ 404: "Preset or election not found"
706
+ }
707
+ });
708
+ };
709
+ var presetSwapParties = (data) => {
710
+ return request(OpenAPI, {
711
+ method: "PUT",
712
+ url: "/api/v1/presets/{presetId}/swapParties",
713
+ path: {
714
+ presetId: data.presetId
715
+ },
716
+ errors: {
717
+ 404: "Preset not found"
718
+ }
719
+ });
720
+ };
721
+ var upgradePresetSchema = (data) => {
722
+ return request(OpenAPI, {
723
+ method: "PUT",
724
+ url: "/api/v1/presets/{presetId}/schema/upgrade",
725
+ path: {
726
+ presetId: data.presetId
727
+ },
728
+ errors: {
729
+ 404: "Preset not found"
730
+ }
731
+ });
732
+ };
733
+ var updateMetadata = (data) => {
734
+ return request(OpenAPI, {
735
+ method: "PUT",
736
+ url: "/api/v1/presets/{presetId}/metadata",
737
+ path: {
738
+ presetId: data.presetId
739
+ },
740
+ body: data.requestBody,
741
+ mediaType: "application/json",
742
+ errors: {
743
+ 404: "Preset not found"
744
+ }
745
+ });
746
+ };
747
+ var downloadPreset = (data) => {
748
+ return request(OpenAPI, {
749
+ method: "GET",
750
+ url: "/api/v1/presets/{presetId}/extension/{extension}",
751
+ path: {
752
+ presetId: data.presetId,
753
+ extension: data.extension
754
+ }
755
+ });
756
+ };
757
+ var listAllPresetsForSubAccountV2 = (data) => {
758
+ return request(OpenAPI, {
759
+ method: "GET",
760
+ url: "/api/v2/subAccounts/{subAccountId}/presets",
761
+ path: {
762
+ subAccountId: data.subAccountId
763
+ },
764
+ query: {
765
+ pageIndex: data.pageIndex,
766
+ pageSize: data.pageSize,
767
+ orderBy: data.orderBy,
768
+ orderDirection: data.orderDirection,
769
+ filterApproved: data.filterApproved,
770
+ advisorRelationshipId: data.advisorRelationshipId,
771
+ accessibleToAdvisor: data.accessibleToAdvisor,
772
+ filterStage2: data.filterStage2,
773
+ query: data.query
774
+ }
775
+ });
776
+ };
777
+ var listPresets = (data) => {
778
+ return request(OpenAPI, {
779
+ method: "GET",
780
+ url: "/api/v1/subAccounts/{subAccountId}/documents/{documentId}/presets",
781
+ path: {
782
+ subAccountId: data.subAccountId,
783
+ documentId: data.documentId
784
+ },
785
+ query: {
786
+ pageIndex: data.pageIndex,
787
+ pageSize: data.pageSize,
788
+ orderBy: data.orderBy,
789
+ orderDirection: data.orderDirection,
790
+ filterApproved: data.filterApproved,
791
+ filterStage2: data.filterStage2
792
+ }
793
+ });
794
+ };
795
+ var presetSendForApproval = (data) => {
796
+ return request(OpenAPI, {
797
+ method: "PUT",
798
+ url: "/api/v1/presets/{presetId}/approvals/sendForApproval",
799
+ path: {
800
+ presetId: data.presetId
801
+ },
802
+ errors: {
803
+ 404: "Preset not found"
804
+ }
805
+ });
806
+ };
807
+ var clonePreset = (data) => {
808
+ return request(OpenAPI, {
809
+ method: "POST",
810
+ url: "/api/v1/presets/{presetId}/clone",
811
+ path: {
812
+ presetId: data.presetId
813
+ },
814
+ query: {
815
+ withApprovers: data.withApprovers
816
+ },
817
+ errors: {
818
+ 404: "Preset not found"
819
+ }
820
+ });
821
+ };
822
+ var presetSetElectionApproval = (data) => {
823
+ return request(OpenAPI, {
824
+ method: "PUT",
825
+ url: "/api/v1/presets/{presetId}/approvals/elections/{electionId}",
826
+ path: {
827
+ presetId: data.presetId,
828
+ electionId: data.electionId
829
+ },
830
+ body: data.requestBody,
831
+ mediaType: "application/json",
832
+ errors: {
833
+ 403: "Forbidden action in this state",
834
+ 404: "Preset not found"
835
+ }
836
+ });
837
+ };
838
+ var presetSetFinalApproval = (data) => {
839
+ return request(OpenAPI, {
840
+ method: "PUT",
841
+ url: "/api/v1/presets/{presetId}/approvals/document",
842
+ path: {
843
+ presetId: data.presetId
844
+ },
845
+ body: data.requestBody,
846
+ mediaType: "application/json",
847
+ errors: {
848
+ 404: "Preset not found"
849
+ }
850
+ });
851
+ };
852
+ var createPresetAuditTrailJson = (data) => {
853
+ return request(OpenAPI, {
854
+ method: "GET",
855
+ url: "/api/v1/presets/{presetId}/audit_trail/json",
856
+ path: {
857
+ presetId: data.presetId
858
+ }
859
+ });
860
+ };
861
+ var createPresetAuditTrailXlsx = (data) => {
862
+ return request(OpenAPI, {
863
+ method: "GET",
864
+ url: "/api/v1/presets/{presetId}/audit_trail/xlsx",
865
+ path: {
866
+ presetId: data.presetId
867
+ },
868
+ query: {
869
+ timeZone: data.timeZone
870
+ }
871
+ });
872
+ };
873
+ var listNegotiations = (data) => {
874
+ return request(OpenAPI, {
875
+ method: "GET",
876
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations",
877
+ path: {
878
+ subAccountId: data.subAccountId
879
+ },
880
+ query: {
881
+ state: data.state,
882
+ status: data.status,
883
+ workflowType: data.workflowType,
884
+ userId: data.userId,
885
+ turn: data.turn,
886
+ staleFrom: data.staleFrom,
887
+ staleTo: data.staleTo,
888
+ groupId: data.groupId,
889
+ bulkSetIds: data.bulkSetIds,
890
+ jobStatus: data.jobStatus,
891
+ filters: data.filters,
892
+ query: data.query,
893
+ pageIndex: data.pageIndex,
894
+ pageSize: data.pageSize,
895
+ orderBy: data.orderBy,
896
+ orderDirection: data.orderDirection,
897
+ documentPublisherId: data.documentPublisherId,
898
+ excludedUiStates: data.excludedUiStates,
899
+ documentType: data.documentType,
900
+ myEntityName: data.myEntityName,
901
+ counterpartyEntityName: data.counterpartyEntityName,
902
+ inBulkSet: data.inBulkSet,
903
+ advisorRelationshipId: data.advisorRelationshipId,
904
+ accessibleToAdvisor: data.accessibleToAdvisor,
905
+ customReferenceId: data.customReferenceId,
906
+ displayReferenceId: data.displayReferenceId,
907
+ isForkedOrFork: data.isForkedOrFork,
908
+ approverName: data.approverName,
909
+ partyA: data.partyA,
910
+ partyB: data.partyB,
911
+ partyC: data.partyC,
912
+ partyAny: data.partyAny,
913
+ isTriparty: data.isTriparty,
914
+ isOffline: data.isOffline,
915
+ forkedFromOrTo: data.forkedFromOrTo
916
+ }
917
+ });
918
+ };
919
+ var createNegotiation = (data) => {
920
+ return request(OpenAPI, {
921
+ method: "POST",
922
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations",
923
+ path: {
924
+ subAccountId: data.subAccountId
925
+ },
926
+ body: data.requestBody,
927
+ mediaType: "application/json",
928
+ errors: {
929
+ 404: "Negotiation or election not found"
930
+ }
931
+ });
932
+ };
933
+ var setFinalApproval = (data) => {
934
+ return request(OpenAPI, {
935
+ method: "PUT",
936
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/document",
937
+ path: {
938
+ subAccountId: data.subAccountId,
939
+ negotiationId: data.negotiationId
940
+ },
941
+ body: data.requestBody,
942
+ mediaType: "application/json"
943
+ });
944
+ };
945
+ var downloadDashboardReportAsExcel = (data) => {
946
+ return request(OpenAPI, {
947
+ method: "GET",
948
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/xlsx",
949
+ path: {
950
+ subAccountId: data.subAccountId
951
+ },
952
+ query: {
953
+ documentId: data.documentId,
954
+ timeZone: data.timeZone,
955
+ state: data.state,
956
+ status: data.status,
957
+ workflowType: data.workflowType,
958
+ userId: data.userId,
959
+ turn: data.turn,
960
+ staleFrom: data.staleFrom,
961
+ staleTo: data.staleTo,
962
+ groupId: data.groupId,
963
+ bulkSetIds: data.bulkSetIds,
964
+ jobStatus: data.jobStatus,
965
+ filters: data.filters,
966
+ query: data.query,
967
+ pageIndex: data.pageIndex,
968
+ pageSize: data.pageSize,
969
+ orderBy: data.orderBy,
970
+ orderDirection: data.orderDirection,
971
+ documentPublisherId: data.documentPublisherId,
972
+ excludedUiStates: data.excludedUiStates,
973
+ documentType: data.documentType,
974
+ myEntityName: data.myEntityName,
975
+ counterpartyEntityName: data.counterpartyEntityName,
976
+ inBulkSet: data.inBulkSet,
977
+ advisorRelationshipId: data.advisorRelationshipId,
978
+ accessibleToAdvisor: data.accessibleToAdvisor,
979
+ customReferenceId: data.customReferenceId,
980
+ displayReferenceId: data.displayReferenceId,
981
+ isForkedOrFork: data.isForkedOrFork,
982
+ approverName: data.approverName,
983
+ partyA: data.partyA,
984
+ partyB: data.partyB,
985
+ partyC: data.partyC,
986
+ partyAny: data.partyAny,
987
+ isTriparty: data.isTriparty,
988
+ isOffline: data.isOffline,
989
+ requestingFromContext: data.requestingFromContext,
990
+ forkedFromOrTo: data.forkedFromOrTo
991
+ }
992
+ });
993
+ };
994
+ var upgradeSchema = (data) => {
995
+ return request(OpenAPI, {
996
+ method: "PUT",
997
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/upgrade",
998
+ path: {
999
+ subAccountId: data.subAccountId,
1000
+ negotiationId: data.negotiationId
1001
+ }
1002
+ });
1003
+ };
1004
+ var breakingChanges = (data) => {
1005
+ return request(OpenAPI, {
1006
+ method: "GET",
1007
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/breaking_changes",
1008
+ path: {
1009
+ subAccountId: data.subAccountId,
1010
+ negotiationId: data.negotiationId
1011
+ }
1012
+ });
1013
+ };
1014
+ var getAccessibleNegotiation = (data) => {
1015
+ return request(OpenAPI, {
1016
+ method: "GET",
1017
+ url: "/api/v1/negotiations/{negotiationId}",
1018
+ path: {
1019
+ negotiationId: data.negotiationId
1020
+ }
1021
+ });
1022
+ };
1023
+ var getNegotiation = (data) => {
1024
+ return request(OpenAPI, {
1025
+ method: "GET",
1026
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}",
1027
+ path: {
1028
+ subAccountId: data.subAccountId,
1029
+ negotiationId: data.negotiationId
1030
+ }
1031
+ });
1032
+ };
1033
+ var getExecutedNegotiationSummary = (data) => {
1034
+ return request(OpenAPI, {
1035
+ method: "GET",
1036
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/metadata",
1037
+ path: {
1038
+ subAccountId: data.subAccountId,
1039
+ negotiationId: data.negotiationId
1040
+ },
1041
+ errors: {
1042
+ 404: "Negotiation not found"
1043
+ }
1044
+ });
1045
+ };
1046
+ var getAsCdm = (data) => {
1047
+ return request(OpenAPI, {
1048
+ method: "GET",
1049
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/cdm",
1050
+ path: {
1051
+ subAccountId: data.subAccountId,
1052
+ negotiationId: data.negotiationId
1053
+ },
1054
+ errors: {
1055
+ 400: "CDM not available for this negotiation",
1056
+ 404: "Negotiation not found"
1057
+ }
1058
+ });
1059
+ };
1060
+ var getDownloadExecutedNegotiationsAsExcel = (data) => {
1061
+ return request(OpenAPI, {
1062
+ method: "GET",
1063
+ url: "/api/v1/subAccounts/{subAccountId}/executed_negotiations/xlsx",
1064
+ path: {
1065
+ subAccountId: data.subAccountId
1066
+ },
1067
+ query: {
1068
+ documentId: data.documentId,
1069
+ timeZone: data.timeZone
1070
+ },
1071
+ errors: {
1072
+ 404: "Negotiation not found"
1073
+ }
1074
+ });
1075
+ };
1076
+ var downloadExecutedNegotiationsAsExcel = (data) => {
1077
+ return request(OpenAPI, {
1078
+ method: "POST",
1079
+ url: "/api/v1/subAccounts/{subAccountId}/executed_negotiations/xlsx",
1080
+ path: {
1081
+ subAccountId: data.subAccountId
1082
+ },
1083
+ body: data.requestBody,
1084
+ mediaType: "application/json",
1085
+ errors: {
1086
+ 404: "Negotiation not found"
1087
+ }
1088
+ });
1089
+ };
1090
+ var getDownloadActiveNegotiationsReportAsExcel = (data) => {
1091
+ return request(OpenAPI, {
1092
+ method: "GET",
1093
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/analytics/xlsx",
1094
+ path: {
1095
+ subAccountId: data.subAccountId
1096
+ },
1097
+ query: {
1098
+ documentId: data.documentId,
1099
+ timeZone: data.timeZone
1100
+ },
1101
+ errors: {
1102
+ 404: "Negotiation not found"
1103
+ }
1104
+ });
1105
+ };
1106
+ var downloadActiveNegotiationsReportAsExcel = (data) => {
1107
+ return request(OpenAPI, {
1108
+ method: "POST",
1109
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/analytics/xlsx",
1110
+ path: {
1111
+ subAccountId: data.subAccountId
1112
+ },
1113
+ body: data.requestBody,
1114
+ mediaType: "application/json",
1115
+ errors: {
1116
+ 404: "Negotiation not found"
1117
+ }
1118
+ });
1119
+ };
1120
+ var downloadNegotiation = (data) => {
1121
+ return request(OpenAPI, {
1122
+ method: "GET",
1123
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extension/{extension}",
1124
+ path: {
1125
+ subAccountId: data.subAccountId,
1126
+ negotiationId: data.negotiationId,
1127
+ extension: data.extension
1128
+ },
1129
+ query: {
1130
+ includeSignaturePages: data.includeSignaturePages,
1131
+ isLockedDocx: data.isLockedDocx,
1132
+ includeFormFields: data.includeFormFields
1133
+ }
1134
+ });
1135
+ };
1136
+ var downloadPreExecutionCounterpartyNegotiation = (data) => {
1137
+ return request(OpenAPI, {
1138
+ method: "GET",
1139
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/parties/{counterpartyId}/extension/{extension}",
1140
+ path: {
1141
+ subAccountId: data.subAccountId,
1142
+ negotiationId: data.negotiationId,
1143
+ counterpartyId: data.counterpartyId,
1144
+ extension: data.extension
1145
+ }
1146
+ });
1147
+ };
1148
+ var getSignedExecutedVersion = (data) => {
1149
+ return request(OpenAPI, {
1150
+ method: "GET",
1151
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executed_version",
1152
+ path: {
1153
+ subAccountId: data.subAccountId,
1154
+ negotiationId: data.negotiationId
1155
+ },
1156
+ errors: {
1157
+ 404: "Missing document"
1158
+ }
1159
+ });
1160
+ };
1161
+ var setSignedExecutedVersion = (data) => {
1162
+ return request(OpenAPI, {
1163
+ method: "PUT",
1164
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executed_version",
1165
+ path: {
1166
+ subAccountId: data.subAccountId,
1167
+ negotiationId: data.negotiationId
1168
+ },
1169
+ body: data.requestBody,
1170
+ mediaType: "application/pdf",
1171
+ errors: {
1172
+ 400: "The negotiation is not at the Review & Sign stage or there is already an executed version uploaded",
1173
+ 403: "The negotiation does not support uploading executed versions",
1174
+ 404: "The negotiation was not found"
1175
+ }
1176
+ });
1177
+ };
1178
+ var deleteSignedExecutedVersion = (data) => {
1179
+ return request(OpenAPI, {
1180
+ method: "DELETE",
1181
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executed_version",
1182
+ path: {
1183
+ subAccountId: data.subAccountId,
1184
+ negotiationId: data.negotiationId
1185
+ },
1186
+ errors: {
1187
+ 403: "The negotiation does not support uploading executed versions"
1188
+ }
1189
+ });
1190
+ };
1191
+ var checkSignedExecutedVersion = (data) => {
1192
+ return request(OpenAPI, {
1193
+ method: "GET",
1194
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executed_version/exists",
1195
+ path: {
1196
+ subAccountId: data.subAccountId,
1197
+ negotiationId: data.negotiationId
1198
+ },
1199
+ errors: {
1200
+ 403: "The negotiation has not yet been agreed"
1201
+ }
1202
+ });
1203
+ };
1204
+ var getNegotiationFilesSummary = (data) => {
1205
+ return request(OpenAPI, {
1206
+ method: "GET",
1207
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/negotiationFiles/summary",
1208
+ path: {
1209
+ subAccountId: data.subAccountId,
1210
+ negotiationId: data.negotiationId
1211
+ },
1212
+ errors: {
1213
+ 404: "No negotiation"
1214
+ }
1215
+ });
1216
+ };
1217
+ var createAuditTrailXlsx = (data) => {
1218
+ return request(OpenAPI, {
1219
+ method: "GET",
1220
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/audit_trail/xlsx",
1221
+ path: {
1222
+ subAccountId: data.subAccountId,
1223
+ negotiationId: data.negotiationId
1224
+ },
1225
+ query: {
1226
+ timeZone: data.timeZone
1227
+ }
1228
+ });
1229
+ };
1230
+ var createAuditTrailPdf = (data) => {
1231
+ return request(OpenAPI, {
1232
+ method: "GET",
1233
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/audit_trail/pdf",
1234
+ path: {
1235
+ subAccountId: data.subAccountId,
1236
+ negotiationId: data.negotiationId
1237
+ },
1238
+ query: {
1239
+ timeZone: data.timeZone
1240
+ }
1241
+ });
1242
+ };
1243
+ var createAuditTrailJson = (data) => {
1244
+ return request(OpenAPI, {
1245
+ method: "GET",
1246
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/audit_trail/json",
1247
+ path: {
1248
+ subAccountId: data.subAccountId,
1249
+ negotiationId: data.negotiationId
1250
+ }
1251
+ });
1252
+ };
1253
+ var createSigningPack = (data) => {
1254
+ return request(OpenAPI, {
1255
+ method: "GET",
1256
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signingPack",
1257
+ path: {
1258
+ subAccountId: data.subAccountId,
1259
+ negotiationId: data.negotiationId
1260
+ }
1261
+ });
1262
+ };
1263
+ var downloadPostExecutionPack = (data) => {
1264
+ return request(OpenAPI, {
1265
+ method: "GET",
1266
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/postExecutionPack",
1267
+ path: {
1268
+ subAccountId: data.subAccountId,
1269
+ negotiationId: data.negotiationId
1270
+ },
1271
+ query: {
1272
+ timeZone: data.timeZone
1273
+ }
1274
+ });
1275
+ };
1276
+ var createSignaturePagePdf = (data) => {
1277
+ return request(OpenAPI, {
1278
+ method: "GET",
1279
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signature/{pageId}/pdf",
1280
+ path: {
1281
+ subAccountId: data.subAccountId,
1282
+ negotiationId: data.negotiationId,
1283
+ pageId: data.pageId
1284
+ }
1285
+ });
1286
+ };
1287
+ var getSignedSignaturePagePdf = (data) => {
1288
+ return request(OpenAPI, {
1289
+ method: "GET",
1290
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signature/{sigPageId}/signed/pdf",
1291
+ path: {
1292
+ subAccountId: data.subAccountId,
1293
+ negotiationId: data.negotiationId,
1294
+ sigPageId: data.sigPageId
1295
+ },
1296
+ errors: {
1297
+ 400: "Invalid state",
1298
+ 404: "Missing document"
1299
+ }
1300
+ });
1301
+ };
1302
+ var checkSignedSignaturePagePdf = (data) => {
1303
+ return request(OpenAPI, {
1304
+ method: "GET",
1305
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signature/signed/pdf/exists",
1306
+ path: {
1307
+ subAccountId: data.subAccountId,
1308
+ negotiationId: data.negotiationId
1309
+ },
1310
+ errors: {
1311
+ 400: "Invalid state"
1312
+ }
1313
+ });
1314
+ };
1315
+ var setSignedSignaturePageForParty = (data) => {
1316
+ return request(OpenAPI, {
1317
+ method: "PUT",
1318
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signature/{pageId}/signed/pdf",
1319
+ path: {
1320
+ subAccountId: data.subAccountId,
1321
+ negotiationId: data.negotiationId,
1322
+ pageId: data.pageId
1323
+ },
1324
+ body: data.requestBody,
1325
+ mediaType: "application/pdf"
1326
+ });
1327
+ };
1328
+ var deleteSignedSignaturePageForParty = (data) => {
1329
+ return request(OpenAPI, {
1330
+ method: "DELETE",
1331
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signature/{pageId}/signed/pdf",
1332
+ path: {
1333
+ subAccountId: data.subAccountId,
1334
+ negotiationId: data.negotiationId,
1335
+ pageId: data.pageId
1336
+ }
1337
+ });
1338
+ };
1339
+ var getAuxiliaryDocument = (data) => {
1340
+ return request(OpenAPI, {
1341
+ method: "GET",
1342
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/auxiliary_document",
1343
+ path: {
1344
+ subAccountId: data.subAccountId,
1345
+ negotiationId: data.negotiationId
1346
+ },
1347
+ errors: {
1348
+ 404: "Missing document"
1349
+ }
1350
+ });
1351
+ };
1352
+ var setAuxiliaryDocument = (data) => {
1353
+ return request(OpenAPI, {
1354
+ method: "PUT",
1355
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/auxiliary_document",
1356
+ path: {
1357
+ subAccountId: data.subAccountId,
1358
+ negotiationId: data.negotiationId
1359
+ },
1360
+ body: data.requestBody,
1361
+ mediaType: "application/pdf",
1362
+ errors: {
1363
+ 400: "The negotiation is not at the Review & Sign stage or there is already an auxiliary document uploaded",
1364
+ 404: "The negotiation was not found"
1365
+ }
1366
+ });
1367
+ };
1368
+ var deleteAuxiliaryDocument = (data) => {
1369
+ return request(OpenAPI, {
1370
+ method: "DELETE",
1371
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/auxiliary_document",
1372
+ path: {
1373
+ subAccountId: data.subAccountId,
1374
+ negotiationId: data.negotiationId
1375
+ }
1376
+ });
1377
+ };
1378
+ var checkAuxiliaryDocument = (data) => {
1379
+ return request(OpenAPI, {
1380
+ method: "GET",
1381
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/auxiliary_document/exists",
1382
+ path: {
1383
+ subAccountId: data.subAccountId,
1384
+ negotiationId: data.negotiationId
1385
+ },
1386
+ errors: {
1387
+ 403: "Auxiliary document upload is not enabled for the document type or the negotiation has not yet been agreed"
1388
+ }
1389
+ });
1390
+ };
1391
+ var getOfflineNegotiatedDocument = (data) => {
1392
+ return request(OpenAPI, {
1393
+ method: "GET",
1394
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/offline_negotiated_document",
1395
+ path: {
1396
+ subAccountId: data.subAccountId,
1397
+ negotiationId: data.negotiationId
1398
+ },
1399
+ errors: {
1400
+ 404: "Missing document"
1401
+ }
1402
+ });
1403
+ };
1404
+ var setOfflineNegotiatedDocument = (data) => {
1405
+ return request(OpenAPI, {
1406
+ method: "PUT",
1407
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/offline_negotiated_document",
1408
+ path: {
1409
+ subAccountId: data.subAccountId,
1410
+ negotiationId: data.negotiationId
1411
+ },
1412
+ body: data.requestBody,
1413
+ mediaType: "application/pdf",
1414
+ errors: {
1415
+ 400: "The negotiation is not offline, is not at the Amending stage, or there is already an offline negotiated document uploaded",
1416
+ 404: "The negotiation was not found"
1417
+ }
1418
+ });
1419
+ };
1420
+ var deleteOfflineNegotiatedDocument = (data) => {
1421
+ return request(OpenAPI, {
1422
+ method: "DELETE",
1423
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/offline_negotiated_document",
1424
+ path: {
1425
+ subAccountId: data.subAccountId,
1426
+ negotiationId: data.negotiationId
1427
+ }
1428
+ });
1429
+ };
1430
+ var getAnnotatedOfflineNegotiatedDocument = (data) => {
1431
+ return request(OpenAPI, {
1432
+ method: "GET",
1433
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/offline_negotiated_document/annotated",
1434
+ path: {
1435
+ subAccountId: data.subAccountId,
1436
+ negotiationId: data.negotiationId
1437
+ },
1438
+ errors: {
1439
+ 400: "Extraction has not yet completed",
1440
+ 404: "Missing document"
1441
+ }
1442
+ });
1443
+ };
1444
+ var getOfflineNegotiatedDocumentAnnotations = (data) => {
1445
+ return request(OpenAPI, {
1446
+ method: "GET",
1447
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/offline_negotiated_document/annotations",
1448
+ path: {
1449
+ subAccountId: data.subAccountId,
1450
+ negotiationId: data.negotiationId
1451
+ },
1452
+ errors: {
1453
+ 400: "Extraction has not yet completed",
1454
+ 404: "Missing document"
1455
+ }
1456
+ });
1457
+ };
1458
+ var checkOfflineNegotiatedDocument = (data) => {
1459
+ return request(OpenAPI, {
1460
+ method: "GET",
1461
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/offline_negotiated_document/exists",
1462
+ path: {
1463
+ subAccountId: data.subAccountId,
1464
+ negotiationId: data.negotiationId
1465
+ },
1466
+ errors: {
1467
+ 403: "Extraction is not enabled for the document type or the negotiation is not offline"
1468
+ }
1469
+ });
1470
+ };
1471
+ var listDocuments = (data) => {
1472
+ return request(OpenAPI, {
1473
+ method: "GET",
1474
+ url: "/api/v1/documents",
1475
+ query: {
1476
+ state: data.state,
1477
+ subAccountId: data.subAccountId,
1478
+ documentPublisherId: data.documentPublisherId,
1479
+ documentPackIds: data.documentPackIds,
1480
+ templateContains: data.templateContains,
1481
+ supportsBulkUpload: data.supportsBulkUpload,
1482
+ hasNegotiations: data.hasNegotiations,
1483
+ year: data.year,
1484
+ abbreviation: data.abbreviation,
1485
+ law: data.law,
1486
+ publisherName: data.publisherName,
1487
+ query: data.query,
1488
+ orderBy: data.orderBy,
1489
+ onlyWithSchema: data.onlyWithSchema,
1490
+ includeTransitive: data.includeTransitive
1491
+ }
1492
+ });
1493
+ };
1494
+ var listDocumentsWithPagination = (data) => {
1495
+ return request(OpenAPI, {
1496
+ method: "GET",
1497
+ url: "/api/v1/documentsWithPaging",
1498
+ query: {
1499
+ pageIndex: data.pageIndex,
1500
+ pageSize: data.pageSize,
1501
+ state: data.state,
1502
+ subAccountId: data.subAccountId,
1503
+ documentPublisherId: data.documentPublisherId,
1504
+ documentPackIds: data.documentPackIds,
1505
+ templateContains: data.templateContains,
1506
+ supportsBulkUpload: data.supportsBulkUpload,
1507
+ hasNegotiations: data.hasNegotiations,
1508
+ year: data.year,
1509
+ abbreviation: data.abbreviation,
1510
+ law: data.law,
1511
+ publisherName: data.publisherName,
1512
+ query: data.query,
1513
+ orderBy: data.orderBy,
1514
+ onlyWithSchema: data.onlyWithSchema,
1515
+ includeTransitive: data.includeTransitive
1516
+ }
1517
+ });
1518
+ };
1519
+ var listDocumentsVersionsSummary = (data) => {
1520
+ return request(OpenAPI, {
1521
+ method: "GET",
1522
+ url: "/api/v1/documents/versions",
1523
+ query: {
1524
+ state: data.state,
1525
+ subAccountId: data.subAccountId,
1526
+ documentPublisherId: data.documentPublisherId,
1527
+ templateContains: data.templateContains,
1528
+ supportsBulkUpload: data.supportsBulkUpload,
1529
+ hasNegotiations: data.hasNegotiations,
1530
+ year: data.year,
1531
+ abbreviation: data.abbreviation,
1532
+ law: data.law,
1533
+ publisherName: data.publisherName,
1534
+ documentPackIds: data.documentPackIds,
1535
+ query: data.query,
1536
+ orderBy: data.orderBy
1537
+ }
1538
+ });
1539
+ };
1540
+ var getDocument = (data) => {
1541
+ return request(OpenAPI, {
1542
+ method: "GET",
1543
+ url: "/api/v1/documents/{documentId}",
1544
+ path: {
1545
+ documentId: data.documentId
1546
+ },
1547
+ errors: {
1548
+ 404: "Schema not found"
1549
+ }
1550
+ });
1551
+ };
1552
+ var getDocumentSchema = (data) => {
1553
+ return request(OpenAPI, {
1554
+ method: "GET",
1555
+ url: "/api/v1/documents/{documentId}/schemas/{version}",
1556
+ path: {
1557
+ documentId: data.documentId,
1558
+ version: data.version
1559
+ },
1560
+ query: {
1561
+ restrictedTo: data.restrictedTo
1562
+ },
1563
+ errors: {
1564
+ 404: "Schema not found"
1565
+ }
1566
+ });
1567
+ };
1568
+ var schemaAvailableAsCdm = (data) => {
1569
+ return request(OpenAPI, {
1570
+ method: "GET",
1571
+ url: "/api/v1/documents/{documentId}/schemas/{version}/availableAsCDM",
1572
+ path: {
1573
+ documentId: data.documentId,
1574
+ version: data.version
1575
+ },
1576
+ errors: {
1577
+ 404: "Document or schema version not found"
1578
+ }
1579
+ });
1580
+ };
1581
+ var documentRenderTemplate = (data) => {
1582
+ return request(OpenAPI, {
1583
+ method: "GET",
1584
+ url: "/api/v1/documents/{documentId}/schemas/{version}/preview",
1585
+ path: {
1586
+ documentId: data.documentId,
1587
+ version: data.version
1588
+ },
1589
+ errors: {
1590
+ 404: "Document or schema version not found"
1591
+ }
1592
+ });
1593
+ };
1594
+ var getAmendDefaults = (data) => {
1595
+ return request(OpenAPI, {
1596
+ method: "GET",
1597
+ url: "/api/v1/documents/{documentId}/schemas/{version}/amendDefaults",
1598
+ path: {
1599
+ documentId: data.documentId,
1600
+ version: data.version
1601
+ },
1602
+ errors: {
1603
+ 404: "Document or schema version not found"
1604
+ }
1605
+ });
1606
+ };
1607
+ var getLatestDocumentSchema = (data) => {
1608
+ return request(OpenAPI, {
1609
+ method: "GET",
1610
+ url: "/api/v1/documents/{documentId}/latest_schema",
1611
+ path: {
1612
+ documentId: data.documentId
1613
+ },
1614
+ errors: {
1615
+ 404: "Document or schema not found"
1616
+ }
1617
+ });
1618
+ };
1619
+ var forkNegotiation = (data) => {
1620
+ return request(OpenAPI, {
1621
+ method: "POST",
1622
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/restate",
1623
+ path: {
1624
+ subAccountId: data.subAccountId,
1625
+ negotiationId: data.negotiationId
1626
+ },
1627
+ errors: {
1628
+ 400: "The negotiation specified cannot be restated.",
1629
+ 404: "Negotiation or sub account not found"
1630
+ }
1631
+ });
1632
+ };
1633
+ var negotiationForkHistory = (data) => {
1634
+ return request(OpenAPI, {
1635
+ method: "GET",
1636
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/restatementHistory",
1637
+ path: {
1638
+ subAccountId: data.subAccountId,
1639
+ negotiationId: data.negotiationId
1640
+ },
1641
+ errors: {
1642
+ 400: "A negotiation in the history is missing",
1643
+ 404: "Negotiation or sub account not found"
1644
+ }
1645
+ });
1646
+ };
1647
+ var getOriginalAnswersForForkNegotiation = (data) => {
1648
+ return request(OpenAPI, {
1649
+ method: "GET",
1650
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{forkedNegotiationId}/originalAnswers",
1651
+ path: {
1652
+ subAccountId: data.subAccountId,
1653
+ forkedNegotiationId: data.forkedNegotiationId
1654
+ },
1655
+ errors: {
1656
+ 404: "Negotiation or sub account not found"
1657
+ }
1658
+ });
1659
+ };
1660
+ var notifyOfDraft = (data) => {
1661
+ return request(OpenAPI, {
1662
+ method: "POST",
1663
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/notifyOfDraft",
1664
+ path: {
1665
+ subAccountId: data.subAccountId,
1666
+ negotiationId: data.negotiationId
1667
+ },
1668
+ errors: {
1669
+ 404: "Negotiation not found"
1670
+ }
1671
+ });
1672
+ };
1673
+ var updateCustomFields = (data) => {
1674
+ return request(OpenAPI, {
1675
+ method: "PUT",
1676
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/customFields",
1677
+ path: {
1678
+ subAccountId: data.subAccountId,
1679
+ negotiationId: data.negotiationId
1680
+ },
1681
+ body: data.requestBody,
1682
+ mediaType: "application/json",
1683
+ errors: {
1684
+ 404: "Negotiation not found"
1685
+ }
1686
+ });
1687
+ };
1688
+ var markAsFinal = (data) => {
1689
+ return request(OpenAPI, {
1690
+ method: "PUT",
1691
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/markAsFinal",
1692
+ path: {
1693
+ subAccountId: data.subAccountId,
1694
+ negotiationId: data.negotiationId
1695
+ },
1696
+ errors: {
1697
+ 404: "Negotiation not found"
1698
+ }
1699
+ });
1700
+ };
1701
+ var editAnswers = (data) => {
1702
+ return request(OpenAPI, {
1703
+ method: "PUT",
1704
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers",
1705
+ path: {
1706
+ subAccountId: data.subAccountId,
1707
+ negotiationId: data.negotiationId
1708
+ },
1709
+ body: data.requestBody,
1710
+ mediaType: "application/json",
1711
+ errors: {
1712
+ 404: "Negotiation or election not found"
1713
+ }
1714
+ });
1715
+ };
1716
+ var editDefaultAnswers = (data) => {
1717
+ return request(OpenAPI, {
1718
+ method: "PUT",
1719
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/defaults",
1720
+ path: {
1721
+ subAccountId: data.subAccountId,
1722
+ negotiationId: data.negotiationId
1723
+ },
1724
+ body: data.requestBody,
1725
+ mediaType: "application/json",
1726
+ errors: {
1727
+ 400: "Initial answers have already been set",
1728
+ 404: "Negotiation or election not found"
1729
+ }
1730
+ });
1731
+ };
1732
+ var acceptAllCounterpartyPositions = (data) => {
1733
+ return request(OpenAPI, {
1734
+ method: "PUT",
1735
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/acceptCpPosition/{partyId}",
1736
+ path: {
1737
+ subAccountId: data.subAccountId,
1738
+ negotiationId: data.negotiationId,
1739
+ partyId: data.partyId
1740
+ },
1741
+ query: {
1742
+ excludeNestedAnswers: data.excludeNestedAnswers
1743
+ },
1744
+ errors: {
1745
+ 400: "The counterparty's position is not available",
1746
+ 404: "Negotiation not found"
1747
+ }
1748
+ });
1749
+ };
1750
+ var acceptAllPresetPositions = (data) => {
1751
+ return request(OpenAPI, {
1752
+ method: "PUT",
1753
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/acceptPresetPosition",
1754
+ path: {
1755
+ subAccountId: data.subAccountId,
1756
+ negotiationId: data.negotiationId
1757
+ },
1758
+ errors: {
1759
+ 400: "The preset's position is not available",
1760
+ 404: "Negotiation not found"
1761
+ }
1762
+ });
1763
+ };
1764
+ var acceptAllCustodianTemplatePositions = (data) => {
1765
+ return request(OpenAPI, {
1766
+ method: "PUT",
1767
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/acceptCustodianTemplatePosition",
1768
+ path: {
1769
+ subAccountId: data.subAccountId,
1770
+ negotiationId: data.negotiationId
1771
+ },
1772
+ errors: {
1773
+ 400: "The custodian template position is not available",
1774
+ 404: "Negotiation not found"
1775
+ }
1776
+ });
1777
+ };
1778
+ var acceptAllPositionsFromPreviousVersion = (data) => {
1779
+ return request(OpenAPI, {
1780
+ method: "PUT",
1781
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/acceptPreviousPosition/{version}",
1782
+ path: {
1783
+ subAccountId: data.subAccountId,
1784
+ negotiationId: data.negotiationId,
1785
+ version: data.version
1786
+ },
1787
+ errors: {
1788
+ 400: "The previous version is not available",
1789
+ 404: "Negotiation not found"
1790
+ }
1791
+ });
1792
+ };
1793
+ var acceptAllPositionsFromFork = (data) => {
1794
+ return request(OpenAPI, {
1795
+ method: "PUT",
1796
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/acceptOriginalPosition/{forkedNegotiationId}",
1797
+ path: {
1798
+ subAccountId: data.subAccountId,
1799
+ negotiationId: data.negotiationId,
1800
+ forkedNegotiationId: data.forkedNegotiationId
1801
+ },
1802
+ errors: {
1803
+ 400: "The original fork position is not available for the specified version",
1804
+ 404: "Negotiation not found"
1805
+ }
1806
+ });
1807
+ };
1808
+ var getElectionAnswer = (data) => {
1809
+ return request(OpenAPI, {
1810
+ method: "GET",
1811
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/elections/{electionId}",
1812
+ path: {
1813
+ subAccountId: data.subAccountId,
1814
+ negotiationId: data.negotiationId,
1815
+ electionId: data.electionId
1816
+ },
1817
+ query: {
1818
+ type: data.type
1819
+ },
1820
+ errors: {
1821
+ 404: "Negotiation not found"
1822
+ }
1823
+ });
1824
+ };
1825
+ var getMajorVersions = (data) => {
1826
+ return request(OpenAPI, {
1827
+ method: "GET",
1828
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/parties/{partyId}/versions",
1829
+ path: {
1830
+ subAccountId: data.subAccountId,
1831
+ negotiationId: data.negotiationId,
1832
+ partyId: data.partyId
1833
+ },
1834
+ errors: {
1835
+ 404: "Negotiation not found"
1836
+ }
1837
+ });
1838
+ };
1839
+ var getAllVersions = (data) => {
1840
+ return request(OpenAPI, {
1841
+ method: "GET",
1842
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/parties/{partyId}/versions/all",
1843
+ path: {
1844
+ subAccountId: data.subAccountId,
1845
+ negotiationId: data.negotiationId,
1846
+ partyId: data.partyId
1847
+ },
1848
+ errors: {
1849
+ 404: "Negotiation not found"
1850
+ }
1851
+ });
1852
+ };
1853
+ var getOtherPartyAnswers = (data) => {
1854
+ return request(OpenAPI, {
1855
+ method: "GET",
1856
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/parties/{counterpartyId}/versions/{version}",
1857
+ path: {
1858
+ subAccountId: data.subAccountId,
1859
+ negotiationId: data.negotiationId,
1860
+ counterpartyId: data.counterpartyId,
1861
+ version: data.version
1862
+ },
1863
+ errors: {
1864
+ 404: "Party answers not found of the party id for the specified version or negotiation not found"
1865
+ }
1866
+ });
1867
+ };
1868
+ var getPartyAnswers = (data) => {
1869
+ return request(OpenAPI, {
1870
+ method: "GET",
1871
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/versions/{version}",
1872
+ path: {
1873
+ subAccountId: data.subAccountId,
1874
+ negotiationId: data.negotiationId,
1875
+ version: data.version
1876
+ },
1877
+ errors: {
1878
+ 404: "Party answers not found for the specified version or negotiation not found"
1879
+ }
1880
+ });
1881
+ };
1882
+ var acceptCounterpartyPosition = (data) => {
1883
+ return request(OpenAPI, {
1884
+ method: "PUT",
1885
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/elections/{electionId}/acceptCpPosition/{partyId}",
1886
+ path: {
1887
+ subAccountId: data.subAccountId,
1888
+ negotiationId: data.negotiationId,
1889
+ electionId: data.electionId,
1890
+ partyId: data.partyId
1891
+ },
1892
+ query: {
1893
+ excludeNestedAnswers: data.excludeNestedAnswers
1894
+ },
1895
+ errors: {
1896
+ 404: "Negotiation not found"
1897
+ }
1898
+ });
1899
+ };
1900
+ var getMultipleNestedAnswers = (data) => {
1901
+ return request(OpenAPI, {
1902
+ method: "POST",
1903
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/nested/bulk",
1904
+ path: {
1905
+ subAccountId: data.subAccountId,
1906
+ negotiationId: data.negotiationId
1907
+ },
1908
+ body: data.requestBody,
1909
+ mediaType: "application/json",
1910
+ errors: {
1911
+ 400: "Too many nested answers IDs passed",
1912
+ 404: "Negotiation not found"
1913
+ }
1914
+ });
1915
+ };
1916
+ var setMultipleNestedAnswers = (data) => {
1917
+ return request(OpenAPI, {
1918
+ method: "PUT",
1919
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/nested/bulk",
1920
+ path: {
1921
+ subAccountId: data.subAccountId,
1922
+ negotiationId: data.negotiationId
1923
+ },
1924
+ body: data.requestBody,
1925
+ mediaType: "application/json",
1926
+ errors: {
1927
+ 400: "Too many nested answers IDs passed",
1928
+ 404: "Negotiation not found"
1929
+ }
1930
+ });
1931
+ };
1932
+ var getNestedAnswers = (data) => {
1933
+ return request(OpenAPI, {
1934
+ method: "GET",
1935
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/nested/{nestedAnswersId}",
1936
+ path: {
1937
+ subAccountId: data.subAccountId,
1938
+ negotiationId: data.negotiationId,
1939
+ nestedAnswersId: data.nestedAnswersId
1940
+ },
1941
+ errors: {
1942
+ 404: "Negotiation not found"
1943
+ }
1944
+ });
1945
+ };
1946
+ var setNestedAnswers = (data) => {
1947
+ return request(OpenAPI, {
1948
+ method: "PUT",
1949
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/nested/{nestedAnswersId}",
1950
+ path: {
1951
+ subAccountId: data.subAccountId,
1952
+ negotiationId: data.negotiationId,
1953
+ nestedAnswersId: data.nestedAnswersId
1954
+ },
1955
+ body: data.requestBody,
1956
+ mediaType: "application/json",
1957
+ errors: {
1958
+ 404: "Negotiation not found"
1959
+ }
1960
+ });
1961
+ };
1962
+ var getPreviousMajorVersionsNestedAnswerElections = (data) => {
1963
+ return request(OpenAPI, {
1964
+ method: "GET",
1965
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/nested/{nestedAnswersId}/previousElections",
1966
+ path: {
1967
+ subAccountId: data.subAccountId,
1968
+ negotiationId: data.negotiationId,
1969
+ nestedAnswersId: data.nestedAnswersId
1970
+ },
1971
+ errors: {
1972
+ 403: "Negotiation not in amending state",
1973
+ 404: "No previous versions found"
1974
+ }
1975
+ });
1976
+ };
1977
+ var getPreviousMajorVersionsNestedAnswerIds = (data) => {
1978
+ return request(OpenAPI, {
1979
+ method: "GET",
1980
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/elections/{electionId}/previousAnswers",
1981
+ path: {
1982
+ subAccountId: data.subAccountId,
1983
+ negotiationId: data.negotiationId,
1984
+ electionId: data.electionId
1985
+ },
1986
+ errors: {
1987
+ 403: "Negotiation not in amending state",
1988
+ 404: "No previous versions found"
1989
+ }
1990
+ });
1991
+ };
1992
+ var acceptNestedAnswersCounterpartyPosition = (data) => {
1993
+ return request(OpenAPI, {
1994
+ method: "PUT",
1995
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/answers/nested/{nestedAnswersId}/acceptCpPosition/{partyId}",
1996
+ path: {
1997
+ subAccountId: data.subAccountId,
1998
+ negotiationId: data.negotiationId,
1999
+ nestedAnswersId: data.nestedAnswersId,
2000
+ partyId: data.partyId
2001
+ },
2002
+ errors: {
2003
+ 404: "Negotiation, nested answers ID or party not found"
2004
+ }
2005
+ });
2006
+ };
2007
+ var initialAnswers = (data) => {
2008
+ return request(OpenAPI, {
2009
+ method: "GET",
2010
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/initialAnswers",
2011
+ path: {
2012
+ subAccountId: data.subAccountId,
2013
+ negotiationId: data.negotiationId
2014
+ },
2015
+ errors: {
2016
+ 404: "Negotiation or election not found"
2017
+ }
2018
+ });
2019
+ };
2020
+ var assignToMe = (data) => {
2021
+ return request(OpenAPI, {
2022
+ method: "PUT",
2023
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/owner/myself",
2024
+ path: {
2025
+ subAccountId: data.subAccountId,
2026
+ negotiationId: data.negotiationId
2027
+ },
2028
+ errors: {
2029
+ 404: "Negotiation not found"
2030
+ }
2031
+ });
2032
+ };
2033
+ var assignUser = (data) => {
2034
+ return request(OpenAPI, {
2035
+ method: "PUT",
2036
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/owner/{userId}",
2037
+ path: {
2038
+ subAccountId: data.subAccountId,
2039
+ negotiationId: data.negotiationId,
2040
+ userId: data.userId
2041
+ },
2042
+ errors: {
2043
+ 400: "Invalid user",
2044
+ 404: "Negotiation or user not found"
2045
+ }
2046
+ });
2047
+ };
2048
+ var getPreviousActiveUsers = (data) => {
2049
+ return request(OpenAPI, {
2050
+ method: "GET",
2051
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/previousActiveUsers",
2052
+ path: {
2053
+ subAccountId: data.subAccountId,
2054
+ negotiationId: data.negotiationId
2055
+ },
2056
+ errors: {
2057
+ 400: "Invalid user",
2058
+ 404: "Negotiation not found"
2059
+ }
2060
+ });
2061
+ };
2062
+ var setCounterparties = (data) => {
2063
+ return request(OpenAPI, {
2064
+ method: "PUT",
2065
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/counterparties",
2066
+ path: {
2067
+ subAccountId: data.subAccountId,
2068
+ negotiationId: data.negotiationId
2069
+ },
2070
+ query: {
2071
+ strictLEI: data.strictLei
2072
+ },
2073
+ body: data.requestBody,
2074
+ mediaType: "application/json",
2075
+ errors: {
2076
+ 400: "Invalid or incomplete answers",
2077
+ 404: "Negotiation not found",
2078
+ 409: "Could not save new version"
2079
+ }
2080
+ });
2081
+ };
2082
+ var getExternalAttachment = (data) => {
2083
+ return request(OpenAPI, {
2084
+ method: "GET",
2085
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/attachment/{fileName}",
2086
+ path: {
2087
+ subAccountId: data.subAccountId,
2088
+ negotiationId: data.negotiationId,
2089
+ fileName: data.fileName
2090
+ },
2091
+ errors: {
2092
+ 404: "Missing document"
2093
+ }
2094
+ });
2095
+ };
2096
+ var deleteExternalAttachment = (data) => {
2097
+ return request(OpenAPI, {
2098
+ method: "DELETE",
2099
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/attachment/{fileName}",
2100
+ path: {
2101
+ subAccountId: data.subAccountId,
2102
+ negotiationId: data.negotiationId,
2103
+ fileName: data.fileName
2104
+ }
2105
+ });
2106
+ };
2107
+ var listExternalAttachments = (data) => {
2108
+ return request(OpenAPI, {
2109
+ method: "GET",
2110
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/attachment",
2111
+ path: {
2112
+ subAccountId: data.subAccountId,
2113
+ negotiationId: data.negotiationId
2114
+ },
2115
+ errors: {
2116
+ 403: "Invite attachment upload is not enabled for the document type"
2117
+ }
2118
+ });
2119
+ };
2120
+ var setExternalAttachment = (data) => {
2121
+ return request(OpenAPI, {
2122
+ method: "PUT",
2123
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/attachment",
2124
+ path: {
2125
+ subAccountId: data.subAccountId,
2126
+ negotiationId: data.negotiationId
2127
+ },
2128
+ body: data.requestBody,
2129
+ mediaType: "application/octet-stream",
2130
+ errors: {
2131
+ 400: "The file is too large or would exceed the maximum total size for all files, or the negotiation is not currently in draft",
2132
+ 404: "The negotiation was not found"
2133
+ }
2134
+ });
2135
+ };
2136
+ var setExternalAttachments = (data) => {
2137
+ return request(OpenAPI, {
2138
+ method: "POST",
2139
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/attachment",
2140
+ path: {
2141
+ subAccountId: data.subAccountId,
2142
+ negotiationId: data.negotiationId
2143
+ },
2144
+ formData: data.formData,
2145
+ mediaType: "multipart/form-data",
2146
+ errors: {
2147
+ 400: "The file(s) are too large or would exceed the maximum total size for all files, or the negotiation is not currently in draft",
2148
+ 404: "The negotiation was not found"
2149
+ }
2150
+ });
2151
+ };
2152
+ var getExecutionAttachment = (data) => {
2153
+ return request(OpenAPI, {
2154
+ method: "GET",
2155
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executionAttachment/{fileName}",
2156
+ path: {
2157
+ subAccountId: data.subAccountId,
2158
+ negotiationId: data.negotiationId,
2159
+ fileName: data.fileName
2160
+ },
2161
+ errors: {
2162
+ 404: "Missing document"
2163
+ }
2164
+ });
2165
+ };
2166
+ var deleteExecutionAttachment = (data) => {
2167
+ return request(OpenAPI, {
2168
+ method: "DELETE",
2169
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executionAttachment/{fileName}",
2170
+ path: {
2171
+ subAccountId: data.subAccountId,
2172
+ negotiationId: data.negotiationId,
2173
+ fileName: data.fileName
2174
+ }
2175
+ });
2176
+ };
2177
+ var listExecutionAttachments = (data) => {
2178
+ return request(OpenAPI, {
2179
+ method: "GET",
2180
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executionAttachment",
2181
+ path: {
2182
+ subAccountId: data.subAccountId,
2183
+ negotiationId: data.negotiationId
2184
+ },
2185
+ errors: {
2186
+ 403: "Execution attachment upload is not enabled for the document type"
2187
+ }
2188
+ });
2189
+ };
2190
+ var setExecutionAttachment = (data) => {
2191
+ return request(OpenAPI, {
2192
+ method: "PUT",
2193
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executionAttachment",
2194
+ path: {
2195
+ subAccountId: data.subAccountId,
2196
+ negotiationId: data.negotiationId
2197
+ },
2198
+ body: data.requestBody,
2199
+ mediaType: "application/pdf",
2200
+ errors: {
2201
+ 400: "The file is too large or would exceed the maximum total size for all execution files, or the negotiation is not currently in ExecutionAgreed",
2202
+ 404: "The negotiation was not found"
2203
+ }
2204
+ });
2205
+ };
2206
+ var setExecutionAttachments = (data) => {
2207
+ return request(OpenAPI, {
2208
+ method: "POST",
2209
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executionAttachment",
2210
+ path: {
2211
+ subAccountId: data.subAccountId,
2212
+ negotiationId: data.negotiationId
2213
+ },
2214
+ formData: data.formData,
2215
+ mediaType: "multipart/form-data",
2216
+ errors: {
2217
+ 400: "The file(s) are too large or would exceed the maximum total size for all execution files, or the negotiation is not currently in ExecutionAgreed.",
2218
+ 404: "The negotiation was not found"
2219
+ }
2220
+ });
2221
+ };
2222
+ var renameExecutionAttachment = (data) => {
2223
+ return request(OpenAPI, {
2224
+ method: "PATCH",
2225
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/executionAttachment/{oldFileName}",
2226
+ path: {
2227
+ subAccountId: data.subAccountId,
2228
+ negotiationId: data.negotiationId,
2229
+ oldFileName: data.oldFileName
2230
+ },
2231
+ errors: {
2232
+ 400: "New filename is invalid",
2233
+ 404: "Old filename not found"
2234
+ }
2235
+ });
2236
+ };
2237
+ var setOwnerEntity = (data) => {
2238
+ return request(OpenAPI, {
2239
+ method: "PUT",
2240
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/owner",
2241
+ path: {
2242
+ subAccountId: data.subAccountId,
2243
+ negotiationId: data.negotiationId
2244
+ },
2245
+ body: data.requestBody,
2246
+ mediaType: "application/json",
2247
+ errors: {
2248
+ 400: "Invalid or incomplete answers",
2249
+ 404: "Negotiation not found",
2250
+ 409: "Could not save new version",
2251
+ 422: "Counterparty email address required"
2252
+ }
2253
+ });
2254
+ };
2255
+ var setReceiverEntity = (data) => {
2256
+ return request(OpenAPI, {
2257
+ method: "PUT",
2258
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/entities",
2259
+ path: {
2260
+ subAccountId: data.subAccountId,
2261
+ negotiationId: data.negotiationId
2262
+ },
2263
+ body: data.requestBody,
2264
+ mediaType: "application/json",
2265
+ errors: {
2266
+ 404: "Negotiation not found",
2267
+ 409: "Could not save new version"
2268
+ }
2269
+ });
2270
+ };
2271
+ var setPreset = (data) => {
2272
+ return request(OpenAPI, {
2273
+ method: "PUT",
2274
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/preset",
2275
+ path: {
2276
+ subAccountId: data.subAccountId,
2277
+ negotiationId: data.negotiationId
2278
+ },
2279
+ body: data.requestBody,
2280
+ mediaType: "application/json",
2281
+ errors: {
2282
+ 404: "Negotiation or preset not found"
2283
+ }
2284
+ });
2285
+ };
2286
+ var swapParties = (data) => {
2287
+ return request(OpenAPI, {
2288
+ method: "PUT",
2289
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/swapParties",
2290
+ path: {
2291
+ subAccountId: data.subAccountId,
2292
+ negotiationId: data.negotiationId
2293
+ },
2294
+ errors: {
2295
+ 403: "Forbidden action in this state",
2296
+ 404: "Negotiation not found"
2297
+ }
2298
+ });
2299
+ };
2300
+ var approveFinalDocument = (data) => {
2301
+ return request(OpenAPI, {
2302
+ method: "PUT",
2303
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/document/approve",
2304
+ path: {
2305
+ subAccountId: data.subAccountId,
2306
+ negotiationId: data.negotiationId
2307
+ },
2308
+ body: data.requestBody,
2309
+ mediaType: "application/json",
2310
+ errors: {
2311
+ 403: "action not permitted (negotiation is in wrong state)",
2312
+ 404: "Negotiation not found",
2313
+ 409: "Could not save new version"
2314
+ }
2315
+ });
2316
+ };
2317
+ var overrideApproveFinalDocument = (data) => {
2318
+ return request(OpenAPI, {
2319
+ method: "PUT",
2320
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/document/approve/override",
2321
+ path: {
2322
+ subAccountId: data.subAccountId,
2323
+ negotiationId: data.negotiationId
2324
+ },
2325
+ body: data.requestBody,
2326
+ mediaType: "application/json",
2327
+ errors: {
2328
+ 403: "action not permitted (negotiation is in wrong state)",
2329
+ 404: "Negotiation not found",
2330
+ 409: "Could not save new version"
2331
+ }
2332
+ });
2333
+ };
2334
+ var rejectFinalDocument = (data) => {
2335
+ return request(OpenAPI, {
2336
+ method: "PUT",
2337
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/document/reject",
2338
+ path: {
2339
+ subAccountId: data.subAccountId,
2340
+ negotiationId: data.negotiationId
2341
+ },
2342
+ body: data.requestBody,
2343
+ mediaType: "application/json",
2344
+ errors: {
2345
+ 403: "action not permitted (negotiation is in wrong state)",
2346
+ 404: "Negotiation not found",
2347
+ 409: "Could not save new version"
2348
+ }
2349
+ });
2350
+ };
2351
+ var overrideRejectFinalDocument = (data) => {
2352
+ return request(OpenAPI, {
2353
+ method: "PUT",
2354
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/document/reject/override",
2355
+ path: {
2356
+ subAccountId: data.subAccountId,
2357
+ negotiationId: data.negotiationId
2358
+ },
2359
+ body: data.requestBody,
2360
+ mediaType: "application/json",
2361
+ errors: {
2362
+ 403: "action not permitted (negotiation is in wrong state)",
2363
+ 404: "Negotiation not found",
2364
+ 409: "Could not save new version"
2365
+ }
2366
+ });
2367
+ };
2368
+ var sendToCounterparty = (data) => {
2369
+ return request(OpenAPI, {
2370
+ method: "PUT",
2371
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/sendToCounterparty",
2372
+ path: {
2373
+ subAccountId: data.subAccountId,
2374
+ negotiationId: data.negotiationId
2375
+ },
2376
+ body: data.requestBody,
2377
+ mediaType: "application/json",
2378
+ errors: {
2379
+ 403: "No counterparty is configured",
2380
+ 404: "Negotiation not found",
2381
+ 409: "Could not save new version"
2382
+ }
2383
+ });
2384
+ };
2385
+ var setGeneralCoverNote = (data) => {
2386
+ return request(OpenAPI, {
2387
+ method: "PUT",
2388
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/coverNote",
2389
+ path: {
2390
+ subAccountId: data.subAccountId,
2391
+ negotiationId: data.negotiationId
2392
+ },
2393
+ body: data.requestBody,
2394
+ mediaType: "application/json",
2395
+ errors: {
2396
+ 404: "Negotiation not found",
2397
+ 409: "Could not save new version"
2398
+ }
2399
+ });
2400
+ };
2401
+ var deleteGeneralCoverNote = (data) => {
2402
+ return request(OpenAPI, {
2403
+ method: "DELETE",
2404
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/coverNote",
2405
+ path: {
2406
+ subAccountId: data.subAccountId,
2407
+ negotiationId: data.negotiationId
2408
+ },
2409
+ errors: {
2410
+ 404: "Negotiation not found",
2411
+ 409: "Could not save new version"
2412
+ }
2413
+ });
2414
+ };
2415
+ var negotiationSendForApproval = (data) => {
2416
+ return request(OpenAPI, {
2417
+ method: "PUT",
2418
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/sendForApproval",
2419
+ path: {
2420
+ subAccountId: data.subAccountId,
2421
+ negotiationId: data.negotiationId
2422
+ },
2423
+ body: data.requestBody,
2424
+ mediaType: "application/json",
2425
+ errors: {
2426
+ 403: "Action not permitted (negotiation is in wrong state)",
2427
+ 404: "Negotiation not found",
2428
+ 409: "Could not save new version"
2429
+ }
2430
+ });
2431
+ };
2432
+ var changeSigningMode = (data) => {
2433
+ return request(OpenAPI, {
2434
+ method: "PUT",
2435
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signingMode",
2436
+ path: {
2437
+ subAccountId: data.subAccountId,
2438
+ negotiationId: data.negotiationId
2439
+ },
2440
+ body: data.requestBody,
2441
+ mediaType: "application/json",
2442
+ errors: {
2443
+ 403: "Action not permitted (negotiation is in wrong state)",
2444
+ 404: "Negotiation not found"
2445
+ }
2446
+ });
2447
+ };
2448
+ var setElectionApproval = (data) => {
2449
+ return request(OpenAPI, {
2450
+ method: "PUT",
2451
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/elections/{electionId}",
2452
+ path: {
2453
+ subAccountId: data.subAccountId,
2454
+ negotiationId: data.negotiationId,
2455
+ electionId: data.electionId
2456
+ },
2457
+ body: data.requestBody,
2458
+ mediaType: "application/json",
2459
+ errors: {
2460
+ 404: "Preset not found"
2461
+ }
2462
+ });
2463
+ };
2464
+ var sendDocumentApprovalReminder = (data) => {
2465
+ return request(OpenAPI, {
2466
+ method: "PUT",
2467
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/document/reminder",
2468
+ path: {
2469
+ subAccountId: data.subAccountId,
2470
+ negotiationId: data.negotiationId
2471
+ },
2472
+ errors: {
2473
+ 400: "There is no pending approval or approval sent date",
2474
+ 404: "Negotiation or sub-account not found"
2475
+ }
2476
+ });
2477
+ };
2478
+ var sendElectionApprovalReminder = (data) => {
2479
+ return request(OpenAPI, {
2480
+ method: "PUT",
2481
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/elections/{electionId}/reminder",
2482
+ path: {
2483
+ subAccountId: data.subAccountId,
2484
+ negotiationId: data.negotiationId,
2485
+ electionId: data.electionId
2486
+ },
2487
+ errors: {
2488
+ 400: "There is no pending approval",
2489
+ 404: "Negotiation, sub-account or election id not found"
2490
+ }
2491
+ });
2492
+ };
2493
+ var addElectionApproval = (data) => {
2494
+ return request(OpenAPI, {
2495
+ method: "PUT",
2496
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/elections/{electionId}/approve",
2497
+ path: {
2498
+ subAccountId: data.subAccountId,
2499
+ negotiationId: data.negotiationId,
2500
+ electionId: data.electionId
2501
+ },
2502
+ body: data.requestBody,
2503
+ mediaType: "application/json",
2504
+ errors: {
2505
+ 403: "Action not permitted (negotiation is in the wrong state or you do not have permission)",
2506
+ 404: "Negotiation not found",
2507
+ 409: "Could not save new version"
2508
+ }
2509
+ });
2510
+ };
2511
+ var addElectionRejection = (data) => {
2512
+ return request(OpenAPI, {
2513
+ method: "PUT",
2514
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/elections/{electionId}/reject",
2515
+ path: {
2516
+ subAccountId: data.subAccountId,
2517
+ negotiationId: data.negotiationId,
2518
+ electionId: data.electionId
2519
+ },
2520
+ body: data.requestBody,
2521
+ mediaType: "application/json",
2522
+ errors: {
2523
+ 403: "Action not permitted (negotiation is in the wrong state or you do not have permission)",
2524
+ 404: "Negotiation not found",
2525
+ 409: "Could not save new version"
2526
+ }
2527
+ });
2528
+ };
2529
+ var overrideElectionApproval = (data) => {
2530
+ return request(OpenAPI, {
2531
+ method: "PUT",
2532
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/elections/{electionId}/approve/override",
2533
+ path: {
2534
+ subAccountId: data.subAccountId,
2535
+ negotiationId: data.negotiationId,
2536
+ electionId: data.electionId
2537
+ },
2538
+ body: data.requestBody,
2539
+ mediaType: "application/json",
2540
+ errors: {
2541
+ 403: "Action not permitted (negotiation is in the wrong state or you do not have permission)",
2542
+ 404: "Negotiation not found",
2543
+ 409: "Could not save new version"
2544
+ }
2545
+ });
2546
+ };
2547
+ var overrideElectionRejection = (data) => {
2548
+ return request(OpenAPI, {
2549
+ method: "PUT",
2550
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/elections/{electionId}/reject/override",
2551
+ path: {
2552
+ subAccountId: data.subAccountId,
2553
+ negotiationId: data.negotiationId,
2554
+ electionId: data.electionId
2555
+ },
2556
+ body: data.requestBody,
2557
+ mediaType: "application/json",
2558
+ errors: {
2559
+ 403: "Action not permitted (negotiation is in the wrong state or you do not have permission)",
2560
+ 404: "Negotiation not found",
2561
+ 409: "Could not save new version"
2562
+ }
2563
+ });
2564
+ };
2565
+ var getApprovalHistory = (data) => {
2566
+ return request(OpenAPI, {
2567
+ method: "GET",
2568
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/history",
2569
+ path: {
2570
+ subAccountId: data.subAccountId,
2571
+ negotiationId: data.negotiationId
2572
+ }
2573
+ });
2574
+ };
2575
+ var getApprovalRound = (data) => {
2576
+ return request(OpenAPI, {
2577
+ method: "GET",
2578
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/{roundId}",
2579
+ path: {
2580
+ subAccountId: data.subAccountId,
2581
+ negotiationId: data.negotiationId,
2582
+ roundId: data.roundId
2583
+ }
2584
+ });
2585
+ };
2586
+ var addApprovalComment = (data) => {
2587
+ return request(OpenAPI, {
2588
+ method: "POST",
2589
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/comment",
2590
+ path: {
2591
+ subAccountId: data.subAccountId,
2592
+ negotiationId: data.negotiationId
2593
+ },
2594
+ body: data.requestBody,
2595
+ mediaType: "application/json",
2596
+ errors: {
2597
+ 403: "Comment value is empty"
2598
+ }
2599
+ });
2600
+ };
2601
+ var editApprovalComment = (data) => {
2602
+ return request(OpenAPI, {
2603
+ method: "PUT",
2604
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/comment/{approvalCommentId}",
2605
+ path: {
2606
+ subAccountId: data.subAccountId,
2607
+ negotiationId: data.negotiationId,
2608
+ approvalCommentId: data.approvalCommentId
2609
+ },
2610
+ body: data.requestBody,
2611
+ mediaType: "application/json",
2612
+ errors: {
2613
+ 403: "Comment value is empty"
2614
+ }
2615
+ });
2616
+ };
2617
+ var deleteApprovalComment = (data) => {
2618
+ return request(OpenAPI, {
2619
+ method: "DELETE",
2620
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/comment/{approvalCommentId}",
2621
+ path: {
2622
+ subAccountId: data.subAccountId,
2623
+ negotiationId: data.negotiationId,
2624
+ approvalCommentId: data.approvalCommentId
2625
+ },
2626
+ errors: {
2627
+ 403: "Action not permitted (user does not have permission)"
2628
+ }
2629
+ });
2630
+ };
2631
+ var getApprovalComments = (data) => {
2632
+ return request(OpenAPI, {
2633
+ method: "GET",
2634
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/comments/all",
2635
+ path: {
2636
+ subAccountId: data.subAccountId,
2637
+ negotiationId: data.negotiationId
2638
+ },
2639
+ errors: {
2640
+ 404: "Negotiation not found"
2641
+ }
2642
+ });
2643
+ };
2644
+ var markApprovalCommentsAsViewed = (data) => {
2645
+ return request(OpenAPI, {
2646
+ method: "PUT",
2647
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/approvals/comments/markAsRead",
2648
+ path: {
2649
+ subAccountId: data.subAccountId,
2650
+ negotiationId: data.negotiationId
2651
+ },
2652
+ body: data.requestBody,
2653
+ mediaType: "application/json",
2654
+ errors: {
2655
+ 404: "Negotiation not found"
2656
+ }
2657
+ });
2658
+ };
2659
+ var sendToCounterpartyInitial = (data) => {
2660
+ return request(OpenAPI, {
2661
+ method: "PUT",
2662
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/sendToCounterparty/initial",
2663
+ path: {
2664
+ subAccountId: data.subAccountId,
2665
+ negotiationId: data.negotiationId
2666
+ },
2667
+ body: data.requestBody,
2668
+ mediaType: "application/json",
2669
+ errors: {
2670
+ 403: "No counterparty is configured",
2671
+ 404: "Negotiation not found",
2672
+ 409: "Could not save new version"
2673
+ }
2674
+ });
2675
+ };
2676
+ var markAsOffline = (data) => {
2677
+ return request(OpenAPI, {
2678
+ method: "PUT",
2679
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/markAsOffline",
2680
+ path: {
2681
+ subAccountId: data.subAccountId,
2682
+ negotiationId: data.negotiationId
2683
+ },
2684
+ errors: {
2685
+ 403: "No counterparty is configured",
2686
+ 404: "Negotiation not found",
2687
+ 409: "Could not save new version"
2688
+ }
2689
+ });
2690
+ };
2691
+ var confirm = (data) => {
2692
+ return request(OpenAPI, {
2693
+ method: "PUT",
2694
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/confirm",
2695
+ path: {
2696
+ subAccountId: data.subAccountId,
2697
+ negotiationId: data.negotiationId
2698
+ },
2699
+ errors: {
2700
+ 400: "Invalid, incomplete or mismatching answers",
2701
+ 404: "Negotiation not found",
2702
+ 409: "Could not save new version"
2703
+ }
2704
+ });
2705
+ };
2706
+ var cancel = (data) => {
2707
+ return request(OpenAPI, {
2708
+ method: "PUT",
2709
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/cancel",
2710
+ path: {
2711
+ subAccountId: data.subAccountId,
2712
+ negotiationId: data.negotiationId
2713
+ },
2714
+ body: data.requestBody,
2715
+ mediaType: "application/json",
2716
+ errors: {
2717
+ 404: "Negotiation not found"
2718
+ }
2719
+ });
2720
+ };
2721
+ var cancelNegotiations = (data) => {
2722
+ return request(OpenAPI, {
2723
+ method: "PUT",
2724
+ url: "/api/v1/subAccounts/{subAccountId}/cancelNegotiations",
2725
+ path: {
2726
+ subAccountId: data.subAccountId
2727
+ },
2728
+ body: data.requestBody,
2729
+ mediaType: "application/json"
2730
+ });
2731
+ };
2732
+ var retract = (data) => {
2733
+ return request(OpenAPI, {
2734
+ method: "PUT",
2735
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/retract",
2736
+ path: {
2737
+ subAccountId: data.subAccountId,
2738
+ negotiationId: data.negotiationId
2739
+ },
2740
+ body: data.requestBody,
2741
+ mediaType: "application/json",
2742
+ errors: {
2743
+ 404: "Negotiation not found"
2744
+ }
2745
+ });
2746
+ };
2747
+ var confirmExecutionVersion = (data) => {
2748
+ return request(OpenAPI, {
2749
+ method: "PUT",
2750
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/confirmExecutionVersion",
2751
+ path: {
2752
+ subAccountId: data.subAccountId,
2753
+ negotiationId: data.negotiationId
2754
+ },
2755
+ errors: {
2756
+ 404: "Negotiation not found"
2757
+ }
2758
+ });
2759
+ };
2760
+ var revertToAmending = (data) => {
2761
+ return request(OpenAPI, {
2762
+ method: "PUT",
2763
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/revertToAmending",
2764
+ path: {
2765
+ subAccountId: data.subAccountId,
2766
+ negotiationId: data.negotiationId
2767
+ },
2768
+ body: data.requestBody,
2769
+ mediaType: "application/json",
2770
+ errors: {
2771
+ 404: "Negotiation not found"
2772
+ }
2773
+ });
2774
+ };
2775
+ var getComments = (data) => {
2776
+ return request(OpenAPI, {
2777
+ method: "GET",
2778
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/comments",
2779
+ path: {
2780
+ subAccountId: data.subAccountId,
2781
+ negotiationId: data.negotiationId
2782
+ },
2783
+ errors: {
2784
+ 404: "Negotiation not found"
2785
+ }
2786
+ });
2787
+ };
2788
+ var getCommentSummary = (data) => {
2789
+ return request(OpenAPI, {
2790
+ method: "GET",
2791
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/commentSummary",
2792
+ path: {
2793
+ subAccountId: data.subAccountId,
2794
+ negotiationId: data.negotiationId
2795
+ },
2796
+ query: {
2797
+ summaryContext: data.summaryContext,
2798
+ unreadOnly: data.unreadOnly
2799
+ },
2800
+ errors: {
2801
+ 400: "The specified summaryContext is not available for this negotiation.",
2802
+ 403: "The AI comment summerisation feature has not been enabled for this account.",
2803
+ 404: "Negotiation not found or No comments to summarise.",
2804
+ 503: "Unable to fetch a summary, the generated summary may have been discarded if it contained inappropriate content."
2805
+ }
2806
+ });
2807
+ };
2808
+ var getTimelineActivity = (data) => {
2809
+ return request(OpenAPI, {
2810
+ method: "GET",
2811
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/activities",
2812
+ path: {
2813
+ subAccountId: data.subAccountId,
2814
+ negotiationId: data.negotiationId
2815
+ },
2816
+ query: {
2817
+ orderDirection: data.orderDirection
2818
+ },
2819
+ errors: {
2820
+ 404: "Negotiation not found"
2821
+ }
2822
+ });
2823
+ };
2824
+ var getChannelTimeline = (data) => {
2825
+ return request(OpenAPI, {
2826
+ method: "GET",
2827
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/{channel}",
2828
+ path: {
2829
+ subAccountId: data.subAccountId,
2830
+ negotiationId: data.negotiationId,
2831
+ channel: data.channel
2832
+ },
2833
+ query: {
2834
+ orderDirection: data.orderDirection
2835
+ },
2836
+ errors: {
2837
+ 404: "Negotiation not found"
2838
+ }
2839
+ });
2840
+ };
2841
+ var getTimeline = (data) => {
2842
+ return request(OpenAPI, {
2843
+ method: "GET",
2844
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline",
2845
+ path: {
2846
+ subAccountId: data.subAccountId,
2847
+ negotiationId: data.negotiationId
2848
+ },
2849
+ query: {
2850
+ orderDirection: data.orderDirection
2851
+ },
2852
+ errors: {
2853
+ 404: "Negotiation not found"
2854
+ }
2855
+ });
2856
+ };
2857
+ var markEventsAsViewed = (data) => {
2858
+ return request(OpenAPI, {
2859
+ method: "POST",
2860
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline",
2861
+ path: {
2862
+ subAccountId: data.subAccountId,
2863
+ negotiationId: data.negotiationId
2864
+ },
2865
+ errors: {
2866
+ 404: "Negotiation not found"
2867
+ }
2868
+ });
2869
+ };
2870
+ var markActivityEventsAsViewed = (data) => {
2871
+ return request(OpenAPI, {
2872
+ method: "PUT",
2873
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/activities/markAsRead",
2874
+ path: {
2875
+ subAccountId: data.subAccountId,
2876
+ negotiationId: data.negotiationId
2877
+ },
2878
+ body: data.requestBody,
2879
+ mediaType: "application/json",
2880
+ errors: {
2881
+ 404: "Negotiation not found"
2882
+ }
2883
+ });
2884
+ };
2885
+ var markCommentEventsAsViewed = (data) => {
2886
+ return request(OpenAPI, {
2887
+ method: "PUT",
2888
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/comments/markAsRead",
2889
+ path: {
2890
+ subAccountId: data.subAccountId,
2891
+ negotiationId: data.negotiationId
2892
+ },
2893
+ body: data.requestBody,
2894
+ mediaType: "application/json",
2895
+ errors: {
2896
+ 404: "Negotiation not found"
2897
+ }
2898
+ });
2899
+ };
2900
+ var addComment = (data) => {
2901
+ return request(OpenAPI, {
2902
+ method: "POST",
2903
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/{channel}/comments",
2904
+ path: {
2905
+ subAccountId: data.subAccountId,
2906
+ negotiationId: data.negotiationId,
2907
+ channel: data.channel
2908
+ },
2909
+ body: data.requestBody,
2910
+ mediaType: "application/json"
2911
+ });
2912
+ };
2913
+ var queueGenerateNegotiationDocumentJob = (data) => {
2914
+ return request(OpenAPI, {
2915
+ method: "POST",
2916
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/generateDocument",
2917
+ path: {
2918
+ subAccountId: data.subAccountId,
2919
+ negotiationId: data.negotiationId
2920
+ },
2921
+ body: data.requestBody,
2922
+ mediaType: "application/json"
2923
+ });
2924
+ };
2925
+ var updateComment = (data) => {
2926
+ return request(OpenAPI, {
2927
+ method: "PUT",
2928
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/{channel}/comments/{eventId}",
2929
+ path: {
2930
+ subAccountId: data.subAccountId,
2931
+ negotiationId: data.negotiationId,
2932
+ eventId: data.eventId,
2933
+ channel: data.channel
2934
+ },
2935
+ body: data.requestBody,
2936
+ mediaType: "application/json"
2937
+ });
2938
+ };
2939
+ var deleteComment = (data) => {
2940
+ return request(OpenAPI, {
2941
+ method: "DELETE",
2942
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/timeline/{channel}/comments/{eventId}",
2943
+ path: {
2944
+ subAccountId: data.subAccountId,
2945
+ negotiationId: data.negotiationId,
2946
+ eventId: data.eventId,
2947
+ channel: data.channel
2948
+ },
2949
+ body: data.requestBody,
2950
+ mediaType: "application/json"
2951
+ });
2952
+ };
2953
+ var updateSubAccount = (data) => {
2954
+ return request(OpenAPI, {
2955
+ method: "PUT",
2956
+ url: "/api/v1/subAccounts/{subAccountId}",
2957
+ path: {
2958
+ subAccountId: data.subAccountId
2959
+ },
2960
+ body: data.requestBody,
2961
+ mediaType: "application/json",
2962
+ errors: {
2963
+ 404: "Sub-account not found"
2964
+ }
2965
+ });
2966
+ };
2967
+ var getSubAccount = (data) => {
2968
+ return request(OpenAPI, {
2969
+ method: "GET",
2970
+ url: "/api/v1/subAccounts/{subAccountId}",
2971
+ path: {
2972
+ subAccountId: data.subAccountId
2973
+ }
2974
+ });
2975
+ };
2976
+ var listSubAccounts = (data = {}) => {
2977
+ return request(OpenAPI, {
2978
+ method: "GET",
2979
+ url: "/api/v1/subAccounts",
2980
+ query: {
2981
+ minimal: data.minimal,
2982
+ subAccountName: data.subAccountName
2983
+ }
2984
+ });
2985
+ };
2986
+ var getLegacyStatistics = (data) => {
2987
+ return request(OpenAPI, {
2988
+ method: "GET",
2989
+ url: "/api/v1/subAccounts/{subAccountId}/statistics",
2990
+ path: {
2991
+ subAccountId: data.subAccountId
2992
+ },
2993
+ query: {
2994
+ documentPublisherId: data.documentPublisherId
2995
+ },
2996
+ errors: {
2997
+ 404: "Sub-account not found"
2998
+ }
2999
+ });
3000
+ };
3001
+ var getStatistics = (data) => {
3002
+ return request(OpenAPI, {
3003
+ method: "GET",
3004
+ url: "/api/v2/subAccounts/{subAccountId}/statistics",
3005
+ path: {
3006
+ subAccountId: data.subAccountId
3007
+ },
3008
+ query: {
3009
+ documentPublisherId: data.documentPublisherId,
3010
+ isDraft: data.isDraft,
3011
+ isCompleted: data.isCompleted,
3012
+ isCancelled: data.isCancelled,
3013
+ isAmendAndRestate: data.isAmendAndRestate,
3014
+ isTriparty: data.isTriparty,
3015
+ isOffline: data.isOffline,
3016
+ isAdvisorAccessible: data.isAdvisorAccessible,
3017
+ isConfirmedTemplate: data.isConfirmedTemplate,
3018
+ creationDateFrom: data.creationDateFrom,
3019
+ creationDateTo: data.creationDateTo,
3020
+ advisorRelationshipId: data.advisorRelationshipId
3021
+ },
3022
+ errors: {
3023
+ 404: "Sub-account not found"
3024
+ }
3025
+ });
3026
+ };
3027
+ var getUserStatistics = (data) => {
3028
+ return request(OpenAPI, {
3029
+ method: "GET",
3030
+ url: "/api/v2/subAccounts/{subAccountId}/statistics/users/{userId}",
3031
+ path: {
3032
+ subAccountId: data.subAccountId,
3033
+ userId: data.userId
3034
+ },
3035
+ query: {
3036
+ documentPublisherId: data.documentPublisherId,
3037
+ isDraft: data.isDraft,
3038
+ isCompleted: data.isCompleted,
3039
+ isCancelled: data.isCancelled,
3040
+ isAmendAndRestate: data.isAmendAndRestate,
3041
+ isTriparty: data.isTriparty,
3042
+ isOffline: data.isOffline,
3043
+ isAdvisorAccessible: data.isAdvisorAccessible,
3044
+ isConfirmedTemplate: data.isConfirmedTemplate,
3045
+ creationDateFrom: data.creationDateFrom,
3046
+ creationDateTo: data.creationDateTo,
3047
+ advisorRelationshipId: data.advisorRelationshipId
3048
+ },
3049
+ errors: {
3050
+ 404: "Sub-account not found"
3051
+ }
3052
+ });
3053
+ };
3054
+ var getStatisticsOverview = (data) => {
3055
+ return request(OpenAPI, {
3056
+ method: "GET",
3057
+ url: "/api/v2/subAccounts/{subAccountId}/statisticsOverview",
3058
+ path: {
3059
+ subAccountId: data.subAccountId
3060
+ },
3061
+ errors: {
3062
+ 404: "Sub-account not found"
3063
+ }
3064
+ });
3065
+ };
3066
+ var assignEntity = (data) => {
3067
+ return request(OpenAPI, {
3068
+ method: "PUT",
3069
+ url: "/api/v1/subAccounts/{subAccountId}/entity",
3070
+ path: {
3071
+ subAccountId: data.subAccountId
3072
+ },
3073
+ body: data.requestBody,
3074
+ mediaType: "application/json",
3075
+ errors: {
3076
+ 404: "Subaccount or Entity not found",
3077
+ 409: "Entity is already assigned to a subaccount in this account"
3078
+ }
3079
+ });
3080
+ };
3081
+ var moveEntity = (data) => {
3082
+ return request(OpenAPI, {
3083
+ method: "PUT",
3084
+ url: "/api/v1/subAccounts/{subAccountId}/entity/{entityId}/move",
3085
+ path: {
3086
+ entityId: data.entityId,
3087
+ subAccountId: data.subAccountId
3088
+ },
3089
+ body: data.requestBody,
3090
+ mediaType: "application/json",
3091
+ errors: {
3092
+ 404: "Entity could not be found on the Sub-Account",
3093
+ 419: "Entity cannot be moved from and to the same Sub-Account"
3094
+ }
3095
+ });
3096
+ };
3097
+ var auditTrailForSubAccountAsJson = (data) => {
3098
+ return request(OpenAPI, {
3099
+ method: "GET",
3100
+ url: "/api/v1/subAccounts/{subAccountId}/audit_trail/json",
3101
+ path: {
3102
+ subAccountId: data.subAccountId
3103
+ },
3104
+ query: {
3105
+ yearMonths: data.yearMonths
3106
+ }
3107
+ });
3108
+ };
3109
+ var auditTrailForSubAccountAsExcel = (data) => {
3110
+ return request(OpenAPI, {
3111
+ method: "GET",
3112
+ url: "/api/v1/subAccounts/{subAccountId}/audit_trail/xlsx",
3113
+ path: {
3114
+ subAccountId: data.subAccountId
3115
+ },
3116
+ query: {
3117
+ yearMonths: data.yearMonths
3118
+ }
3119
+ });
3120
+ };
3121
+ var auditTrailFilters = () => {
3122
+ return request(OpenAPI, {
3123
+ method: "GET",
3124
+ url: "/api/v1/account/audit_trail/filters"
3125
+ });
3126
+ };
3127
+ var auditTrailForAccountAsJson = (data) => {
3128
+ return request(OpenAPI, {
3129
+ method: "GET",
3130
+ url: "/api/v1/account/audit_trail/json",
3131
+ query: {
3132
+ includeSubAccountEvents: data.includeSubAccountEvents,
3133
+ yearMonths: data.yearMonths
3134
+ }
3135
+ });
3136
+ };
3137
+ var auditTrailForAccountAsExcel = (data) => {
3138
+ return request(OpenAPI, {
3139
+ method: "GET",
3140
+ url: "/api/v1/account/audit_trail/xlsx",
3141
+ query: {
3142
+ includeSubAccountEvents: data.includeSubAccountEvents,
3143
+ yearMonths: data.yearMonths
3144
+ }
3145
+ });
3146
+ };
3147
+ var emailPreferences = () => {
3148
+ return request(OpenAPI, {
3149
+ method: "GET",
3150
+ url: "/api/v1/emailPreferences"
3151
+ });
3152
+ };
3153
+ var patchEmailPreferences = (data) => {
3154
+ return request(OpenAPI, {
3155
+ method: "PATCH",
3156
+ url: "/api/v1/emailPreferences",
3157
+ body: data.requestBody,
3158
+ mediaType: "application/json"
3159
+ });
3160
+ };
3161
+ var listPotentialNegotiationAdvisors = (data) => {
3162
+ return request(OpenAPI, {
3163
+ method: "GET",
3164
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/negotiations/{negotiationId}/potentialAdvisors",
3165
+ path: {
3166
+ subAccountId: data.subAccountId,
3167
+ negotiationId: data.negotiationId
3168
+ }
3169
+ });
3170
+ };
3171
+ var listPotentialPresetAdvisors = (data) => {
3172
+ return request(OpenAPI, {
3173
+ method: "GET",
3174
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/presets/{presetId}/potentialAdvisors",
3175
+ path: {
3176
+ subAccountId: data.subAccountId,
3177
+ presetId: data.presetId
3178
+ }
3179
+ });
3180
+ };
3181
+ var getAccountRelationshipSummaries = () => {
3182
+ return request(OpenAPI, {
3183
+ method: "GET",
3184
+ url: "/api/v1/advisor/accounts/relationships/summary",
3185
+ errors: {
3186
+ 403: "The request is from advisor"
3187
+ }
3188
+ });
3189
+ };
3190
+ var listAdvisorsForWorkspace = (data) => {
3191
+ return request(OpenAPI, {
3192
+ method: "GET",
3193
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/listAdvisors",
3194
+ path: {
3195
+ subAccountId: data.subAccountId
3196
+ }
3197
+ });
3198
+ };
3199
+ var grantNegotiationsAccess = (data) => {
3200
+ return request(OpenAPI, {
3201
+ method: "POST",
3202
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/relationships/{relationshipId}/negotiations",
3203
+ path: {
3204
+ relationshipId: data.relationshipId,
3205
+ subAccountId: data.subAccountId
3206
+ },
3207
+ body: data.requestBody,
3208
+ mediaType: "application/json"
3209
+ });
3210
+ };
3211
+ var revokeNegotiationsAccess = (data) => {
3212
+ return request(OpenAPI, {
3213
+ method: "DELETE",
3214
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/relationships/{relationshipId}/negotiations",
3215
+ path: {
3216
+ relationshipId: data.relationshipId,
3217
+ subAccountId: data.subAccountId
3218
+ },
3219
+ body: data.requestBody,
3220
+ mediaType: "application/json"
3221
+ });
3222
+ };
3223
+ var grantAllNegotiationsAccess = (data) => {
3224
+ return request(OpenAPI, {
3225
+ method: "PUT",
3226
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/relationships/{relationshipId}/negotiations/all",
3227
+ path: {
3228
+ relationshipId: data.relationshipId,
3229
+ subAccountId: data.subAccountId
3230
+ }
3231
+ });
3232
+ };
3233
+ var grantPresetsAccess = (data) => {
3234
+ return request(OpenAPI, {
3235
+ method: "POST",
3236
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/relationships/{relationshipId}/presets",
3237
+ path: {
3238
+ relationshipId: data.relationshipId,
3239
+ subAccountId: data.subAccountId
3240
+ },
3241
+ body: data.requestBody,
3242
+ mediaType: "application/json"
3243
+ });
3244
+ };
3245
+ var revokePresetsAccess = (data) => {
3246
+ return request(OpenAPI, {
3247
+ method: "DELETE",
3248
+ url: "/api/v1/advisor/subAccounts/{subAccountId}/relationships/{relationshipId}/presets",
3249
+ path: {
3250
+ relationshipId: data.relationshipId,
3251
+ subAccountId: data.subAccountId
3252
+ },
3253
+ body: data.requestBody,
3254
+ mediaType: "application/json"
3255
+ });
3256
+ };
3257
+ var createGroup = (data) => {
3258
+ return request(OpenAPI, {
3259
+ method: "POST",
3260
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups",
3261
+ path: {
3262
+ subAccountId: data.subAccountId
3263
+ },
3264
+ body: data.requestBody,
3265
+ mediaType: "application/json"
3266
+ });
3267
+ };
3268
+ var getGroupNames = (data) => {
3269
+ return request(OpenAPI, {
3270
+ method: "GET",
3271
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups",
3272
+ path: {
3273
+ subAccountId: data.subAccountId
3274
+ }
3275
+ });
3276
+ };
3277
+ var updateGroupName = (data) => {
3278
+ return request(OpenAPI, {
3279
+ method: "PUT",
3280
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups/{negotiationGroupId}",
3281
+ path: {
3282
+ subAccountId: data.subAccountId,
3283
+ negotiationGroupId: data.negotiationGroupId
3284
+ },
3285
+ body: data.requestBody,
3286
+ mediaType: "application/json",
3287
+ errors: {
3288
+ 404: "Negotiation group not found"
3289
+ }
3290
+ });
3291
+ };
3292
+ var getNegotiationDeltas = (data) => {
3293
+ return request(OpenAPI, {
3294
+ method: "PUT",
3295
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups/deltas/calculate",
3296
+ path: {
3297
+ subAccountId: data.subAccountId
3298
+ },
3299
+ body: data.requestBody,
3300
+ mediaType: "application/json"
3301
+ });
3302
+ };
3303
+ var updateNegotiationsToMatch = (data) => {
3304
+ return request(OpenAPI, {
3305
+ method: "PUT",
3306
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups/deltas/apply",
3307
+ path: {
3308
+ subAccountId: data.subAccountId
3309
+ },
3310
+ body: data.requestBody,
3311
+ mediaType: "application/json",
3312
+ errors: {
3313
+ 409: "One or more negotiations could not be updated, so none were updated."
3314
+ }
3315
+ });
3316
+ };
3317
+ var suggestGroupName = (data) => {
3318
+ return request(OpenAPI, {
3319
+ method: "GET",
3320
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups/nameSuggestions",
3321
+ path: {
3322
+ subAccountId: data.subAccountId
3323
+ },
3324
+ query: {
3325
+ desiredName: data.desiredName
3326
+ }
3327
+ });
3328
+ };
3329
+ var updateGroupMembers = (data) => {
3330
+ return request(OpenAPI, {
3331
+ method: "PUT",
3332
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups/{negotiationGroupId}/members",
3333
+ path: {
3334
+ subAccountId: data.subAccountId,
3335
+ negotiationGroupId: data.negotiationGroupId
3336
+ },
3337
+ body: data.requestBody,
3338
+ mediaType: "application/json",
3339
+ errors: {
3340
+ 404: "Negotiation group not found"
3341
+ }
3342
+ });
3343
+ };
3344
+ var getNegotiationsGroup = (data) => {
3345
+ return request(OpenAPI, {
3346
+ method: "GET",
3347
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups/{negotiationGroupId}/negotiations",
3348
+ path: {
3349
+ subAccountId: data.subAccountId,
3350
+ negotiationGroupId: data.negotiationGroupId
3351
+ }
3352
+ });
3353
+ };
3354
+ var sendGroupToCounterparty = (data) => {
3355
+ return request(OpenAPI, {
3356
+ method: "PUT",
3357
+ url: "/api/v1/subAccounts/{subAccountId}/negotiationGroups/{negotiationGroupId}/sendToCounterparty",
3358
+ path: {
3359
+ subAccountId: data.subAccountId,
3360
+ negotiationGroupId: data.negotiationGroupId
3361
+ },
3362
+ body: data.requestBody,
3363
+ mediaType: "application/json",
3364
+ errors: {
3365
+ 403: "Unauthorised access of the negotiation group and the Sub-Account",
3366
+ 409: "Could not save new version"
3367
+ }
3368
+ });
3369
+ };
3370
+ var createBulkSet = (data) => {
3371
+ return request(OpenAPI, {
3372
+ method: "POST",
3373
+ url: "/api/v1/subAccounts/{subAccountId}/bulkSets",
3374
+ path: {
3375
+ subAccountId: data.subAccountId
3376
+ },
3377
+ body: data.requestBody,
3378
+ mediaType: "application/json"
3379
+ });
3380
+ };
3381
+ var listBulkSets = (data) => {
3382
+ return request(OpenAPI, {
3383
+ method: "GET",
3384
+ url: "/api/v1/subAccounts/{subAccountId}/bulkSets",
3385
+ path: {
3386
+ subAccountId: data.subAccountId
3387
+ }
3388
+ });
3389
+ };
3390
+ var getBulkSet = (data) => {
3391
+ return request(OpenAPI, {
3392
+ method: "GET",
3393
+ url: "/api/v1/bulkSets/{bulkSetId}",
3394
+ path: {
3395
+ bulkSetId: data.bulkSetId
3396
+ }
3397
+ });
3398
+ };
3399
+ var updateAttachDocx = (data) => {
3400
+ return request(OpenAPI, {
3401
+ method: "PUT",
3402
+ url: "/api/v1/bulkSets/{bulkSetId}/updateAttachDocx",
3403
+ path: {
3404
+ bulkSetId: data.bulkSetId
3405
+ }
3406
+ });
3407
+ };
3408
+ var updateCoverNote = (data) => {
3409
+ return request(OpenAPI, {
3410
+ method: "PUT",
3411
+ url: "/api/v1/bulkSets/{bulkSetId}/coverNote",
3412
+ path: {
3413
+ bulkSetId: data.bulkSetId
3414
+ },
3415
+ body: data.requestBody,
3416
+ mediaType: "application/json"
3417
+ });
3418
+ };
3419
+ var deleteCoverNote = (data) => {
3420
+ return request(OpenAPI, {
3421
+ method: "DELETE",
3422
+ url: "/api/v1/bulkSets/{bulkSetId}/coverNote",
3423
+ path: {
3424
+ bulkSetId: data.bulkSetId
3425
+ }
3426
+ });
3427
+ };
3428
+ var bulkSetsJobCount = (data) => {
3429
+ return request(OpenAPI, {
3430
+ method: "GET",
3431
+ url: "/api/v1/subAccounts/{subAccountId}/bulkSets/count",
3432
+ path: {
3433
+ subAccountId: data.subAccountId
3434
+ }
3435
+ });
3436
+ };
3437
+ var cancelNegotiationsJobCount = (data) => {
3438
+ return request(OpenAPI, {
3439
+ method: "GET",
3440
+ url: "/api/v1/subAccounts/{subAccountId}/cancelNegotiationJobCount",
3441
+ path: {
3442
+ subAccountId: data.subAccountId
3443
+ }
3444
+ });
3445
+ };
3446
+ var sendBulkSetToCounterpartiesInitial = (data) => {
3447
+ return request(OpenAPI, {
3448
+ method: "PUT",
3449
+ url: "/api/v1/bulkSets/{bulkSetId}/sendToCounterparty/initial",
3450
+ path: {
3451
+ bulkSetId: data.bulkSetId
3452
+ }
3453
+ });
3454
+ };
3455
+ var setBulkSetAttachments = (data) => {
3456
+ return request(OpenAPI, {
3457
+ method: "POST",
3458
+ url: "/api/v1/bulkSets/{bulkSetId}/attachment",
3459
+ path: {
3460
+ bulkSetId: data.bulkSetId
3461
+ },
3462
+ formData: data.formData,
3463
+ mediaType: "multipart/form-data",
3464
+ errors: {
3465
+ 400: "The file(s) are too large or would exceed the maximum total size for all files",
3466
+ 404: "The bulk set was not found"
3467
+ }
3468
+ });
3469
+ };
3470
+ var deleteBulkSetAttachment = (data) => {
3471
+ return request(OpenAPI, {
3472
+ method: "DELETE",
3473
+ url: "/api/v1/bulkSets/{bulkSetId}/attachment/{fileName}",
3474
+ path: {
3475
+ bulkSetId: data.bulkSetId,
3476
+ fileName: data.fileName
3477
+ }
3478
+ });
3479
+ };
3480
+ var getBulkSetAttachment = (data) => {
3481
+ return request(OpenAPI, {
3482
+ method: "GET",
3483
+ url: "/api/v1/bulkSets/{bulkSetId}/attachment/{fileName}",
3484
+ path: {
3485
+ bulkSetId: data.bulkSetId,
3486
+ fileName: data.fileName
3487
+ }
3488
+ });
3489
+ };
3490
+ var validateDraftReceiverEmails = (data) => {
3491
+ return request(OpenAPI, {
3492
+ method: "POST",
3493
+ url: "/api/v1/subAccounts/{subAccountId}/bulkSets/validateEmails",
3494
+ path: {
3495
+ subAccountId: data.subAccountId
3496
+ },
3497
+ body: data.requestBody,
3498
+ mediaType: "application/json"
3499
+ });
3500
+ };
3501
+ var getDraftingNotes = (data) => {
3502
+ return request(OpenAPI, {
3503
+ method: "GET",
3504
+ url: "/api/v1/documents/{documentId}/subAccounts/{subAccountId}/draftingNotes",
3505
+ path: {
3506
+ documentId: data.documentId,
3507
+ subAccountId: data.subAccountId
3508
+ }
3509
+ });
3510
+ };
3511
+ var updateDraftingNotes = (data) => {
3512
+ return request(OpenAPI, {
3513
+ method: "POST",
3514
+ url: "/api/v1/documents/{documentId}/subAccounts/{subAccountId}/draftingNotes",
3515
+ path: {
3516
+ documentId: data.documentId,
3517
+ subAccountId: data.subAccountId
3518
+ },
3519
+ errors: {
3520
+ 400: "Update drafting notes failed"
3521
+ }
3522
+ });
3523
+ };
3524
+ var deleteDraftingNotesDocument = (data) => {
3525
+ return request(OpenAPI, {
3526
+ method: "DELETE",
3527
+ url: "/api/v1/documents/{documentId}/subAccounts/{subAccountId}/draftingNotes",
3528
+ path: {
3529
+ documentId: data.documentId,
3530
+ subAccountId: data.subAccountId
3531
+ }
3532
+ });
3533
+ };
3534
+ var updateDocumentDraftingNote = (data) => {
3535
+ return request(OpenAPI, {
3536
+ method: "PUT",
3537
+ url: "/api/v1/documents/{documentId}/subAccounts/{subAccountId}/draftingNote/noteType/{noteType}",
3538
+ path: {
3539
+ documentId: data.documentId,
3540
+ subAccountId: data.subAccountId,
3541
+ noteType: data.noteType
3542
+ },
3543
+ errors: {
3544
+ 400: "Drafting note update failed"
3545
+ }
3546
+ });
3547
+ };
3548
+ var deleteDocumentDraftingNote = (data) => {
3549
+ return request(OpenAPI, {
3550
+ method: "DELETE",
3551
+ url: "/api/v1/documents/{documentId}/subAccounts/{subAccountId}/draftingNote/noteType/{noteType}",
3552
+ path: {
3553
+ documentId: data.documentId,
3554
+ subAccountId: data.subAccountId,
3555
+ noteType: data.noteType
3556
+ },
3557
+ errors: {
3558
+ 400: "Deletion of drafting note failed",
3559
+ 404: "No document draftinmg note exist for the specified type"
3560
+ }
3561
+ });
3562
+ };
3563
+ var updateDocumentElectionDraftingNote = (data) => {
3564
+ return request(OpenAPI, {
3565
+ method: "PUT",
3566
+ url: "/api/v1/documents/{documentId}/subAccounts/{subAccountId}/draftingNote/elections/{electionId}/noteType/{noteType}",
3567
+ path: {
3568
+ documentId: data.documentId,
3569
+ subAccountId: data.subAccountId,
3570
+ electionId: data.electionId,
3571
+ noteType: data.noteType
3572
+ },
3573
+ errors: {
3574
+ 400: "Drafting note update failed"
3575
+ }
3576
+ });
3577
+ };
3578
+ var deleteDocumentElectionDraftingNote = (data) => {
3579
+ return request(OpenAPI, {
3580
+ method: "DELETE",
3581
+ url: "/api/v1/documents/{documentId}/subAccounts/{subAccountId}/draftingNote/elections/{electionId}/noteType/{noteType}",
3582
+ path: {
3583
+ documentId: data.documentId,
3584
+ subAccountId: data.subAccountId,
3585
+ electionId: data.electionId,
3586
+ noteType: data.noteType
3587
+ },
3588
+ errors: {
3589
+ 400: "Deletion of drafting note failed",
3590
+ 404: "No document draftinmg note exist for the specified type"
3591
+ }
3592
+ });
3593
+ };
3594
+ var getNegotiationDraftingNotes = (data) => {
3595
+ return request(OpenAPI, {
3596
+ method: "GET",
3597
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/negotiationDraftingNotes",
3598
+ path: {
3599
+ subAccountId: data.subAccountId,
3600
+ negotiationId: data.negotiationId
3601
+ }
3602
+ });
3603
+ };
3604
+ var getDraftingNotesDocument = (data) => {
3605
+ return request(OpenAPI, {
3606
+ method: "GET",
3607
+ url: "/api/v1/subAccounts/{subAccountId}/draftingNotes",
3608
+ path: {
3609
+ subAccountId: data.subAccountId
3610
+ }
3611
+ });
3612
+ };
3613
+ var obtainConsent = () => {
3614
+ return request(OpenAPI, {
3615
+ method: "GET",
3616
+ url: "/api/v1/docusign/connect",
3617
+ errors: {
3618
+ 308: "Redirects user to the DocuSign consent form"
3619
+ }
3620
+ });
3621
+ };
3622
+ var getNegotiationESignStatus = (data) => {
3623
+ return request(OpenAPI, {
3624
+ method: "GET",
3625
+ url: "/api/v1/docusign/status/subAccounts/{subAccountId}/negotiations/{negotiationId}",
3626
+ path: {
3627
+ subAccountId: data.subAccountId,
3628
+ negotiationId: data.negotiationId
3629
+ }
3630
+ });
3631
+ };
3632
+ var consentCodeCallback = () => {
3633
+ return request(OpenAPI, {
3634
+ method: "GET",
3635
+ url: "/api/v1/docusign/redirectCodeCallback",
3636
+ errors: {
3637
+ 308: "Redirects the user back to the negotiation signing page"
3638
+ }
3639
+ });
3640
+ };
3641
+ var generateAndMaybeSendEnvelope = (data) => {
3642
+ return request(OpenAPI, {
3643
+ method: "GET",
3644
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/signWithDocuSign",
3645
+ path: {
3646
+ subAccountId: data.subAccountId,
3647
+ negotiationId: data.negotiationId
3648
+ },
3649
+ errors: {
3650
+ 400: "DocuSign API errors"
3651
+ }
3652
+ });
3653
+ };
3654
+ var voidESignEnvelopeForNegotiation = (data) => {
3655
+ return request(OpenAPI, {
3656
+ method: "PUT",
3657
+ url: "/api/v1/esign/{subAccountId}/negotiations/{negotiationId}/cancelSession",
3658
+ path: {
3659
+ subAccountId: data.subAccountId,
3660
+ negotiationId: data.negotiationId
3661
+ },
3662
+ errors: {
3663
+ 400: "DocuSign API errors"
3664
+ }
3665
+ });
3666
+ };
3667
+ var usersWithNegotiationAccess = (data) => {
3668
+ return request(OpenAPI, {
3669
+ method: "GET",
3670
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/users",
3671
+ path: {
3672
+ subAccountId: data.subAccountId,
3673
+ negotiationId: data.negotiationId
3674
+ },
3675
+ query: {
3676
+ potentialApproversOnly: data.potentialApproversOnly
3677
+ }
3678
+ });
3679
+ };
3680
+ var negotiationRenderTemplate = (data) => {
3681
+ return request(OpenAPI, {
3682
+ method: "GET",
3683
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/preview",
3684
+ path: {
3685
+ subAccountId: data.subAccountId,
3686
+ negotiationId: data.negotiationId
3687
+ },
3688
+ errors: {
3689
+ 404: "Negotiation not found"
3690
+ }
3691
+ });
3692
+ };
3693
+ var presetRenderTemplate = (data) => {
3694
+ return request(OpenAPI, {
3695
+ method: "GET",
3696
+ url: "/api/v1/presets/{presetId}/preview",
3697
+ path: {
3698
+ presetId: data.presetId
3699
+ },
3700
+ errors: {
3701
+ 404: "Preset not found"
3702
+ }
3703
+ });
3704
+ };
3705
+ var getAllNegotiationCommentsForSubAccount = (data) => {
3706
+ return request(OpenAPI, {
3707
+ method: "GET",
3708
+ url: "/api/v1/subAccounts/{subAccountId}/comments/xlsx",
3709
+ path: {
3710
+ subAccountId: data.subAccountId
3711
+ },
3712
+ query: {
3713
+ yearMonths: data.yearMonths
3714
+ }
3715
+ });
3716
+ };
3717
+ var getWatchers = (data) => {
3718
+ return request(OpenAPI, {
3719
+ method: "GET",
3720
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/watchers",
3721
+ path: {
3722
+ negotiationId: data.negotiationId,
3723
+ subAccountId: data.subAccountId
3724
+ },
3725
+ errors: {
3726
+ 403: "You do not have access to the specified sub account"
3727
+ }
3728
+ });
3729
+ };
3730
+ var addWatchers = (data) => {
3731
+ return request(OpenAPI, {
3732
+ method: "POST",
3733
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/watchers",
3734
+ path: {
3735
+ negotiationId: data.negotiationId,
3736
+ subAccountId: data.subAccountId
3737
+ },
3738
+ body: data.requestBody,
3739
+ mediaType: "application/json",
3740
+ errors: {
3741
+ 403: "You do not have access to the specified sub account"
3742
+ }
3743
+ });
3744
+ };
3745
+ var removeWatchers = (data) => {
3746
+ return request(OpenAPI, {
3747
+ method: "POST",
3748
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/removeWatchers",
3749
+ path: {
3750
+ negotiationId: data.negotiationId,
3751
+ subAccountId: data.subAccountId
3752
+ },
3753
+ body: data.requestBody,
3754
+ mediaType: "application/json",
3755
+ errors: {
3756
+ 403: "You do not have access to the specified sub account"
3757
+ }
3758
+ });
3759
+ };
3760
+ var negotiationsFilter = (data) => {
3761
+ return request(OpenAPI, {
3762
+ method: "GET",
3763
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/filters/{filter}",
3764
+ path: {
3765
+ subAccountId: data.subAccountId,
3766
+ filter: data.filter
3767
+ },
3768
+ query: {
3769
+ query: data.query,
3770
+ searchContext: data.searchContext,
3771
+ pageIndex: data.pageIndex,
3772
+ pageSize: data.pageSize
3773
+ },
3774
+ errors: {
3775
+ 403: "You do not have access to the specified sub account"
3776
+ }
3777
+ });
3778
+ };
3779
+ var negotiationGetDocumentSchema = (data) => {
3780
+ return request(OpenAPI, {
3781
+ method: "GET",
3782
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/schema",
3783
+ path: {
3784
+ subAccountId: data.subAccountId,
3785
+ negotiationId: data.negotiationId
3786
+ },
3787
+ errors: {
3788
+ 404: "Schema not found"
3789
+ }
3790
+ });
3791
+ };
3792
+ var presetGetDocumentSchema = (data) => {
3793
+ return request(OpenAPI, {
3794
+ method: "GET",
3795
+ url: "/api/v1/presets/{presetId}/schema",
3796
+ path: {
3797
+ presetId: data.presetId
3798
+ },
3799
+ errors: {
3800
+ 404: "Schema not found"
3801
+ }
3802
+ });
3803
+ };
3804
+ var documentsFilter = (data) => {
3805
+ return request(OpenAPI, {
3806
+ method: "GET",
3807
+ url: "/api/v1/subAccounts/{subAccountId}/documents/filters/{filter}",
3808
+ path: {
3809
+ subAccountId: data.subAccountId,
3810
+ filter: data.filter
3811
+ },
3812
+ query: {
3813
+ query: data.query,
3814
+ pageIndex: data.pageIndex,
3815
+ pageSize: data.pageSize
3816
+ },
3817
+ errors: {
3818
+ 403: "You do not have access to the specified sub account"
3819
+ }
3820
+ });
3821
+ };
3822
+ var grantWindow = () => {
3823
+ return request(OpenAPI, {
3824
+ method: "POST",
3825
+ url: "/api/v1/supportAccess/window",
3826
+ errors: {
3827
+ 400: "Maximum limit on access duration exceeded"
3828
+ }
3829
+ });
3830
+ };
3831
+ var getWindow = () => {
3832
+ return request(OpenAPI, {
3833
+ method: "GET",
3834
+ url: "/api/v1/supportAccess/window",
3835
+ errors: {
3836
+ 404: "No access provided for the requester or the access is expired"
3837
+ }
3838
+ });
3839
+ };
3840
+ var extendWindow = () => {
3841
+ return request(OpenAPI, {
3842
+ method: "PUT",
3843
+ url: "/api/v1/supportAccess/window",
3844
+ errors: {
3845
+ 404: "No access provided for the requester"
3846
+ }
3847
+ });
3848
+ };
3849
+ var revokeWindow = () => {
3850
+ return request(OpenAPI, {
3851
+ method: "DELETE",
3852
+ url: "/api/v1/supportAccess/window"
3853
+ });
3854
+ };
3855
+ var getExtractionResults = (data) => {
3856
+ return request(OpenAPI, {
3857
+ method: "GET",
3858
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/getResults",
3859
+ path: {
3860
+ subAccountId: data.subAccountId,
3861
+ negotiationId: data.negotiationId
3862
+ },
3863
+ errors: {
3864
+ 404: "Extraction has not started for this negotiation"
3865
+ }
3866
+ });
3867
+ };
3868
+ var scheduleExtraction = (data) => {
3869
+ return request(OpenAPI, {
3870
+ method: "PUT",
3871
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/start",
3872
+ path: {
3873
+ subAccountId: data.subAccountId,
3874
+ negotiationId: data.negotiationId
3875
+ },
3876
+ errors: {
3877
+ 403: "Extraction is not enabled for the document type or the negotiation is not offline"
3878
+ }
3879
+ });
3880
+ };
3881
+ var updateSelectedElections = (data) => {
3882
+ return request(OpenAPI, {
3883
+ method: "PUT",
3884
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/elections",
3885
+ path: {
3886
+ subAccountId: data.subAccountId,
3887
+ negotiationId: data.negotiationId
3888
+ },
3889
+ body: data.requestBody,
3890
+ mediaType: "application/json",
3891
+ errors: {
3892
+ 404: "Negotiation or election not found"
3893
+ }
3894
+ });
3895
+ };
3896
+ var updateExtractionFeedback = (data) => {
3897
+ return request(OpenAPI, {
3898
+ method: "PUT",
3899
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/feedback",
3900
+ path: {
3901
+ subAccountId: data.subAccountId,
3902
+ negotiationId: data.negotiationId
3903
+ },
3904
+ body: data.requestBody,
3905
+ mediaType: "application/json",
3906
+ errors: {
3907
+ 404: "Negotiation or election not found"
3908
+ }
3909
+ });
3910
+ };
3911
+ var updateUserAnswers = (data) => {
3912
+ return request(OpenAPI, {
3913
+ method: "PUT",
3914
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/answers",
3915
+ path: {
3916
+ subAccountId: data.subAccountId,
3917
+ negotiationId: data.negotiationId
3918
+ },
3919
+ body: data.requestBody,
3920
+ mediaType: "application/json",
3921
+ errors: {
3922
+ 404: "Negotiation or election not found"
3923
+ }
3924
+ });
3925
+ };
3926
+ var resetUserAnswers = (data) => {
3927
+ return request(OpenAPI, {
3928
+ method: "POST",
3929
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/resetAnswers",
3930
+ path: {
3931
+ subAccountId: data.subAccountId,
3932
+ negotiationId: data.negotiationId
3933
+ },
3934
+ body: data.requestBody,
3935
+ mediaType: "application/json",
3936
+ errors: {
3937
+ 404: "Negotiation or election not found"
3938
+ }
3939
+ });
3940
+ };
3941
+ var cancelExtraction = (data) => {
3942
+ return request(OpenAPI, {
3943
+ method: "PUT",
3944
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/cancel",
3945
+ path: {
3946
+ subAccountId: data.subAccountId,
3947
+ negotiationId: data.negotiationId
3948
+ },
3949
+ errors: {
3950
+ 403: "Extraction has not started for the negotiation or has already been accepted"
3951
+ }
3952
+ });
3953
+ };
3954
+ var applyExtractedAnswers = (data) => {
3955
+ return request(OpenAPI, {
3956
+ method: "PUT",
3957
+ url: "/api/v1/subAccounts/{subAccountId}/negotiations/{negotiationId}/extraction/apply",
3958
+ path: {
3959
+ subAccountId: data.subAccountId,
3960
+ negotiationId: data.negotiationId
3961
+ },
3962
+ errors: {
3963
+ 403: "Extraction has not started for the negotiation or has already been accepted"
3964
+ }
3965
+ });
3966
+ };
3967
+ export {
3968
+ ApiError,
3969
+ CancelError,
3970
+ CancelablePromise,
3971
+ OpenAPI,
3972
+ acceptAllCounterpartyPositions,
3973
+ acceptAllCustodianTemplatePositions,
3974
+ acceptAllPositionsFromFork,
3975
+ acceptAllPositionsFromPreviousVersion,
3976
+ acceptAllPresetPositions,
3977
+ acceptCounterpartyPosition,
3978
+ acceptNestedAnswersCounterpartyPosition,
3979
+ accountSummary,
3980
+ addApprovalComment,
3981
+ addComment,
3982
+ addElectionApproval,
3983
+ addElectionRejection,
3984
+ addWatchers,
3985
+ applyExtractedAnswers,
3986
+ approveFinalDocument,
3987
+ assignEntity,
3988
+ assignToMe,
3989
+ assignUser,
3990
+ auditTrailFilters,
3991
+ auditTrailForAccountAsExcel,
3992
+ auditTrailForAccountAsJson,
3993
+ auditTrailForSubAccountAsExcel,
3994
+ auditTrailForSubAccountAsJson,
3995
+ authPing,
3996
+ breakingChanges,
3997
+ bulkSetsJobCount,
3998
+ cancel,
3999
+ cancelExtraction,
4000
+ cancelNegotiations,
4001
+ cancelNegotiationsJobCount,
4002
+ changeSigningMode,
4003
+ checkAuxiliaryDocument,
4004
+ checkOfflineNegotiatedDocument,
4005
+ checkSignedExecutedVersion,
4006
+ checkSignedSignaturePagePdf,
4007
+ clonePreset,
4008
+ confirm,
4009
+ confirmExecutionVersion,
4010
+ consentCodeCallback,
4011
+ createAuditTrailJson,
4012
+ createAuditTrailPdf,
4013
+ createAuditTrailXlsx,
4014
+ createBulkSet,
4015
+ createGroup,
4016
+ createNegotiation,
4017
+ createPreset,
4018
+ createPresetAuditTrailJson,
4019
+ createPresetAuditTrailXlsx,
4020
+ createSignaturePagePdf,
4021
+ createSigningPack,
4022
+ deleteApprovalComment,
4023
+ deleteAuxiliaryDocument,
4024
+ deleteBulkSetAttachment,
4025
+ deleteComment,
4026
+ deleteCoverNote,
4027
+ deleteDocumentDraftingNote,
4028
+ deleteDocumentElectionDraftingNote,
4029
+ deleteDraftingNotesDocument,
4030
+ deleteEntity,
4031
+ deleteExecutionAttachment,
4032
+ deleteExternalAttachment,
4033
+ deleteGeneralCoverNote,
4034
+ deleteOfflineNegotiatedDocument,
4035
+ deletePreset,
4036
+ deleteSignedExecutedVersion,
4037
+ deleteSignedSignaturePageForParty,
4038
+ documentRenderTemplate,
4039
+ documentsFilter,
4040
+ downloadActiveNegotiationsReportAsExcel,
4041
+ downloadDashboardReportAsExcel,
4042
+ downloadExecutedNegotiationsAsExcel,
4043
+ downloadNegotiation,
4044
+ downloadPostExecutionPack,
4045
+ downloadPreExecutionCounterpartyNegotiation,
4046
+ downloadPreset,
4047
+ editAnswers,
4048
+ editApprovalComment,
4049
+ editDefaultAnswers,
4050
+ emailPreferences,
4051
+ extendWindow,
4052
+ forkNegotiation,
4053
+ generateAndMaybeSendEnvelope,
4054
+ getAccessibleNegotiation,
4055
+ getAccountRelationshipSummaries,
4056
+ getAllNegotiationCommentsForSubAccount,
4057
+ getAllVersions,
4058
+ getAmendDefaults,
4059
+ getAnnotatedOfflineNegotiatedDocument,
4060
+ getApprovalComments,
4061
+ getApprovalHistory,
4062
+ getApprovalRound,
4063
+ getAsCdm,
4064
+ getAuxiliaryDocument,
4065
+ getBulkSet,
4066
+ getBulkSetAttachment,
4067
+ getChannelTimeline,
4068
+ getCommentSummary,
4069
+ getComments,
4070
+ getCompanyByEntityId,
4071
+ getDocument,
4072
+ getDocumentSchema,
4073
+ getDownloadActiveNegotiationsReportAsExcel,
4074
+ getDownloadExecutedNegotiationsAsExcel,
4075
+ getDraftingNotes,
4076
+ getDraftingNotesDocument,
4077
+ getElectionAnswer,
4078
+ getExecutedNegotiationSummary,
4079
+ getExecutionAttachment,
4080
+ getExternalAttachment,
4081
+ getExtractionResults,
4082
+ getGroupNames,
4083
+ getLatestDocumentSchema,
4084
+ getLegacyStatistics,
4085
+ getMajorVersions,
4086
+ getMultipleNestedAnswers,
4087
+ getNegotiation,
4088
+ getNegotiationDeltas,
4089
+ getNegotiationDraftingNotes,
4090
+ getNegotiationESignStatus,
4091
+ getNegotiationFilesSummary,
4092
+ getNegotiationsGroup,
4093
+ getNestedAnswers,
4094
+ getOfflineNegotiatedDocument,
4095
+ getOfflineNegotiatedDocumentAnnotations,
4096
+ getOriginalAnswersForForkNegotiation,
4097
+ getOtherPartyAnswers,
4098
+ getPartyAnswers,
4099
+ getPreset,
4100
+ getPreviousActiveUsers,
4101
+ getPreviousMajorVersionsNestedAnswerElections,
4102
+ getPreviousMajorVersionsNestedAnswerIds,
4103
+ getProfile,
4104
+ getSecurityContext,
4105
+ getSettings,
4106
+ getSignedExecutedVersion,
4107
+ getSignedSignaturePagePdf,
4108
+ getSsoConfig,
4109
+ getStatistics,
4110
+ getStatisticsOverview,
4111
+ getSubAccount,
4112
+ getTimeline,
4113
+ getTimelineActivity,
4114
+ getUserStatistics,
4115
+ getUsers,
4116
+ getUsersForPicker,
4117
+ getWatchers,
4118
+ getWindow,
4119
+ grantAllNegotiationsAccess,
4120
+ grantNegotiationsAccess,
4121
+ grantPresetsAccess,
4122
+ grantWindow,
4123
+ initialAnswers,
4124
+ listAdvisorsForWorkspace,
4125
+ listAllPresetsForSubAccountV1,
4126
+ listAllPresetsForSubAccountV2,
4127
+ listBulkSets,
4128
+ listDocuments,
4129
+ listDocumentsVersionsSummary,
4130
+ listDocumentsWithPagination,
4131
+ listEntities,
4132
+ listExecutionAttachments,
4133
+ listExternalAttachments,
4134
+ listNegotiations,
4135
+ listPotentialNegotiationAdvisors,
4136
+ listPotentialPresetAdvisors,
4137
+ listPresets,
4138
+ listSubAccounts,
4139
+ markActivityEventsAsViewed,
4140
+ markApprovalCommentsAsViewed,
4141
+ markAsFinal,
4142
+ markAsOffline,
4143
+ markCommentEventsAsViewed,
4144
+ markEventsAsViewed,
4145
+ moveEntity,
4146
+ negotiationForkHistory,
4147
+ negotiationGetDocumentSchema,
4148
+ negotiationRenderTemplate,
4149
+ negotiationSendForApproval,
4150
+ negotiationsFilter,
4151
+ notifyOfDraft,
4152
+ obtainConsent,
4153
+ overrideApproveFinalDocument,
4154
+ overrideElectionApproval,
4155
+ overrideElectionRejection,
4156
+ overrideRejectFinalDocument,
4157
+ patchEmailPreferences,
4158
+ presetEditAnswers,
4159
+ presetGetDocumentSchema,
4160
+ presetGetMultipleNestedAnswers,
4161
+ presetGetNestedAnswers,
4162
+ presetRenderTemplate,
4163
+ presetSendForApproval,
4164
+ presetSetElectionApproval,
4165
+ presetSetFinalApproval,
4166
+ presetSetMultipleNestedAnswers,
4167
+ presetSetNestedAnswers,
4168
+ presetSwapParties,
4169
+ queueGenerateNegotiationDocumentJob,
4170
+ rejectFinalDocument,
4171
+ removeWatchers,
4172
+ renameExecutionAttachment,
4173
+ resetUserAnswers,
4174
+ retract,
4175
+ revertToAmending,
4176
+ revokeNegotiationsAccess,
4177
+ revokePresetsAccess,
4178
+ revokeWindow,
4179
+ scheduleExtraction,
4180
+ schemaAvailableAsCdm,
4181
+ searchEntity,
4182
+ sendBulkSetToCounterpartiesInitial,
4183
+ sendChaserEmail,
4184
+ sendDocumentApprovalReminder,
4185
+ sendElectionApprovalReminder,
4186
+ sendGroupToCounterparty,
4187
+ sendToCounterparty,
4188
+ sendToCounterpartyInitial,
4189
+ setAuxiliaryDocument,
4190
+ setBulkSetAttachments,
4191
+ setCounterparties,
4192
+ setElectionApproval,
4193
+ setExecutionAttachment,
4194
+ setExecutionAttachments,
4195
+ setExternalAttachment,
4196
+ setExternalAttachments,
4197
+ setFinalApproval,
4198
+ setGeneralCoverNote,
4199
+ setMultipleNestedAnswers,
4200
+ setNestedAnswers,
4201
+ setOfflineNegotiatedDocument,
4202
+ setOwnerEntity,
4203
+ setPreset,
4204
+ setReceiverEntity,
4205
+ setSignedExecutedVersion,
4206
+ setSignedSignaturePageForParty,
4207
+ suggestGroupName,
4208
+ swapParties,
4209
+ unsubscribe,
4210
+ updateAttachDocx,
4211
+ updateComment,
4212
+ updateCoverNote,
4213
+ updateCustomFields,
4214
+ updateDocumentDraftingNote,
4215
+ updateDocumentElectionDraftingNote,
4216
+ updateDraftingNotes,
4217
+ updateExtractionFeedback,
4218
+ updateGroupMembers,
4219
+ updateGroupName,
4220
+ updateMetadata,
4221
+ updateNegotiationsToMatch,
4222
+ updateSelectedElections,
4223
+ updateSubAccount,
4224
+ updateUserAnswers,
4225
+ upgradePresetSchema,
4226
+ upgradeSchema,
4227
+ usersWithNegotiationAccess,
4228
+ validateDraftReceiverEmails,
4229
+ validateEntities,
4230
+ version,
4231
+ voidESignEnvelopeForNegotiation
4232
+ };
4233
+ //# sourceMappingURL=index.js.map