@breign/client 1.0.156 → 1.0.158
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/apis/ConversationsApi.d.ts +28 -1
- package/dist/apis/ConversationsApi.js +63 -0
- package/dist/apis/McpApi.d.ts +58 -0
- package/dist/apis/McpApi.js +154 -0
- package/dist/apis/MetricsApi.d.ts +16 -1
- package/dist/apis/MetricsApi.js +35 -0
- package/dist/apis/index.d.ts +1 -0
- package/dist/apis/index.js +1 -0
- package/dist/models/AgentChatOverviewEntryUio.d.ts +6 -0
- package/dist/models/AgentChatOverviewEntryUio.js +2 -0
- package/dist/models/AgentHumanEscalationConfigurationUio.d.ts +44 -0
- package/dist/models/AgentHumanEscalationConfigurationUio.js +52 -0
- package/dist/models/AgentMcpExposureConfigurationUio.d.ts +32 -0
- package/dist/models/AgentMcpExposureConfigurationUio.js +48 -0
- package/dist/models/AgentPatchUio.d.ts +17 -3
- package/dist/models/AgentPatchUio.js +9 -3
- package/dist/models/AgentUio.d.ts +14 -0
- package/dist/models/AgentUio.js +6 -0
- package/dist/models/ChatMessageUio.d.ts +7 -0
- package/dist/models/ChatMessageUio.js +3 -0
- package/dist/models/ConversationHumanRequestRequestedByUio.d.ts +46 -0
- package/dist/models/ConversationHumanRequestRequestedByUio.js +60 -0
- package/dist/models/ConversationHumanRequestUio.d.ts +109 -0
- package/dist/models/ConversationHumanRequestUio.js +93 -0
- package/dist/models/HumanRequestAnswerResultUio.d.ts +40 -0
- package/dist/models/HumanRequestAnswerResultUio.js +58 -0
- package/dist/models/HumanRequestAnswerUio.d.ts +38 -0
- package/dist/models/HumanRequestAnswerUio.js +50 -0
- package/dist/models/HumanRequestSummaryRequestedByUio.d.ts +46 -0
- package/dist/models/HumanRequestSummaryRequestedByUio.js +58 -0
- package/dist/models/HumanRequestSummaryUio.d.ts +93 -0
- package/dist/models/HumanRequestSummaryUio.js +81 -0
- package/dist/models/McpAgentListAgentsInnerUio.d.ts +50 -0
- package/dist/models/McpAgentListAgentsInnerUio.js +58 -0
- package/dist/models/McpAgentListUio.d.ts +33 -0
- package/dist/models/McpAgentListUio.js +51 -0
- package/dist/models/McpCallToolResultStructuredContentUio.d.ts +23 -0
- package/dist/models/McpCallToolResultStructuredContentUio.js +57 -0
- package/dist/models/McpCallToolResultUio.d.ts +47 -0
- package/dist/models/McpCallToolResultUio.js +56 -0
- package/dist/models/McpJsonRpcErrorUio.d.ts +38 -0
- package/dist/models/McpJsonRpcErrorUio.js +54 -0
- package/dist/models/McpJsonRpcRequestIdUio.d.ts +21 -0
- package/dist/models/McpJsonRpcRequestIdUio.js +37 -0
- package/dist/models/McpJsonRpcRequestUio.d.ts +60 -0
- package/dist/models/McpJsonRpcRequestUio.js +66 -0
- package/dist/models/McpJsonRpcResponseIdUio.d.ts +21 -0
- package/dist/models/McpJsonRpcResponseIdUio.js +37 -0
- package/dist/models/McpJsonRpcResponseUio.d.ts +60 -0
- package/dist/models/McpJsonRpcResponseUio.js +66 -0
- package/dist/models/McpTextContentUio.d.ts +45 -0
- package/dist/models/McpTextContentUio.js +61 -0
- package/dist/models/McpTicketViewUio.d.ts +114 -0
- package/dist/models/McpTicketViewUio.js +90 -0
- package/dist/models/ModelConsumptionItemUio.d.ts +81 -0
- package/dist/models/ModelConsumptionItemUio.js +83 -0
- package/dist/models/ModelConsumptionSliceUio.d.ts +78 -0
- package/dist/models/ModelConsumptionSliceUio.js +84 -0
- package/dist/models/OrganizationModelConsumptionTotalUio.d.ts +56 -0
- package/dist/models/OrganizationModelConsumptionTotalUio.js +66 -0
- package/dist/models/OrganizationModelConsumptionUio.d.ts +40 -0
- package/dist/models/OrganizationModelConsumptionUio.js +56 -0
- package/dist/models/index.d.ts +23 -0
- package/dist/models/index.js +23 -0
- package/dist/openapi.json +797 -10
- package/package.json +1 -1
|
@@ -10,7 +10,11 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { AgentChatOverviewEntryUio, AttachmentCreateRequestUio, AttachmentCreateResponseUio, AttachmentDetailsResponseUio, AttachmentProcessedRequestUio, BodyWithMessageUio, ContextLocationRequestUio, ContextUio, ConversationSummaryUio, CreateCustomVariable200ResponseUio, MarkConversationReadRequestUio, MessageAnonymizationUio, SetUserAgentConversationRequestUio, ToolCallResultRequestUio, ToolCallResultResponseUio, ToolCallsResponseUio, UpdateConversationTitleRequestUio, UpdateUserChatPreferencesRequestUio, UserChatPreferencesUio, WorkspaceFileContentUio, WorkspaceFileEntryUio, WorkspaceFileWriteRequestUio } from '../models/index';
|
|
13
|
+
import type { AgentChatOverviewEntryUio, AttachmentCreateRequestUio, AttachmentCreateResponseUio, AttachmentDetailsResponseUio, AttachmentProcessedRequestUio, BodyWithMessageUio, ContextLocationRequestUio, ContextUio, ConversationSummaryUio, CreateCustomVariable200ResponseUio, HumanRequestAnswerResultUio, HumanRequestAnswerUio, HumanRequestSummaryUio, MarkConversationReadRequestUio, MessageAnonymizationUio, SetUserAgentConversationRequestUio, ToolCallResultRequestUio, ToolCallResultResponseUio, ToolCallsResponseUio, UpdateConversationTitleRequestUio, UpdateUserChatPreferencesRequestUio, UserChatPreferencesUio, WorkspaceFileContentUio, WorkspaceFileEntryUio, WorkspaceFileWriteRequestUio } from '../models/index';
|
|
14
|
+
export interface AnswerHumanRequestRequest {
|
|
15
|
+
callId: string;
|
|
16
|
+
humanRequestAnswerUio: HumanRequestAnswerUio;
|
|
17
|
+
}
|
|
14
18
|
export interface ArchiveConversationByIdRequest {
|
|
15
19
|
conversationId: string;
|
|
16
20
|
}
|
|
@@ -82,6 +86,9 @@ export interface ListMessageToolCallsRequest {
|
|
|
82
86
|
messageId: string;
|
|
83
87
|
pending?: boolean;
|
|
84
88
|
}
|
|
89
|
+
export interface ListPendingHumanRequestsRequest {
|
|
90
|
+
organizationId: string;
|
|
91
|
+
}
|
|
85
92
|
export interface MarkAttachmentProcessedRequest {
|
|
86
93
|
conversationId: string;
|
|
87
94
|
attachmentId: string;
|
|
@@ -126,6 +133,16 @@ export interface UploadAttachmentRequest {
|
|
|
126
133
|
*
|
|
127
134
|
*/
|
|
128
135
|
export declare class ConversationsApi extends runtime.BaseAPI {
|
|
136
|
+
/**
|
|
137
|
+
* Répond (ou décline) une question posée par un agent via Human_ask. Termine l\'appel différé et relance le tour de la tâche en arrière-plan. Seul l\'humain à qui la question a été adressée peut y répondre.
|
|
138
|
+
* Answer a question asked by an agent
|
|
139
|
+
*/
|
|
140
|
+
answerHumanRequestRaw(requestParameters: AnswerHumanRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<HumanRequestAnswerResultUio>>;
|
|
141
|
+
/**
|
|
142
|
+
* Répond (ou décline) une question posée par un agent via Human_ask. Termine l\'appel différé et relance le tour de la tâche en arrière-plan. Seul l\'humain à qui la question a été adressée peut y répondre.
|
|
143
|
+
* Answer a question asked by an agent
|
|
144
|
+
*/
|
|
145
|
+
answerHumanRequest(callId: string, humanRequestAnswerUio: HumanRequestAnswerUio, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<HumanRequestAnswerResultUio>;
|
|
129
146
|
/**
|
|
130
147
|
* Archives a specific conversation by its ID.
|
|
131
148
|
* Archive a conversation.
|
|
@@ -312,6 +329,16 @@ export declare class ConversationsApi extends runtime.BaseAPI {
|
|
|
312
329
|
* List the tool calls of a message
|
|
313
330
|
*/
|
|
314
331
|
listMessageToolCalls(conversationId: string, messageId: string, pending?: boolean, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ToolCallsResponseUio>;
|
|
332
|
+
/**
|
|
333
|
+
* Questions posées par des agents (outil Human_ask) depuis des conversations de tâche et qui attendent une réponse de l\'utilisateur courant. Les questions échues sont expirées au passage et n\'apparaissent pas.
|
|
334
|
+
* List the questions waiting for the current user
|
|
335
|
+
*/
|
|
336
|
+
listPendingHumanRequestsRaw(requestParameters: ListPendingHumanRequestsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<HumanRequestSummaryUio>>>;
|
|
337
|
+
/**
|
|
338
|
+
* Questions posées par des agents (outil Human_ask) depuis des conversations de tâche et qui attendent une réponse de l\'utilisateur courant. Les questions échues sont expirées au passage et n\'apparaissent pas.
|
|
339
|
+
* List the questions waiting for the current user
|
|
340
|
+
*/
|
|
341
|
+
listPendingHumanRequests(organizationId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<HumanRequestSummaryUio>>;
|
|
315
342
|
/**
|
|
316
343
|
* Internal callback endpoint called when attachment processing is complete. Réservé au service de documents : tout autre appelant reçoit un 403. L\'attachment doit être en état `PROCESSING`.
|
|
317
344
|
* Mark a conversation attachment as processed
|
|
@@ -53,6 +53,40 @@ const index_1 = require("../models/index");
|
|
|
53
53
|
*
|
|
54
54
|
*/
|
|
55
55
|
class ConversationsApi extends runtime.BaseAPI {
|
|
56
|
+
/**
|
|
57
|
+
* Répond (ou décline) une question posée par un agent via Human_ask. Termine l\'appel différé et relance le tour de la tâche en arrière-plan. Seul l\'humain à qui la question a été adressée peut y répondre.
|
|
58
|
+
* Answer a question asked by an agent
|
|
59
|
+
*/
|
|
60
|
+
async answerHumanRequestRaw(requestParameters, initOverrides) {
|
|
61
|
+
if (requestParameters['callId'] == null) {
|
|
62
|
+
throw new runtime.RequiredError('callId', 'Required parameter "callId" was null or undefined when calling answerHumanRequest().');
|
|
63
|
+
}
|
|
64
|
+
if (requestParameters['humanRequestAnswerUio'] == null) {
|
|
65
|
+
throw new runtime.RequiredError('humanRequestAnswerUio', 'Required parameter "humanRequestAnswerUio" was null or undefined when calling answerHumanRequest().');
|
|
66
|
+
}
|
|
67
|
+
const queryParameters = {};
|
|
68
|
+
const headerParameters = {};
|
|
69
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
70
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
71
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
72
|
+
}
|
|
73
|
+
const response = await this.request({
|
|
74
|
+
path: `/human-requests/{callId}/answer`.replace(`{${"callId"}}`, encodeURIComponent(String(requestParameters['callId']))),
|
|
75
|
+
method: 'POST',
|
|
76
|
+
headers: headerParameters,
|
|
77
|
+
query: queryParameters,
|
|
78
|
+
body: (0, index_1.HumanRequestAnswerUioToJSON)(requestParameters['humanRequestAnswerUio']),
|
|
79
|
+
}, initOverrides);
|
|
80
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.HumanRequestAnswerResultUioFromJSON)(jsonValue));
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Répond (ou décline) une question posée par un agent via Human_ask. Termine l\'appel différé et relance le tour de la tâche en arrière-plan. Seul l\'humain à qui la question a été adressée peut y répondre.
|
|
84
|
+
* Answer a question asked by an agent
|
|
85
|
+
*/
|
|
86
|
+
async answerHumanRequest(callId, humanRequestAnswerUio, initOverrides) {
|
|
87
|
+
const response = await this.answerHumanRequestRaw({ callId: callId, humanRequestAnswerUio: humanRequestAnswerUio }, initOverrides);
|
|
88
|
+
return await response.value();
|
|
89
|
+
}
|
|
56
90
|
/**
|
|
57
91
|
* Archives a specific conversation by its ID.
|
|
58
92
|
* Archive a conversation.
|
|
@@ -630,6 +664,35 @@ class ConversationsApi extends runtime.BaseAPI {
|
|
|
630
664
|
const response = await this.listMessageToolCallsRaw({ conversationId: conversationId, messageId: messageId, pending: pending }, initOverrides);
|
|
631
665
|
return await response.value();
|
|
632
666
|
}
|
|
667
|
+
/**
|
|
668
|
+
* Questions posées par des agents (outil Human_ask) depuis des conversations de tâche et qui attendent une réponse de l\'utilisateur courant. Les questions échues sont expirées au passage et n\'apparaissent pas.
|
|
669
|
+
* List the questions waiting for the current user
|
|
670
|
+
*/
|
|
671
|
+
async listPendingHumanRequestsRaw(requestParameters, initOverrides) {
|
|
672
|
+
if (requestParameters['organizationId'] == null) {
|
|
673
|
+
throw new runtime.RequiredError('organizationId', 'Required parameter "organizationId" was null or undefined when calling listPendingHumanRequests().');
|
|
674
|
+
}
|
|
675
|
+
const queryParameters = {};
|
|
676
|
+
const headerParameters = {};
|
|
677
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
678
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
679
|
+
}
|
|
680
|
+
const response = await this.request({
|
|
681
|
+
path: `/organizations/{organizationId}/chat/human-requests`.replace(`{${"organizationId"}}`, encodeURIComponent(String(requestParameters['organizationId']))),
|
|
682
|
+
method: 'GET',
|
|
683
|
+
headers: headerParameters,
|
|
684
|
+
query: queryParameters,
|
|
685
|
+
}, initOverrides);
|
|
686
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(index_1.HumanRequestSummaryUioFromJSON));
|
|
687
|
+
}
|
|
688
|
+
/**
|
|
689
|
+
* Questions posées par des agents (outil Human_ask) depuis des conversations de tâche et qui attendent une réponse de l\'utilisateur courant. Les questions échues sont expirées au passage et n\'apparaissent pas.
|
|
690
|
+
* List the questions waiting for the current user
|
|
691
|
+
*/
|
|
692
|
+
async listPendingHumanRequests(organizationId, initOverrides) {
|
|
693
|
+
const response = await this.listPendingHumanRequestsRaw({ organizationId: organizationId }, initOverrides);
|
|
694
|
+
return await response.value();
|
|
695
|
+
}
|
|
633
696
|
/**
|
|
634
697
|
* Internal callback endpoint called when attachment processing is complete. Réservé au service de documents : tout autre appelant reçoit un 403. L\'attachment doit être en état `PROCESSING`.
|
|
635
698
|
* Mark a conversation attachment as processed
|
|
@@ -0,0 +1,58 @@
|
|
|
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 * as runtime from '../runtime';
|
|
13
|
+
import type { McpJsonRpcRequestUio, McpJsonRpcResponseUio } from '../models/index';
|
|
14
|
+
export interface DeleteMcpSessionRequest {
|
|
15
|
+
organizationId: string;
|
|
16
|
+
}
|
|
17
|
+
export interface GetMcpStreamRequest {
|
|
18
|
+
organizationId: string;
|
|
19
|
+
}
|
|
20
|
+
export interface HandleMcpRequestRequest {
|
|
21
|
+
organizationId: string;
|
|
22
|
+
mcpJsonRpcRequestUio: McpJsonRpcRequestUio;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
export declare class McpApi extends runtime.BaseAPI {
|
|
28
|
+
/**
|
|
29
|
+
* Aucune session à clore : le transport est sans état.
|
|
30
|
+
* Not supported (stateless MCP server)
|
|
31
|
+
*/
|
|
32
|
+
deleteMcpSessionRaw(requestParameters: DeleteMcpSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
33
|
+
/**
|
|
34
|
+
* Aucune session à clore : le transport est sans état.
|
|
35
|
+
* Not supported (stateless MCP server)
|
|
36
|
+
*/
|
|
37
|
+
deleteMcpSession(organizationId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
38
|
+
/**
|
|
39
|
+
* Pas de flux SSE côté serveur : le transport est sans état.
|
|
40
|
+
* Not supported (stateless MCP server)
|
|
41
|
+
*/
|
|
42
|
+
getMcpStreamRaw(requestParameters: GetMcpStreamRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
43
|
+
/**
|
|
44
|
+
* Pas de flux SSE côté serveur : le transport est sans état.
|
|
45
|
+
* Not supported (stateless MCP server)
|
|
46
|
+
*/
|
|
47
|
+
getMcpStream(organizationId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
48
|
+
/**
|
|
49
|
+
* Serveur MCP (Model Context Protocol, transport Streamable HTTP, sans état) par lequel les agents locaux — Claude Code, Pi, Hermes… — interrogent les agents Breign de l\'organisation. Authentification par clé API personnelle (`x-api-key` ou `Authorization: Bearer ai-…`) ; les credentials d\'app et la clé maître sans `x-user-id` sont refusés. Seuls les agents dont `mcpExposureConfiguration.enabled` est vrai sont joignables. Outils exposés : - `list_agents` — agents joignables, avec leur rôle et leur description. - `ask_agent` `{ agentId, message, conversationId?, waitSeconds? }` — pose une question ; attend la réponse jusqu\'à `waitSeconds` (25 s par défaut, 50 s max), sinon rend un ticket. - `wait_for_reply` `{ ticket, timeoutSeconds? }` — attend la réponse d\'un ticket (45 s par défaut, 50 s max). Chaque question vit dans une conversation de tâche au nom du propriétaire de la clé. L\'agent interrogé peut consulter d\'autres agents ou poser une question à un humain (outil Human_ask) : le statut vaut alors `waiting_human`, parfois pendant des heures. Configuration d\'un client, par exemple Claude Code : `claude mcp add --transport http breign https://<api>/organizations/<organizationId>/mcp --header \"Authorization: Bearer ai-…\"`. Le client doit accepter `application/json` et `text/event-stream` (header `Accept`).
|
|
50
|
+
* MCP server for local agents
|
|
51
|
+
*/
|
|
52
|
+
handleMcpRequestRaw(requestParameters: HandleMcpRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<McpJsonRpcResponseUio>>;
|
|
53
|
+
/**
|
|
54
|
+
* Serveur MCP (Model Context Protocol, transport Streamable HTTP, sans état) par lequel les agents locaux — Claude Code, Pi, Hermes… — interrogent les agents Breign de l\'organisation. Authentification par clé API personnelle (`x-api-key` ou `Authorization: Bearer ai-…`) ; les credentials d\'app et la clé maître sans `x-user-id` sont refusés. Seuls les agents dont `mcpExposureConfiguration.enabled` est vrai sont joignables. Outils exposés : - `list_agents` — agents joignables, avec leur rôle et leur description. - `ask_agent` `{ agentId, message, conversationId?, waitSeconds? }` — pose une question ; attend la réponse jusqu\'à `waitSeconds` (25 s par défaut, 50 s max), sinon rend un ticket. - `wait_for_reply` `{ ticket, timeoutSeconds? }` — attend la réponse d\'un ticket (45 s par défaut, 50 s max). Chaque question vit dans une conversation de tâche au nom du propriétaire de la clé. L\'agent interrogé peut consulter d\'autres agents ou poser une question à un humain (outil Human_ask) : le statut vaut alors `waiting_human`, parfois pendant des heures. Configuration d\'un client, par exemple Claude Code : `claude mcp add --transport http breign https://<api>/organizations/<organizationId>/mcp --header \"Authorization: Bearer ai-…\"`. Le client doit accepter `application/json` et `text/event-stream` (header `Accept`).
|
|
55
|
+
* MCP server for local agents
|
|
56
|
+
*/
|
|
57
|
+
handleMcpRequest(organizationId: string, mcpJsonRpcRequestUio: McpJsonRpcRequestUio, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<McpJsonRpcResponseUio | null | undefined>;
|
|
58
|
+
}
|
|
@@ -0,0 +1,154 @@
|
|
|
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
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
16
|
+
if (k2 === undefined) k2 = k;
|
|
17
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
18
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
19
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
20
|
+
}
|
|
21
|
+
Object.defineProperty(o, k2, desc);
|
|
22
|
+
}) : (function(o, m, k, k2) {
|
|
23
|
+
if (k2 === undefined) k2 = k;
|
|
24
|
+
o[k2] = m[k];
|
|
25
|
+
}));
|
|
26
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
27
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
28
|
+
}) : function(o, v) {
|
|
29
|
+
o["default"] = v;
|
|
30
|
+
});
|
|
31
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
32
|
+
var ownKeys = function(o) {
|
|
33
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
34
|
+
var ar = [];
|
|
35
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
36
|
+
return ar;
|
|
37
|
+
};
|
|
38
|
+
return ownKeys(o);
|
|
39
|
+
};
|
|
40
|
+
return function (mod) {
|
|
41
|
+
if (mod && mod.__esModule) return mod;
|
|
42
|
+
var result = {};
|
|
43
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
44
|
+
__setModuleDefault(result, mod);
|
|
45
|
+
return result;
|
|
46
|
+
};
|
|
47
|
+
})();
|
|
48
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
49
|
+
exports.McpApi = void 0;
|
|
50
|
+
const runtime = __importStar(require("../runtime"));
|
|
51
|
+
const index_1 = require("../models/index");
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
*/
|
|
55
|
+
class McpApi extends runtime.BaseAPI {
|
|
56
|
+
/**
|
|
57
|
+
* Aucune session à clore : le transport est sans état.
|
|
58
|
+
* Not supported (stateless MCP server)
|
|
59
|
+
*/
|
|
60
|
+
async deleteMcpSessionRaw(requestParameters, initOverrides) {
|
|
61
|
+
if (requestParameters['organizationId'] == null) {
|
|
62
|
+
throw new runtime.RequiredError('organizationId', 'Required parameter "organizationId" was null or undefined when calling deleteMcpSession().');
|
|
63
|
+
}
|
|
64
|
+
const queryParameters = {};
|
|
65
|
+
const headerParameters = {};
|
|
66
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
67
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
68
|
+
}
|
|
69
|
+
const response = await this.request({
|
|
70
|
+
path: `/organizations/{organizationId}/mcp`.replace(`{${"organizationId"}}`, encodeURIComponent(String(requestParameters['organizationId']))),
|
|
71
|
+
method: 'DELETE',
|
|
72
|
+
headers: headerParameters,
|
|
73
|
+
query: queryParameters,
|
|
74
|
+
}, initOverrides);
|
|
75
|
+
return new runtime.VoidApiResponse(response);
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Aucune session à clore : le transport est sans état.
|
|
79
|
+
* Not supported (stateless MCP server)
|
|
80
|
+
*/
|
|
81
|
+
async deleteMcpSession(organizationId, initOverrides) {
|
|
82
|
+
await this.deleteMcpSessionRaw({ organizationId: organizationId }, initOverrides);
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Pas de flux SSE côté serveur : le transport est sans état.
|
|
86
|
+
* Not supported (stateless MCP server)
|
|
87
|
+
*/
|
|
88
|
+
async getMcpStreamRaw(requestParameters, initOverrides) {
|
|
89
|
+
if (requestParameters['organizationId'] == null) {
|
|
90
|
+
throw new runtime.RequiredError('organizationId', 'Required parameter "organizationId" was null or undefined when calling getMcpStream().');
|
|
91
|
+
}
|
|
92
|
+
const queryParameters = {};
|
|
93
|
+
const headerParameters = {};
|
|
94
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
95
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
96
|
+
}
|
|
97
|
+
const response = await this.request({
|
|
98
|
+
path: `/organizations/{organizationId}/mcp`.replace(`{${"organizationId"}}`, encodeURIComponent(String(requestParameters['organizationId']))),
|
|
99
|
+
method: 'GET',
|
|
100
|
+
headers: headerParameters,
|
|
101
|
+
query: queryParameters,
|
|
102
|
+
}, initOverrides);
|
|
103
|
+
return new runtime.VoidApiResponse(response);
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Pas de flux SSE côté serveur : le transport est sans état.
|
|
107
|
+
* Not supported (stateless MCP server)
|
|
108
|
+
*/
|
|
109
|
+
async getMcpStream(organizationId, initOverrides) {
|
|
110
|
+
await this.getMcpStreamRaw({ organizationId: organizationId }, initOverrides);
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Serveur MCP (Model Context Protocol, transport Streamable HTTP, sans état) par lequel les agents locaux — Claude Code, Pi, Hermes… — interrogent les agents Breign de l\'organisation. Authentification par clé API personnelle (`x-api-key` ou `Authorization: Bearer ai-…`) ; les credentials d\'app et la clé maître sans `x-user-id` sont refusés. Seuls les agents dont `mcpExposureConfiguration.enabled` est vrai sont joignables. Outils exposés : - `list_agents` — agents joignables, avec leur rôle et leur description. - `ask_agent` `{ agentId, message, conversationId?, waitSeconds? }` — pose une question ; attend la réponse jusqu\'à `waitSeconds` (25 s par défaut, 50 s max), sinon rend un ticket. - `wait_for_reply` `{ ticket, timeoutSeconds? }` — attend la réponse d\'un ticket (45 s par défaut, 50 s max). Chaque question vit dans une conversation de tâche au nom du propriétaire de la clé. L\'agent interrogé peut consulter d\'autres agents ou poser une question à un humain (outil Human_ask) : le statut vaut alors `waiting_human`, parfois pendant des heures. Configuration d\'un client, par exemple Claude Code : `claude mcp add --transport http breign https://<api>/organizations/<organizationId>/mcp --header \"Authorization: Bearer ai-…\"`. Le client doit accepter `application/json` et `text/event-stream` (header `Accept`).
|
|
114
|
+
* MCP server for local agents
|
|
115
|
+
*/
|
|
116
|
+
async handleMcpRequestRaw(requestParameters, initOverrides) {
|
|
117
|
+
if (requestParameters['organizationId'] == null) {
|
|
118
|
+
throw new runtime.RequiredError('organizationId', 'Required parameter "organizationId" was null or undefined when calling handleMcpRequest().');
|
|
119
|
+
}
|
|
120
|
+
if (requestParameters['mcpJsonRpcRequestUio'] == null) {
|
|
121
|
+
throw new runtime.RequiredError('mcpJsonRpcRequestUio', 'Required parameter "mcpJsonRpcRequestUio" was null or undefined when calling handleMcpRequest().');
|
|
122
|
+
}
|
|
123
|
+
const queryParameters = {};
|
|
124
|
+
const headerParameters = {};
|
|
125
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
126
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
127
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
128
|
+
}
|
|
129
|
+
const response = await this.request({
|
|
130
|
+
path: `/organizations/{organizationId}/mcp`.replace(`{${"organizationId"}}`, encodeURIComponent(String(requestParameters['organizationId']))),
|
|
131
|
+
method: 'POST',
|
|
132
|
+
headers: headerParameters,
|
|
133
|
+
query: queryParameters,
|
|
134
|
+
body: (0, index_1.McpJsonRpcRequestUioToJSON)(requestParameters['mcpJsonRpcRequestUio']),
|
|
135
|
+
}, initOverrides);
|
|
136
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.McpJsonRpcResponseUioFromJSON)(jsonValue));
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Serveur MCP (Model Context Protocol, transport Streamable HTTP, sans état) par lequel les agents locaux — Claude Code, Pi, Hermes… — interrogent les agents Breign de l\'organisation. Authentification par clé API personnelle (`x-api-key` ou `Authorization: Bearer ai-…`) ; les credentials d\'app et la clé maître sans `x-user-id` sont refusés. Seuls les agents dont `mcpExposureConfiguration.enabled` est vrai sont joignables. Outils exposés : - `list_agents` — agents joignables, avec leur rôle et leur description. - `ask_agent` `{ agentId, message, conversationId?, waitSeconds? }` — pose une question ; attend la réponse jusqu\'à `waitSeconds` (25 s par défaut, 50 s max), sinon rend un ticket. - `wait_for_reply` `{ ticket, timeoutSeconds? }` — attend la réponse d\'un ticket (45 s par défaut, 50 s max). Chaque question vit dans une conversation de tâche au nom du propriétaire de la clé. L\'agent interrogé peut consulter d\'autres agents ou poser une question à un humain (outil Human_ask) : le statut vaut alors `waiting_human`, parfois pendant des heures. Configuration d\'un client, par exemple Claude Code : `claude mcp add --transport http breign https://<api>/organizations/<organizationId>/mcp --header \"Authorization: Bearer ai-…\"`. Le client doit accepter `application/json` et `text/event-stream` (header `Accept`).
|
|
140
|
+
* MCP server for local agents
|
|
141
|
+
*/
|
|
142
|
+
async handleMcpRequest(organizationId, mcpJsonRpcRequestUio, initOverrides) {
|
|
143
|
+
const response = await this.handleMcpRequestRaw({ organizationId: organizationId, mcpJsonRpcRequestUio: mcpJsonRpcRequestUio }, initOverrides);
|
|
144
|
+
switch (response.raw.status) {
|
|
145
|
+
case 200:
|
|
146
|
+
return await response.value();
|
|
147
|
+
case 202:
|
|
148
|
+
return null;
|
|
149
|
+
default:
|
|
150
|
+
return await response.value();
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
exports.McpApi = McpApi;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { EphemeralInstancesMetricsResponseUio, MetricForAgentUio, MetricForDayInnerUio, MetricUio, MetricsBrainsAgentResponseUio, MetricsTopAgentsResponseInnerUio, MetricsTopAgentsUsageResponseInnerUio, MetricsUsersResponseUio, OrgUsageMetricsResponseUio } from '../models/index';
|
|
13
|
+
import type { EphemeralInstancesMetricsResponseUio, MetricForAgentUio, MetricForDayInnerUio, MetricUio, MetricsBrainsAgentResponseUio, MetricsTopAgentsResponseInnerUio, MetricsTopAgentsUsageResponseInnerUio, MetricsUsersResponseUio, OrgUsageMetricsResponseUio, OrganizationModelConsumptionUio } from '../models/index';
|
|
14
14
|
export interface GetBrainsMetricsRequest {
|
|
15
15
|
startDate?: string;
|
|
16
16
|
endDate?: string;
|
|
@@ -34,6 +34,11 @@ export interface GetMetricsOrganizationEphemeralInstancesRequest {
|
|
|
34
34
|
endDate?: string;
|
|
35
35
|
granularity?: GetMetricsOrganizationEphemeralInstancesGranularityEnum;
|
|
36
36
|
}
|
|
37
|
+
export interface GetMetricsOrganizationModelConsumptionRequest {
|
|
38
|
+
organizationId: string;
|
|
39
|
+
startDate?: string;
|
|
40
|
+
endDate?: string;
|
|
41
|
+
}
|
|
37
42
|
export interface GetMetricsOrganizationUsageRequest {
|
|
38
43
|
organizationId: string;
|
|
39
44
|
startDate?: string;
|
|
@@ -111,6 +116,16 @@ export declare class MetricsApi extends runtime.BaseAPI {
|
|
|
111
116
|
* Get ephemeral instances metrics for an organization
|
|
112
117
|
*/
|
|
113
118
|
getMetricsOrganizationEphemeralInstances(organizationId: string, startDate?: string, endDate?: string, granularity?: GetMetricsOrganizationEphemeralInstancesGranularityEnum, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<EphemeralInstancesMetricsResponseUio>;
|
|
119
|
+
/**
|
|
120
|
+
* Tokens consumed by model and provider, split between agents, organization costs without an agent, direct AI Gateway calls, and users. Restricted to organization administrators.
|
|
121
|
+
* Get model consumption for an organization
|
|
122
|
+
*/
|
|
123
|
+
getMetricsOrganizationModelConsumptionRaw(requestParameters: GetMetricsOrganizationModelConsumptionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<OrganizationModelConsumptionUio>>;
|
|
124
|
+
/**
|
|
125
|
+
* Tokens consumed by model and provider, split between agents, organization costs without an agent, direct AI Gateway calls, and users. Restricted to organization administrators.
|
|
126
|
+
* Get model consumption for an organization
|
|
127
|
+
*/
|
|
128
|
+
getMetricsOrganizationModelConsumption(organizationId: string, startDate?: string, endDate?: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<OrganizationModelConsumptionUio>;
|
|
114
129
|
/**
|
|
115
130
|
* Returns LLM requests and token usage over time for all agents in the organization
|
|
116
131
|
* Get usage metrics for an organization
|
package/dist/apis/MetricsApi.js
CHANGED
|
@@ -222,6 +222,41 @@ class MetricsApi extends runtime.BaseAPI {
|
|
|
222
222
|
const response = await this.getMetricsOrganizationEphemeralInstancesRaw({ organizationId: organizationId, startDate: startDate, endDate: endDate, granularity: granularity }, initOverrides);
|
|
223
223
|
return await response.value();
|
|
224
224
|
}
|
|
225
|
+
/**
|
|
226
|
+
* Tokens consumed by model and provider, split between agents, organization costs without an agent, direct AI Gateway calls, and users. Restricted to organization administrators.
|
|
227
|
+
* Get model consumption for an organization
|
|
228
|
+
*/
|
|
229
|
+
async getMetricsOrganizationModelConsumptionRaw(requestParameters, initOverrides) {
|
|
230
|
+
if (requestParameters['organizationId'] == null) {
|
|
231
|
+
throw new runtime.RequiredError('organizationId', 'Required parameter "organizationId" was null or undefined when calling getMetricsOrganizationModelConsumption().');
|
|
232
|
+
}
|
|
233
|
+
const queryParameters = {};
|
|
234
|
+
if (requestParameters['startDate'] != null) {
|
|
235
|
+
queryParameters['startDate'] = requestParameters['startDate'];
|
|
236
|
+
}
|
|
237
|
+
if (requestParameters['endDate'] != null) {
|
|
238
|
+
queryParameters['endDate'] = requestParameters['endDate'];
|
|
239
|
+
}
|
|
240
|
+
const headerParameters = {};
|
|
241
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
242
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
243
|
+
}
|
|
244
|
+
const response = await this.request({
|
|
245
|
+
path: `/metrics/organizations/{organizationId}/model-consumption`.replace(`{${"organizationId"}}`, encodeURIComponent(String(requestParameters['organizationId']))),
|
|
246
|
+
method: 'GET',
|
|
247
|
+
headers: headerParameters,
|
|
248
|
+
query: queryParameters,
|
|
249
|
+
}, initOverrides);
|
|
250
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OrganizationModelConsumptionUioFromJSON)(jsonValue));
|
|
251
|
+
}
|
|
252
|
+
/**
|
|
253
|
+
* Tokens consumed by model and provider, split between agents, organization costs without an agent, direct AI Gateway calls, and users. Restricted to organization administrators.
|
|
254
|
+
* Get model consumption for an organization
|
|
255
|
+
*/
|
|
256
|
+
async getMetricsOrganizationModelConsumption(organizationId, startDate, endDate, initOverrides) {
|
|
257
|
+
const response = await this.getMetricsOrganizationModelConsumptionRaw({ organizationId: organizationId, startDate: startDate, endDate: endDate }, initOverrides);
|
|
258
|
+
return await response.value();
|
|
259
|
+
}
|
|
225
260
|
/**
|
|
226
261
|
* Returns LLM requests and token usage over time for all agents in the organization
|
|
227
262
|
* Get usage metrics for an organization
|
package/dist/apis/index.d.ts
CHANGED
|
@@ -16,6 +16,7 @@ export * from './InstancesApi';
|
|
|
16
16
|
export * from './KnowledgeApi';
|
|
17
17
|
export * from './LibraryAgentsApi';
|
|
18
18
|
export * from './ManifestsApi';
|
|
19
|
+
export * from './McpApi';
|
|
19
20
|
export * from './MetricsApi';
|
|
20
21
|
export * from './OrganizationsApi';
|
|
21
22
|
export * from './PromptsApi';
|
package/dist/apis/index.js
CHANGED
|
@@ -34,6 +34,7 @@ __exportStar(require("./InstancesApi"), exports);
|
|
|
34
34
|
__exportStar(require("./KnowledgeApi"), exports);
|
|
35
35
|
__exportStar(require("./LibraryAgentsApi"), exports);
|
|
36
36
|
__exportStar(require("./ManifestsApi"), exports);
|
|
37
|
+
__exportStar(require("./McpApi"), exports);
|
|
37
38
|
__exportStar(require("./MetricsApi"), exports);
|
|
38
39
|
__exportStar(require("./OrganizationsApi"), exports);
|
|
39
40
|
__exportStar(require("./PromptsApi"), exports);
|
|
@@ -45,6 +45,12 @@ export interface AgentChatOverviewEntryUio {
|
|
|
45
45
|
* @memberof AgentChatOverviewEntryUio
|
|
46
46
|
*/
|
|
47
47
|
isGenerating: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Questions de cet agent qui attendent une réponse de l'utilisateur courant (outil Human_ask), toutes tâches confondues.
|
|
50
|
+
* @type {number}
|
|
51
|
+
* @memberof AgentChatOverviewEntryUio
|
|
52
|
+
*/
|
|
53
|
+
pendingHumanRequests?: number;
|
|
48
54
|
}
|
|
49
55
|
/**
|
|
50
56
|
* Check if a given object implements the AgentChatOverviewEntryUio interface.
|
|
@@ -45,6 +45,7 @@ function AgentChatOverviewEntryUioFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
45
45
|
'lastMessageAt': json['lastMessageAt'] == null ? undefined : json['lastMessageAt'],
|
|
46
46
|
'unreadCount': json['unreadCount'],
|
|
47
47
|
'isGenerating': json['isGenerating'],
|
|
48
|
+
'pendingHumanRequests': json['pendingHumanRequests'] == null ? undefined : json['pendingHumanRequests'],
|
|
48
49
|
};
|
|
49
50
|
}
|
|
50
51
|
function AgentChatOverviewEntryUioToJSON(json) {
|
|
@@ -60,5 +61,6 @@ function AgentChatOverviewEntryUioToJSONTyped(value, ignoreDiscriminator = false
|
|
|
60
61
|
'lastMessageAt': value['lastMessageAt'],
|
|
61
62
|
'unreadCount': value['unreadCount'],
|
|
62
63
|
'isGenerating': value['isGenerating'],
|
|
64
|
+
'pendingHumanRequests': value['pendingHumanRequests'],
|
|
63
65
|
};
|
|
64
66
|
}
|
|
@@ -0,0 +1,44 @@
|
|
|
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
|
+
* Per-agent activation of the Human_ask tool, offered only in task conversations (a local agent or another agent asking). The question goes to the first valid referent; without one, to the user who owns the task — the person who connected the local agent.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface AgentHumanEscalationConfigurationUio
|
|
16
|
+
*/
|
|
17
|
+
export interface AgentHumanEscalationConfigurationUio {
|
|
18
|
+
/**
|
|
19
|
+
* Enables the Human_ask tool for this agent.
|
|
20
|
+
* @type {boolean}
|
|
21
|
+
* @memberof AgentHumanEscalationConfigurationUio
|
|
22
|
+
*/
|
|
23
|
+
enabled?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Organisation members who answer this agent's questions, in order of preference.
|
|
26
|
+
* @type {Array<string>}
|
|
27
|
+
* @memberof AgentHumanEscalationConfigurationUio
|
|
28
|
+
*/
|
|
29
|
+
referentUserIds?: Array<string>;
|
|
30
|
+
/**
|
|
31
|
+
* How long a question stays answerable. Past it, the agent resumes on its own assumption.
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof AgentHumanEscalationConfigurationUio
|
|
34
|
+
*/
|
|
35
|
+
questionTtlHours?: number;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Check if a given object implements the AgentHumanEscalationConfigurationUio interface.
|
|
39
|
+
*/
|
|
40
|
+
export declare function instanceOfAgentHumanEscalationConfigurationUio(value: object): value is AgentHumanEscalationConfigurationUio;
|
|
41
|
+
export declare function AgentHumanEscalationConfigurationUioFromJSON(json: any): AgentHumanEscalationConfigurationUio;
|
|
42
|
+
export declare function AgentHumanEscalationConfigurationUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AgentHumanEscalationConfigurationUio;
|
|
43
|
+
export declare function AgentHumanEscalationConfigurationUioToJSON(json: any): AgentHumanEscalationConfigurationUio;
|
|
44
|
+
export declare function AgentHumanEscalationConfigurationUioToJSONTyped(value?: AgentHumanEscalationConfigurationUio | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,52 @@
|
|
|
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.instanceOfAgentHumanEscalationConfigurationUio = instanceOfAgentHumanEscalationConfigurationUio;
|
|
17
|
+
exports.AgentHumanEscalationConfigurationUioFromJSON = AgentHumanEscalationConfigurationUioFromJSON;
|
|
18
|
+
exports.AgentHumanEscalationConfigurationUioFromJSONTyped = AgentHumanEscalationConfigurationUioFromJSONTyped;
|
|
19
|
+
exports.AgentHumanEscalationConfigurationUioToJSON = AgentHumanEscalationConfigurationUioToJSON;
|
|
20
|
+
exports.AgentHumanEscalationConfigurationUioToJSONTyped = AgentHumanEscalationConfigurationUioToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the AgentHumanEscalationConfigurationUio interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfAgentHumanEscalationConfigurationUio(value) {
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
function AgentHumanEscalationConfigurationUioFromJSON(json) {
|
|
28
|
+
return AgentHumanEscalationConfigurationUioFromJSONTyped(json, false);
|
|
29
|
+
}
|
|
30
|
+
function AgentHumanEscalationConfigurationUioFromJSONTyped(json, ignoreDiscriminator) {
|
|
31
|
+
if (json == null) {
|
|
32
|
+
return json;
|
|
33
|
+
}
|
|
34
|
+
return {
|
|
35
|
+
'enabled': json['enabled'] == null ? undefined : json['enabled'],
|
|
36
|
+
'referentUserIds': json['referentUserIds'] == null ? undefined : json['referentUserIds'],
|
|
37
|
+
'questionTtlHours': json['questionTtlHours'] == null ? undefined : json['questionTtlHours'],
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
function AgentHumanEscalationConfigurationUioToJSON(json) {
|
|
41
|
+
return AgentHumanEscalationConfigurationUioToJSONTyped(json, false);
|
|
42
|
+
}
|
|
43
|
+
function AgentHumanEscalationConfigurationUioToJSONTyped(value, ignoreDiscriminator = false) {
|
|
44
|
+
if (value == null) {
|
|
45
|
+
return value;
|
|
46
|
+
}
|
|
47
|
+
return {
|
|
48
|
+
'enabled': value['enabled'],
|
|
49
|
+
'referentUserIds': value['referentUserIds'],
|
|
50
|
+
'questionTtlHours': value['questionTtlHours'],
|
|
51
|
+
};
|
|
52
|
+
}
|
|
@@ -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
|
+
* Reachability from local agents (Claude Code, Pi, Hermes…) through Breign's MCP server. Opt-in: an agent nobody exposed is invisible to list_agents and refuses ask_agent.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface AgentMcpExposureConfigurationUio
|
|
16
|
+
*/
|
|
17
|
+
export interface AgentMcpExposureConfigurationUio {
|
|
18
|
+
/**
|
|
19
|
+
* Makes this agent reachable from local agents.
|
|
20
|
+
* @type {boolean}
|
|
21
|
+
* @memberof AgentMcpExposureConfigurationUio
|
|
22
|
+
*/
|
|
23
|
+
enabled?: boolean;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if a given object implements the AgentMcpExposureConfigurationUio interface.
|
|
27
|
+
*/
|
|
28
|
+
export declare function instanceOfAgentMcpExposureConfigurationUio(value: object): value is AgentMcpExposureConfigurationUio;
|
|
29
|
+
export declare function AgentMcpExposureConfigurationUioFromJSON(json: any): AgentMcpExposureConfigurationUio;
|
|
30
|
+
export declare function AgentMcpExposureConfigurationUioFromJSONTyped(json: any, ignoreDiscriminator: boolean): AgentMcpExposureConfigurationUio;
|
|
31
|
+
export declare function AgentMcpExposureConfigurationUioToJSON(json: any): AgentMcpExposureConfigurationUio;
|
|
32
|
+
export declare function AgentMcpExposureConfigurationUioToJSONTyped(value?: AgentMcpExposureConfigurationUio | null, ignoreDiscriminator?: boolean): any;
|