@breign/client 1.0.43 → 1.0.44

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.
@@ -20,6 +20,9 @@ export interface CreateCustomVariableRequest {
20
20
  [key: string]: string;
21
21
  };
22
22
  }
23
+ export interface DeleteAllAttachmentsRequest {
24
+ conversationId: string;
25
+ }
23
26
  export interface DeleteAllConversationsRequest {
24
27
  organizationId: string;
25
28
  providerSource?: DeleteAllConversationsProviderSourceEnum;
@@ -80,6 +83,16 @@ export declare class ConversationsApi extends runtime.BaseAPI {
80
83
  createCustomVariable(conversationId: string, requestBody: {
81
84
  [key: string]: string;
82
85
  }, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
86
+ /**
87
+ * Remove all attachments from the context of a specific conversation.
88
+ * Delete all attachments from a conversation context.
89
+ */
90
+ deleteAllAttachmentsRaw(requestParameters: DeleteAllAttachmentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
91
+ /**
92
+ * Remove all attachments from the context of a specific conversation.
93
+ * Delete all attachments from a conversation context.
94
+ */
95
+ deleteAllAttachments(conversationId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
83
96
  /**
84
97
  * Delete all conversations created by the authenticated user in the specified organization.
85
98
  * Delete all conversations
@@ -114,6 +114,34 @@ class ConversationsApi extends runtime.BaseAPI {
114
114
  async createCustomVariable(conversationId, requestBody, initOverrides) {
115
115
  await this.createCustomVariableRaw({ conversationId: conversationId, requestBody: requestBody }, initOverrides);
116
116
  }
117
+ /**
118
+ * Remove all attachments from the context of a specific conversation.
119
+ * Delete all attachments from a conversation context.
120
+ */
121
+ async deleteAllAttachmentsRaw(requestParameters, initOverrides) {
122
+ if (requestParameters['conversationId'] == null) {
123
+ throw new runtime.RequiredError('conversationId', 'Required parameter "conversationId" was null or undefined when calling deleteAllAttachments().');
124
+ }
125
+ const queryParameters = {};
126
+ const headerParameters = {};
127
+ if (this.configuration && this.configuration.apiKey) {
128
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
129
+ }
130
+ const response = await this.request({
131
+ path: `/conversations/{conversationId}/context/attachments`.replace(`{${"conversationId"}}`, encodeURIComponent(String(requestParameters['conversationId']))),
132
+ method: 'DELETE',
133
+ headers: headerParameters,
134
+ query: queryParameters,
135
+ }, initOverrides);
136
+ return new runtime.VoidApiResponse(response);
137
+ }
138
+ /**
139
+ * Remove all attachments from the context of a specific conversation.
140
+ * Delete all attachments from a conversation context.
141
+ */
142
+ async deleteAllAttachments(conversationId, initOverrides) {
143
+ await this.deleteAllAttachmentsRaw({ conversationId: conversationId }, initOverrides);
144
+ }
117
145
  /**
118
146
  * Delete all conversations created by the authenticated user in the specified organization.
119
147
  * Delete all conversations
package/dist/openapi.json CHANGED
@@ -2981,6 +2981,38 @@
2981
2981
  }
2982
2982
  },
2983
2983
  "/conversations/{conversationId}/context/attachments" : {
2984
+ "delete" : {
2985
+ "description" : "Remove all attachments from the context of a specific conversation.",
2986
+ "operationId" : "deleteAllAttachments",
2987
+ "parameters" : [ {
2988
+ "description" : "The ID of the conversation",
2989
+ "in" : "path",
2990
+ "name" : "conversationId",
2991
+ "required" : true,
2992
+ "schema" : {
2993
+ "type" : "string"
2994
+ }
2995
+ } ],
2996
+ "responses" : {
2997
+ "204" : {
2998
+ "description" : "Successfully deleted all attachments."
2999
+ },
3000
+ "401" : {
3001
+ "description" : "Unauthorized"
3002
+ },
3003
+ "403" : {
3004
+ "description" : "Forbidden - User cannot access this conversation"
3005
+ },
3006
+ "404" : {
3007
+ "description" : "Conversation not found"
3008
+ },
3009
+ "500" : {
3010
+ "description" : "Server error"
3011
+ }
3012
+ },
3013
+ "summary" : "Delete all attachments from a conversation context.",
3014
+ "tags" : [ "conversations" ]
3015
+ },
2984
3016
  "post" : {
2985
3017
  "description" : "Upload one file attachment to the context of a specific conversation.",
2986
3018
  "operationId" : "uploadAttachment",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@breign/client",
3
- "version": "1.0.43",
3
+ "version": "1.0.44",
4
4
  "main": "dist/index.js",
5
5
  "exports": {
6
6
  ".": "./dist/index.js",