@inkeep/agents-core 0.22.12 → 0.23.1
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/{signoz-queries-Bqpkx5sK.d.cts → auth-detection-BO8bSpe4.d.cts} +158 -1
- package/dist/{signoz-queries-Bqpkx5sK.d.ts → auth-detection-BO8bSpe4.d.ts} +158 -1
- package/dist/{chunk-QFIITHNT.js → chunk-5GAUAB2P.js} +164 -1
- package/dist/{chunk-NLZO4BB6.js → chunk-AN3YZP42.js} +1 -1
- package/dist/{chunk-4SE2FOJY.js → chunk-HN77JIDP.js} +2 -1
- package/dist/client-exports.cjs +66 -1
- package/dist/client-exports.d.cts +4 -3
- package/dist/client-exports.d.ts +4 -3
- package/dist/client-exports.js +3 -3
- package/dist/db/schema.d.cts +2 -2
- package/dist/db/schema.d.ts +2 -2
- package/dist/index.cjs +181 -105
- package/dist/index.d.cts +9 -115
- package/dist/index.d.ts +9 -115
- package/dist/index.js +44 -131
- package/dist/{schema-HuJ7Qh0C.d.cts → schema-B8NMPwEM.d.cts} +1 -1
- package/dist/{schema-Bo7m08k2.d.ts → schema-PgBNwsV-.d.ts} +1 -1
- package/dist/types/index.d.cts +2 -2
- package/dist/types/index.d.ts +2 -2
- package/dist/{utility-usOTNbMG.d.cts → utility-mGrlR4Ta.d.cts} +2 -0
- package/dist/{utility-usOTNbMG.d.ts → utility-mGrlR4Ta.d.ts} +2 -0
- package/dist/validation/index.cjs +2 -1
- package/dist/validation/index.d.cts +2 -2
- package/dist/validation/index.d.ts +2 -2
- package/dist/validation/index.js +2 -2
- package/package.json +3 -3
package/dist/db/schema.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import 'drizzle-orm';
|
|
2
2
|
import 'drizzle-orm/sqlite-core';
|
|
3
|
-
import '../utility-
|
|
4
|
-
export { E as agentRelations, H as agentToolRelationsRelations, a as agents, w as apiKeys, G as apiKeysRelations, j as artifactComponents, M as artifactComponentsRelations, b as contextCache, C as contextCacheRelations, c as contextConfigs, B as contextConfigsRelations, r as conversations, K as conversationsRelations, x as credentialReferences, I as credentialReferencesRelations, h as dataComponents, O as dataComponentsRelations, f as externalAgents, F as externalAgentsRelations, m as functionTools, T as functionToolsRelations, n as functions, R as functionsRelations, v as ledgerArtifacts, Q as ledgerArtifactsRelations, u as messages, L as messagesRelations, p as projects, z as projectsRelations, k as subAgentArtifactComponents, N as subAgentArtifactComponentsRelations, i as subAgentDataComponents, P as subAgentDataComponentsRelations, q as subAgentFunctionToolRelations, U as subAgentFunctionToolRelationsRelations, e as subAgentRelations, S as subAgentRelationsRelations, o as subAgentToolRelations, d as subAgents, D as subAgentsRelations, g as taskRelations, A as taskRelationsRelations, t as tasks, y as tasksRelations, l as tools, J as toolsRelations } from '../schema-
|
|
3
|
+
import '../utility-mGrlR4Ta.js';
|
|
4
|
+
export { E as agentRelations, H as agentToolRelationsRelations, a as agents, w as apiKeys, G as apiKeysRelations, j as artifactComponents, M as artifactComponentsRelations, b as contextCache, C as contextCacheRelations, c as contextConfigs, B as contextConfigsRelations, r as conversations, K as conversationsRelations, x as credentialReferences, I as credentialReferencesRelations, h as dataComponents, O as dataComponentsRelations, f as externalAgents, F as externalAgentsRelations, m as functionTools, T as functionToolsRelations, n as functions, R as functionsRelations, v as ledgerArtifacts, Q as ledgerArtifactsRelations, u as messages, L as messagesRelations, p as projects, z as projectsRelations, k as subAgentArtifactComponents, N as subAgentArtifactComponentsRelations, i as subAgentDataComponents, P as subAgentDataComponentsRelations, q as subAgentFunctionToolRelations, U as subAgentFunctionToolRelationsRelations, e as subAgentRelations, S as subAgentRelationsRelations, o as subAgentToolRelations, d as subAgents, D as subAgentsRelations, g as taskRelations, A as taskRelationsRelations, t as tasks, y as tasksRelations, l as tools, J as toolsRelations } from '../schema-PgBNwsV-.js';
|
|
5
5
|
import 'zod';
|
|
6
6
|
import 'drizzle-zod';
|
|
7
7
|
import '@hono/zod-openapi';
|
package/dist/index.cjs
CHANGED
|
@@ -13,6 +13,7 @@ var client = require('@libsql/client');
|
|
|
13
13
|
var libsql = require('drizzle-orm/libsql');
|
|
14
14
|
var crypto = require('crypto');
|
|
15
15
|
var util = require('util');
|
|
16
|
+
var auth_js = require('@modelcontextprotocol/sdk/client/auth.js');
|
|
16
17
|
var httpException = require('hono/http-exception');
|
|
17
18
|
var index_js = require('@modelcontextprotocol/sdk/client/index.js');
|
|
18
19
|
var sse_js = require('@modelcontextprotocol/sdk/client/sse.js');
|
|
@@ -214719,7 +214720,8 @@ var McpToolSchema = ToolInsertSchema.extend({
|
|
|
214719
214720
|
status: ToolStatusSchema.default("unknown"),
|
|
214720
214721
|
version: zodOpenapi.z.string().optional(),
|
|
214721
214722
|
createdAt: zodOpenapi.z.date(),
|
|
214722
|
-
updatedAt: zodOpenapi.z.date()
|
|
214723
|
+
updatedAt: zodOpenapi.z.date(),
|
|
214724
|
+
expiresAt: zodOpenapi.z.date().optional()
|
|
214723
214725
|
});
|
|
214724
214726
|
var MCPToolConfigSchema = McpToolSchema.omit({
|
|
214725
214727
|
config: true,
|
|
@@ -217182,71 +217184,146 @@ function extractPublicId(key) {
|
|
|
217182
217184
|
function maskApiKey(keyPrefix) {
|
|
217183
217185
|
return `${keyPrefix}...`;
|
|
217184
217186
|
}
|
|
217185
|
-
|
|
217186
|
-
|
|
217187
|
-
|
|
217188
|
-
|
|
217189
|
-
|
|
217190
|
-
|
|
217191
|
-
|
|
217192
|
-
|
|
217193
|
-
|
|
217194
|
-
|
|
217195
|
-
authorizationUrl: metadata.authorization_endpoint,
|
|
217196
|
-
tokenUrl: metadata.token_endpoint,
|
|
217197
|
-
registrationUrl: metadata.registration_endpoint,
|
|
217198
|
-
supportsDynamicRegistration: !!metadata.registration_endpoint
|
|
217199
|
-
});
|
|
217200
|
-
var tryWellKnownEndpoints = async (baseUrl, logger14) => {
|
|
217201
|
-
const wellKnownUrls = getWellKnownUrls(baseUrl);
|
|
217202
|
-
for (const wellKnownUrl of wellKnownUrls) {
|
|
217187
|
+
function discoverScopes(resourceMetadata, metadata) {
|
|
217188
|
+
const resourceScopes = resourceMetadata?.scopes_supported;
|
|
217189
|
+
const oauthScopes = metadata?.scopes_supported;
|
|
217190
|
+
const scopes = (resourceScopes?.length ? resourceScopes : oauthScopes) || [];
|
|
217191
|
+
return scopes.length > 0 ? scopes.join(" ") : void 0;
|
|
217192
|
+
}
|
|
217193
|
+
async function discoverMcpMetadata(mcpServerUrl, logger14) {
|
|
217194
|
+
try {
|
|
217195
|
+
let resourceMetadata = null;
|
|
217196
|
+
let authServerUrl = new URL(mcpServerUrl);
|
|
217203
217197
|
try {
|
|
217204
|
-
|
|
217205
|
-
if (
|
|
217206
|
-
|
|
217207
|
-
if (validateOAuthMetadata(metadata)) {
|
|
217208
|
-
logger14?.debug({ baseUrl, wellKnownUrl }, "OAuth 2.1/PKCE support detected");
|
|
217209
|
-
return buildOAuthConfig(metadata);
|
|
217210
|
-
}
|
|
217198
|
+
resourceMetadata = await auth_js.discoverOAuthProtectedResourceMetadata(mcpServerUrl);
|
|
217199
|
+
if (resourceMetadata?.authorization_servers?.length && resourceMetadata.authorization_servers[0]) {
|
|
217200
|
+
authServerUrl = new URL(resourceMetadata.authorization_servers[0]);
|
|
217211
217201
|
}
|
|
217212
|
-
} catch
|
|
217213
|
-
|
|
217202
|
+
} catch {
|
|
217203
|
+
}
|
|
217204
|
+
const metadata = await auth_js.discoverAuthorizationServerMetadata(authServerUrl);
|
|
217205
|
+
if (!metadata) {
|
|
217206
|
+
throw new Error("Failed to discover OAuth authorization server metadata");
|
|
217214
217207
|
}
|
|
217208
|
+
logger14?.debug(
|
|
217209
|
+
{
|
|
217210
|
+
tokenEndpoint: metadata.token_endpoint,
|
|
217211
|
+
authEndpoint: metadata.authorization_endpoint
|
|
217212
|
+
},
|
|
217213
|
+
"MCP metadata discovery successful"
|
|
217214
|
+
);
|
|
217215
|
+
const discoveredScopes = discoverScopes(resourceMetadata ?? void 0, metadata);
|
|
217216
|
+
return {
|
|
217217
|
+
success: true,
|
|
217218
|
+
metadata,
|
|
217219
|
+
...resourceMetadata && { resourceMetadata },
|
|
217220
|
+
...discoveredScopes && { scopes: discoveredScopes }
|
|
217221
|
+
};
|
|
217222
|
+
} catch (err) {
|
|
217223
|
+
const errorMessage = err instanceof Error ? err.message : String(err);
|
|
217224
|
+
logger14?.debug({ error: errorMessage }, "MCP metadata discovery failed");
|
|
217225
|
+
return { success: false, error: errorMessage };
|
|
217215
217226
|
}
|
|
217216
|
-
|
|
217217
|
-
|
|
217218
|
-
|
|
217219
|
-
|
|
217220
|
-
|
|
217221
|
-
|
|
217222
|
-
|
|
217223
|
-
|
|
217224
|
-
|
|
217225
|
-
|
|
217226
|
-
|
|
217227
|
-
|
|
217227
|
+
}
|
|
217228
|
+
async function initiateMcpOAuthFlow({
|
|
217229
|
+
mcpServerUrl,
|
|
217230
|
+
redirectUri,
|
|
217231
|
+
state,
|
|
217232
|
+
clientName = "Inkeep Agent Framework",
|
|
217233
|
+
clientUri = "https://inkeep.com",
|
|
217234
|
+
logoUri,
|
|
217235
|
+
defaultClientId = "mcp-client",
|
|
217236
|
+
logger: logger14
|
|
217237
|
+
}) {
|
|
217238
|
+
const discoveryResult = await discoverMcpMetadata(mcpServerUrl, logger14);
|
|
217239
|
+
if (!discoveryResult.success || !discoveryResult.metadata) {
|
|
217240
|
+
throw new Error(`OAuth not supported by this server: ${discoveryResult.error}`);
|
|
217241
|
+
}
|
|
217242
|
+
const { metadata, resourceMetadata, scopes: discoveredScopes } = discoveryResult;
|
|
217243
|
+
const clientMetadata = {
|
|
217244
|
+
redirect_uris: [redirectUri],
|
|
217245
|
+
token_endpoint_auth_method: "none",
|
|
217246
|
+
// PKCE - no client secret
|
|
217247
|
+
grant_types: ["authorization_code", "refresh_token"],
|
|
217248
|
+
response_types: ["code"],
|
|
217249
|
+
client_name: clientName,
|
|
217250
|
+
client_uri: clientUri,
|
|
217251
|
+
...logoUri && { logo_uri: logoUri }
|
|
217252
|
+
};
|
|
217253
|
+
let clientInformation;
|
|
217254
|
+
if (metadata.registration_endpoint) {
|
|
217255
|
+
clientInformation = await auth_js.registerClient(mcpServerUrl, {
|
|
217256
|
+
metadata,
|
|
217257
|
+
clientMetadata
|
|
217228
217258
|
});
|
|
217229
|
-
|
|
217230
|
-
|
|
217231
|
-
|
|
217232
|
-
|
|
217233
|
-
|
|
217234
|
-
const metadataResponse = await fetch(metadataMatch[1]);
|
|
217235
|
-
if (metadataResponse.ok) {
|
|
217236
|
-
const metadata = await metadataResponse.json();
|
|
217237
|
-
if (metadata.authorization_servers?.length > 0) {
|
|
217238
|
-
return await tryWellKnownEndpoints(metadata.authorization_servers[0], logger14);
|
|
217239
|
-
}
|
|
217240
|
-
}
|
|
217241
|
-
}
|
|
217242
|
-
}
|
|
217243
|
-
}
|
|
217244
|
-
} catch (_error) {
|
|
217259
|
+
} else {
|
|
217260
|
+
clientInformation = {
|
|
217261
|
+
client_id: defaultClientId,
|
|
217262
|
+
...clientMetadata
|
|
217263
|
+
};
|
|
217245
217264
|
}
|
|
217246
|
-
const
|
|
217247
|
-
const
|
|
217248
|
-
|
|
217249
|
-
|
|
217265
|
+
const resource = resourceMetadata?.resource ? new URL(resourceMetadata.resource) : void 0;
|
|
217266
|
+
const authResult = await auth_js.startAuthorization(mcpServerUrl, {
|
|
217267
|
+
metadata,
|
|
217268
|
+
clientInformation,
|
|
217269
|
+
redirectUrl: redirectUri,
|
|
217270
|
+
state,
|
|
217271
|
+
scope: discoveredScopes || "",
|
|
217272
|
+
...resource && { resource }
|
|
217273
|
+
});
|
|
217274
|
+
logger14?.debug(
|
|
217275
|
+
{
|
|
217276
|
+
authorizationUrl: authResult.authorizationUrl.href,
|
|
217277
|
+
scopes: discoveredScopes,
|
|
217278
|
+
clientId: clientInformation.client_id
|
|
217279
|
+
},
|
|
217280
|
+
"MCP OAuth flow initiated successfully"
|
|
217281
|
+
);
|
|
217282
|
+
return {
|
|
217283
|
+
authorizationUrl: authResult.authorizationUrl.href,
|
|
217284
|
+
codeVerifier: authResult.codeVerifier,
|
|
217285
|
+
state,
|
|
217286
|
+
clientInformation,
|
|
217287
|
+
metadata,
|
|
217288
|
+
resourceUrl: resource?.href || void 0,
|
|
217289
|
+
...discoveredScopes && { scopes: discoveredScopes }
|
|
217290
|
+
};
|
|
217291
|
+
}
|
|
217292
|
+
async function exchangeMcpAuthorizationCode({
|
|
217293
|
+
mcpServerUrl,
|
|
217294
|
+
metadata,
|
|
217295
|
+
clientInformation,
|
|
217296
|
+
authorizationCode,
|
|
217297
|
+
codeVerifier,
|
|
217298
|
+
redirectUri,
|
|
217299
|
+
resourceUrl,
|
|
217300
|
+
logger: logger14
|
|
217301
|
+
}) {
|
|
217302
|
+
const resource = resourceUrl ? new URL(resourceUrl) : void 0;
|
|
217303
|
+
const tokens = await auth_js.exchangeAuthorization(mcpServerUrl, {
|
|
217304
|
+
metadata,
|
|
217305
|
+
clientInformation,
|
|
217306
|
+
authorizationCode,
|
|
217307
|
+
codeVerifier,
|
|
217308
|
+
redirectUri,
|
|
217309
|
+
...resource && { resource }
|
|
217310
|
+
});
|
|
217311
|
+
logger14?.debug(
|
|
217312
|
+
{
|
|
217313
|
+
tokenType: tokens.token_type,
|
|
217314
|
+
hasRefreshToken: !!tokens.refresh_token,
|
|
217315
|
+
expiresIn: tokens.expires_in
|
|
217316
|
+
},
|
|
217317
|
+
"MCP token exchange successful"
|
|
217318
|
+
);
|
|
217319
|
+
return {
|
|
217320
|
+
access_token: tokens.access_token,
|
|
217321
|
+
refresh_token: tokens.refresh_token,
|
|
217322
|
+
expires_at: tokens.expires_in ? new Date(Date.now() + tokens.expires_in * 1e3) : void 0,
|
|
217323
|
+
token_type: tokens.token_type || "Bearer",
|
|
217324
|
+
scope: tokens.scope
|
|
217325
|
+
};
|
|
217326
|
+
}
|
|
217250
217327
|
var detectAuthenticationRequired = async ({
|
|
217251
217328
|
serverUrl,
|
|
217252
217329
|
toolId,
|
|
@@ -217254,53 +217331,17 @@ var detectAuthenticationRequired = async ({
|
|
|
217254
217331
|
logger: logger14
|
|
217255
217332
|
}) => {
|
|
217256
217333
|
try {
|
|
217257
|
-
const
|
|
217258
|
-
if (
|
|
217259
|
-
logger14?.info(
|
|
217260
|
-
{ toolId, serverUrl },
|
|
217261
|
-
"OAuth 2.1/PKCE support confirmed via endpoint discovery"
|
|
217262
|
-
);
|
|
217334
|
+
const discoveryResult = await discoverMcpMetadata(serverUrl, logger14);
|
|
217335
|
+
if (discoveryResult.success && discoveryResult.metadata) {
|
|
217336
|
+
logger14?.info({ toolId, serverUrl }, "MCP OAuth support confirmed via metadata discovery");
|
|
217263
217337
|
return true;
|
|
217264
217338
|
}
|
|
217265
217339
|
} catch (discoveryError) {
|
|
217266
|
-
logger14?.debug({ toolId, discoveryError }, "OAuth
|
|
217267
|
-
}
|
|
217268
|
-
try {
|
|
217269
|
-
const response = await fetch(serverUrl, {
|
|
217270
|
-
method: "POST",
|
|
217271
|
-
headers: { "Content-Type": "application/json" },
|
|
217272
|
-
body: JSON.stringify({
|
|
217273
|
-
jsonrpc: "2.0",
|
|
217274
|
-
method: "initialize",
|
|
217275
|
-
id: 1,
|
|
217276
|
-
params: { protocolVersion: "2024-11-05", capabilities: {} }
|
|
217277
|
-
})
|
|
217278
|
-
});
|
|
217279
|
-
if (response.status === 401) {
|
|
217280
|
-
const wwwAuth = response.headers.get("WWW-Authenticate");
|
|
217281
|
-
if (wwwAuth) {
|
|
217282
|
-
const authLower = wwwAuth.toLowerCase();
|
|
217283
|
-
const hasActiveOAuthFlow = authLower.includes("authorization_uri") || authLower.includes("as_uri=") || authLower.includes("bearer") && (authLower.includes("scope=") || authLower.includes("error_uri="));
|
|
217284
|
-
if (hasActiveOAuthFlow) {
|
|
217285
|
-
logger14?.info(
|
|
217286
|
-
{ toolId, wwwAuth },
|
|
217287
|
-
"Active OAuth flow detected via WWW-Authenticate parameters"
|
|
217288
|
-
);
|
|
217289
|
-
return true;
|
|
217290
|
-
} else {
|
|
217291
|
-
logger14?.debug(
|
|
217292
|
-
{ toolId, wwwAuth },
|
|
217293
|
-
"Bearer authentication detected - likely simple token auth, not OAuth"
|
|
217294
|
-
);
|
|
217295
|
-
}
|
|
217296
|
-
}
|
|
217297
|
-
}
|
|
217298
|
-
} catch (fetchError) {
|
|
217299
|
-
logger14?.debug({ toolId, fetchError }, "Direct fetch authentication check failed");
|
|
217340
|
+
logger14?.debug({ toolId, discoveryError }, "MCP OAuth metadata discovery failed");
|
|
217300
217341
|
}
|
|
217301
217342
|
logger14?.debug(
|
|
217302
|
-
{ toolId, error: error
|
|
217303
|
-
"No OAuth
|
|
217343
|
+
{ toolId, error: error?.message },
|
|
217344
|
+
"No MCP OAuth authentication requirement detected"
|
|
217304
217345
|
);
|
|
217305
217346
|
return false;
|
|
217306
217347
|
};
|
|
@@ -218007,7 +218048,7 @@ var discoverToolsFromServer = async (tool2, dbClient, credentialStoreRegistry) =
|
|
|
218007
218048
|
id: credentialReferenceId
|
|
218008
218049
|
});
|
|
218009
218050
|
if (!credentialReference) {
|
|
218010
|
-
throw new Error(`Credential
|
|
218051
|
+
throw new Error(`Credential reference not found: ${credentialReferenceId}`);
|
|
218011
218052
|
}
|
|
218012
218053
|
const storeReference = {
|
|
218013
218054
|
credentialStoreId: credentialReference.credentialStoreId,
|
|
@@ -218086,6 +218127,38 @@ var dbResultToMcpTool = async (dbResult, dbClient, credentialStoreRegistry) => {
|
|
|
218086
218127
|
let availableTools = [];
|
|
218087
218128
|
let status = "unknown";
|
|
218088
218129
|
let lastErrorComputed;
|
|
218130
|
+
let expiresAt;
|
|
218131
|
+
if (credentialReferenceId) {
|
|
218132
|
+
const credentialReference = await getCredentialReference(dbClient)({
|
|
218133
|
+
scopes: { tenantId: dbResult.tenantId, projectId: dbResult.projectId },
|
|
218134
|
+
id: credentialReferenceId
|
|
218135
|
+
});
|
|
218136
|
+
if (credentialReference?.retrievalParams) {
|
|
218137
|
+
const credentialStore = credentialStoreRegistry?.get(credentialReference.credentialStoreId);
|
|
218138
|
+
if (credentialStore && credentialStore.type !== CredentialStoreType.memory) {
|
|
218139
|
+
const lookupKey = getCredentialStoreLookupKeyFromRetrievalParams({
|
|
218140
|
+
retrievalParams: credentialReference.retrievalParams,
|
|
218141
|
+
credentialStoreType: credentialStore.type
|
|
218142
|
+
});
|
|
218143
|
+
if (lookupKey) {
|
|
218144
|
+
const credentialDataString = await credentialStore.get(lookupKey);
|
|
218145
|
+
if (credentialDataString) {
|
|
218146
|
+
if (credentialStore.type === CredentialStoreType.nango) {
|
|
218147
|
+
const nangoCredentialData = JSON.parse(credentialDataString);
|
|
218148
|
+
if (nangoCredentialData.expiresAt) {
|
|
218149
|
+
expiresAt = nangoCredentialData.expiresAt;
|
|
218150
|
+
}
|
|
218151
|
+
} else if (credentialStore.type === CredentialStoreType.keychain) {
|
|
218152
|
+
const oauthTokens = JSON.parse(credentialDataString);
|
|
218153
|
+
if (oauthTokens.expires_at) {
|
|
218154
|
+
expiresAt = new Date(oauthTokens.expires_at);
|
|
218155
|
+
}
|
|
218156
|
+
}
|
|
218157
|
+
}
|
|
218158
|
+
}
|
|
218159
|
+
}
|
|
218160
|
+
}
|
|
218161
|
+
}
|
|
218089
218162
|
try {
|
|
218090
218163
|
availableTools = await discoverToolsFromServer(dbResult, dbClient, credentialStoreRegistry);
|
|
218091
218164
|
status = "healthy";
|
|
@@ -218117,6 +218190,7 @@ var dbResultToMcpTool = async (dbResult, dbClient, credentialStoreRegistry) => {
|
|
|
218117
218190
|
credentialReferenceId: credentialReferenceId || void 0,
|
|
218118
218191
|
createdAt: new Date(createdAt),
|
|
218119
218192
|
updatedAt: new Date(now),
|
|
218193
|
+
expiresAt,
|
|
218120
218194
|
lastError: lastErrorComputed,
|
|
218121
218195
|
headers: headers2 || void 0,
|
|
218122
218196
|
imageUrl: imageUrl || void 0
|
|
@@ -224698,7 +224772,8 @@ var NangoCredentialStore = class {
|
|
|
224698
224772
|
case "OAUTH2":
|
|
224699
224773
|
return {
|
|
224700
224774
|
token: extractAccessTokenForBearerType(credentials.access_token),
|
|
224701
|
-
refresh_token: credentials.refresh_token
|
|
224775
|
+
refresh_token: credentials.refresh_token,
|
|
224776
|
+
expiresAt: credentials.expires_at
|
|
224702
224777
|
};
|
|
224703
224778
|
case "OAUTH2_CC":
|
|
224704
224779
|
return {
|
|
@@ -225576,9 +225651,9 @@ exports.deleteSubAgentRelation = deleteSubAgentRelation;
|
|
|
225576
225651
|
exports.deleteTool = deleteTool;
|
|
225577
225652
|
exports.detectAuthenticationRequired = detectAuthenticationRequired;
|
|
225578
225653
|
exports.determineContextTrigger = determineContextTrigger;
|
|
225579
|
-
exports.discoverOAuthEndpoints = discoverOAuthEndpoints;
|
|
225580
225654
|
exports.errorResponseSchema = errorResponseSchema;
|
|
225581
225655
|
exports.errorSchemaFactory = errorSchemaFactory;
|
|
225656
|
+
exports.exchangeMcpAuthorizationCode = exchangeMcpAuthorizationCode;
|
|
225582
225657
|
exports.externalAgentExists = externalAgentExists;
|
|
225583
225658
|
exports.externalAgentUrlExists = externalAgentUrlExists;
|
|
225584
225659
|
exports.externalAgents = externalAgents;
|
|
@@ -225663,6 +225738,7 @@ exports.hasContextConfig = hasContextConfig;
|
|
|
225663
225738
|
exports.hasCredentialReference = hasCredentialReference;
|
|
225664
225739
|
exports.hashApiKey = hashApiKey;
|
|
225665
225740
|
exports.headers = headers;
|
|
225741
|
+
exports.initiateMcpOAuthFlow = initiateMcpOAuthFlow;
|
|
225666
225742
|
exports.invalidateHeadersCache = invalidateHeadersCache;
|
|
225667
225743
|
exports.invalidateInvocationDefinitionsCache = invalidateInvocationDefinitionsCache;
|
|
225668
225744
|
exports.isApiKeyExpired = isApiKeyExpired;
|
package/dist/index.d.cts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
export { ANTHROPIC_MODELS, AnthropicModel, GOOGLE_MODELS, GoogleModel, ModelName, OPENAI_MODELS, OpenAIModel } from './constants/models.cjs';
|
|
2
|
-
|
|
2
|
+
import { r as PinoLogger, s as getLogger } from './auth-detection-BO8bSpe4.cjs';
|
|
3
|
+
export { i as ACTIVITY_NAMES, g as ACTIVITY_STATUS, f as ACTIVITY_TYPES, h as AGENT_IDS, p as AGGREGATE_OPERATORS, A as AI_OPERATIONS, j as AI_TOOL_TYPES, o as DATA_SOURCES, k as DATA_TYPES, D as DELEGATION_FROM_SUB_AGENT_ID, b as DELEGATION_ID, a as DELEGATION_TO_SUB_AGENT_ID, F as FIELD_TYPES, L as LoggerFactoryConfig, M as McpOAuthFlowResult, u as McpTokenExchangeResult, t as OAuthConfig, O as OPERATORS, m as ORDER_DIRECTIONS, P as PANEL_TYPES, x as PinoLoggerConfig, q as QUERY_DEFAULTS, l as QUERY_EXPRESSIONS, Q as QUERY_FIELD_CONFIGS, n as QUERY_TYPES, R as REDUCE_OPERATIONS, e as SPAN_KEYS, S as SPAN_NAMES, T as TRANSFER_FROM_SUB_AGENT_ID, c as TRANSFER_TO_SUB_AGENT_ID, U as UNKNOWN_VALUE, d as detectAuthenticationRequired, w as exchangeMcpAuthorizationCode, v as initiateMcpOAuthFlow, y as loggerFactory } from './auth-detection-BO8bSpe4.cjs';
|
|
3
4
|
import { z } from 'zod';
|
|
4
|
-
import { r as CredentialReferenceApiInsert, s as ContextConfigSelect, l as ContextFetchDefinition, i as MCPTransportType, t as MCPToolConfig, u as AgentScopeConfig, C as ConversationHistoryConfig, v as ProjectScopeConfig, w as PaginationConfig, x as AgentInsert, y as AgentUpdate, z as FullAgentDefinition, B as AgentSelect, D as ApiKeySelect, E as ApiKeyInsert, G as ApiKeyUpdate, H as CreateApiKeyParams, I as ApiKeyCreateResult, J as ArtifactComponentSelect, K as ArtifactComponentInsert, L as ArtifactComponentUpdate, N as SubAgentScopeConfig, O as ContextCacheSelect, Q as ContextCacheInsert, R as ContextConfigInsert, U as ContextConfigUpdate, V as ConversationSelect, W as ConversationInsert, o as ConversationMetadata, X as ConversationUpdate, Y as CredentialReferenceSelect, Z as ToolSelect, _ as CredentialReferenceInsert, $ as CredentialReferenceUpdate, a0 as DataComponentSelect, a1 as DataComponentInsert, a2 as DataComponentUpdate, a3 as ExternalAgentInsert, a4 as ExternalAgentSelect, a5 as ExternalAgentUpdate, a6 as FunctionApiInsert, a7 as FunctionToolApiInsert, a8 as FunctionToolApiUpdate, a9 as Artifact, aa as LedgerArtifactSelect, q as MessageMetadata, p as MessageContent, ab as MessageVisibility, ac as MessageInsert, ad as MessageUpdate, ae as FullProjectDefinition, af as ProjectInfo, ag as ProjectSelect, ah as PaginationResult, ai as ProjectResourceCounts, aj as ProjectInsert, ak as ProjectUpdate, al as SubAgentRelationInsert, am as ExternalSubAgentRelationInsert, an as SubAgentRelationUpdate, ao as SubAgentToolRelationUpdate, m as ToolMcpConfig, n as ToolServerCapabilities, ap as SubAgentInsert, aq as SubAgentUpdate, ar as SubAgentSelect, as as TaskInsert, T as TaskMetadataConfig, at as TaskSelect, au as McpTool, av as ToolInsert, aw as ToolUpdate, h as CredentialStoreType, ax as ExecutionContext } from './utility-
|
|
5
|
-
export { b9 as A2AError, bF as A2ARequest, bG as A2AResponse, aK as APIKeySecurityScheme, bT as AgentApiInsert, dW as AgentApiInsertSchema, bS as AgentApiSelect, dV as AgentApiSelectSchema, bU as AgentApiUpdate, dX as AgentApiUpdateSchema, aG as AgentCapabilities, aU as AgentCard, dk as AgentConversationHistoryConfig, dT as AgentInsertSchema, gh as AgentListResponse, aH as AgentProvider, g1 as AgentResponse, dS as AgentSelectSchema, aI as AgentSkill, e as AgentStopWhen, b as AgentStopWhenSchema, dU as AgentUpdateSchema, fN as AgentWithinContextOfProjectSchema, e_ as AllAgentSchema, cN as AllAgentSelect, cR as ApiKeyApiCreationResponse, f3 as ApiKeyApiCreationResponseSchema, cP as ApiKeyApiInsert, f4 as ApiKeyApiInsertSchema, cO as ApiKeyApiSelect, f2 as ApiKeyApiSelectSchema, cQ as ApiKeyApiUpdate, A as ApiKeyApiUpdateSchema, f0 as ApiKeyInsertSchema, gl as ApiKeyListResponse, g5 as ApiKeyResponse, e$ as ApiKeySelectSchema, f1 as ApiKeyUpdateSchema, cC as ArtifactComponentApiInsert, eM as ArtifactComponentApiInsertSchema, cB as ArtifactComponentApiSelect, eL as ArtifactComponentApiSelectSchema, cD as ArtifactComponentApiUpdate, eN as ArtifactComponentApiUpdateSchema, eJ as ArtifactComponentInsertSchema, gq as ArtifactComponentListResponse, ga as ArtifactComponentResponse, eI as ArtifactComponentSelectSchema, eK as ArtifactComponentUpdateSchema, aN as AuthorizationCodeOAuthFlow, d3 as CanUseItem, fM as CanUseItemSchema, bp as CancelTaskRequest, bA as CancelTaskResponse, bz as CancelTaskSuccessResponse, aO as ClientCredentialsOAuthFlow, b7 as ContentTypeNotSupportedError, cq as ContextCacheApiInsert, et as ContextCacheApiInsertSchema, cp as ContextCacheApiSelect, es as ContextCacheApiSelectSchema, cr as ContextCacheApiUpdate, eu as ContextCacheApiUpdateSchema, dl as ContextCacheEntry, eq as ContextCacheInsertSchema, ep as ContextCacheSelectSchema, co as ContextCacheUpdate, er as ContextCacheUpdateSchema, ck as ContextConfigApiInsert, fw as ContextConfigApiInsertSchema, cj as ContextConfigApiSelect, fv as ContextConfigApiSelectSchema, cl as ContextConfigApiUpdate, fx as ContextConfigApiUpdateSchema, ft as ContextConfigInsertSchema, gk as ContextConfigListResponse, g4 as ContextConfigResponse, fs as ContextConfigSelectSchema, fu as ContextConfigUpdateSchema, cd as ConversationApiInsert, eh as ConversationApiInsertSchema, cc as ConversationApiSelect, eg as ConversationApiSelectSchema, ce as ConversationApiUpdate, ei as ConversationApiUpdateSchema, ee as ConversationInsertSchema, gt as ConversationListResponse, gd as ConversationResponse, dj as ConversationScopeOptions, ed as ConversationSelectSchema, ef as ConversationUpdateSchema, f9 as CredentialReferenceApiInsertSchema, cS as CredentialReferenceApiSelect, f8 as CredentialReferenceApiSelectSchema, cT as CredentialReferenceApiUpdate, fa as CredentialReferenceApiUpdateSchema, f6 as CredentialReferenceInsertSchema, gm as CredentialReferenceListResponse, g6 as CredentialReferenceResponse, f5 as CredentialReferenceSelectSchema, f7 as CredentialReferenceUpdateSchema, ct as DataComponentApiInsert, eA as DataComponentApiInsertSchema, cs as DataComponentApiSelect, ez as DataComponentApiSelectSchema, cu as DataComponentApiUpdate, eB as DataComponentApiUpdateSchema, ex as DataComponentBaseSchema, ew as DataComponentInsertSchema, gp as DataComponentListResponse, g9 as DataComponentResponse, ev as DataComponentSelectSchema, ey as DataComponentUpdateSchema, aE as DataPart, fR as ErrorResponseSchema, fS as ExistsResponseSchema, eY as ExternalAgentApiInsertSchema, cK as ExternalAgentApiSelect, eX as ExternalAgentApiSelectSchema, cM as ExternalAgentApiUpdate, eZ as ExternalAgentApiUpdateSchema, eV as ExternalAgentInsertSchema, gj as ExternalAgentListResponse, g3 as ExternalAgentResponse, eU as ExternalAgentSelectSchema, eW as ExternalAgentUpdateSchema, cL as ExternalSubAgentApiInsert, bR as ExternalSubAgentRelationApiInsert, dR as ExternalSubAgentRelationApiInsertSchema, dQ as ExternalSubAgentRelationInsertSchema, cn as FetchConfig, fq as FetchConfigSchema, cm as FetchDefinition, fr as FetchDefinitionSchema, aA as FileBase, aD as FilePart, aB as FileWithBytes, aC as FileWithUri, d2 as FullAgentAgentInsert, a as FullAgentAgentInsertSchema, f_ as FullProjectDefinitionSchema, F as FunctionApiInsertSchema, c9 as FunctionApiSelect, j as FunctionApiSelectSchema, ca as FunctionApiUpdate, k as FunctionApiUpdateSchema, c7 as FunctionInsert, fo as FunctionInsertSchema, gn as FunctionListResponse, g7 as FunctionResponse, c6 as FunctionSelect, fn as FunctionSelectSchema, fl as FunctionToolApiInsertSchema, cb as FunctionToolApiSelect, fk as FunctionToolApiSelectSchema, fm as FunctionToolApiUpdateSchema, dC as FunctionToolConfig, dB as FunctionToolConfigSchema, fi as FunctionToolInsertSchema, go as FunctionToolListResponse, g8 as FunctionToolResponse, fh as FunctionToolSelectSchema, fj as FunctionToolUpdateSchema, c8 as FunctionUpdate, fp as FunctionUpdateSchema, br as GetTaskPushNotificationConfigRequest, bE as GetTaskPushNotificationConfigResponse, bD as GetTaskPushNotificationConfigSuccessResponse, bo as GetTaskRequest, by as GetTaskResponse, bx as GetTaskSuccessResponse, aL as HTTPAuthSecurityScheme, gz as HeadersScopeSchema, aP as ImplicitOAuthFlow, b2 as InternalError, d4 as InternalSubAgentDefinition, b8 as InvalidAgentResponseError, b1 as InvalidParamsError, a$ as InvalidRequestError, a_ as JSONParseError, bj as JSONRPCError, bl as JSONRPCErrorResponse, bh as JSONRPCMessage, bi as JSONRPCRequest, bk as JSONRPCResult, d0 as LedgerArtifactApiInsert, fI as LedgerArtifactApiInsertSchema, c$ as LedgerArtifactApiSelect, fH as LedgerArtifactApiSelectSchema, d1 as LedgerArtifactApiUpdate, fJ as LedgerArtifactApiUpdateSchema, cZ as LedgerArtifactInsert, fF as LedgerArtifactInsertSchema, fE as LedgerArtifactSelectSchema, c_ as LedgerArtifactUpdate, fG as LedgerArtifactUpdateSchema, fP as ListResponseSchema, dw as MAX_ID_LENGTH, du as MCPServerType, fc as MCPToolConfigSchema, dv as MIN_ID_LENGTH, dm as McpAuthType, dn as McpServerAuth, dq as McpServerCapabilities, dr as McpToolDefinition, ea as McpToolDefinitionSchema, fb as McpToolSchema, dp as McpTransportConfig, e8 as McpTransportConfigSchema, aV as Message, ch as MessageApiInsert, en as MessageApiInsertSchema, cg as MessageApiSelect, em as MessageApiSelectSchema, ci as MessageApiUpdate, eo as MessageApiUpdateSchema, ek as MessageInsertSchema, gu as MessageListResponse, de as MessageMode, bH as MessagePart, ge as MessageResponse, dd as MessageRole, cf as MessageSelect, ej as MessageSelectSchema, bf as MessageSendConfiguration, bg as MessageSendParams, dc as MessageType, el as MessageUpdateSchema, b0 as MethodNotFoundError, dz as ModelSchema, g as ModelSettings, M as ModelSettingsSchema, df as Models, aR as OAuth2SecurityScheme, aM as OAuthFlows, aS as OpenIdConnectSecurityScheme, da as Pagination, gI as PaginationQueryParamsSchema, fO as PaginationSchema, P as Part, ay as PartBase, aQ as PasswordOAuthFlow, d8 as ProjectApiInsert, fY as ProjectApiInsertSchema, d7 as ProjectApiSelect, fX as ProjectApiSelectSchema, d9 as ProjectApiUpdate, fZ as ProjectApiUpdateSchema, fV as ProjectInsertSchema, gf as ProjectListResponse, dA as ProjectModelSchema, dg as ProjectModels, f$ as ProjectResponse, fU as ProjectSelectSchema, fW as ProjectUpdateSchema, ba as PushNotificationAuthenticationInfo, bb as PushNotificationConfig, b5 as PushNotificationNotSupportedError, fT as RemovedResponseSchema, aT as SecurityScheme, aJ as SecuritySchemeBase, bm as SendMessageRequest, bu as SendMessageResponse, bt as SendMessageSuccessResponse, bn as SendStreamingMessageRequest, bw as SendStreamingMessageResponse, bv as SendStreamingMessageSuccessResponse, bq as SetTaskPushNotificationConfigRequest, bC as SetTaskPushNotificationConfigResponse, bB as SetTaskPushNotificationConfigSuccessResponse, fQ as SingleResponseSchema, di as StatusComponent, fK as StatusComponentSchema, fL as StatusUpdateSchema, dh as StatusUpdateSettings, d as StopWhen, S as StopWhenSchema, bK as SubAgentApiInsert, dH as SubAgentApiInsertSchema, bJ as SubAgentApiSelect, dG as SubAgentApiSelectSchema, bL as SubAgentApiUpdate, dI as SubAgentApiUpdateSchema, cI as SubAgentArtifactComponentApiInsert, eS as SubAgentArtifactComponentApiInsertSchema, cH as SubAgentArtifactComponentApiSelect, eR as SubAgentArtifactComponentApiSelectSchema, cJ as SubAgentArtifactComponentApiUpdate, eT as SubAgentArtifactComponentApiUpdateSchema, cF as SubAgentArtifactComponentInsert, eP as SubAgentArtifactComponentInsertSchema, gy as SubAgentArtifactComponentListResponse, gw as SubAgentArtifactComponentResponse, cE as SubAgentArtifactComponentSelect, eO as SubAgentArtifactComponentSelectSchema, cG as SubAgentArtifactComponentUpdate, eQ as SubAgentArtifactComponentUpdateSchema, cz as SubAgentDataComponentApiInsert, eG as SubAgentDataComponentApiInsertSchema, cy as SubAgentDataComponentApiSelect, eF as SubAgentDataComponentApiSelectSchema, cA as SubAgentDataComponentApiUpdate, eH as SubAgentDataComponentApiUpdateSchema, cw as SubAgentDataComponentInsert, eD as SubAgentDataComponentInsertSchema, gx as SubAgentDataComponentListResponse, gv as SubAgentDataComponentResponse, cv as SubAgentDataComponentSelect, eC as SubAgentDataComponentSelectSchema, cx as SubAgentDataComponentUpdate, eE as SubAgentDataComponentUpdateSchema, d5 as SubAgentDefinition, dE as SubAgentInsertSchema, gg as SubAgentListResponse, bO as SubAgentRelationApiInsert, dN as SubAgentRelationApiInsertSchema, bN as SubAgentRelationApiSelect, dM as SubAgentRelationApiSelectSchema, bP as SubAgentRelationApiUpdate, dO as SubAgentRelationApiUpdateSchema, dK as SubAgentRelationInsertSchema, gr as SubAgentRelationListResponse, bQ as SubAgentRelationQuery, dP as SubAgentRelationQuerySchema, gb as SubAgentRelationResponse, bM as SubAgentRelationSelect, dJ as SubAgentRelationSelectSchema, dL as SubAgentRelationUpdateSchema, g0 as SubAgentResponse, dD as SubAgentSelectSchema, f as SubAgentStopWhen, c as SubAgentStopWhenSchema, cX as SubAgentToolRelationApiInsert, fC as SubAgentToolRelationApiInsertSchema, cW as SubAgentToolRelationApiSelect, fB as SubAgentToolRelationApiSelectSchema, cY as SubAgentToolRelationApiUpdate, fD as SubAgentToolRelationApiUpdateSchema, cV as SubAgentToolRelationInsert, fz as SubAgentToolRelationInsertSchema, gs as SubAgentToolRelationListResponse, gc as SubAgentToolRelationResponse, cU as SubAgentToolRelationSelect, fy as SubAgentToolRelationSelectSchema, fA as SubAgentToolRelationUpdateSchema, dF as SubAgentUpdateSchema, db as SummaryEvent, ds as TOOL_STATUS_VALUES, aX as Task, bX as TaskApiInsert, e0 as TaskApiInsertSchema, bW as TaskApiSelect, d$ as TaskApiSelectSchema, bY as TaskApiUpdate, e1 as TaskApiUpdateSchema, bI as TaskArtifact, aZ as TaskArtifactUpdateEvent, bd as TaskIdParams, dZ as TaskInsertSchema, b4 as TaskNotCancelableError, b3 as TaskNotFoundError, bc as TaskPushNotificationConfig, be as TaskQueryParams, c1 as TaskRelationApiInsert, e6 as TaskRelationApiInsertSchema, c0 as TaskRelationApiSelect, e5 as TaskRelationApiSelectSchema, c2 as TaskRelationApiUpdate, e7 as TaskRelationApiUpdateSchema, b_ as TaskRelationInsert, e3 as TaskRelationInsertSchema, bZ as TaskRelationSelect, e2 as TaskRelationSelectSchema, b$ as TaskRelationUpdate, e4 as TaskRelationUpdateSchema, bs as TaskResubscriptionRequest, dY as TaskSelectSchema, aF as TaskState, aW as TaskStatus, aY as TaskStatusUpdateEvent, bV as TaskUpdate, d_ as TaskUpdateSchema, gB as TenantIdParamsSchema, gA as TenantParamsSchema, gF as TenantProjectAgentIdParamsSchema, gE as TenantProjectAgentParamsSchema, gH as TenantProjectAgentSubAgentIdParamsSchema, gG as TenantProjectAgentSubAgentParamsSchema, gD as TenantProjectIdParamsSchema, gC as TenantProjectParamsSchema, az as TextPart, c4 as ToolApiInsert, ff as ToolApiInsertSchema, c3 as ToolApiSelect, fe as ToolApiSelectSchema, c5 as ToolApiUpdate, fg as ToolApiUpdateSchema, d6 as ToolDefinition, ec as ToolInsertSchema, gi as ToolListResponse, g2 as ToolResponse, eb as ToolSelectSchema, e9 as ToolStatusSchema, fd as ToolUpdateSchema, dx as URL_SAFE_ID_PATTERN, b6 as UnsupportedOperationError, dt as VALID_RELATION_TYPES, dy as resourceIdSchema } from './utility-usOTNbMG.cjs';
|
|
5
|
+
import { r as CredentialReferenceApiInsert, s as ContextConfigSelect, l as ContextFetchDefinition, i as MCPTransportType, t as MCPToolConfig, u as AgentScopeConfig, C as ConversationHistoryConfig, v as ProjectScopeConfig, w as PaginationConfig, x as AgentInsert, y as AgentUpdate, z as FullAgentDefinition, B as AgentSelect, D as ApiKeySelect, E as ApiKeyInsert, G as ApiKeyUpdate, H as CreateApiKeyParams, I as ApiKeyCreateResult, J as ArtifactComponentSelect, K as ArtifactComponentInsert, L as ArtifactComponentUpdate, N as SubAgentScopeConfig, O as ContextCacheSelect, Q as ContextCacheInsert, R as ContextConfigInsert, U as ContextConfigUpdate, V as ConversationSelect, W as ConversationInsert, o as ConversationMetadata, X as ConversationUpdate, Y as CredentialReferenceSelect, Z as ToolSelect, _ as CredentialReferenceInsert, $ as CredentialReferenceUpdate, a0 as DataComponentSelect, a1 as DataComponentInsert, a2 as DataComponentUpdate, a3 as ExternalAgentInsert, a4 as ExternalAgentSelect, a5 as ExternalAgentUpdate, a6 as FunctionApiInsert, a7 as FunctionToolApiInsert, a8 as FunctionToolApiUpdate, a9 as Artifact, aa as LedgerArtifactSelect, q as MessageMetadata, p as MessageContent, ab as MessageVisibility, ac as MessageInsert, ad as MessageUpdate, ae as FullProjectDefinition, af as ProjectInfo, ag as ProjectSelect, ah as PaginationResult, ai as ProjectResourceCounts, aj as ProjectInsert, ak as ProjectUpdate, al as SubAgentRelationInsert, am as ExternalSubAgentRelationInsert, an as SubAgentRelationUpdate, ao as SubAgentToolRelationUpdate, m as ToolMcpConfig, n as ToolServerCapabilities, ap as SubAgentInsert, aq as SubAgentUpdate, ar as SubAgentSelect, as as TaskInsert, T as TaskMetadataConfig, at as TaskSelect, au as McpTool, av as ToolInsert, aw as ToolUpdate, h as CredentialStoreType, ax as ExecutionContext } from './utility-mGrlR4Ta.cjs';
|
|
6
|
+
export { b9 as A2AError, bF as A2ARequest, bG as A2AResponse, aK as APIKeySecurityScheme, bT as AgentApiInsert, dW as AgentApiInsertSchema, bS as AgentApiSelect, dV as AgentApiSelectSchema, bU as AgentApiUpdate, dX as AgentApiUpdateSchema, aG as AgentCapabilities, aU as AgentCard, dk as AgentConversationHistoryConfig, dT as AgentInsertSchema, gh as AgentListResponse, aH as AgentProvider, g1 as AgentResponse, dS as AgentSelectSchema, aI as AgentSkill, e as AgentStopWhen, b as AgentStopWhenSchema, dU as AgentUpdateSchema, fN as AgentWithinContextOfProjectSchema, e_ as AllAgentSchema, cN as AllAgentSelect, cR as ApiKeyApiCreationResponse, f3 as ApiKeyApiCreationResponseSchema, cP as ApiKeyApiInsert, f4 as ApiKeyApiInsertSchema, cO as ApiKeyApiSelect, f2 as ApiKeyApiSelectSchema, cQ as ApiKeyApiUpdate, A as ApiKeyApiUpdateSchema, f0 as ApiKeyInsertSchema, gl as ApiKeyListResponse, g5 as ApiKeyResponse, e$ as ApiKeySelectSchema, f1 as ApiKeyUpdateSchema, cC as ArtifactComponentApiInsert, eM as ArtifactComponentApiInsertSchema, cB as ArtifactComponentApiSelect, eL as ArtifactComponentApiSelectSchema, cD as ArtifactComponentApiUpdate, eN as ArtifactComponentApiUpdateSchema, eJ as ArtifactComponentInsertSchema, gq as ArtifactComponentListResponse, ga as ArtifactComponentResponse, eI as ArtifactComponentSelectSchema, eK as ArtifactComponentUpdateSchema, aN as AuthorizationCodeOAuthFlow, d3 as CanUseItem, fM as CanUseItemSchema, bp as CancelTaskRequest, bA as CancelTaskResponse, bz as CancelTaskSuccessResponse, aO as ClientCredentialsOAuthFlow, b7 as ContentTypeNotSupportedError, cq as ContextCacheApiInsert, et as ContextCacheApiInsertSchema, cp as ContextCacheApiSelect, es as ContextCacheApiSelectSchema, cr as ContextCacheApiUpdate, eu as ContextCacheApiUpdateSchema, dl as ContextCacheEntry, eq as ContextCacheInsertSchema, ep as ContextCacheSelectSchema, co as ContextCacheUpdate, er as ContextCacheUpdateSchema, ck as ContextConfigApiInsert, fw as ContextConfigApiInsertSchema, cj as ContextConfigApiSelect, fv as ContextConfigApiSelectSchema, cl as ContextConfigApiUpdate, fx as ContextConfigApiUpdateSchema, ft as ContextConfigInsertSchema, gk as ContextConfigListResponse, g4 as ContextConfigResponse, fs as ContextConfigSelectSchema, fu as ContextConfigUpdateSchema, cd as ConversationApiInsert, eh as ConversationApiInsertSchema, cc as ConversationApiSelect, eg as ConversationApiSelectSchema, ce as ConversationApiUpdate, ei as ConversationApiUpdateSchema, ee as ConversationInsertSchema, gt as ConversationListResponse, gd as ConversationResponse, dj as ConversationScopeOptions, ed as ConversationSelectSchema, ef as ConversationUpdateSchema, f9 as CredentialReferenceApiInsertSchema, cS as CredentialReferenceApiSelect, f8 as CredentialReferenceApiSelectSchema, cT as CredentialReferenceApiUpdate, fa as CredentialReferenceApiUpdateSchema, f6 as CredentialReferenceInsertSchema, gm as CredentialReferenceListResponse, g6 as CredentialReferenceResponse, f5 as CredentialReferenceSelectSchema, f7 as CredentialReferenceUpdateSchema, ct as DataComponentApiInsert, eA as DataComponentApiInsertSchema, cs as DataComponentApiSelect, ez as DataComponentApiSelectSchema, cu as DataComponentApiUpdate, eB as DataComponentApiUpdateSchema, ex as DataComponentBaseSchema, ew as DataComponentInsertSchema, gp as DataComponentListResponse, g9 as DataComponentResponse, ev as DataComponentSelectSchema, ey as DataComponentUpdateSchema, aE as DataPart, fR as ErrorResponseSchema, fS as ExistsResponseSchema, eY as ExternalAgentApiInsertSchema, cK as ExternalAgentApiSelect, eX as ExternalAgentApiSelectSchema, cM as ExternalAgentApiUpdate, eZ as ExternalAgentApiUpdateSchema, eV as ExternalAgentInsertSchema, gj as ExternalAgentListResponse, g3 as ExternalAgentResponse, eU as ExternalAgentSelectSchema, eW as ExternalAgentUpdateSchema, cL as ExternalSubAgentApiInsert, bR as ExternalSubAgentRelationApiInsert, dR as ExternalSubAgentRelationApiInsertSchema, dQ as ExternalSubAgentRelationInsertSchema, cn as FetchConfig, fq as FetchConfigSchema, cm as FetchDefinition, fr as FetchDefinitionSchema, aA as FileBase, aD as FilePart, aB as FileWithBytes, aC as FileWithUri, d2 as FullAgentAgentInsert, a as FullAgentAgentInsertSchema, f_ as FullProjectDefinitionSchema, F as FunctionApiInsertSchema, c9 as FunctionApiSelect, j as FunctionApiSelectSchema, ca as FunctionApiUpdate, k as FunctionApiUpdateSchema, c7 as FunctionInsert, fo as FunctionInsertSchema, gn as FunctionListResponse, g7 as FunctionResponse, c6 as FunctionSelect, fn as FunctionSelectSchema, fl as FunctionToolApiInsertSchema, cb as FunctionToolApiSelect, fk as FunctionToolApiSelectSchema, fm as FunctionToolApiUpdateSchema, dC as FunctionToolConfig, dB as FunctionToolConfigSchema, fi as FunctionToolInsertSchema, go as FunctionToolListResponse, g8 as FunctionToolResponse, fh as FunctionToolSelectSchema, fj as FunctionToolUpdateSchema, c8 as FunctionUpdate, fp as FunctionUpdateSchema, br as GetTaskPushNotificationConfigRequest, bE as GetTaskPushNotificationConfigResponse, bD as GetTaskPushNotificationConfigSuccessResponse, bo as GetTaskRequest, by as GetTaskResponse, bx as GetTaskSuccessResponse, aL as HTTPAuthSecurityScheme, gz as HeadersScopeSchema, aP as ImplicitOAuthFlow, b2 as InternalError, d4 as InternalSubAgentDefinition, b8 as InvalidAgentResponseError, b1 as InvalidParamsError, a$ as InvalidRequestError, a_ as JSONParseError, bj as JSONRPCError, bl as JSONRPCErrorResponse, bh as JSONRPCMessage, bi as JSONRPCRequest, bk as JSONRPCResult, d0 as LedgerArtifactApiInsert, fI as LedgerArtifactApiInsertSchema, c$ as LedgerArtifactApiSelect, fH as LedgerArtifactApiSelectSchema, d1 as LedgerArtifactApiUpdate, fJ as LedgerArtifactApiUpdateSchema, cZ as LedgerArtifactInsert, fF as LedgerArtifactInsertSchema, fE as LedgerArtifactSelectSchema, c_ as LedgerArtifactUpdate, fG as LedgerArtifactUpdateSchema, fP as ListResponseSchema, dw as MAX_ID_LENGTH, du as MCPServerType, fc as MCPToolConfigSchema, dv as MIN_ID_LENGTH, dm as McpAuthType, dn as McpServerAuth, dq as McpServerCapabilities, dr as McpToolDefinition, ea as McpToolDefinitionSchema, fb as McpToolSchema, dp as McpTransportConfig, e8 as McpTransportConfigSchema, aV as Message, ch as MessageApiInsert, en as MessageApiInsertSchema, cg as MessageApiSelect, em as MessageApiSelectSchema, ci as MessageApiUpdate, eo as MessageApiUpdateSchema, ek as MessageInsertSchema, gu as MessageListResponse, de as MessageMode, bH as MessagePart, ge as MessageResponse, dd as MessageRole, cf as MessageSelect, ej as MessageSelectSchema, bf as MessageSendConfiguration, bg as MessageSendParams, dc as MessageType, el as MessageUpdateSchema, b0 as MethodNotFoundError, dz as ModelSchema, g as ModelSettings, M as ModelSettingsSchema, df as Models, aR as OAuth2SecurityScheme, aM as OAuthFlows, aS as OpenIdConnectSecurityScheme, da as Pagination, gI as PaginationQueryParamsSchema, fO as PaginationSchema, P as Part, ay as PartBase, aQ as PasswordOAuthFlow, d8 as ProjectApiInsert, fY as ProjectApiInsertSchema, d7 as ProjectApiSelect, fX as ProjectApiSelectSchema, d9 as ProjectApiUpdate, fZ as ProjectApiUpdateSchema, fV as ProjectInsertSchema, gf as ProjectListResponse, dA as ProjectModelSchema, dg as ProjectModels, f$ as ProjectResponse, fU as ProjectSelectSchema, fW as ProjectUpdateSchema, ba as PushNotificationAuthenticationInfo, bb as PushNotificationConfig, b5 as PushNotificationNotSupportedError, fT as RemovedResponseSchema, aT as SecurityScheme, aJ as SecuritySchemeBase, bm as SendMessageRequest, bu as SendMessageResponse, bt as SendMessageSuccessResponse, bn as SendStreamingMessageRequest, bw as SendStreamingMessageResponse, bv as SendStreamingMessageSuccessResponse, bq as SetTaskPushNotificationConfigRequest, bC as SetTaskPushNotificationConfigResponse, bB as SetTaskPushNotificationConfigSuccessResponse, fQ as SingleResponseSchema, di as StatusComponent, fK as StatusComponentSchema, fL as StatusUpdateSchema, dh as StatusUpdateSettings, d as StopWhen, S as StopWhenSchema, bK as SubAgentApiInsert, dH as SubAgentApiInsertSchema, bJ as SubAgentApiSelect, dG as SubAgentApiSelectSchema, bL as SubAgentApiUpdate, dI as SubAgentApiUpdateSchema, cI as SubAgentArtifactComponentApiInsert, eS as SubAgentArtifactComponentApiInsertSchema, cH as SubAgentArtifactComponentApiSelect, eR as SubAgentArtifactComponentApiSelectSchema, cJ as SubAgentArtifactComponentApiUpdate, eT as SubAgentArtifactComponentApiUpdateSchema, cF as SubAgentArtifactComponentInsert, eP as SubAgentArtifactComponentInsertSchema, gy as SubAgentArtifactComponentListResponse, gw as SubAgentArtifactComponentResponse, cE as SubAgentArtifactComponentSelect, eO as SubAgentArtifactComponentSelectSchema, cG as SubAgentArtifactComponentUpdate, eQ as SubAgentArtifactComponentUpdateSchema, cz as SubAgentDataComponentApiInsert, eG as SubAgentDataComponentApiInsertSchema, cy as SubAgentDataComponentApiSelect, eF as SubAgentDataComponentApiSelectSchema, cA as SubAgentDataComponentApiUpdate, eH as SubAgentDataComponentApiUpdateSchema, cw as SubAgentDataComponentInsert, eD as SubAgentDataComponentInsertSchema, gx as SubAgentDataComponentListResponse, gv as SubAgentDataComponentResponse, cv as SubAgentDataComponentSelect, eC as SubAgentDataComponentSelectSchema, cx as SubAgentDataComponentUpdate, eE as SubAgentDataComponentUpdateSchema, d5 as SubAgentDefinition, dE as SubAgentInsertSchema, gg as SubAgentListResponse, bO as SubAgentRelationApiInsert, dN as SubAgentRelationApiInsertSchema, bN as SubAgentRelationApiSelect, dM as SubAgentRelationApiSelectSchema, bP as SubAgentRelationApiUpdate, dO as SubAgentRelationApiUpdateSchema, dK as SubAgentRelationInsertSchema, gr as SubAgentRelationListResponse, bQ as SubAgentRelationQuery, dP as SubAgentRelationQuerySchema, gb as SubAgentRelationResponse, bM as SubAgentRelationSelect, dJ as SubAgentRelationSelectSchema, dL as SubAgentRelationUpdateSchema, g0 as SubAgentResponse, dD as SubAgentSelectSchema, f as SubAgentStopWhen, c as SubAgentStopWhenSchema, cX as SubAgentToolRelationApiInsert, fC as SubAgentToolRelationApiInsertSchema, cW as SubAgentToolRelationApiSelect, fB as SubAgentToolRelationApiSelectSchema, cY as SubAgentToolRelationApiUpdate, fD as SubAgentToolRelationApiUpdateSchema, cV as SubAgentToolRelationInsert, fz as SubAgentToolRelationInsertSchema, gs as SubAgentToolRelationListResponse, gc as SubAgentToolRelationResponse, cU as SubAgentToolRelationSelect, fy as SubAgentToolRelationSelectSchema, fA as SubAgentToolRelationUpdateSchema, dF as SubAgentUpdateSchema, db as SummaryEvent, ds as TOOL_STATUS_VALUES, aX as Task, bX as TaskApiInsert, e0 as TaskApiInsertSchema, bW as TaskApiSelect, d$ as TaskApiSelectSchema, bY as TaskApiUpdate, e1 as TaskApiUpdateSchema, bI as TaskArtifact, aZ as TaskArtifactUpdateEvent, bd as TaskIdParams, dZ as TaskInsertSchema, b4 as TaskNotCancelableError, b3 as TaskNotFoundError, bc as TaskPushNotificationConfig, be as TaskQueryParams, c1 as TaskRelationApiInsert, e6 as TaskRelationApiInsertSchema, c0 as TaskRelationApiSelect, e5 as TaskRelationApiSelectSchema, c2 as TaskRelationApiUpdate, e7 as TaskRelationApiUpdateSchema, b_ as TaskRelationInsert, e3 as TaskRelationInsertSchema, bZ as TaskRelationSelect, e2 as TaskRelationSelectSchema, b$ as TaskRelationUpdate, e4 as TaskRelationUpdateSchema, bs as TaskResubscriptionRequest, dY as TaskSelectSchema, aF as TaskState, aW as TaskStatus, aY as TaskStatusUpdateEvent, bV as TaskUpdate, d_ as TaskUpdateSchema, gB as TenantIdParamsSchema, gA as TenantParamsSchema, gF as TenantProjectAgentIdParamsSchema, gE as TenantProjectAgentParamsSchema, gH as TenantProjectAgentSubAgentIdParamsSchema, gG as TenantProjectAgentSubAgentParamsSchema, gD as TenantProjectIdParamsSchema, gC as TenantProjectParamsSchema, az as TextPart, c4 as ToolApiInsert, ff as ToolApiInsertSchema, c3 as ToolApiSelect, fe as ToolApiSelectSchema, c5 as ToolApiUpdate, fg as ToolApiUpdateSchema, d6 as ToolDefinition, ec as ToolInsertSchema, gi as ToolListResponse, g2 as ToolResponse, eb as ToolSelectSchema, e9 as ToolStatusSchema, fd as ToolUpdateSchema, dx as URL_SAFE_ID_PATTERN, b6 as UnsupportedOperationError, dt as VALID_RELATION_TYPES, dy as resourceIdSchema } from './utility-mGrlR4Ta.cjs';
|
|
6
7
|
import { CredentialStore } from './types/index.cjs';
|
|
7
8
|
export { CorsConfig, ServerConfig, ServerOptions } from './types/index.cjs';
|
|
8
9
|
import { LibSQLDatabase } from 'drizzle-orm/libsql';
|
|
9
|
-
import { s as schema } from './schema-
|
|
10
|
-
export { E as agentRelations, H as agentToolRelationsRelations, a as agents, w as apiKeys, G as apiKeysRelations, j as artifactComponents, M as artifactComponentsRelations, b as contextCache, C as contextCacheRelations, c as contextConfigs, B as contextConfigsRelations, r as conversations, K as conversationsRelations, x as credentialReferences, I as credentialReferencesRelations, h as dataComponents, O as dataComponentsRelations, f as externalAgents, F as externalAgentsRelations, m as functionTools, T as functionToolsRelations, n as functions, R as functionsRelations, v as ledgerArtifacts, Q as ledgerArtifactsRelations, u as messages, L as messagesRelations, p as projects, z as projectsRelations, k as subAgentArtifactComponents, N as subAgentArtifactComponentsRelations, i as subAgentDataComponents, P as subAgentDataComponentsRelations, q as subAgentFunctionToolRelations, U as subAgentFunctionToolRelationsRelations, e as subAgentRelations, S as subAgentRelationsRelations, o as subAgentToolRelations, d as subAgents, D as subAgentsRelations, g as taskRelations, A as taskRelationsRelations, t as tasks, y as tasksRelations, l as tools, J as toolsRelations } from './schema-
|
|
11
|
-
import { LoggerOptions, TransportSingleOptions, Logger } from 'pino';
|
|
10
|
+
import { s as schema } from './schema-B8NMPwEM.cjs';
|
|
11
|
+
export { E as agentRelations, H as agentToolRelationsRelations, a as agents, w as apiKeys, G as apiKeysRelations, j as artifactComponents, M as artifactComponentsRelations, b as contextCache, C as contextCacheRelations, c as contextConfigs, B as contextConfigsRelations, r as conversations, K as conversationsRelations, x as credentialReferences, I as credentialReferencesRelations, h as dataComponents, O as dataComponentsRelations, f as externalAgents, F as externalAgentsRelations, m as functionTools, T as functionToolsRelations, n as functions, R as functionsRelations, v as ledgerArtifacts, Q as ledgerArtifactsRelations, u as messages, L as messagesRelations, p as projects, z as projectsRelations, k as subAgentArtifactComponents, N as subAgentArtifactComponentsRelations, i as subAgentDataComponents, P as subAgentDataComponentsRelations, q as subAgentFunctionToolRelations, U as subAgentFunctionToolRelationsRelations, e as subAgentRelations, S as subAgentRelationsRelations, o as subAgentToolRelations, d as subAgents, D as subAgentsRelations, g as taskRelations, A as taskRelationsRelations, t as tasks, y as tasksRelations, l as tools, J as toolsRelations } from './schema-B8NMPwEM.cjs';
|
|
12
12
|
import { SSEClientTransportOptions } from '@modelcontextprotocol/sdk/client/sse.js';
|
|
13
13
|
import { StreamableHTTPClientTransportOptions } from '@modelcontextprotocol/sdk/client/streamableHttp.js';
|
|
14
14
|
import { ClientCapabilities } from '@modelcontextprotocol/sdk/types.js';
|
|
@@ -21,6 +21,7 @@ export { convertZodToJsonSchema, convertZodToJsonSchemaWithPreview, extractPrevi
|
|
|
21
21
|
import { Span, Tracer } from '@opentelemetry/api';
|
|
22
22
|
export { A2AMessageMetadata, A2AMessageMetadataSchema, DataOperationDetails, DataOperationDetailsSchema, DataOperationEvent, DataOperationEventSchema, DelegationReturnedData, DelegationReturnedDataSchema, DelegationSentData, DelegationSentDataSchema, PreviewValidationResult, TransferData, TransferDataSchema, generateIdFromName, isExternalAgent, isInternalAgent, isValidResourceId, validateAgentRelationships, validateAgentStructure, validateAndTypeAgentData, validateArtifactComponentReferences, validateDataComponentReferences, validatePreview, validateToolReferences } from './validation/index.cjs';
|
|
23
23
|
export { P as PropsValidationResult, v as validatePropsAsJsonSchema } from './props-validation-BMR1qNiy.cjs';
|
|
24
|
+
import 'pino';
|
|
24
25
|
import 'drizzle-zod';
|
|
25
26
|
import 'drizzle-orm';
|
|
26
27
|
|
|
@@ -638,87 +639,6 @@ declare class NangoCredentialStore implements CredentialStore {
|
|
|
638
639
|
*/
|
|
639
640
|
declare function createNangoCredentialStore(id: string, config?: Partial<NangoConfig>): NangoCredentialStore;
|
|
640
641
|
|
|
641
|
-
/**
|
|
642
|
-
* Configuration options for PinoLogger
|
|
643
|
-
*/
|
|
644
|
-
interface PinoLoggerConfig {
|
|
645
|
-
/** Pino logger options */
|
|
646
|
-
options?: LoggerOptions;
|
|
647
|
-
/** Pino transport configuration */
|
|
648
|
-
transportConfigs?: TransportSingleOptions[];
|
|
649
|
-
}
|
|
650
|
-
/**
|
|
651
|
-
* Pino logger implementation with transport customization support
|
|
652
|
-
*/
|
|
653
|
-
declare class PinoLogger {
|
|
654
|
-
private name;
|
|
655
|
-
private transportConfigs;
|
|
656
|
-
private pinoInstance;
|
|
657
|
-
private options;
|
|
658
|
-
constructor(name: string, config?: PinoLoggerConfig);
|
|
659
|
-
/**
|
|
660
|
-
* Recreate the pino instance with current transports
|
|
661
|
-
*/
|
|
662
|
-
private recreateInstance;
|
|
663
|
-
/**
|
|
664
|
-
* Add a new transport to the logger
|
|
665
|
-
*/
|
|
666
|
-
addTransport(transportConfig: TransportSingleOptions): void;
|
|
667
|
-
/**
|
|
668
|
-
* Remove a transport by index
|
|
669
|
-
*/
|
|
670
|
-
removeTransport(index: number): void;
|
|
671
|
-
/**
|
|
672
|
-
* Get current transports
|
|
673
|
-
*/
|
|
674
|
-
getTransports(): TransportSingleOptions[];
|
|
675
|
-
/**
|
|
676
|
-
* Update logger options
|
|
677
|
-
*/
|
|
678
|
-
updateOptions(options: Partial<LoggerOptions>): void;
|
|
679
|
-
/**
|
|
680
|
-
* Get the underlying pino instance for advanced usage
|
|
681
|
-
*/
|
|
682
|
-
getPinoInstance(): Logger;
|
|
683
|
-
error(data: any, message: string): void;
|
|
684
|
-
warn(data: any, message: string): void;
|
|
685
|
-
info(data: any, message: string): void;
|
|
686
|
-
debug(data: any, message: string): void;
|
|
687
|
-
}
|
|
688
|
-
/**
|
|
689
|
-
* Logger factory configuration
|
|
690
|
-
*/
|
|
691
|
-
interface LoggerFactoryConfig {
|
|
692
|
-
defaultLogger?: PinoLogger;
|
|
693
|
-
loggerFactory?: (name: string) => PinoLogger;
|
|
694
|
-
/** Configuration for creating PinoLogger instances when using createPinoLoggerFactory */
|
|
695
|
-
pinoConfig?: PinoLoggerConfig;
|
|
696
|
-
}
|
|
697
|
-
/**
|
|
698
|
-
* Global logger factory singleton
|
|
699
|
-
*/
|
|
700
|
-
declare class LoggerFactory {
|
|
701
|
-
private config;
|
|
702
|
-
private loggers;
|
|
703
|
-
/**
|
|
704
|
-
* Configure the logger factory
|
|
705
|
-
*/
|
|
706
|
-
configure(config: LoggerFactoryConfig): void;
|
|
707
|
-
/**
|
|
708
|
-
* Get or create a logger instance
|
|
709
|
-
*/
|
|
710
|
-
getLogger(name: string): PinoLogger;
|
|
711
|
-
/**
|
|
712
|
-
* Reset factory to default state
|
|
713
|
-
*/
|
|
714
|
-
reset(): void;
|
|
715
|
-
}
|
|
716
|
-
declare const loggerFactory: LoggerFactory;
|
|
717
|
-
/**
|
|
718
|
-
* Convenience function to get a logger
|
|
719
|
-
*/
|
|
720
|
-
declare function getLogger(name: string): PinoLogger;
|
|
721
|
-
|
|
722
642
|
interface SharedServerConfig {
|
|
723
643
|
timeout?: number;
|
|
724
644
|
activeTools?: string[];
|
|
@@ -788,6 +708,7 @@ interface CredentialData {
|
|
|
788
708
|
headers: Record<string, string>;
|
|
789
709
|
/** Additional metadata for the credentials */
|
|
790
710
|
metadata?: Record<string, any>;
|
|
711
|
+
expiresAt?: Date;
|
|
791
712
|
}
|
|
792
713
|
/**
|
|
793
714
|
* Credential store reference for lookups
|
|
@@ -3556,33 +3477,6 @@ declare function extractPublicId(key: string): string | null;
|
|
|
3556
3477
|
*/
|
|
3557
3478
|
declare function maskApiKey(keyPrefix: string): string;
|
|
3558
3479
|
|
|
3559
|
-
/**
|
|
3560
|
-
* Centralized authentication detection utilities for MCP tools
|
|
3561
|
-
*/
|
|
3562
|
-
|
|
3563
|
-
/**
|
|
3564
|
-
* OAuth configuration interface
|
|
3565
|
-
*/
|
|
3566
|
-
interface OAuthConfig {
|
|
3567
|
-
authorizationUrl: string;
|
|
3568
|
-
tokenUrl: string;
|
|
3569
|
-
registrationUrl?: string;
|
|
3570
|
-
supportsDynamicRegistration: boolean;
|
|
3571
|
-
}
|
|
3572
|
-
/**
|
|
3573
|
-
* Full OAuth endpoint discovery with complete configuration
|
|
3574
|
-
*/
|
|
3575
|
-
declare const discoverOAuthEndpoints: (serverUrl: string, logger?: PinoLogger) => Promise<OAuthConfig | null>;
|
|
3576
|
-
/**
|
|
3577
|
-
* Detect if OAuth 2.1/PKCE authentication is specifically required for a tool
|
|
3578
|
-
*/
|
|
3579
|
-
declare const detectAuthenticationRequired: ({ serverUrl, toolId, error, logger, }: {
|
|
3580
|
-
serverUrl: string;
|
|
3581
|
-
toolId: string;
|
|
3582
|
-
error: Error;
|
|
3583
|
-
logger?: PinoLogger;
|
|
3584
|
-
}) => Promise<boolean>;
|
|
3585
|
-
|
|
3586
3480
|
declare const generateId: (size?: number) => string;
|
|
3587
3481
|
/**
|
|
3588
3482
|
* Generates a standardized conversation ID.
|
|
@@ -4164,4 +4058,4 @@ declare function setSpanWithError(span: Span, error: Error, logger?: {
|
|
|
4164
4058
|
*/
|
|
4165
4059
|
declare function getTracer(serviceName: string, serviceVersion?: string): Tracer;
|
|
4166
4060
|
|
|
4167
|
-
export { AgentInsert, type AgentLogger, AgentScopeConfig, AgentSelect, AgentUpdate, ApiKeyCreateResult, type ApiKeyGenerationResult, ApiKeyInsert, ApiKeySelect, ApiKeyUpdate, Artifact, ArtifactComponentInsert, ArtifactComponentSelect, ArtifactComponentUpdate, type CommonCreateErrorResponses, type CommonDeleteErrorResponses, type CommonGetErrorResponses, type CommonUpdateErrorResponses, ContextCache, ContextCacheInsert, ContextCacheSelect, ContextConfigBuilder, type ContextConfigBuilderOptions, ContextConfigInsert, ContextConfigSelect, ContextConfigUpdate, ContextFetchDefinition, ContextFetcher, type ContextResolutionOptions, type ContextResolutionResult, ContextResolver, type ContextResolverInterface, type ContextValidationError, type ContextValidationResult, ConversationHistoryConfig, ConversationInsert, ConversationMetadata, ConversationSelect, ConversationUpdate, CreateApiKeyParams, type CredentialContext, type CredentialData, CredentialReferenceApiInsert, CredentialReferenceInsert, CredentialReferenceSelect, CredentialReferenceUpdate, type CredentialReferenceWithTools, type CredentialResolverInput, CredentialStore, type CredentialStoreReference, CredentialStoreRegistry, CredentialStoreType, CredentialStuffer, DataComponentInsert, DataComponentSelect, DataComponentUpdate, type DatabaseClient, type DatabaseConfig, type DotPaths, ERROR_DOCS_BASE_URL, ErrorCode, type ErrorCodes, type ErrorResponse, ExecutionContext, ExternalAgentInsert, ExternalAgentSelect, ExternalAgentUpdate, ExternalSubAgentRelationInsert, type FetchResult, FullAgentDefinition, FullProjectDefinition, FunctionApiInsert, FunctionToolApiInsert, FunctionToolApiUpdate, HTTP_REQUEST_PARTS, type HttpRequestPart, InMemoryCredentialStore, KeyChainStore, LedgerArtifactSelect,
|
|
4061
|
+
export { AgentInsert, type AgentLogger, AgentScopeConfig, AgentSelect, AgentUpdate, ApiKeyCreateResult, type ApiKeyGenerationResult, ApiKeyInsert, ApiKeySelect, ApiKeyUpdate, Artifact, ArtifactComponentInsert, ArtifactComponentSelect, ArtifactComponentUpdate, type CommonCreateErrorResponses, type CommonDeleteErrorResponses, type CommonGetErrorResponses, type CommonUpdateErrorResponses, ContextCache, ContextCacheInsert, ContextCacheSelect, ContextConfigBuilder, type ContextConfigBuilderOptions, ContextConfigInsert, ContextConfigSelect, ContextConfigUpdate, ContextFetchDefinition, ContextFetcher, type ContextResolutionOptions, type ContextResolutionResult, ContextResolver, type ContextResolverInterface, type ContextValidationError, type ContextValidationResult, ConversationHistoryConfig, ConversationInsert, ConversationMetadata, ConversationSelect, ConversationUpdate, CreateApiKeyParams, type CredentialContext, type CredentialData, CredentialReferenceApiInsert, CredentialReferenceInsert, CredentialReferenceSelect, CredentialReferenceUpdate, type CredentialReferenceWithTools, type CredentialResolverInput, CredentialStore, type CredentialStoreReference, CredentialStoreRegistry, CredentialStoreType, CredentialStuffer, DataComponentInsert, DataComponentSelect, DataComponentUpdate, type DatabaseClient, type DatabaseConfig, type DotPaths, ERROR_DOCS_BASE_URL, ErrorCode, type ErrorCodes, type ErrorResponse, ExecutionContext, ExternalAgentInsert, ExternalAgentSelect, ExternalAgentUpdate, ExternalSubAgentRelationInsert, type FetchResult, FullAgentDefinition, FullProjectDefinition, FunctionApiInsert, FunctionToolApiInsert, FunctionToolApiUpdate, HTTP_REQUEST_PARTS, type HttpRequestPart, InMemoryCredentialStore, KeyChainStore, LedgerArtifactSelect, MCPToolConfig, MCPTransportType, McpClient, type McpClientOptions, type McpSSEConfig, type McpServerConfig, type McpStreamableHttpConfig, McpTool, MessageContent, MessageInsert, MessageMetadata, MessageUpdate, MessageVisibility, NangoCredentialStore, PaginationConfig, PaginationResult, type ParsedHttpRequest, PinoLogger, type ProblemDetails, ProjectInfo, ProjectInsert, type ProjectLogger, ProjectResourceCounts, ProjectScopeConfig, ProjectSelect, ProjectUpdate, type ResolvedContext, SubAgentInsert, SubAgentRelationInsert, SubAgentRelationUpdate, SubAgentScopeConfig, SubAgentSelect, SubAgentToolRelationUpdate, SubAgentUpdate, TaskInsert, TaskMetadataConfig, TaskSelect, type TemplateContext, TemplateEngine, type TemplateRenderOptions, ToolInsert, ToolMcpConfig, ToolSelect, ToolServerCapabilities, ToolUpdate, addFunctionToolToSubAgent, addLedgerArtifacts, addToolToAgent, agentHasArtifactComponents, apiFetch, associateArtifactComponentWithAgent, associateDataComponentWithAgent, cleanupTenantCache, clearContextConfigCache, clearConversationCache, commonCreateErrorResponses, commonDeleteErrorResponses, commonGetErrorResponses, commonUpdateErrorResponses, contextConfig, contextValidationMiddleware, countApiKeys, countArtifactComponents, countArtifactComponentsForAgent, countContextConfigs, countCredentialReferences, countDataComponents, countExternalAgents, countLedgerArtifactsByTask, countMessagesByConversation, countProjects, createAgent, createAgentToolRelation, createApiError, createApiKey, createArtifactComponent, createContextConfig, createConversation, createCredentialReference, createDataComponent, createDatabaseClient, createDefaultCredentialStores, createExecutionContext, createExternalAgent, createExternalAgentRelation, createFullAgentServerSide, createFullProjectServerSide, createFunctionTool, createInMemoryDatabaseClient, createKeyChainStore, createMessage, createNangoCredentialStore, createOrGetConversation, createProject, createSubAgent, createSubAgentRelation, createTask, createTool, createValidatedDataAccess, dbResultToMcpTool, deleteAgent, deleteAgentArtifactComponentRelationByAgent, deleteAgentDataComponentRelationByAgent, deleteAgentRelationsByAgent, deleteAgentToolRelation, deleteAgentToolRelationByAgent, deleteApiKey, deleteArtifactComponent, deleteContextConfig, deleteConversation, deleteCredentialReference, deleteDataComponent, deleteExternalAgent, deleteFullAgent, deleteFullProject, deleteFunction, deleteFunctionTool, deleteLedgerArtifactsByContext, deleteLedgerArtifactsByTask, deleteMessage, deleteProject, deleteSubAgent, deleteSubAgentRelation, deleteTool, determineContextTrigger, errorResponseSchema, errorSchemaFactory, externalAgentExists, externalAgentUrlExists, extractPublicId, fetchComponentRelationships, fetchDefinition, generateAndCreateApiKey, generateApiKey, generateId, getActiveAgentForConversation, getAgentById, getAgentRelationById, getAgentRelationByParams, getAgentRelations, getAgentRelationsByAgent, getAgentRelationsBySource, getAgentSubAgentInfos, getAgentToolRelationByAgent, getAgentToolRelationById, getAgentToolRelationByTool, getAgentWithDefaultSubAgent, getAgentsForTool, getAgentsUsingArtifactComponent, getAgentsUsingDataComponent, getApiKeyById, getApiKeyByPublicId, getArtifactComponentById, getArtifactComponentsForAgent, getCacheEntry, getCachedValidator, getContextConfigById, getContextConfigCacheEntries, getConversation, getConversationCacheEntries, getConversationHistory, getConversationId, getCredentialReference, getCredentialReferenceById, getCredentialReferenceWithTools, getCredentialStoreLookupKeyFromRetrievalParams, getDataComponent, getDataComponentsForAgent, getExternalAgent, getExternalAgentByUrl, getExternalAgentRelations, getFullAgent, getFullAgentDefinition, getFullProject, getFunction, getFunctionToolById, getFunctionToolsForSubAgent, getLedgerArtifacts, getLedgerArtifactsByContext, getLogger, getMessageById, getMessagesByConversation, getMessagesByTask, getProject, getProjectResourceCounts, getRelatedAgentsForAgent, getRequestExecutionContext, getSubAgentById, getSubAgentRelationsByTarget, getSubAgentsByIds, getTask, getToolById, getToolsForAgent, getTracer, getVisibleMessages, handleApiError, handleContextConfigChange, handleContextResolution, hasApiKey, hasContextConfig, hasCredentialReference, hashApiKey, headers, invalidateHeadersCache, invalidateInvocationDefinitionsCache, isApiKeyExpired, isArtifactComponentAssociatedWithAgent, isDataComponentAssociatedWithAgent, isValidHttpRequest, listAgentRelations, listAgentToolRelations, listAgents, listAgentsPaginated, listApiKeys, listApiKeysPaginated, listArtifactComponents, listArtifactComponentsPaginated, listContextConfigs, listContextConfigsPaginated, listConversations, listCredentialReferences, listCredentialReferencesPaginated, listDataComponents, listDataComponentsPaginated, listExternalAgents, listExternalAgentsPaginated, listFunctionTools, listFunctions, listMessages, listProjects, listProjectsPaginated, listSubAgents, listSubAgentsPaginated, listTaskIdsByContextId, listTools, loadEnvironmentFiles, maskApiKey, problemDetailsSchema, projectExists, projectExistsInTable, projectHasResources, removeArtifactComponentFromAgent, removeDataComponentFromAgent, removeToolFromAgent, setActiveAgentForConversation, setActiveAgentForThread, setCacheEntry, setSpanWithError, updateAgent, updateAgentRelation, updateAgentToolRelation, updateApiKey, updateApiKeyLastUsed, updateArtifactComponent, updateContextConfig, updateConversation, updateConversationActiveAgent, updateCredentialReference, updateDataComponent, updateExternalAgent, updateFullAgentServerSide, updateFullProjectServerSide, updateFunctionTool, updateMessage, updateProject, updateSubAgent, updateSubAgentFunctionToolRelation, updateTask, updateTool, upsertAgent, upsertAgentArtifactComponentRelation, upsertAgentDataComponentRelation, upsertArtifactComponent, upsertContextConfig, upsertCredentialReference, upsertDataComponent, upsertExternalAgent, upsertFunction, upsertFunctionTool, upsertLedgerArtifact, upsertSubAgent, upsertSubAgentFunctionToolRelation, upsertSubAgentRelation, upsertSubAgentToolRelation, upsertTool, validateAgainstJsonSchema, validateAndGetApiKey, validateApiKey, validateExternalAgent, validateHeaders, validateHttpRequestHeaders, validateInternalSubAgent, validateProjectExists, validationHelper, withProjectValidation };
|