@breign/client 1.0.57 → 1.0.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/apis/AppApi.d.ts +48 -1
  2. package/dist/apis/AppApi.js +110 -0
  3. package/dist/apis/ConversationsApi.d.ts +5 -5
  4. package/dist/apis/ConversationsApi.js +4 -3
  5. package/dist/models/AttachmentCreateRequestUio.d.ts +5 -39
  6. package/dist/models/AttachmentCreateRequestUio.js +22 -32
  7. package/dist/models/AttachmentCreateResponseUio.d.ts +24 -0
  8. package/dist/models/AttachmentCreateResponseUio.js +64 -0
  9. package/dist/models/AttachmentDetailsResponseUio.d.ts +23 -0
  10. package/dist/models/AttachmentDetailsResponseUio.js +57 -0
  11. package/dist/models/AttachmentTypeUio.d.ts +1 -0
  12. package/dist/models/AttachmentTypeUio.js +2 -1
  13. package/dist/models/AudioFillerExistsResponseUio.d.ts +32 -0
  14. package/dist/models/AudioFillerExistsResponseUio.js +50 -0
  15. package/dist/models/ChatContextAttachmentUio.d.ts +23 -0
  16. package/dist/models/ChatContextAttachmentUio.js +57 -0
  17. package/dist/models/ContextUio.d.ts +3 -3
  18. package/dist/models/ContextUio.js +3 -3
  19. package/dist/models/FileAttachmentCreateRequestUio.d.ts +63 -0
  20. package/dist/models/FileAttachmentCreateRequestUio.js +73 -0
  21. package/dist/models/FileAttachmentDetailsResponseUio.d.ts +89 -0
  22. package/dist/models/FileAttachmentDetailsResponseUio.js +85 -0
  23. package/dist/models/FileAttachmentProcessedOneOfUio.d.ts +9 -3
  24. package/dist/models/FileAttachmentProcessedOneOfUio.js +9 -3
  25. package/dist/models/FileAttachmentUio.d.ts +1 -1
  26. package/dist/models/FileAttachmentUploadResponseUio.d.ts +103 -0
  27. package/dist/models/FileAttachmentUploadResponseUio.js +93 -0
  28. package/dist/models/ImageAttachment1Uio.d.ts +94 -0
  29. package/dist/models/ImageAttachment1Uio.js +90 -0
  30. package/dist/models/ImageAttachmentCreateRequestUio.d.ts +69 -0
  31. package/dist/models/ImageAttachmentCreateRequestUio.js +75 -0
  32. package/dist/models/ImageAttachmentDetailsResponseUio.d.ts +94 -0
  33. package/dist/models/ImageAttachmentDetailsResponseUio.js +90 -0
  34. package/dist/models/ImageAttachmentUio.d.ts +94 -0
  35. package/dist/models/ImageAttachmentUio.js +90 -0
  36. package/dist/models/ImageAttachmentUploadResponseUio.d.ts +108 -0
  37. package/dist/models/ImageAttachmentUploadResponseUio.js +98 -0
  38. package/dist/models/index.d.ts +12 -0
  39. package/dist/models/index.js +12 -0
  40. package/dist/openapi.json +425 -6
  41. package/package.json +1 -1
@@ -10,12 +10,17 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AppChatCreateRequestUio, AppChatCreateResponseUio, AppChatSayRequestUio, AppChatSayResponseUio, AppChatSubmitMessageRequestUio, AppConfigurationUio, AppConfigurationUpdateRequestUio, AppCreateRequestUio, AppFlowCreateRequestUio, AppInstanceCreateRequestUio, AppLightUio, AppProbeRequestUio, AppProbeResponseUio, AppStatusRequestUio, AppStatusResponseUio, AppSubmitMessageRequestUio, AppTextToSpeechRequestUio, AppTextToSpeechResponseUio, AppUio, AppUpdateRequestUio, BodyWithIdUio, FileCreationRequestUio, FileCreationResponseUio, FlowUio, S3UploadBodyUio } from '../models/index';
13
+ import type { AppChatCreateRequestUio, AppChatCreateResponseUio, AppChatSayRequestUio, AppChatSayResponseUio, AppChatSubmitMessageRequestUio, AppConfigurationUio, AppConfigurationUpdateRequestUio, AppCreateRequestUio, AppFlowCreateRequestUio, AppInstanceCreateRequestUio, AppLightUio, AppProbeRequestUio, AppProbeResponseUio, AppStatusRequestUio, AppStatusResponseUio, AppSubmitMessageRequestUio, AppTextToSpeechRequestUio, AppTextToSpeechResponseUio, AppUio, AppUpdateRequestUio, AudioFileUio, AudioFillerExistsResponseUio, BodyWithIdUio, FileCreationRequestUio, FileCreationResponseUio, FlowUio, S3UploadBodyUio } from '../models/index';
14
14
  export interface AddAppConfigurationFileRequest {
15
15
  appId: string;
16
16
  type: string;
17
17
  fileCreationRequestUio: FileCreationRequestUio;
18
18
  }
