@breign/client 1.0.128 → 1.0.129

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 { AttachmentCreateRequestUio, AttachmentCreateResponseUio, AttachmentDetailsResponseUio, AttachmentProcessedRequestUio, BodyWithMessageUio, ContextLocationRequestUio, ContextUio, ConversationSummaryUio, CreateCustomVariable200ResponseUio, UpdateConversationTitleRequestUio, WorkspaceFileContentUio, WorkspaceFileEntryUio } from '../models/index';
13
+ import type { AttachmentCreateRequestUio, AttachmentCreateResponseUio, AttachmentDetailsResponseUio, AttachmentProcessedRequestUio, BodyWithMessageUio, ContextLocationRequestUio, ContextUio, ConversationSummaryUio, CreateCustomVariable200ResponseUio, MessageAnonymizationUio, UpdateConversationTitleRequestUio, WorkspaceFileContentUio, WorkspaceFileEntryUio } from '../models/index';
14
14
  export interface ArchiveConversationByIdRequest {
15
15
  conversationId: string;
16
16
  }
@@ -39,6 +39,9 @@ export interface DeleteConversationWorkspaceFileRequest {
39
39
  conversationId: string;
40
40
  path: string;
41
41
  }
42
+ export interface GetAnonymizedMessagesRequest {
43
+ conversationId: string;
44
+ }
42
45
  export interface GetAttachmentRequest {
43
46
  conversationId: string;
44
47
  attachmentId: string;
@@ -161,6 +164,16 @@ export declare class ConversationsApi extends runtime.BaseAPI {
161
164
  * Delete a file from a conversation workspace
162
165
  */
163
166
  deleteConversationWorkspaceFile(conversationId: string, path: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
167
+ /**
168
+ * Retrieve the list of anonymized messages for a given conversation.
169
+ * Get the anonymized messages of a conversation
170
+ */
171
+ getAnonymizedMessagesRaw(requestParameters: GetAnonymizedMessagesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<MessageAnonymizationUio>>>;
172
+ /**
173
+ * Retrieve the list of anonymized messages for a given conversation.
174
+ * Get the anonymized messages of a conversation
175
+ */
176
+ getAnonymizedMessages(conversationId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<MessageAnonymizationUio>>;
164
177
  /**
165
178
  * Get a specific attachment by its ID from the context of a conversation.
166
179
  * Retrieve an attachment from a conversation context
@@ -273,6 +273,35 @@ class ConversationsApi extends runtime.BaseAPI {
273
273
  async deleteConversationWorkspaceFile(conversationId, path, initOverrides) {
274
274
  await this.deleteConversationWorkspaceFileRaw({ conversationId: conversationId, path: path }, initOverrides);
275
275
  }
276
+ /**
277
+ * Retrieve the list of anonymized messages for a given conversation.
278
+ * Get the anonymized messages of a conversation
279
+ */
280
+ async getAnonymizedMessagesRaw(requestParameters, initOverrides) {
281
+ if (requestParameters['conversationId'] == null) {
282
+ throw new runtime.RequiredError('conversationId', 'Required parameter "conversationId" was null or undefined when calling getAnonymizedMessages().');
283
+ }
284
+ const queryParameters = {};
285
+ const headerParameters = {};
286
+ if (this.configuration && this.configuration.apiKey) {
287
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
288
+ }
289
+ const response = await this.request({
290
+ path: `/conversations/{conversationId}/anonymization`.replace(`{${"conversationId"}}`, encodeURIComponent(String(requestParameters['conversationId']))),
291
+ method: 'GET',
292
+ headers: headerParameters,
293
+ query: queryParameters,
294
+ }, initOverrides);
295
+ return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(index_1.MessageAnonymizationUioFromJSON));
296
+ }
297
+ /**
298
+ * Retrieve the list of anonymized messages for a given conversation.
299
+ * Get the anonymized messages of a conversation
300
+ */
301
+ async getAnonymizedMessages(conversationId, initOverrides) {
302
+ const response = await this.getAnonymizedMessagesRaw({ conversationId: conversationId }, initOverrides);
303
+ return await response.value();
304
+ }
276
305
  /**
277
306
  * Get a specific attachment by its ID from the context of a conversation.
278
307
  * Retrieve an attachment from a conversation context
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { BodyWithMessageUio, GuardianCreateRequestUio, GuardianPutRequestUio, GuardianUio } from '../models/index';
13
+ import type { AnonymizeRequestUio, AnonymizeResponseUio, BodyWithMessageUio, GuardianCreateRequestUio, GuardianPutRequestUio, GuardianUio } from '../models/index';
14
14
  export interface CreateGuardianForAgentRequest {
15
15
  agentId: string;
16
16
  guardianCreateRequestUio: GuardianCreateRequestUio;
@@ -31,6 +31,10 @@ export interface GetGuardiansForAgentRequest {
31
31
  export interface GetGuardiansForOrganizationRequest {
32
32
  organizationId: string;
33
33
  }
34
+ export interface TestAnonymizeRequest {
35
+ guardianId: string;
36
+ anonymizeRequestUio: AnonymizeRequestUio;
37
+ }
34
38
  export interface UpdateExcludedAgentsRequest {
35
39
  guardianId: string;
36
40
  requestBody: Array<string>;
@@ -99,6 +103,16 @@ export declare class GuardiansApi extends runtime.BaseAPI {
99
103
  * Get all guardians for an organization
100
104
  */
101
105
  getGuardiansForOrganization(organizationId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<GuardianUio>>;
106
+ /**
107
+ * Test the Anonymization of a guardian
108
+ * Test the Anonymization of a guardian
109
+ */
110
+ testAnonymizeRaw(requestParameters: TestAnonymizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AnonymizeResponseUio>>;
111
+ /**
112
+ * Test the Anonymization of a guardian
113
+ * Test the Anonymization of a guardian
114
+ */
115
+ testAnonymize(guardianId: string, anonymizeRequestUio: AnonymizeRequestUio, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AnonymizeResponseUio>;
102
116
  /**
103
117
  * Updates the excluded agents for a guardian
104
118
  * Update excluded agents for a guardian
@@ -232,6 +232,40 @@ class GuardiansApi extends runtime.BaseAPI {
232
232
  const response = await this.getGuardiansForOrganizationRaw({ organizationId: organizationId }, initOverrides);
233
233
  return await response.value();
234
234
  }
235
+ /**
236
+ * Test the Anonymization of a guardian
237
+ * Test the Anonymization of a guardian
238
+ */
239
+ async testAnonymizeRaw(requestParameters, initOverrides) {
240
+ if (requestParameters['guardianId'] == null) {
241
+ throw new runtime.RequiredError('guardianId', 'Required parameter "guardianId" was null or undefined when calling testAnonymize().');
242
+ }
243
+ if (requestParameters['anonymizeRequestUio'] == null) {
244
+ throw new runtime.RequiredError('anonymizeRequestUio', 'Required parameter "anonymizeRequestUio" was null or undefined when calling testAnonymize().');
245
+ }
246
+ const queryParameters = {};
247
+ const headerParameters = {};
248
+ headerParameters['Content-Type'] = 'application/json';
249
+ if (this.configuration && this.configuration.apiKey) {
250
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
251
+ }
252
+ const response = await this.request({
253
+ path: `/guardians/{guardianId}/anonymize`.replace(`{${"guardianId"}}`, encodeURIComponent(String(requestParameters['guardianId']))),
254
+ method: 'POST',
255
+ headers: headerParameters,
256
+ query: queryParameters,
257
+ body: (0, index_1.AnonymizeRequestUioToJSON)(requestParameters['anonymizeRequestUio']),
258
+ }, initOverrides);
259
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.AnonymizeResponseUioFromJSON)(jsonValue));
260
+ }
261
+ /**
262
+ * Test the Anonymization of a guardian
263
+ * Test the Anonymization of a guardian
264
+ */
265
+ async testAnonymize(guardianId, anonymizeRequestUio, initOverrides) {
266
+ const response = await this.testAnonymizeRaw({ guardianId: guardianId, anonymizeRequestUio: anonymizeRequestUio }, initOverrides);
267
+ return await response.value();
268
+ }
235
269
  /**
236
270
  * Updates the excluded agents for a guardian
237
271
  * Update excluded agents for a guardian
@@ -0,0 +1,27 @@
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
+ */
16
+ export declare const AnonymizationStatusUio: {
17
+ readonly Pending: "pending";
18
+ readonly Anonymized: "anonymized";
19
+ readonly Deanonymized: "deanonymized";
20
+ readonly Error: "error";
21
+ };
22
+ export type AnonymizationStatusUio = typeof AnonymizationStatusUio[keyof typeof AnonymizationStatusUio];
23
+ export declare function instanceOfAnonymizationStatusUio(value: any): boolean;
24
+ export declare function AnonymizationStatusUioFromJSON(json: any): AnonymizationStatusUio;
25
+ export declare function AnonymizationStatusUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AnonymizationStatusUio;
26
+ export declare function AnonymizationStatusUioToJSON(value?: AnonymizationStatusUio | null): any;
27
+ export declare function AnonymizationStatusUioToJSONTyped(value: any, ignoreDiscriminator: boolean): AnonymizationStatusUio;
@@ -0,0 +1,53 @@
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.AnonymizationStatusUio = void 0;
17
+ exports.instanceOfAnonymizationStatusUio = instanceOfAnonymizationStatusUio;
18
+ exports.AnonymizationStatusUioFromJSON = AnonymizationStatusUioFromJSON;
19
+ exports.AnonymizationStatusUioFromJSONTyped = AnonymizationStatusUioFromJSONTyped;
20
+ exports.AnonymizationStatusUioToJSON = AnonymizationStatusUioToJSON;
21
+ exports.AnonymizationStatusUioToJSONTyped = AnonymizationStatusUioToJSONTyped;
22
+ /**
23
+ *
24
+ * @export
25
+ */
26
+ exports.AnonymizationStatusUio = {
27
+ Pending: 'pending',
28
+ Anonymized: 'anonymized',
29
+ Deanonymized: 'deanonymized',
30
+ Error: 'error'
31
+ };
32
+ function instanceOfAnonymizationStatusUio(value) {
33
+ for (const key in exports.AnonymizationStatusUio) {
34
+ if (Object.prototype.hasOwnProperty.call(exports.AnonymizationStatusUio, key)) {
35
+ if (exports.AnonymizationStatusUio[key] === value) {
36
+ return true;
37
+ }
38
+ }
39
+ }
40
+ return false;
41
+ }
42
+ function AnonymizationStatusUioFromJSON(json) {
43
+ return AnonymizationStatusUioFromJSONTyped(json, false);
44
+ }
45
+ function AnonymizationStatusUioFromJSONTyped(json, ignoreDiscriminator) {
46
+ return json;
47
+ }
48
+ function AnonymizationStatusUioToJSON(value) {
49
+ return value;
50
+ }
51
+ function AnonymizationStatusUioToJSONTyped(value, ignoreDiscriminator) {
52
+ return value;
53
+ }
@@ -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 AnonymizeRequestUio
16
+ */
17
+ export interface AnonymizeRequestUio {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof AnonymizeRequestUio
22
+ */
23
+ prompt: string;
24
+ }
25
+ /**
26
+ * Check if a given object implements the AnonymizeRequestUio interface.
27
+ */
28
+ export declare function instanceOfAnonymizeRequestUio(value: object): value is AnonymizeRequestUio;
29
+ export declare function AnonymizeRequestUioFromJSON(json: any): AnonymizeRequestUio;
30
+ export declare function AnonymizeRequestUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AnonymizeRequestUio;
31
+ export declare function AnonymizeRequestUioToJSON(json: any): AnonymizeRequestUio;
32
+ export declare function AnonymizeRequestUioToJSONTyped(value?: AnonymizeRequestUio | 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.instanceOfAnonymizeRequestUio = instanceOfAnonymizeRequestUio;
17
+ exports.AnonymizeRequestUioFromJSON = AnonymizeRequestUioFromJSON;
18
+ exports.AnonymizeRequestUioFromJSONTyped = AnonymizeRequestUioFromJSONTyped;
19
+ exports.AnonymizeRequestUioToJSON = AnonymizeRequestUioToJSON;
20
+ exports.AnonymizeRequestUioToJSONTyped = AnonymizeRequestUioToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the AnonymizeRequestUio interface.
23
+ */
24
+ function instanceOfAnonymizeRequestUio(value) {
25
+ if (!('prompt' in value) || value['prompt'] === undefined)
26
+ return false;
27
+ return true;
28
+ }
29
+ function AnonymizeRequestUioFromJSON(json) {
30
+ return AnonymizeRequestUioFromJSONTyped(json, false);
31
+ }
32
+ function AnonymizeRequestUioFromJSONTyped(json, ignoreDiscriminator) {
33
+ if (json == null) {
34
+ return json;
35
+ }
36
+ return {
37
+ 'prompt': json['prompt'],
38
+ };
39
+ }
40
+ function AnonymizeRequestUioToJSON(json) {
41
+ return AnonymizeRequestUioToJSONTyped(json, false);
42
+ }
43
+ function AnonymizeRequestUioToJSONTyped(value, ignoreDiscriminator = false) {
44
+ if (value == null) {
45
+ return value;
46
+ }
47
+ return {
48
+ 'prompt': value['prompt'],
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 AnonymizeResponseUio
16
+ */
17
+ export interface AnonymizeResponseUio {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof AnonymizeResponseUio
22
+ */
23
+ anonymizedPrompt?: string;
24
+ }
25
+ /**
26
+ * Check if a given object implements the AnonymizeResponseUio interface.
27
+ */
28
+ export declare function instanceOfAnonymizeResponseUio(value: object): value is AnonymizeResponseUio;
29
+ export declare function AnonymizeResponseUioFromJSON(json: any): AnonymizeResponseUio;
30
+ export declare function AnonymizeResponseUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AnonymizeResponseUio;
31
+ export declare function AnonymizeResponseUioToJSON(json: any): AnonymizeResponseUio;
32
+ export declare function AnonymizeResponseUioToJSONTyped(value?: AnonymizeResponseUio | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,48 @@
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.instanceOfAnonymizeResponseUio = instanceOfAnonymizeResponseUio;
17
+ exports.AnonymizeResponseUioFromJSON = AnonymizeResponseUioFromJSON;
18
+ exports.AnonymizeResponseUioFromJSONTyped = AnonymizeResponseUioFromJSONTyped;
19
+ exports.AnonymizeResponseUioToJSON = AnonymizeResponseUioToJSON;
20
+ exports.AnonymizeResponseUioToJSONTyped = AnonymizeResponseUioToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the AnonymizeResponseUio interface.
23
+ */
24
+ function instanceOfAnonymizeResponseUio(value) {
25
+ return true;
26
+ }
27
+ function AnonymizeResponseUioFromJSON(json) {
28
+ return AnonymizeResponseUioFromJSONTyped(json, false);
29
+ }
30
+ function AnonymizeResponseUioFromJSONTyped(json, ignoreDiscriminator) {
31
+ if (json == null) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'anonymizedPrompt': json['anonymizedPrompt'] == null ? undefined : json['anonymizedPrompt'],
36
+ };
37
+ }
38
+ function AnonymizeResponseUioToJSON(json) {
39
+ return AnonymizeResponseUioToJSONTyped(json, false);
40
+ }
41
+ function AnonymizeResponseUioToJSONTyped(value, ignoreDiscriminator = false) {
42
+ if (value == null) {
43
+ return value;
44
+ }
45
+ return {
46
+ 'anonymizedPrompt': value['anonymizedPrompt'],
47
+ };
48
+ }
@@ -53,6 +53,12 @@ export interface ChatMessageUio {
53
53
  * @memberof ChatMessageUio
54
54
  */
55
55
  askConfirmation?: boolean;
56
+ /**
57
+ *
58
+ * @type {string}
59
+ * @memberof ChatMessageUio
60
+ */
61
+ anonymizedContent?: string;
56
62
  /**
57
63
  *
58
64
  * @type {string}
@@ -61,6 +61,7 @@ function ChatMessageUioFromJSONTyped(json, ignoreDiscriminator) {
61
61
  'content': json['content'],
62
62
  'reaction': json['reaction'] == null ? undefined : json['reaction'],
63
63
  'askConfirmation': json['askConfirmation'] == null ? undefined : json['askConfirmation'],
64
+ 'anonymizedContent': json['anonymizedContent'] == null ? undefined : json['anonymizedContent'],
64
65
  'confirmationLink': json['confirmationLink'] == null ? undefined : json['confirmationLink'],
65
66
  'toolResults': json['toolResults'] == null ? undefined : (json['toolResults'].map(ToolResultsUio_1.ToolResultsUioFromJSON)),
66
67
  'suggestions': json['suggestions'] == null ? undefined : (json['suggestions'].map(SuggestionUio_1.SuggestionUioFromJSON)),
@@ -92,6 +93,7 @@ function ChatMessageUioToJSONTyped(value, ignoreDiscriminator = false) {
92
93
  'content': value['content'],
93
94
  'reaction': value['reaction'],
94
95
  'askConfirmation': value['askConfirmation'],
96
+ 'anonymizedContent': value['anonymizedContent'],
95
97
  'confirmationLink': value['confirmationLink'],
96
98
  'toolResults': value['toolResults'] == null ? undefined : (value['toolResults'].map(ToolResultsUio_1.ToolResultsUioToJSON)),
97
99
  'suggestions': value['suggestions'] == null ? undefined : (value['suggestions'].map(SuggestionUio_1.SuggestionUioToJSON)),
@@ -11,6 +11,7 @@
11
11
  */
12
12
  import type { GuardianRoleUio } from './GuardianRoleUio';
13
13
  import type { GuardianEngineUio } from './GuardianEngineUio';
14
+ import type { RegexPatternUio } from './RegexPatternUio';
14
15
  import type { GuardianTypeUio } from './GuardianTypeUio';
15
16
  import type { GuardianPositionUio } from './GuardianPositionUio';
16
17
  /**
@@ -75,6 +76,18 @@ export interface GuardianPutRequestUio {
75
76
  * @memberof GuardianPutRequestUio
76
77
  */
77
78
  excludedAgents?: Array<any>;
79
+ /**
80
+ *
81
+ * @type {Array<RegexPatternUio>}
82
+ * @memberof GuardianPutRequestUio
83
+ */
84
+ regexPatterns?: Array<RegexPatternUio>;
85
+ /**
86
+ *
87
+ * @type {boolean}
88
+ * @memberof GuardianPutRequestUio
89
+ */
90
+ useFaker?: boolean;
78
91
  }
79
92
  /**
80
93
  * Check if a given object implements the GuardianPutRequestUio interface.
@@ -20,6 +20,7 @@ exports.GuardianPutRequestUioToJSON = GuardianPutRequestUioToJSON;
20
20
  exports.GuardianPutRequestUioToJSONTyped = GuardianPutRequestUioToJSONTyped;
21
21
  const GuardianRoleUio_1 = require("./GuardianRoleUio");
22
22
  const GuardianEngineUio_1 = require("./GuardianEngineUio");
23
+ const RegexPatternUio_1 = require("./RegexPatternUio");
23
24
  const GuardianTypeUio_1 = require("./GuardianTypeUio");
24
25
  const GuardianPositionUio_1 = require("./GuardianPositionUio");
25
26
  /**
@@ -45,6 +46,8 @@ function GuardianPutRequestUioFromJSONTyped(json, ignoreDiscriminator) {
45
46
  'position': json['position'] == null ? undefined : (json['position'].map(GuardianPositionUio_1.GuardianPositionUioFromJSON)),
46
47
  'engine': json['engine'] == null ? undefined : (0, GuardianEngineUio_1.GuardianEngineUioFromJSON)(json['engine']),
47
48
  'excludedAgents': json['excludedAgents'] == null ? undefined : json['excludedAgents'],
49
+ 'regexPatterns': json['regexPatterns'] == null ? undefined : (json['regexPatterns'].map(RegexPatternUio_1.RegexPatternUioFromJSON)),
50
+ 'useFaker': json['useFaker'] == null ? undefined : json['useFaker'],
48
51
  };
49
52
  }
50
53
  function GuardianPutRequestUioToJSON(json) {
@@ -64,5 +67,7 @@ function GuardianPutRequestUioToJSONTyped(value, ignoreDiscriminator = false) {
64
67
  'position': value['position'] == null ? undefined : (value['position'].map(GuardianPositionUio_1.GuardianPositionUioToJSON)),
65
68
  'engine': (0, GuardianEngineUio_1.GuardianEngineUioToJSON)(value['engine']),
66
69
  'excludedAgents': value['excludedAgents'],
70
+ 'regexPatterns': value['regexPatterns'] == null ? undefined : (value['regexPatterns'].map(RegexPatternUio_1.RegexPatternUioToJSON)),
71
+ 'useFaker': value['useFaker'],
67
72
  };
68
73
  }
@@ -18,7 +18,7 @@ export declare const GuardianRoleUio: {
18
18
  readonly Wordcheck: "WORDCHECK";
19
19
  readonly Intentioncheck: "INTENTIONCHECK";
20
20
  readonly Attackcheck: "ATTACKCHECK";
21
- readonly Anonimize: "ANONIMIZE";
21
+ readonly Anonymize: "ANONYMIZE";
22
22
  };
23
23
  export type GuardianRoleUio = typeof GuardianRoleUio[keyof typeof GuardianRoleUio];
24
24
  export declare function instanceOfGuardianRoleUio(value: any): boolean;
@@ -28,7 +28,7 @@ exports.GuardianRoleUio = {
28
28
  Wordcheck: 'WORDCHECK',
29
29
  Intentioncheck: 'INTENTIONCHECK',
30
30
  Attackcheck: 'ATTACKCHECK',
31
- Anonimize: 'ANONIMIZE'
31
+ Anonymize: 'ANONYMIZE'
32
32
  };
33
33
  function instanceOfGuardianRoleUio(value) {
34
34
  for (const key in exports.GuardianRoleUio) {
@@ -11,6 +11,7 @@
11
11
  */
12
12
  import type { GuardianRoleUio } from './GuardianRoleUio';
13
13
  import type { GuardianEngineUio } from './GuardianEngineUio';
14
+ import type { RegexPatternUio } from './RegexPatternUio';
14
15
  import type { GuardianTypeUio } from './GuardianTypeUio';
15
16
  import type { GuardianPositionUio } from './GuardianPositionUio';
16
17
  /**
@@ -111,6 +112,18 @@ export interface GuardianUio {
111
112
  * @memberof GuardianUio
112
113
  */
113
114
  excludedAgents?: Array<string>;
115
+ /**
116
+ *
117
+ * @type {boolean}
118
+ * @memberof GuardianUio
119
+ */
120
+ useFaker?: boolean;
121
+ /**
122
+ *
123
+ * @type {Array<RegexPatternUio>}
124
+ * @memberof GuardianUio
125
+ */
126
+ regexPatterns?: Array<RegexPatternUio>;
114
127
  }
115
128
  /**
116
129
  * Check if a given object implements the GuardianUio interface.
@@ -20,6 +20,7 @@ exports.GuardianUioToJSON = GuardianUioToJSON;
20
20
  exports.GuardianUioToJSONTyped = GuardianUioToJSONTyped;
21
21
  const GuardianRoleUio_1 = require("./GuardianRoleUio");
22
22
  const GuardianEngineUio_1 = require("./GuardianEngineUio");
23
+ const RegexPatternUio_1 = require("./RegexPatternUio");
23
24
  const GuardianTypeUio_1 = require("./GuardianTypeUio");
24
25
  const GuardianPositionUio_1 = require("./GuardianPositionUio");
25
26
  /**
@@ -63,6 +64,8 @@ function GuardianUioFromJSONTyped(json, ignoreDiscriminator) {
63
64
  'updatedAt': json['updatedAt'] == null ? undefined : json['updatedAt'],
64
65
  'thresholds': json['thresholds'] == null ? undefined : json['thresholds'],
65
66
  'excludedAgents': json['excludedAgents'] == null ? undefined : json['excludedAgents'],
67
+ 'useFaker': json['useFaker'] == null ? undefined : json['useFaker'],
68
+ 'regexPatterns': json['regexPatterns'] == null ? undefined : (json['regexPatterns'].map(RegexPatternUio_1.RegexPatternUioFromJSON)),
66
69
  };
67
70
  }
68
71
  function GuardianUioToJSON(json) {
@@ -88,5 +91,7 @@ function GuardianUioToJSONTyped(value, ignoreDiscriminator = false) {
88
91
  'updatedAt': value['updatedAt'],
89
92
  'thresholds': value['thresholds'],
90
93
  'excludedAgents': value['excludedAgents'],
94
+ 'useFaker': value['useFaker'],
95
+ 'regexPatterns': value['regexPatterns'] == null ? undefined : (value['regexPatterns'].map(RegexPatternUio_1.RegexPatternUioToJSON)),
91
96
  };
92
97
  }
@@ -0,0 +1,93 @@
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 { AnonymizationStatusUio } from './AnonymizationStatusUio';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface MessageAnonymizationUio
17
+ */
18
+ export interface MessageAnonymizationUio {
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof MessageAnonymizationUio
23
+ */
24
+ id: string;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof MessageAnonymizationUio
29
+ */
30
+ conversationId: string;
31
+ /**
32
+ *
33
+ * @type {string}
34
+ * @memberof MessageAnonymizationUio
35
+ */
36
+ messageId: string;
37
+ /**
38
+ *
39
+ * @type {string}
40
+ * @memberof MessageAnonymizationUio
41
+ */
42
+ guardianId: string;
43
+ /**
44
+ *
45
+ * @type {string}
46
+ * @memberof MessageAnonymizationUio
47
+ */
48
+ originalContent: string;
49
+ /**
50
+ *
51
+ * @type {string}
52
+ * @memberof MessageAnonymizationUio
53
+ */
54
+ anonymizedContent?: string;
55
+ /**
56
+ *
57
+ * @type {string}
58
+ * @memberof MessageAnonymizationUio
59
+ */
60
+ deanonymizedContent?: string;
61
+ /**
62
+ *
63
+ * @type {string}
64
+ * @memberof MessageAnonymizationUio
65
+ */
66
+ anonymizedReasoning?: string;
67
+ /**
68
+ *
69
+ * @type {AnonymizationStatusUio}
70
+ * @memberof MessageAnonymizationUio
71
+ */
72
+ status: AnonymizationStatusUio;
73
+ /**
74
+ *
75
+ * @type {Date}
76
+ * @memberof MessageAnonymizationUio
77
+ */
78
+ createdAt: Date;
79
+ /**
80
+ *
81
+ * @type {Date}
82
+ * @memberof MessageAnonymizationUio
83
+ */
84
+ updatedAt: Date;
85
+ }
86
+ /**
87
+ * Check if a given object implements the MessageAnonymizationUio interface.
88
+ */
89
+ export declare function instanceOfMessageAnonymizationUio(value: object): value is MessageAnonymizationUio;
90
+ export declare function MessageAnonymizationUioFromJSON(json: any): MessageAnonymizationUio;
91
+ export declare function MessageAnonymizationUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): MessageAnonymizationUio;
92
+ export declare function MessageAnonymizationUioToJSON(json: any): MessageAnonymizationUio;
93
+ export declare function MessageAnonymizationUioToJSONTyped(value?: MessageAnonymizationUio | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,85 @@
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.instanceOfMessageAnonymizationUio = instanceOfMessageAnonymizationUio;
17
+ exports.MessageAnonymizationUioFromJSON = MessageAnonymizationUioFromJSON;
18
+ exports.MessageAnonymizationUioFromJSONTyped = MessageAnonymizationUioFromJSONTyped;
19
+ exports.MessageAnonymizationUioToJSON = MessageAnonymizationUioToJSON;
20
+ exports.MessageAnonymizationUioToJSONTyped = MessageAnonymizationUioToJSONTyped;
21
+ const AnonymizationStatusUio_1 = require("./AnonymizationStatusUio");
22
+ /**
23
+ * Check if a given object implements the MessageAnonymizationUio interface.
24
+ */
25
+ function instanceOfMessageAnonymizationUio(value) {
26
+ if (!('id' in value) || value['id'] === undefined)
27
+ return false;
28
+ if (!('conversationId' in value) || value['conversationId'] === undefined)
29
+ return false;
30
+ if (!('messageId' in value) || value['messageId'] === undefined)
31
+ return false;
32
+ if (!('guardianId' in value) || value['guardianId'] === undefined)
33
+ return false;
34
+ if (!('originalContent' in value) || value['originalContent'] === undefined)
35
+ return false;
36
+ if (!('status' in value) || value['status'] === undefined)
37
+ return false;
38
+ if (!('createdAt' in value) || value['createdAt'] === undefined)
39
+ return false;
40
+ if (!('updatedAt' in value) || value['updatedAt'] === undefined)
41
+ return false;
42
+ return true;
43
+ }
44
+ function MessageAnonymizationUioFromJSON(json) {
45
+ return MessageAnonymizationUioFromJSONTyped(json, false);
46
+ }
47
+ function MessageAnonymizationUioFromJSONTyped(json, ignoreDiscriminator) {
48
+ if (json == null) {
49
+ return json;
50
+ }
51
+ return {
52
+ 'id': json['id'],
53
+ 'conversationId': json['conversationId'],
54
+ 'messageId': json['messageId'],
55
+ 'guardianId': json['guardianId'],
56
+ 'originalContent': json['originalContent'],
57
+ 'anonymizedContent': json['anonymizedContent'] == null ? undefined : json['anonymizedContent'],
58
+ 'deanonymizedContent': json['deanonymizedContent'] == null ? undefined : json['deanonymizedContent'],
59
+ 'anonymizedReasoning': json['anonymizedReasoning'] == null ? undefined : json['anonymizedReasoning'],
60
+ 'status': (0, AnonymizationStatusUio_1.AnonymizationStatusUioFromJSON)(json['status']),
61
+ 'createdAt': (new Date(json['createdAt'])),
62
+ 'updatedAt': (new Date(json['updatedAt'])),
63
+ };
64
+ }
65
+ function MessageAnonymizationUioToJSON(json) {
66
+ return MessageAnonymizationUioToJSONTyped(json, false);
67
+ }
68
+ function MessageAnonymizationUioToJSONTyped(value, ignoreDiscriminator = false) {
69
+ if (value == null) {
70
+ return value;
71
+ }
72
+ return {
73
+ 'id': value['id'],
74
+ 'conversationId': value['conversationId'],
75
+ 'messageId': value['messageId'],
76
+ 'guardianId': value['guardianId'],
77
+ 'originalContent': value['originalContent'],
78
+ 'anonymizedContent': value['anonymizedContent'],
79
+ 'deanonymizedContent': value['deanonymizedContent'],
80
+ 'anonymizedReasoning': value['anonymizedReasoning'],
81
+ 'status': (0, AnonymizationStatusUio_1.AnonymizationStatusUioToJSON)(value['status']),
82
+ 'createdAt': ((value['createdAt']).toISOString()),
83
+ 'updatedAt': ((value['updatedAt']).toISOString()),
84
+ };
85
+ }
@@ -0,0 +1,56 @@
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 RegexPatternUio
16
+ */
17
+ export interface RegexPatternUio {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof RegexPatternUio
22
+ */
23
+ id: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof RegexPatternUio
28
+ */
29
+ name: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof RegexPatternUio
34
+ */
35
+ expression: string;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof RegexPatternUio
40
+ */
41
+ entityType: string;
42
+ /**
43
+ *
44
+ * @type {boolean}
45
+ * @memberof RegexPatternUio
46
+ */
47
+ enabled: boolean;
48
+ }
49
+ /**
50
+ * Check if a given object implements the RegexPatternUio interface.
51
+ */
52
+ export declare function instanceOfRegexPatternUio(value: object): value is RegexPatternUio;
53
+ export declare function RegexPatternUioFromJSON(json: any): RegexPatternUio;
54
+ export declare function RegexPatternUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): RegexPatternUio;
55
+ export declare function RegexPatternUioToJSON(json: any): RegexPatternUio;
56
+ export declare function RegexPatternUioToJSONTyped(value?: RegexPatternUio | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,66 @@
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.instanceOfRegexPatternUio = instanceOfRegexPatternUio;
17
+ exports.RegexPatternUioFromJSON = RegexPatternUioFromJSON;
18
+ exports.RegexPatternUioFromJSONTyped = RegexPatternUioFromJSONTyped;
19
+ exports.RegexPatternUioToJSON = RegexPatternUioToJSON;
20
+ exports.RegexPatternUioToJSONTyped = RegexPatternUioToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the RegexPatternUio interface.
23
+ */
24
+ function instanceOfRegexPatternUio(value) {
25
+ if (!('id' in value) || value['id'] === undefined)
26
+ return false;
27
+ if (!('name' in value) || value['name'] === undefined)
28
+ return false;
29
+ if (!('expression' in value) || value['expression'] === undefined)
30
+ return false;
31
+ if (!('entityType' in value) || value['entityType'] === undefined)
32
+ return false;
33
+ if (!('enabled' in value) || value['enabled'] === undefined)
34
+ return false;
35
+ return true;
36
+ }
37
+ function RegexPatternUioFromJSON(json) {
38
+ return RegexPatternUioFromJSONTyped(json, false);
39
+ }
40
+ function RegexPatternUioFromJSONTyped(json, ignoreDiscriminator) {
41
+ if (json == null) {
42
+ return json;
43
+ }
44
+ return {
45
+ 'id': json['id'],
46
+ 'name': json['name'],
47
+ 'expression': json['expression'],
48
+ 'entityType': json['entityType'],
49
+ 'enabled': json['enabled'],
50
+ };
51
+ }
52
+ function RegexPatternUioToJSON(json) {
53
+ return RegexPatternUioToJSONTyped(json, false);
54
+ }
55
+ function RegexPatternUioToJSONTyped(value, ignoreDiscriminator = false) {
56
+ if (value == null) {
57
+ return value;
58
+ }
59
+ return {
60
+ 'id': value['id'],
61
+ 'name': value['name'],
62
+ 'expression': value['expression'],
63
+ 'entityType': value['entityType'],
64
+ 'enabled': value['enabled'],
65
+ };
66
+ }
@@ -63,6 +63,9 @@ export * from './AiGatewayModelListUio';
63
63
  export * from './AiGatewayModelUio';
64
64
  export * from './AnimationCreateRequestUio';
65
65
  export * from './AnimationUio';
66
+ export * from './AnonymizationStatusUio';
67
+ export * from './AnonymizeRequestUio';
68
+ export * from './AnonymizeResponseUio';
66
69
  export * from './ApiKeyCreateRequestUio';
67
70
  export * from './ApiKeyCreatedUio';
68
71
  export * from './ApiKeyRefUio';
@@ -247,6 +250,7 @@ export * from './LipsyncUio';
247
250
  export * from './ManifestCreateRequestUio';
248
251
  export * from './ManifestUio';
249
252
  export * from './MarkAttachmentProcessed400ResponseUio';
253
+ export * from './MessageAnonymizationUio';
250
254
  export * from './MessageAudioDownloadUrlUio';
251
255
  export * from './MessageStatusErrorUio';
252
256
  export * from './MessageStatusToolCallUio';
@@ -299,6 +303,7 @@ export * from './ProviderCreateRequestUio';
299
303
  export * from './ProviderTypeUio';
300
304
  export * from './ProviderUio';
301
305
  export * from './ProviderValiationRequestUio';
306
+ export * from './RegexPatternUio';
302
307
  export * from './RevealTokenRequestUio';
303
308
  export * from './RevealTokenResponseUio';
304
309
  export * from './RoleCreateRequestUio';
@@ -81,6 +81,9 @@ __exportStar(require("./AiGatewayModelListUio"), exports);
81
81
  __exportStar(require("./AiGatewayModelUio"), exports);
82
82
  __exportStar(require("./AnimationCreateRequestUio"), exports);
83
83
  __exportStar(require("./AnimationUio"), exports);
84
+ __exportStar(require("./AnonymizationStatusUio"), exports);
85
+ __exportStar(require("./AnonymizeRequestUio"), exports);
86
+ __exportStar(require("./AnonymizeResponseUio"), exports);
84
87
  __exportStar(require("./ApiKeyCreateRequestUio"), exports);
85
88
  __exportStar(require("./ApiKeyCreatedUio"), exports);
86
89
  __exportStar(require("./ApiKeyRefUio"), exports);
@@ -265,6 +268,7 @@ __exportStar(require("./LipsyncUio"), exports);
265
268
  __exportStar(require("./ManifestCreateRequestUio"), exports);
266
269
  __exportStar(require("./ManifestUio"), exports);
267
270
  __exportStar(require("./MarkAttachmentProcessed400ResponseUio"), exports);
271
+ __exportStar(require("./MessageAnonymizationUio"), exports);
268
272
  __exportStar(require("./MessageAudioDownloadUrlUio"), exports);
269
273
  __exportStar(require("./MessageStatusErrorUio"), exports);
270
274
  __exportStar(require("./MessageStatusToolCallUio"), exports);
@@ -317,6 +321,7 @@ __exportStar(require("./ProviderCreateRequestUio"), exports);
317
321
  __exportStar(require("./ProviderTypeUio"), exports);
318
322
  __exportStar(require("./ProviderUio"), exports);
319
323
  __exportStar(require("./ProviderValiationRequestUio"), exports);
324
+ __exportStar(require("./RegexPatternUio"), exports);
320
325
  __exportStar(require("./RevealTokenRequestUio"), exports);
321
326
  __exportStar(require("./RevealTokenResponseUio"), exports);
322
327
  __exportStar(require("./RoleCreateRequestUio"), exports);
package/dist/openapi.json CHANGED
@@ -5821,6 +5821,50 @@
5821
5821
  "tags" : [ "conversations" ]
5822
5822
  }
5823
5823
  },
5824
+ "/conversations/{conversationId}/anonymization" : {
5825
+ "get" : {
5826
+ "description" : "Retrieve the list of anonymized messages for a given conversation.",
5827
+ "operationId" : "getAnonymizedMessages",
5828
+ "parameters" : [ {
5829
+ "description" : "The ID of the conversation",
5830
+ "in" : "path",
5831
+ "name" : "conversationId",
5832
+ "required" : true,
5833
+ "schema" : {
5834
+ "type" : "string"
5835
+ }
5836
+ } ],
5837
+ "responses" : {
5838
+ "200" : {
5839
+ "content" : {
5840
+ "application/json" : {
5841
+ "schema" : {
5842
+ "items" : {
5843
+ "$ref" : "#/components/schemas/MessageAnonymization"
5844
+ },
5845
+ "type" : "array"
5846
+ }
5847
+ }
5848
+ },
5849
+ "description" : "Successfully retrieved the list of anonymized messages."
5850
+ },
5851
+ "401" : {
5852
+ "description" : "Unauthorized"
5853
+ },
5854
+ "403" : {
5855
+ "description" : "Forbidden - User cannot access this conversation"
5856
+ },
5857
+ "404" : {
5858
+ "description" : "Conversation not found"
5859
+ },
5860
+ "500" : {
5861
+ "description" : "Server error"
5862
+ }
5863
+ },
5864
+ "summary" : "Get the anonymized messages of a conversation",
5865
+ "tags" : [ "conversations" ]
5866
+ }
5867
+ },
5824
5868
  "/engines/default" : {
5825
5869
  "put" : {
5826
5870
  "description" : "Update the default engine for an organization",
@@ -7176,6 +7220,60 @@
7176
7220
  "tags" : [ "guardians" ]
7177
7221
  }
7178
7222
  },
7223
+ "/guardians/{guardianId}/anonymize" : {
7224
+ "post" : {
7225
+ "description" : "Test the Anonymization of a guardian",
7226
+ "operationId" : "testAnonymize",
7227
+ "parameters" : [ {
7228
+ "description" : "ID of the guardian",
7229
+ "in" : "path",
7230
+ "name" : "guardianId",
7231
+ "required" : true,
7232
+ "schema" : {
7233
+ "type" : "string"
7234
+ }
7235
+ } ],
7236
+ "requestBody" : {
7237
+ "content" : {
7238
+ "application/json" : {
7239
+ "schema" : {
7240
+ "$ref" : "#/components/schemas/AnonymizeRequest"
7241
+ }
7242
+ }
7243
+ },
7244
+ "required" : true
7245
+ },
7246
+ "responses" : {
7247
+ "200" : {
7248
+ "content" : {
7249
+ "application/json" : {
7250
+ "schema" : {
7251
+ "$ref" : "#/components/schemas/AnonymizeResponse"
7252
+ }
7253
+ }
7254
+ },
7255
+ "description" : "Text anonymized successfully"
7256
+ },
7257
+ "400" : {
7258
+ "description" : "Invalid request body"
7259
+ },
7260
+ "401" : {
7261
+ "description" : "Unauthorized"
7262
+ },
7263
+ "403" : {
7264
+ "description" : "Forbidden - User doesn't have permission"
7265
+ },
7266
+ "404" : {
7267
+ "description" : "Guardian not found"
7268
+ },
7269
+ "500" : {
7270
+ "description" : "Server error"
7271
+ }
7272
+ },
7273
+ "summary" : "Test the Anonymization of a guardian",
7274
+ "tags" : [ "guardians" ]
7275
+ }
7276
+ },
7179
7277
  "/organizations" : {
7180
7278
  "get" : {
7181
7279
  "description" : "Lists all organizations for the current user. Admins see all organizations.",
@@ -14840,6 +14938,9 @@
14840
14938
  "askConfirmation" : {
14841
14939
  "type" : "boolean"
14842
14940
  },
14941
+ "anonymizedContent" : {
14942
+ "type" : "string"
14943
+ },
14843
14944
  "confirmationLink" : {
14844
14945
  "type" : "string"
14845
14946
  },
@@ -16836,6 +16937,48 @@
16836
16937
  "required" : [ "content", "mimeType", "path", "size", "updatedAt", "version" ],
16837
16938
  "type" : "object"
16838
16939
  },
16940
+ "MessageAnonymization" : {
16941
+ "additionalProperties" : false,
16942
+ "properties" : {
16943
+ "id" : {
16944
+ "type" : "string"
16945
+ },
16946
+ "conversationId" : {
16947
+ "type" : "string"
16948
+ },
16949
+ "messageId" : {
16950
+ "type" : "string"
16951
+ },
16952
+ "guardianId" : {
16953
+ "type" : "string"
16954
+ },
16955
+ "originalContent" : {
16956
+ "type" : "string"
16957
+ },
16958
+ "anonymizedContent" : {
16959
+ "type" : "string"
16960
+ },
16961
+ "deanonymizedContent" : {
16962
+ "type" : "string"
16963
+ },
16964
+ "anonymizedReasoning" : {
16965
+ "type" : "string"
16966
+ },
16967
+ "status" : {
16968
+ "$ref" : "#/components/schemas/AnonymizationStatus"
16969
+ },
16970
+ "createdAt" : {
16971
+ "format" : "date-time",
16972
+ "type" : "string"
16973
+ },
16974
+ "updatedAt" : {
16975
+ "format" : "date-time",
16976
+ "type" : "string"
16977
+ }
16978
+ },
16979
+ "required" : [ "conversationId", "createdAt", "guardianId", "id", "messageId", "originalContent", "status", "updatedAt" ],
16980
+ "type" : "object"
16981
+ },
16839
16982
  "DefaultEngineRequest" : {
16840
16983
  "properties" : {
16841
16984
  "providerId" : {
@@ -17216,11 +17359,41 @@
17216
17359
  "type" : "string"
17217
17360
  },
17218
17361
  "type" : "array"
17362
+ },
17363
+ "useFaker" : {
17364
+ "type" : "boolean"
17365
+ },
17366
+ "regexPatterns" : {
17367
+ "items" : {
17368
+ "$ref" : "#/components/schemas/RegexPattern"
17369
+ },
17370
+ "type" : "array"
17219
17371
  }
17220
17372
  },
17221
17373
  "required" : [ "createdAt", "engine", "id", "organisationId", "role", "type" ],
17222
17374
  "type" : "object"
17223
17375
  },
17376
+ "RegexPattern" : {
17377
+ "properties" : {
17378
+ "id" : {
17379
+ "type" : "string"
17380
+ },
17381
+ "name" : {
17382
+ "type" : "string"
17383
+ },
17384
+ "expression" : {
17385
+ "type" : "string"
17386
+ },
17387
+ "entityType" : {
17388
+ "type" : "string"
17389
+ },
17390
+ "enabled" : {
17391
+ "type" : "boolean"
17392
+ }
17393
+ },
17394
+ "required" : [ "enabled", "entityType", "expression", "id", "name" ],
17395
+ "type" : "object"
17396
+ },
17224
17397
  "GuardianCreateRequest" : {
17225
17398
  "properties" : {
17226
17399
  "role" : {
@@ -17292,6 +17465,32 @@
17292
17465
  "excludedAgents" : {
17293
17466
  "items" : { },
17294
17467
  "type" : "array"
17468
+ },
17469
+ "regexPatterns" : {
17470
+ "items" : {
17471
+ "$ref" : "#/components/schemas/RegexPattern"
17472
+ },
17473
+ "type" : "array"
17474
+ },
17475
+ "useFaker" : {
17476
+ "type" : "boolean"
17477
+ }
17478
+ },
17479
+ "type" : "object"
17480
+ },
17481
+ "AnonymizeRequest" : {
17482
+ "properties" : {
17483
+ "prompt" : {
17484
+ "type" : "string"
17485
+ }
17486
+ },
17487
+ "required" : [ "prompt" ],
17488
+ "type" : "object"
17489
+ },
17490
+ "AnonymizeResponse" : {
17491
+ "properties" : {
17492
+ "anonymizedPrompt" : {
17493
+ "type" : "string"
17295
17494
  }
17296
17495
  },
17297
17496
  "type" : "object"
@@ -19303,6 +19502,10 @@
19303
19502
  "required" : [ "ext", "id", "key", "mimeType", "name", "size", "status", "type" ],
19304
19503
  "type" : "object"
19305
19504
  },
19505
+ "AnonymizationStatus" : {
19506
+ "enum" : [ "pending", "anonymized", "deanonymized", "error" ],
19507
+ "type" : "string"
19508
+ },
19306
19509
  "ProviderType" : {
19307
19510
  "enum" : [ "ollama", "openai", "mistral", "other", "gemini", "vllm", "vllm-responses", "anthropic" ],
19308
19511
  "type" : "string"
@@ -19312,7 +19515,7 @@
19312
19515
  "type" : "string"
19313
19516
  },
19314
19517
  "GuardianRole" : {
19315
- "enum" : [ "PROMPTCHECK", "WORDCHECK", "INTENTIONCHECK", "ATTACKCHECK", "ANONIMIZE" ],
19518
+ "enum" : [ "PROMPTCHECK", "WORDCHECK", "INTENTIONCHECK", "ATTACKCHECK", "ANONYMIZE" ],
19316
19519
  "type" : "string"
19317
19520
  },
19318
19521
  "GuardianEngine" : {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@breign/client",
3
- "version": "1.0.128",
3
+ "version": "1.0.129",
4
4
  "main": "dist/index.js",
5
5
  "exports": {
6
6
  ".": "./dist/index.js",