@breign/client 1.0.89 → 1.0.90

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.
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AdvancedFlowEditorUio, AdvancedFlowEditorUpdateRequestUio, AgentDuplicateRequestUio, AgentFlowCreateUio, AgentFlowUio, AgentMetricsEventUio, AgentMetricsOverviewUio, AgentModuleUio, AgentPatchUio, AgentRequestUio, AgentSubscriptionUio, AgentUio, AgentUsageMetricsUio, BodyWithIdUio, ChatUio, FileCreationRequestUio, FileCreationResponseUio, FlowEditorUio, FlowEditorUpdateRequestUio, S3UploadBodyUio } from '../models/index';
13
+ import type { AdvancedFlowEditorUio, AdvancedFlowEditorUpdateRequestUio, AgentDuplicateRequestUio, AgentFlowCreateUio, AgentFlowUio, AgentMetricsEventUio, AgentMetricsOverviewUio, AgentModuleUio, AgentPatchUio, AgentRequestUio, AgentSubscriptionUio, AgentUio, AgentUsageMetricsUio, BodyWithIdUio, ChatUio, DeleteMessageAudio200ResponseUio, FileCreationRequestUio, FileCreationResponseUio, FlowEditorUio, FlowEditorUpdateRequestUio, MessageAudioDownloadUrlUio, S3UploadBodyUio } from '../models/index';
14
14
  export interface AddModuleRequest {
15
15
  agentId: string;
16
16
  agentModuleUio: AgentModuleUio;
@@ -29,6 +29,10 @@ export interface DeleteFlowRequest {
29
29
  agentId: string;
30
30
  flowId: string;
31
31
  }
32
+ export interface DeleteMessageAudioRequest {
33
+ agentId: string;
34
+ audioFileId: string;
35
+ }
32
36
  export interface DeleteModuleRequest {
33
37
  agentId: string;
34
38
  moduleName: string;
@@ -77,6 +81,10 @@ export interface GetFlowEditorRequest {
77
81
  export interface GetFlowsRequest {
78
82
  agentId: string;
79
83
  }
84
+ export interface GetMessageAudioDownloadUrlRequest {
85
+ agentId: string;
86
+ audioFileId: string;
87
+ }
80
88
  export interface GetModulesRequest {
81
89
  agentId: string;
82
90
  }
@@ -186,6 +194,16 @@ export declare class AgentApi extends runtime.BaseAPI {
186
194
  * Delete a flow
187
195
  */
188
196
  deleteFlow(agentId: string, flowId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
197
+ /**
198
+ * Removes the audio chunk from the message in the database and deletes the file from object storage.
199
+ * Delete a conversation message audio file
200
+ */
201
+ deleteMessageAudioRaw(requestParameters: DeleteMessageAudioRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DeleteMessageAudio200ResponseUio>>;
202
+ /**
203
+ * Removes the audio chunk from the message in the database and deletes the file from object storage.
204
+ * Delete a conversation message audio file
205
+ */
206
+ deleteMessageAudio(agentId: string, audioFileId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DeleteMessageAudio200ResponseUio>;
189
207
  /**
190
208
  * Deletes a specific module from the agent
191
209
  * Remove a module from an agent
@@ -302,6 +320,16 @@ export declare class AgentApi extends runtime.BaseAPI {
302
320
  * Get all flows for an agent
303
321
  */
304
322
  getFlows(agentId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AgentFlowUio>>;
323
+ /**
324
+ * Returns a short-lived presigned URL for a message audio chunk (`audio/{audioFileId}/input.mp3`). Call this when the user plays audio in conversation history, not when listing conversations.
325
+ * Get presigned download URL for a conversation message audio
326
+ */
327
+ getMessageAudioDownloadUrlRaw(requestParameters: GetMessageAudioDownloadUrlRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<MessageAudioDownloadUrlUio>>;
328
+ /**
329
+ * Returns a short-lived presigned URL for a message audio chunk (`audio/{audioFileId}/input.mp3`). Call this when the user plays audio in conversation history, not when listing conversations.
330
+ * Get presigned download URL for a conversation message audio
331
+ */
332
+ getMessageAudioDownloadUrl(agentId: string, audioFileId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<MessageAudioDownloadUrlUio>;
305
333
  /**
306
334
  * Retrieves all modules for a specific agent
307
335
  * Get agent modules
@@ -211,6 +211,38 @@ class AgentApi extends runtime.BaseAPI {
211
211
  async deleteFlow(agentId, flowId, initOverrides) {
212
212
  await this.deleteFlowRaw({ agentId: agentId, flowId: flowId }, initOverrides);
213
213
  }
214
+ /**
215
+ * Removes the audio chunk from the message in the database and deletes the file from object storage.
216
+ * Delete a conversation message audio file
217
+ */
218
+ async deleteMessageAudioRaw(requestParameters, initOverrides) {
219
+ if (requestParameters['agentId'] == null) {
220
+ throw new runtime.RequiredError('agentId', 'Required parameter "agentId" was null or undefined when calling deleteMessageAudio().');
221
+ }
222
+ if (requestParameters['audioFileId'] == null) {
223
+ throw new runtime.RequiredError('audioFileId', 'Required parameter "audioFileId" was null or undefined when calling deleteMessageAudio().');
224
+ }
225
+ const queryParameters = {};
226
+ const headerParameters = {};
227
+ if (this.configuration && this.configuration.apiKey) {
228
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
229
+ }
230
+ const response = await this.request({
231
+ path: `/agents/{agentId}/message-audio/{audioFileId}`.replace(`{${"agentId"}}`, encodeURIComponent(String(requestParameters['agentId']))).replace(`{${"audioFileId"}}`, encodeURIComponent(String(requestParameters['audioFileId']))),
232
+ method: 'DELETE',
233
+ headers: headerParameters,
234
+ query: queryParameters,
235
+ }, initOverrides);
236
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.DeleteMessageAudio200ResponseUioFromJSON)(jsonValue));
237
+ }
238
+ /**
239
+ * Removes the audio chunk from the message in the database and deletes the file from object storage.
240
+ * Delete a conversation message audio file
241
+ */
242
+ async deleteMessageAudio(agentId, audioFileId, initOverrides) {
243
+ const response = await this.deleteMessageAudioRaw({ agentId: agentId, audioFileId: audioFileId }, initOverrides);
244
+ return await response.value();
245
+ }
214
246
  /**
215
247
  * Deletes a specific module from the agent
216
248
  * Remove a module from an agent
@@ -592,6 +624,38 @@ class AgentApi extends runtime.BaseAPI {
592
624
  const response = await this.getFlowsRaw({ agentId: agentId }, initOverrides);
593
625
  return await response.value();
594
626
  }
627
+ /**
628
+ * Returns a short-lived presigned URL for a message audio chunk (`audio/{audioFileId}/input.mp3`). Call this when the user plays audio in conversation history, not when listing conversations.
629
+ * Get presigned download URL for a conversation message audio
630
+ */
631
+ async getMessageAudioDownloadUrlRaw(requestParameters, initOverrides) {
632
+ if (requestParameters['agentId'] == null) {
633
+ throw new runtime.RequiredError('agentId', 'Required parameter "agentId" was null or undefined when calling getMessageAudioDownloadUrl().');
634
+ }
635
+ if (requestParameters['audioFileId'] == null) {
636
+ throw new runtime.RequiredError('audioFileId', 'Required parameter "audioFileId" was null or undefined when calling getMessageAudioDownloadUrl().');
637
+ }
638
+ const queryParameters = {};
639
+ const headerParameters = {};
640
+ if (this.configuration && this.configuration.apiKey) {
641
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
642
+ }
643
+ const response = await this.request({
644
+ path: `/agents/{agentId}/message-audio/{audioFileId}/download-url`.replace(`{${"agentId"}}`, encodeURIComponent(String(requestParameters['agentId']))).replace(`{${"audioFileId"}}`, encodeURIComponent(String(requestParameters['audioFileId']))),
645
+ method: 'GET',
646
+ headers: headerParameters,
647
+ query: queryParameters,
648
+ }, initOverrides);
649
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.MessageAudioDownloadUrlUioFromJSON)(jsonValue));
650
+ }
651
+ /**
652
+ * Returns a short-lived presigned URL for a message audio chunk (`audio/{audioFileId}/input.mp3`). Call this when the user plays audio in conversation history, not when listing conversations.
653
+ * Get presigned download URL for a conversation message audio
654
+ */
655
+ async getMessageAudioDownloadUrl(agentId, audioFileId, initOverrides) {
656
+ const response = await this.getMessageAudioDownloadUrlRaw({ agentId: agentId, audioFileId: audioFileId }, initOverrides);
657
+ return await response.value();
658
+ }
595
659
  /**
596
660
  * Retrieves all modules for a specific agent
597
661
  * Get agent modules
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AnimationCreateRequestUio, AppChatCreateRequestUio, AppChatCreateResponseUio, AppChatSayRequestUio, AppChatSayResponseUio, AppChatSubmitMessageRequestUio, AppConfigurationUio, AppCreateRequestUio, AppFlowCreateRequestUio, AppInstanceCreateRequestUio, AppLightUio, AppProbeRequestUio, AppProbeResponseUio, AppStatusRequestUio, AppStatusResponseUio, AppSubmitMessageRequestUio, AppTextToSpeechRequestUio, AppTextToSpeechResponseUio, AppUio, AppUpdateRequestUio, AudioFileUio, AudioFillerExistsResponseUio, BodyWithIdUio, BodyWithMessageUio, ConversationUio, FileCreationRequestUio, FileCreationResponseUio, FillersArrayInnerUio, FlowUio, S3UploadBodyUio, SequenceCreateRequestUio } from '../models/index';
13
+ import type { AnimationCreateRequestUio, AppChatCreateRequestUio, AppChatCreateResponseUio, AppChatSayRequestUio, AppChatSayResponseUio, AppChatSubmitMessageRequestUio, AppConfigurationUio, AppCreateRequestUio, AppFlowCreateRequestUio, AppInstanceCreateRequestUio, AppLightUio, AppProbeRequestUio, AppProbeResponseUio, AppStatusRequestUio, AppStatusResponseUio, AppSubmitMessageRequestUio, AppTextToSpeechRequestUio, AppTextToSpeechResponseUio, AppUio, AppUpdateRequestUio, AudioFileUio, AudioFillerExistsResponseUio, BodyWithIdUio, BodyWithMessageUio, ConversationUio, DeleteMessageAudio200ResponseUio, FileCreationRequestUio, FileCreationResponseUio, FillersArrayInnerUio, FlowUio, S3UploadBodyUio, SequenceCreateRequestUio } from '../models/index';
14
14
  export interface AddAnimationRequest {
15
15
  appId: string;
16
16
  animationCreateRequestUio: AnimationCreateRequestUio;
@@ -56,6 +56,10 @@ export interface DeleteAppConfigurationRequest {
56
56
  appId: string;
57
57
  instanceId?: string;
58
58
  }
59
+ export interface DeleteAppMessageAudioRequest {
60
+ appId: string;
61
+ audioFileId: string;
62
+ }
59
63
  export interface DeleteDefaultFillerRequest {
60
64
  appId: string;
61
65
  voiceId: string;
@@ -253,6 +257,16 @@ export declare class AppApi extends runtime.BaseAPI {
253
257
  * Delete app configuration
254
258
  */
255
259
  deleteAppConfiguration(appId: string, instanceId?: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
260
+ /**
261
+ * Removes the audio chunk from a message in an app conversation and deletes the file from object storage.
262
+ * Delete a conversation message audio file for an app
263
+ */
264
+ deleteAppMessageAudioRaw(requestParameters: DeleteAppMessageAudioRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DeleteMessageAudio200ResponseUio>>;
265
+ /**
266
+ * Removes the audio chunk from a message in an app conversation and deletes the file from object storage.
267
+ * Delete a conversation message audio file for an app
268
+ */
269
+ deleteAppMessageAudio(appId: string, audioFileId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DeleteMessageAudio200ResponseUio>;
256
270
  /**
257
271
  * Delete a default filler
258
272
  * Delete a default filler
@@ -400,6 +400,38 @@ class AppApi extends runtime.BaseAPI {
400
400
  async deleteAppConfiguration(appId, instanceId, initOverrides) {
401
401
  await this.deleteAppConfigurationRaw({ appId: appId, instanceId: instanceId }, initOverrides);
402
402
  }
403
+ /**
404
+ * Removes the audio chunk from a message in an app conversation and deletes the file from object storage.
405
+ * Delete a conversation message audio file for an app
406
+ */
407
+ async deleteAppMessageAudioRaw(requestParameters, initOverrides) {
408
+ if (requestParameters['appId'] == null) {
409
+ throw new runtime.RequiredError('appId', 'Required parameter "appId" was null or undefined when calling deleteAppMessageAudio().');
410
+ }
411
+ if (requestParameters['audioFileId'] == null) {
412
+ throw new runtime.RequiredError('audioFileId', 'Required parameter "audioFileId" was null or undefined when calling deleteAppMessageAudio().');
413
+ }
414
+ const queryParameters = {};
415
+ const headerParameters = {};
416
+ if (this.configuration && this.configuration.apiKey) {
417
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
418
+ }
419
+ const response = await this.request({
420
+ path: `/apps/{appId}/message-audio/{audioFileId}`.replace(`{${"appId"}}`, encodeURIComponent(String(requestParameters['appId']))).replace(`{${"audioFileId"}}`, encodeURIComponent(String(requestParameters['audioFileId']))),
421
+ method: 'DELETE',
422
+ headers: headerParameters,
423
+ query: queryParameters,
424
+ }, initOverrides);
425
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.DeleteMessageAudio200ResponseUioFromJSON)(jsonValue));
426
+ }
427
+ /**
428
+ * Removes the audio chunk from a message in an app conversation and deletes the file from object storage.
429
+ * Delete a conversation message audio file for an app
430
+ */
431
+ async deleteAppMessageAudio(appId, audioFileId, initOverrides) {
432
+ const response = await this.deleteAppMessageAudioRaw({ appId: appId, audioFileId: audioFileId }, initOverrides);
433
+ return await response.value();
434
+ }
403
435
  /**
404
436
  * Delete a default filler
405
437
  * Delete a default filler
@@ -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 DeleteMessageAudio200ResponseUio
16
+ */
17
+ export interface DeleteMessageAudio200ResponseUio {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof DeleteMessageAudio200ResponseUio
22
+ */
23
+ message: string;
24
+ }
25
+ /**
26
+ * Check if a given object implements the DeleteMessageAudio200ResponseUio interface.
27
+ */
28
+ export declare function instanceOfDeleteMessageAudio200ResponseUio(value: object): value is DeleteMessageAudio200ResponseUio;
29
+ export declare function DeleteMessageAudio200ResponseUioFromJSON(json: any): DeleteMessageAudio200ResponseUio;
30
+ export declare function DeleteMessageAudio200ResponseUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): DeleteMessageAudio200ResponseUio;
31
+ export declare function DeleteMessageAudio200ResponseUioToJSON(json: any): DeleteMessageAudio200ResponseUio;
32
+ export declare function DeleteMessageAudio200ResponseUioToJSONTyped(value?: DeleteMessageAudio200ResponseUio | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,50 @@
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.instanceOfDeleteMessageAudio200ResponseUio = instanceOfDeleteMessageAudio200ResponseUio;
17
+ exports.DeleteMessageAudio200ResponseUioFromJSON = DeleteMessageAudio200ResponseUioFromJSON;
18
+ exports.DeleteMessageAudio200ResponseUioFromJSONTyped = DeleteMessageAudio200ResponseUioFromJSONTyped;
19
+ exports.DeleteMessageAudio200ResponseUioToJSON = DeleteMessageAudio200ResponseUioToJSON;
20
+ exports.DeleteMessageAudio200ResponseUioToJSONTyped = DeleteMessageAudio200ResponseUioToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the DeleteMessageAudio200ResponseUio interface.
23
+ */
24
+ function instanceOfDeleteMessageAudio200ResponseUio(value) {
25
+ if (!('message' in value) || value['message'] === undefined)
26
+ return false;
27
+ return true;
28
+ }
29
+ function DeleteMessageAudio200ResponseUioFromJSON(json) {
30
+ return DeleteMessageAudio200ResponseUioFromJSONTyped(json, false);
31
+ }
32
+ function DeleteMessageAudio200ResponseUioFromJSONTyped(json, ignoreDiscriminator) {
33
+ if (json == null) {
34
+ return json;
35
+ }
36
+ return {
37
+ 'message': json['message'],
38
+ };
39
+ }
40
+ function DeleteMessageAudio200ResponseUioToJSON(json) {
41
+ return DeleteMessageAudio200ResponseUioToJSONTyped(json, false);
42
+ }
43
+ function DeleteMessageAudio200ResponseUioToJSONTyped(value, ignoreDiscriminator = false) {
44
+ if (value == null) {
45
+ return value;
46
+ }
47
+ return {
48
+ 'message': value['message'],
49
+ };
50
+ }
@@ -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 MessageAudioDownloadUrlUio
16
+ */
17
+ export interface MessageAudioDownloadUrlUio {
18
+ /**
19
+ * Presigned download URL for the message audio file
20
+ * @type {string}
21
+ * @memberof MessageAudioDownloadUrlUio
22
+ */
23
+ url: string;
24
+ }
25
+ /**
26
+ * Check if a given object implements the MessageAudioDownloadUrlUio interface.
27
+ */
28
+ export declare function instanceOfMessageAudioDownloadUrlUio(value: object): value is MessageAudioDownloadUrlUio;
29
+ export declare function MessageAudioDownloadUrlUioFromJSON(json: any): MessageAudioDownloadUrlUio;
30
+ export declare function MessageAudioDownloadUrlUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): MessageAudioDownloadUrlUio;
31
+ export declare function MessageAudioDownloadUrlUioToJSON(json: any): MessageAudioDownloadUrlUio;
32
+ export declare function MessageAudioDownloadUrlUioToJSONTyped(value?: MessageAudioDownloadUrlUio | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,50 @@
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.instanceOfMessageAudioDownloadUrlUio = instanceOfMessageAudioDownloadUrlUio;
17
+ exports.MessageAudioDownloadUrlUioFromJSON = MessageAudioDownloadUrlUioFromJSON;
18
+ exports.MessageAudioDownloadUrlUioFromJSONTyped = MessageAudioDownloadUrlUioFromJSONTyped;
19
+ exports.MessageAudioDownloadUrlUioToJSON = MessageAudioDownloadUrlUioToJSON;
20
+ exports.MessageAudioDownloadUrlUioToJSONTyped = MessageAudioDownloadUrlUioToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the MessageAudioDownloadUrlUio interface.
23
+ */
24
+ function instanceOfMessageAudioDownloadUrlUio(value) {
25
+ if (!('url' in value) || value['url'] === undefined)
26
+ return false;
27
+ return true;
28
+ }
29
+ function MessageAudioDownloadUrlUioFromJSON(json) {
30
+ return MessageAudioDownloadUrlUioFromJSONTyped(json, false);
31
+ }
32
+ function MessageAudioDownloadUrlUioFromJSONTyped(json, ignoreDiscriminator) {
33
+ if (json == null) {
34
+ return json;
35
+ }
36
+ return {
37
+ 'url': json['url'],
38
+ };
39
+ }
40
+ function MessageAudioDownloadUrlUioToJSON(json) {
41
+ return MessageAudioDownloadUrlUioToJSONTyped(json, false);
42
+ }
43
+ function MessageAudioDownloadUrlUioToJSONTyped(value, ignoreDiscriminator = false) {
44
+ if (value == null) {
45
+ return value;
46
+ }
47
+ return {
48
+ 'url': value['url'],
49
+ };
50
+ }
@@ -111,6 +111,7 @@ export * from './ConversationUio';
111
111
  export * from './CostMetricUio';
112
112
  export * from './DefaultClientPricesUio';
113
113
  export * from './DefaultEngineRequestUio';
114
+ export * from './DeleteMessageAudio200ResponseUio';
114
115
  export * from './DocumentAddRequestUio';
115
116
  export * from './EngineOptionsUio';
116
117
  export * from './EngineUio';
@@ -179,6 +180,7 @@ export * from './KnowledgeFilesByIdsRequestUio';
179
180
  export * from './LipsyncUio';
180
181
  export * from './ManifestCreateRequestUio';
181
182
  export * from './ManifestUio';
183
+ export * from './MessageAudioDownloadUrlUio';
182
184
  export * from './MessageUio';
183
185
  export * from './MetricForAgentAgentUio';
184
186
  export * from './MetricForAgentIdentifierUio';
@@ -129,6 +129,7 @@ __exportStar(require("./ConversationUio"), exports);
129
129
  __exportStar(require("./CostMetricUio"), exports);
130
130
  __exportStar(require("./DefaultClientPricesUio"), exports);
131
131
  __exportStar(require("./DefaultEngineRequestUio"), exports);
132
+ __exportStar(require("./DeleteMessageAudio200ResponseUio"), exports);
132
133
  __exportStar(require("./DocumentAddRequestUio"), exports);
133
134
  __exportStar(require("./EngineOptionsUio"), exports);
134
135
  __exportStar(require("./EngineUio"), exports);
@@ -197,6 +198,7 @@ __exportStar(require("./KnowledgeFilesByIdsRequestUio"), exports);
197
198
  __exportStar(require("./LipsyncUio"), exports);
198
199
  __exportStar(require("./ManifestCreateRequestUio"), exports);
199
200
  __exportStar(require("./ManifestUio"), exports);
201
+ __exportStar(require("./MessageAudioDownloadUrlUio"), exports);
200
202
  __exportStar(require("./MessageUio"), exports);
201
203
  __exportStar(require("./MetricForAgentAgentUio"), exports);
202
204
  __exportStar(require("./MetricForAgentIdentifierUio"), exports);
package/dist/openapi.json CHANGED
@@ -1552,6 +1552,100 @@
1552
1552
  "tags" : [ "prompts" ]
1553
1553
  }
1554
1554
  },
1555
+ "/agents/{agentId}/message-audio/{audioFileId}" : {
1556
+ "delete" : {
1557
+ "description" : "Removes the audio chunk from the message in the database and deletes the file from object storage.\n",
1558
+ "operationId" : "deleteMessageAudio",
1559
+ "parameters" : [ {
1560
+ "description" : "ID of the agent",
1561
+ "in" : "path",
1562
+ "name" : "agentId",
1563
+ "required" : true,
1564
+ "schema" : {
1565
+ "format" : "uuid",
1566
+ "type" : "string"
1567
+ }
1568
+ }, {
1569
+ "description" : "ID of the message audio file stored in object storage",
1570
+ "in" : "path",
1571
+ "name" : "audioFileId",
1572
+ "required" : true,
1573
+ "schema" : {
1574
+ "type" : "string"
1575
+ }
1576
+ } ],
1577
+ "responses" : {
1578
+ "200" : {
1579
+ "content" : {
1580
+ "application/json" : {
1581
+ "schema" : {
1582
+ "$ref" : "#/components/schemas/deleteMessageAudio_200_response"
1583
+ }
1584
+ }
1585
+ },
1586
+ "description" : "Audio deleted"
1587
+ },
1588
+ "401" : {
1589
+ "description" : "Unauthorized"
1590
+ },
1591
+ "403" : {
1592
+ "description" : "Forbidden"
1593
+ },
1594
+ "404" : {
1595
+ "description" : "Agent or audio reference not found"
1596
+ }
1597
+ },
1598
+ "summary" : "Delete a conversation message audio file",
1599
+ "tags" : [ "agent" ]
1600
+ }
1601
+ },
1602
+ "/agents/{agentId}/message-audio/{audioFileId}/download-url" : {
1603
+ "get" : {
1604
+ "description" : "Returns a short-lived presigned URL for a message audio chunk (`audio/{audioFileId}/input.mp3`).\nCall this when the user plays audio in conversation history, not when listing conversations.\n",
1605
+ "operationId" : "getMessageAudioDownloadUrl",
1606
+ "parameters" : [ {
1607
+ "description" : "ID of the agent",
1608
+ "in" : "path",
1609
+ "name" : "agentId",
1610
+ "required" : true,
1611
+ "schema" : {
1612
+ "format" : "uuid",
1613
+ "type" : "string"
1614
+ }
1615
+ }, {
1616
+ "description" : "ID of the message audio file stored in object storage",
1617
+ "in" : "path",
1618
+ "name" : "audioFileId",
1619
+ "required" : true,
1620
+ "schema" : {
1621
+ "type" : "string"
1622
+ }
1623
+ } ],
1624
+ "responses" : {
1625
+ "200" : {
1626
+ "content" : {
1627
+ "application/json" : {
1628
+ "schema" : {
1629
+ "$ref" : "#/components/schemas/MessageAudioDownloadUrl"
1630
+ }
1631
+ }
1632
+ },
1633
+ "description" : "Presigned download URL"
1634
+ },
1635
+ "401" : {
1636
+ "description" : "Unauthorized"
1637
+ },
1638
+ "403" : {
1639
+ "description" : "Forbidden - User doesn't have access to this agent"
1640
+ },
1641
+ "404" : {
1642
+ "description" : "Agent or audio file not found"
1643
+ }
1644
+ },
1645
+ "summary" : "Get presigned download URL for a conversation message audio",
1646
+ "tags" : [ "agent" ]
1647
+ }
1648
+ },
1555
1649
  "/agents/{agentId}/apps" : {
1556
1650
  "get" : {
1557
1651
  "description" : "Get apps for agent id",
@@ -2673,6 +2767,52 @@
2673
2767
  "tags" : [ "app" ]
2674
2768
  }
2675
2769
  },
2770
+ "/apps/{appId}/message-audio/{audioFileId}" : {
2771
+ "delete" : {
2772
+ "description" : "Removes the audio chunk from a message in an app conversation and deletes the file from object storage.\n",
2773
+ "operationId" : "deleteAppMessageAudio",
2774
+ "parameters" : [ {
2775
+ "description" : "ID of the app",
2776
+ "in" : "path",
2777
+ "name" : "appId",
2778
+ "required" : true,
2779
+ "schema" : {
2780
+ "type" : "string"
2781
+ }
2782
+ }, {
2783
+ "description" : "ID of the message audio file stored in object storage",
2784
+ "in" : "path",
2785
+ "name" : "audioFileId",
2786
+ "required" : true,
2787
+ "schema" : {
2788
+ "type" : "string"
2789
+ }
2790
+ } ],
2791
+ "responses" : {
2792
+ "200" : {
2793
+ "content" : {
2794
+ "application/json" : {
2795
+ "schema" : {
2796
+ "$ref" : "#/components/schemas/deleteMessageAudio_200_response"
2797
+ }
2798
+ }
2799
+ },
2800
+ "description" : "Audio deleted"
2801
+ },
2802
+ "401" : {
2803
+ "description" : "Unauthorized"
2804
+ },
2805
+ "403" : {
2806
+ "description" : "Forbidden"
2807
+ },
2808
+ "404" : {
2809
+ "description" : "App or audio reference not found"
2810
+ }
2811
+ },
2812
+ "summary" : "Delete a conversation message audio file for an app",
2813
+ "tags" : [ "app" ]
2814
+ }
2815
+ },
2676
2816
  "/auth/code" : {
2677
2817
  "post" : {
2678
2818
  "description" : "Get auth code",
@@ -8007,6 +8147,15 @@
8007
8147
  "type" : "boolean"
8008
8148
  }
8009
8149
  },
8150
+ "audioFileIdPath" : {
8151
+ "description" : "ID of the message audio file stored in object storage",
8152
+ "in" : "path",
8153
+ "name" : "audioFileId",
8154
+ "required" : true,
8155
+ "schema" : {
8156
+ "type" : "string"
8157
+ }
8158
+ },
8010
8159
  "instanceId" : {
8011
8160
  "description" : "Instance id",
8012
8161
  "in" : "query",
@@ -9740,6 +9889,16 @@
9740
9889
  "required" : [ "lang" ],
9741
9890
  "type" : "object"
9742
9891
  },
9892
+ "MessageAudioDownloadUrl" : {
9893
+ "properties" : {
9894
+ "url" : {
9895
+ "description" : "Presigned download URL for the message audio file",
9896
+ "type" : "string"
9897
+ }
9898
+ },
9899
+ "required" : [ "url" ],
9900
+ "type" : "object"
9901
+ },
9743
9902
  "AppLight" : {
9744
9903
  "properties" : {
9745
9904
  "id" : {
@@ -12301,6 +12460,15 @@
12301
12460
  "enum" : [ "ELEVENLABS" ],
12302
12461
  "type" : "string"
12303
12462
  },
12463
+ "deleteMessageAudio_200_response" : {
12464
+ "properties" : {
12465
+ "message" : {
12466
+ "type" : "string"
12467
+ }
12468
+ },
12469
+ "required" : [ "message" ],
12470
+ "type" : "object"
12471
+ },
12304
12472
  "updateConversationTitle_request" : {
12305
12473
  "properties" : {
12306
12474
  "title" : {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@breign/client",
3
- "version": "1.0.89",
3
+ "version": "1.0.90",
4
4
  "main": "dist/index.js",
5
5
  "exports": {
6
6
  ".": "./dist/index.js",