19
+ export interface CheckAudioFillerExistsRequest {
20
+ appId: string;
21
+ lang?: string;
22
+ fillersIds?: string;
23
+ }
19
24
  export interface CreateAppRequest {
20
25
  appCreateRequestUio: AppCreateRequestUio;
21
26
  instanceId?: string;
@@ -41,6 +46,12 @@ export interface DeleteAppConfigurationRequest {
41
46
  appId: string;
42
47
  instanceId?: string;
43
48
  }
49
+ export interface DeleteDefaultFillerRequest {
50
+ appId: string;
51
+ voiceId: string;
52
+ language: string;
53
+ fillerId: string;
54
+ }
44
55
  export interface GetAppByIdRequest {
45
56
  appId: string;
46
57
  }
@@ -59,6 +70,12 @@ export interface GetAppProbeRequest {
59
70
  export interface GetAppsForAgentIdRequest {
60
71
  agentId: string;
61
72
  }
73
+ export interface GetAudioFillerByIdRequest {
74
+ appId: string;
75
+ voiceId: string;
76
+ language: string;
77
+ fillerId: string;
78
+ }
62
79
  export interface InterruptAppRequest {
63
80
  appId: string;
64
81
  instanceId?: string;
@@ -123,6 +140,16 @@ export declare class AppApi extends runtime.BaseAPI {
123
140
  * Add file to app configuration
124
141
  */
125
142
  addAppConfigurationFile(appId: string, type: string, fileCreationRequestUio: FileCreationRequestUio, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<FileCreationResponseUio>;
143
+ /**
144
+ * Check if audio filler exists
145
+ * Check if audio filler exists
146
+ */
147
+ checkAudioFillerExistsRaw(requestParameters: CheckAudioFillerExistsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AudioFillerExistsResponseUio>>;
148
+ /**
149
+ * Check if audio filler exists
150
+ * Check if audio filler exists
151
+ */
152
+ checkAudioFillerExists(appId: string, lang?: string, fillersIds?: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AudioFillerExistsResponseUio>;
126
153
  /**
127
154
  * Creates a new app
128
155
  * Create an app
@@ -183,6 +210,16 @@ export declare class AppApi extends runtime.BaseAPI {
183
210
  * Delete app configuration
184
211
  */
185
212
  deleteAppConfiguration(appId: string, instanceId?: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
213
+ /**
214
+ * Delete a default filler
215
+ * Delete a default filler
216
+ */
217
+ deleteDefaultFillerRaw(requestParameters: DeleteDefaultFillerRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
218
+ /**
219
+ * Delete a default filler
220
+ * Delete a default filler
221
+ */
222
+ deleteDefaultFiller(appId: string, voiceId: string, language: string, fillerId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
186
223
  /**
187
224
  * Get an app
188
225
  * Get an app
@@ -233,6 +270,16 @@ export declare class AppApi extends runtime.BaseAPI {
233
270
  * Get apps for agent id
234
271
  */
235
272
  getAppsForAgentId(agentId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AppLightUio>>;
273
+ /**
274
+ * Get audio filler by ID
275
+ * Get audio filler by ID
276
+ */
277
+ getAudioFillerByIdRaw(requestParameters: GetAudioFillerByIdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AudioFileUio>>;
278
+ /**
279
+ * Get audio filler by ID
280
+ * Get audio filler by ID
281
+ */
282
+ getAudioFillerById(appId: string, voiceId: string, language: string, fillerId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AudioFileUio>;
236
283
  /**
237
284
  * Interrupt app
238
285
  * Interrupt app
@@ -90,6 +90,41 @@ class AppApi extends runtime.BaseAPI {
90
90
  const response = await this.addAppConfigurationFileRaw({ appId: appId, type: type, fileCreationRequestUio: fileCreationRequestUio }, initOverrides);
91
91
  return await response.value();
92
92
  }
93
+ /**
94
+ * Check if audio filler exists
95
+ * Check if audio filler exists
96
+ */
97
+ async checkAudioFillerExistsRaw(requestParameters, initOverrides) {
98
+ if (requestParameters['appId'] == null) {
99
+ throw new runtime.RequiredError('appId', 'Required parameter "appId" was null or undefined when calling checkAudioFillerExists().');
100
+ }
101
+ const queryParameters = {};
102
+ if (requestParameters['lang'] != null) {
103
+ queryParameters['lang'] = requestParameters['lang'];
104
+ }
105
+ if (requestParameters['fillersIds'] != null) {
106
+ queryParameters['fillersIds'] = requestParameters['fillersIds'];
107
+ }
108
+ const headerParameters = {};
109
+ if (this.configuration && this.configuration.apiKey) {
110
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
111
+ }
112
+ const response = await this.request({
113
+ path: `/apps/{appId}/fillers`.replace(`{${"appId"}}`, encodeURIComponent(String(requestParameters['appId']))),
114
+ method: 'GET',
115
+ headers: headerParameters,
116
+ query: queryParameters,
117
+ }, initOverrides);
118
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.AudioFillerExistsResponseUioFromJSON)(jsonValue));
119
+ }
120
+ /**
121
+ * Check if audio filler exists
122
+ * Check if audio filler exists
123
+ */
124
+ async checkAudioFillerExists(appId, lang, fillersIds, initOverrides) {
125
+ const response = await this.checkAudioFillerExistsRaw({ appId: appId, lang: lang, fillersIds: fillersIds }, initOverrides);
126
+ return await response.value();
127
+ }
93
128
  /**
94
129
  * Creates a new app
95
130
  * Create an app
@@ -291,6 +326,43 @@ class AppApi extends runtime.BaseAPI {
291
326
  async deleteAppConfiguration(appId, instanceId, initOverrides) {
292
327
  await this.deleteAppConfigurationRaw({ appId: appId, instanceId: instanceId }, initOverrides);
293
328
  }
329
+ /**
330
+ * Delete a default filler
331
+ * Delete a default filler
332
+ */
333
+ async deleteDefaultFillerRaw(requestParameters, initOverrides) {
334
+ if (requestParameters['appId'] == null) {
335
+ throw new runtime.RequiredError('appId', 'Required parameter "appId" was null or undefined when calling deleteDefaultFiller().');
336
+ }
337
+ if (requestParameters['voiceId'] == null) {
338
+ throw new runtime.RequiredError('voiceId', 'Required parameter "voiceId" was null or undefined when calling deleteDefaultFiller().');
339
+ }
340
+ if (requestParameters['language'] == null) {
341
+ throw new runtime.RequiredError('language', 'Required parameter "language" was null or undefined when calling deleteDefaultFiller().');
342
+ }
343
+ if (requestParameters['fillerId'] == null) {
344
+ throw new runtime.RequiredError('fillerId', 'Required parameter "fillerId" was null or undefined when calling deleteDefaultFiller().');
345
+ }
346
+ const queryParameters = {};
347
+ const headerParameters = {};
348
+ if (this.configuration && this.configuration.apiKey) {
349
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
350
+ }
351
+ const response = await this.request({
352
+ path: `/apps/{appId}/voice/{voiceId}/default-fillers/{fillerId}`.replace(`{${"appId"}}`, encodeURIComponent(String(requestParameters['appId']))).replace(`{${"voiceId"}}`, encodeURIComponent(String(requestParameters['voiceId']))).replace(`{${"language"}}`, encodeURIComponent(String(requestParameters['language']))).replace(`{${"fillerId"}}`, encodeURIComponent(String(requestParameters['fillerId']))),
353
+ method: 'DELETE',
354
+ headers: headerParameters,
355
+ query: queryParameters,
356
+ }, initOverrides);
357
+ return new runtime.VoidApiResponse(response);
358
+ }
359
+ /**
360
+ * Delete a default filler
361
+ * Delete a default filler
362
+ */
363
+ async deleteDefaultFiller(appId, voiceId, language, fillerId, initOverrides) {
364
+ await this.deleteDefaultFillerRaw({ appId: appId, voiceId: voiceId, language: language, fillerId: fillerId }, initOverrides);
365
+ }
294
366
  /**
295
367
  * Get an app
296
368
  * Get an app
@@ -450,6 +522,44 @@ class AppApi extends runtime.BaseAPI {
450
522
  const response = await this.getAppsForAgentIdRaw({ agentId: agentId }, initOverrides);
451
523
  return await response.value();
452
524
  }
525
+ /**
526
+ * Get audio filler by ID
527
+ * Get audio filler by ID
528
+ */
529
+ async getAudioFillerByIdRaw(requestParameters, initOverrides) {
530
+ if (requestParameters['appId'] == null) {
531
+ throw new runtime.RequiredError('appId', 'Required parameter "appId" was null or undefined when calling getAudioFillerById().');
532
+ }
533
+ if (requestParameters['voiceId'] == null) {
534
+ throw new runtime.RequiredError('voiceId', 'Required parameter "voiceId" was null or undefined when calling getAudioFillerById().');
535
+ }
536
+ if (requestParameters['language'] == null) {
537
+ throw new runtime.RequiredError('language', 'Required parameter "language" was null or undefined when calling getAudioFillerById().');
538
+ }
539
+ if (requestParameters['fillerId'] == null) {
540
+ throw new runtime.RequiredError('fillerId', 'Required parameter "fillerId" was null or undefined when calling getAudioFillerById().');
541
+ }
542
+ const queryParameters = {};
543
+ const headerParameters = {};
544
+ if (this.configuration && this.configuration.apiKey) {
545
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
546
+ }
547
+ const response = await this.request({
548
+ path: `/apps/{appId}/languages/{language}/fillers/{fillerId}/audio`.replace(`{${"appId"}}`, encodeURIComponent(String(requestParameters['appId']))).replace(`{${"voiceId"}}`, encodeURIComponent(String(requestParameters['voiceId']))).replace(`{${"language"}}`, encodeURIComponent(String(requestParameters['language']))).replace(`{${"fillerId"}}`, encodeURIComponent(String(requestParameters['fillerId']))),
549
+ method: 'GET',
550
+ headers: headerParameters,
551
+ query: queryParameters,
552
+ }, initOverrides);
553
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.AudioFileUioFromJSON)(jsonValue));
554
+ }
555
+ /**
556
+ * Get audio filler by ID
557
+ * Get audio filler by ID
558
+ */
559
+ async getAudioFillerById(appId, voiceId, language, fillerId, initOverrides) {
560
+ const response = await this.getAudioFillerByIdRaw({ appId: appId, voiceId: voiceId, language: language, fillerId: fillerId }, initOverrides);
561
+ return await response.value();
562
+ }
453
563
  /**
454
564
  * Interrupt app
455
565
  * Interrupt app
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AttachmentCreateRequestUio, BodyWithMessageUio, ContextUio, ConversationSummaryUio, FileAttachmentUio } from '../models/index';
13
+ import type { AttachmentCreateRequestUio, AttachmentCreateResponseUio, AttachmentDetailsResponseUio, BodyWithMessageUio, ContextUio, ConversationSummaryUio } from '../models/index';
14
14
  export interface ArchiveConversationByIdRequest {
15
15
  conversationId: string;
16
16
  }
@@ -127,12 +127,12 @@ export declare class ConversationsApi extends runtime.BaseAPI {
127
127
  * Get a specific attachment by its ID from the context of a conversation.
128
128
  * Retrieve an attachment from a conversation context
129
129
  */
130
- getAttachmentRaw(requestParameters: GetAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<FileAttachmentUio>>;
130
+ getAttachmentRaw(requestParameters: GetAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AttachmentDetailsResponseUio>>;
131
131
  /**
132
132
  * Get a specific attachment by its ID from the context of a conversation.
133
133
  * Retrieve an attachment from a conversation context
134
134
  */
135
- getAttachment(conversationId: string, attachmentId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<FileAttachmentUio>;
135
+ getAttachment(conversationId: string, attachmentId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AttachmentDetailsResponseUio>;
136
136
  /**
137
137
  * Retrieve the context of a specific conversation by its ID.
138
138
  * Get the context of a conversation
@@ -181,12 +181,12 @@ export declare class ConversationsApi extends runtime.BaseAPI {
181
181
  * Upload one file attachment to the context of a specific conversation.
182
182
  * Upload attachment to a conversation context.
183
183
  */
184
- uploadAttachmentRaw(requestParameters: UploadAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
184
+ uploadAttachmentRaw(requestParameters: UploadAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AttachmentCreateResponseUio>>;
185
185
  /**
186
186
  * Upload one file attachment to the context of a specific conversation.
187
187
  * Upload attachment to a conversation context.
188
188
  */
189
- uploadAttachment(conversationId: string, attachmentCreateRequestUio: AttachmentCreateRequestUio, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
189
+ uploadAttachment(conversationId: string, attachmentCreateRequestUio: AttachmentCreateRequestUio, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AttachmentCreateResponseUio>;
190
190
  }
191
191
  /**
192
192
  * @export
@@ -260,7 +260,7 @@ class ConversationsApi extends runtime.BaseAPI {
260
260
  headers: headerParameters,
261
261
  query: queryParameters,
262
262
  }, initOverrides);
263
- return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.FileAttachmentUioFromJSON)(jsonValue));
263
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.AttachmentDetailsResponseUioFromJSON)(jsonValue));
264
264
  }
265
265
  /**
266
266
  * Get a specific attachment by its ID from the context of a conversation.
@@ -416,14 +416,15 @@ class ConversationsApi extends runtime.BaseAPI {
416
416
  query: queryParameters,
417
417
  body: (0, index_1.AttachmentCreateRequestUioToJSON)(requestParameters['attachmentCreateRequestUio']),
418
418
  }, initOverrides);
419
- return new runtime.VoidApiResponse(response);
419
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.AttachmentCreateResponseUioFromJSON)(jsonValue));
420
420
  }
421
421
  /**
422
422
  * Upload one file attachment to the context of a specific conversation.
423
423
  * Upload attachment to a conversation context.
424
424
  */
425
425
  async uploadAttachment(conversationId, attachmentCreateRequestUio, initOverrides) {
426
- await this.uploadAttachmentRaw({ conversationId: conversationId, attachmentCreateRequestUio: attachmentCreateRequestUio }, initOverrides);
426
+ const response = await this.uploadAttachmentRaw({ conversationId: conversationId, attachmentCreateRequestUio: attachmentCreateRequestUio }, initOverrides);
427
+ return await response.value();
427
428
  }
428
429
  }
429
430
  exports.ConversationsApi = ConversationsApi;
@@ -9,49 +9,15 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import type { AttachmentTypeUio } from './AttachmentTypeUio';
12
+ import type { FileAttachmentCreateRequestUio } from './FileAttachmentCreateRequestUio';
13
+ import type { ImageAttachmentCreateRequestUio } from './ImageAttachmentCreateRequestUio';
13
14
  /**
15
+ * @type AttachmentCreateRequestUio
14
16
  *
15
17
  * @export
16
- * @interface AttachmentCreateRequestUio
17
18
  */
18
- export interface AttachmentCreateRequestUio {
19
- /**
20
- *
21
- * @type {AttachmentTypeUio}
22
- * @memberof AttachmentCreateRequestUio
23
- */
24
- type: AttachmentTypeUio;
25
- /**
26
- *
27
- * @type {string}
28
- * @memberof AttachmentCreateRequestUio
29
- */
30
- name: string;
31
- /**
32
- *
33
- * @type {string}
34
- * @memberof AttachmentCreateRequestUio
35
- */
36
- mimeType: string;
37
- /**
38
- *
39
- * @type {number}
40
- * @memberof AttachmentCreateRequestUio
41
- */
42
- size: number;
43
- /**
44
- *
45
- * @type {string}
46
- * @memberof AttachmentCreateRequestUio
47
- */
48
- ext: string;
49
- }
50
- /**
51
- * Check if a given object implements the AttachmentCreateRequestUio interface.
52
- */
53
- export declare function instanceOfAttachmentCreateRequestUio(value: object): value is AttachmentCreateRequestUio;
19
+ export type AttachmentCreateRequestUio = FileAttachmentCreateRequestUio | ImageAttachmentCreateRequestUio;
54
20
  export declare function AttachmentCreateRequestUioFromJSON(json: any): AttachmentCreateRequestUio;
55
21
  export declare function AttachmentCreateRequestUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AttachmentCreateRequestUio;
56
- export declare function AttachmentCreateRequestUioToJSON(json: any): AttachmentCreateRequestUio;
22
+ export declare function AttachmentCreateRequestUioToJSON(json: any): any;
57
23
  export declare function AttachmentCreateRequestUioToJSONTyped(value?: AttachmentCreateRequestUio | null, ignoreDiscriminator?: boolean): any;
@@ -13,28 +13,12 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.instanceOfAttachmentCreateRequestUio = instanceOfAttachmentCreateRequestUio;
17
16
  exports.AttachmentCreateRequestUioFromJSON = AttachmentCreateRequestUioFromJSON;
18
17
  exports.AttachmentCreateRequestUioFromJSONTyped = AttachmentCreateRequestUioFromJSONTyped;
19
18
  exports.AttachmentCreateRequestUioToJSON = AttachmentCreateRequestUioToJSON;
20
19
  exports.AttachmentCreateRequestUioToJSONTyped = AttachmentCreateRequestUioToJSONTyped;
21
- const AttachmentTypeUio_1 = require("./AttachmentTypeUio");
22
- /**
23
- * Check if a given object implements the AttachmentCreateRequestUio interface.
24
- */
25
- function instanceOfAttachmentCreateRequestUio(value) {
26
- if (!('type' in value) || value['type'] === undefined)
27
- return false;
28
- if (!('name' in value) || value['name'] === undefined)
29
- return false;
30
- if (!('mimeType' in value) || value['mimeType'] === undefined)
31
- return false;
32
- if (!('size' in value) || value['size'] === undefined)
33
- return false;
34
- if (!('ext' in value) || value['ext'] === undefined)
35
- return false;
36
- return true;
37
- }
20
+ const FileAttachmentCreateRequestUio_1 = require("./FileAttachmentCreateRequestUio");
21
+ const ImageAttachmentCreateRequestUio_1 = require("./ImageAttachmentCreateRequestUio");
38
22
  function AttachmentCreateRequestUioFromJSON(json) {
39
23
  return AttachmentCreateRequestUioFromJSONTyped(json, false);
40
24
  }
@@ -42,13 +26,16 @@ function AttachmentCreateRequestUioFromJSONTyped(json, ignoreDiscriminator) {
42
26
  if (json == null) {
43
27
  return json;
44
28
  }
45
- return {
46
- 'type': (0, AttachmentTypeUio_1.AttachmentTypeUioFromJSON)(json['type']),
47
- 'name': json['name'],
48
- 'mimeType': json['mimeType'],
49
- 'size': json['size'],
50
- 'ext': json['ext'],
51
- };
29
+ if (typeof json !== 'object') {
30
+ return json;
31
+ }
32
+ if ((0, FileAttachmentCreateRequestUio_1.instanceOfFileAttachmentCreateRequestUio)(json)) {
33
+ return (0, FileAttachmentCreateRequestUio_1.FileAttachmentCreateRequestUioFromJSONTyped)(json, true);
34
+ }
35
+ if ((0, ImageAttachmentCreateRequestUio_1.instanceOfImageAttachmentCreateRequestUio)(json)) {
36
+ return (0, ImageAttachmentCreateRequestUio_1.ImageAttachmentCreateRequestUioFromJSONTyped)(json, true);
37
+ }
38
+ return {};
52
39
  }
53
40
  function AttachmentCreateRequestUioToJSON(json) {
54
41
  return AttachmentCreateRequestUioToJSONTyped(json, false);
@@ -57,11 +44,14 @@ function AttachmentCreateRequestUioToJSONTyped(value, ignoreDiscriminator = fals
57
44
  if (value == null) {
58
45
  return value;
59
46
  }
60
- return {
61
- 'type': (0, AttachmentTypeUio_1.AttachmentTypeUioToJSON)(value['type']),
62
- 'name': value['name'],
63
- 'mimeType': value['mimeType'],
64
- 'size': value['size'],
65
- 'ext': value['ext'],
66
- };
47
+ if (typeof value !== 'object') {
48
+ return value;
49
+ }
50
+ if ((0, FileAttachmentCreateRequestUio_1.instanceOfFileAttachmentCreateRequestUio)(value)) {
51
+ return (0, FileAttachmentCreateRequestUio_1.FileAttachmentCreateRequestUioToJSON)(value);
52
+ }
53
+ if ((0, ImageAttachmentCreateRequestUio_1.instanceOfImageAttachmentCreateRequestUio)(value)) {
54
+ return (0, ImageAttachmentCreateRequestUio_1.ImageAttachmentCreateRequestUioToJSON)(value);
55
+ }
56
+ return {};
67
57
  }
@@ -0,0 +1,24 @@
1
+ /**
2
+ * brain-client
3
+ * Api ands models for brain-app and brain-app
4
+ *
5
+ * The version of the OpenAPI document: 0.0.0-SNAPSHOT
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { FileAttachmentUploadResponseUio } from './FileAttachmentUploadResponseUio';
13
+ import type { ImageAttachmentUio } from './ImageAttachmentUio';
14
+ import type { ImageAttachmentUploadResponseUio } from './ImageAttachmentUploadResponseUio';
15
+ /**
16
+ * @type AttachmentCreateResponseUio
17
+ *
18
+ * @export
19
+ */
20
+ export type AttachmentCreateResponseUio = FileAttachmentUploadResponseUio | ImageAttachmentUio | ImageAttachmentUploadResponseUio;
21
+ export declare function AttachmentCreateResponseUioFromJSON(json: any): AttachmentCreateResponseUio;
22
+ export declare function AttachmentCreateResponseUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AttachmentCreateResponseUio;
23
+ export declare function AttachmentCreateResponseUioToJSON(json: any): any;
24
+ export declare function AttachmentCreateResponseUioToJSONTyped(value?: AttachmentCreateResponseUio | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,64 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * brain-client
6
+ * Api ands models for brain-app and brain-app
7
+ *
8
+ * The version of the OpenAPI document: 0.0.0-SNAPSHOT
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.AttachmentCreateResponseUioFromJSON = AttachmentCreateResponseUioFromJSON;
17
+ exports.AttachmentCreateResponseUioFromJSONTyped = AttachmentCreateResponseUioFromJSONTyped;
18
+ exports.AttachmentCreateResponseUioToJSON = AttachmentCreateResponseUioToJSON;
19
+ exports.AttachmentCreateResponseUioToJSONTyped = AttachmentCreateResponseUioToJSONTyped;
20
+ const FileAttachmentUploadResponseUio_1 = require("./FileAttachmentUploadResponseUio");
21
+ const ImageAttachmentUio_1 = require("./ImageAttachmentUio");
22
+ const ImageAttachmentUploadResponseUio_1 = require("./ImageAttachmentUploadResponseUio");
23
+ function AttachmentCreateResponseUioFromJSON(json) {
24
+ return AttachmentCreateResponseUioFromJSONTyped(json, false);
25
+ }
26
+ function AttachmentCreateResponseUioFromJSONTyped(json, ignoreDiscriminator) {
27
+ if (json == null) {
28
+ return json;
29
+ }
30
+ if (typeof json !== 'object') {
31
+ return json;
32
+ }
33
+ if ((0, FileAttachmentUploadResponseUio_1.instanceOfFileAttachmentUploadResponseUio)(json)) {
34
+ return (0, FileAttachmentUploadResponseUio_1.FileAttachmentUploadResponseUioFromJSONTyped)(json, true);
35
+ }
36
+ if ((0, ImageAttachmentUio_1.instanceOfImageAttachmentUio)(json)) {
37
+ return (0, ImageAttachmentUio_1.ImageAttachmentUioFromJSONTyped)(json, true);
38
+ }
39
+ if ((0, ImageAttachmentUploadResponseUio_1.instanceOfImageAttachmentUploadResponseUio)(json)) {
40
+ return (0, ImageAttachmentUploadResponseUio_1.ImageAttachmentUploadResponseUioFromJSONTyped)(json, true);
41
+ }
42
+ return {};
43
+ }
44
+ function AttachmentCreateResponseUioToJSON(json) {
45
+ return AttachmentCreateResponseUioToJSONTyped(json, false);
46
+ }
47
+ function AttachmentCreateResponseUioToJSONTyped(value, ignoreDiscriminator = false) {
48
+ if (value == null) {
49
+ return value;
50
+ }
51
+ if (typeof value !== 'object') {
52
+ return value;
53
+ }
54
+ if ((0, FileAttachmentUploadResponseUio_1.instanceOfFileAttachmentUploadResponseUio)(value)) {
55
+ return (0, FileAttachmentUploadResponseUio_1.FileAttachmentUploadResponseUioToJSON)(value);
56
+ }
57
+ if ((0, ImageAttachmentUio_1.instanceOfImageAttachmentUio)(value)) {
58
+ return (0, ImageAttachmentUio_1.ImageAttachmentUioToJSON)(value);
59
+ }
60
+ if ((0, ImageAttachmentUploadResponseUio_1.instanceOfImageAttachmentUploadResponseUio)(value)) {
61
+ return (0, ImageAttachmentUploadResponseUio_1.ImageAttachmentUploadResponseUioToJSON)(value);
62
+ }
63
+ return {};
64
+ }
@@ -0,0 +1,23 @@
1
+ /**
2
+ * brain-client
3
+ * Api ands models for brain-app and brain-app
4
+ *
5
+ * The version of the OpenAPI document: 0.0.0-SNAPSHOT
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { FileAttachmentDetailsResponseUio } from './FileAttachmentDetailsResponseUio';
13
+ import type { ImageAttachmentDetailsResponseUio } from './ImageAttachmentDetailsResponseUio';
14
+ /**
15
+ * @type AttachmentDetailsResponseUio
16
+ *
17
+ * @export
18
+ */
19
+ export type AttachmentDetailsResponseUio = FileAttachmentDetailsResponseUio | ImageAttachmentDetailsResponseUio;
20
+ export declare function AttachmentDetailsResponseUioFromJSON(json: any): AttachmentDetailsResponseUio;
21
+ export declare function AttachmentDetailsResponseUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AttachmentDetailsResponseUio;
22
+ export declare function AttachmentDetailsResponseUioToJSON(json: any): any;
23
+ export declare function AttachmentDetailsResponseUioToJSONTyped(value?: AttachmentDetailsResponseUio | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,57 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * brain-client
6
+ * Api ands models for brain-app and brain-app
7
+ *
8
+ * The version of the OpenAPI document: 0.0.0-SNAPSHOT
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.AttachmentDetailsResponseUioFromJSON = AttachmentDetailsResponseUioFromJSON;
17
+ exports.AttachmentDetailsResponseUioFromJSONTyped = AttachmentDetailsResponseUioFromJSONTyped;
18
+ exports.AttachmentDetailsResponseUioToJSON = AttachmentDetailsResponseUioToJSON;
19
+ exports.AttachmentDetailsResponseUioToJSONTyped = AttachmentDetailsResponseUioToJSONTyped;
20
+ const FileAttachmentDetailsResponseUio_1 = require("./FileAttachmentDetailsResponseUio");
21
+ const ImageAttachmentDetailsResponseUio_1 = require("./ImageAttachmentDetailsResponseUio");
22
+ function AttachmentDetailsResponseUioFromJSON(json) {
23
+ return AttachmentDetailsResponseUioFromJSONTyped(json, false);
24
+ }
25
+ function AttachmentDetailsResponseUioFromJSONTyped(json, ignoreDiscriminator) {
26
+ if (json == null) {
27
+ return json;
28
+ }
29
+ if (typeof json !== 'object') {
30
+ return json;
31
+ }
32
+ if ((0, FileAttachmentDetailsResponseUio_1.instanceOfFileAttachmentDetailsResponseUio)(json)) {
33
+ return (0, FileAttachmentDetailsResponseUio_1.FileAttachmentDetailsResponseUioFromJSONTyped)(json, true);
34
+ }
35
+ if ((0, ImageAttachmentDetailsResponseUio_1.instanceOfImageAttachmentDetailsResponseUio)(json)) {
36
+ return (0, ImageAttachmentDetailsResponseUio_1.ImageAttachmentDetailsResponseUioFromJSONTyped)(json, true);
37
+ }
38
+ return {};
39
+ }
40
+ function AttachmentDetailsResponseUioToJSON(json) {
41
+ return AttachmentDetailsResponseUioToJSONTyped(json, false);
42
+ }
43
+ function AttachmentDetailsResponseUioToJSONTyped(value, ignoreDiscriminator = false) {
44
+ if (value == null) {
45
+ return value;
46
+ }
47
+ if (typeof value !== 'object') {
48
+ return value;
49
+ }
50
+ if ((0, FileAttachmentDetailsResponseUio_1.instanceOfFileAttachmentDetailsResponseUio)(value)) {
51
+ return (0, FileAttachmentDetailsResponseUio_1.FileAttachmentDetailsResponseUioToJSON)(value);
52
+ }
53
+ if ((0, ImageAttachmentDetailsResponseUio_1.instanceOfImageAttachmentDetailsResponseUio)(value)) {
54
+ return (0, ImageAttachmentDetailsResponseUio_1.ImageAttachmentDetailsResponseUioToJSON)(value);
55
+ }
56
+ return {};
57
+ }
@@ -15,6 +15,7 @@
15
15
  */
16
16
  export declare const AttachmentTypeUio: {
17
17
  readonly File: "file";
18
+ readonly Image: "image";
18
19
  };
19
20
  export type AttachmentTypeUio = typeof AttachmentTypeUio[keyof typeof AttachmentTypeUio];
20
21
  export declare function instanceOfAttachmentTypeUio(value: any): boolean;
@@ -24,7 +24,8 @@ exports.AttachmentTypeUioToJSONTyped = AttachmentTypeUioToJSONTyped;
24
24
  * @export
25
25
  */
26
26
  exports.AttachmentTypeUio = {
27
- File: 'file'
27
+ File: 'file',
28
+ Image: 'image'
28
29
  };
29
30
  function instanceOfAttachmentTypeUio(value) {
30
31
  for (const key in exports.AttachmentTypeUio) {
@@ -0,0 +1,32 @@
1
+ /**
2
+ * brain-client
3
+ * Api ands models for brain-app and brain-app
4
+ *
5
+ * The version of the OpenAPI document: 0.0.0-SNAPSHOT
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface AudioFillerExistsResponseUio
16
+ */
17
+ export interface AudioFillerExistsResponseUio {
18
+ /**
19
+ *
20
+ * @type {boolean}
21
+ * @memberof AudioFillerExistsResponseUio
22
+ */
23
+ _exists: boolean;
24
+ }
25
+ /**
26
+ * Check if a given object implements the AudioFillerExistsResponseUio interface.
27
+ */
28
+ export declare function instanceOfAudioFillerExistsResponseUio(value: object): value is AudioFillerExistsResponseUio;
29
+ export declare function AudioFillerExistsResponseUioFromJSON(json: any): AudioFillerExistsResponseUio;
30
+ export declare function AudioFillerExistsResponseUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AudioFillerExistsResponseUio;
31
+ export declare function AudioFillerExistsResponseUioToJSON(json: any): AudioFillerExistsResponseUio;
32
+ export declare function AudioFillerExistsResponseUioToJSONTyped(value?: AudioFillerExistsResponseUio | null, ignoreDiscriminator?: boolean): any;