@inkeep/agents-core 0.50.1 → 0.50.3
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/auth/auth-schema.d.ts +105 -105
- package/dist/auth/auth-validation-schemas.d.ts +148 -148
- package/dist/auth/auth.d.ts +24 -24
- package/dist/auth/auth.js +8 -9
- package/dist/auth/authz/sync.d.ts +22 -1
- package/dist/auth/authz/sync.js +59 -4
- package/dist/auth/permissions.d.ts +9 -9
- package/dist/client-exports.d.ts +12 -11
- package/dist/constants/models.d.ts +1 -0
- package/dist/constants/models.js +1 -0
- package/dist/constants/otel-attributes.d.ts +4 -0
- package/dist/constants/otel-attributes.js +4 -0
- package/dist/data-access/manage/agents.d.ts +40 -40
- package/dist/data-access/manage/artifactComponents.d.ts +12 -12
- package/dist/data-access/manage/contextConfigs.d.ts +12 -12
- package/dist/data-access/manage/dataComponents.d.ts +6 -6
- package/dist/data-access/manage/functionTools.d.ts +18 -18
- package/dist/data-access/manage/scope-helpers.d.ts +25 -0
- package/dist/data-access/manage/scope-helpers.js +18 -0
- package/dist/data-access/manage/skills.d.ts +14 -14
- package/dist/data-access/manage/subAgentExternalAgentRelations.d.ts +24 -24
- package/dist/data-access/manage/subAgentExternalAgentRelations.js +13 -12
- package/dist/data-access/manage/subAgentRelations.d.ts +20 -20
- package/dist/data-access/manage/subAgentTeamAgentRelations.d.ts +18 -18
- package/dist/data-access/manage/subAgents.d.ts +24 -24
- package/dist/data-access/manage/tools.d.ts +24 -24
- package/dist/data-access/runtime/apiKeys.d.ts +16 -16
- package/dist/data-access/runtime/conversations.d.ts +24 -24
- package/dist/data-access/runtime/messages.d.ts +18 -18
- package/dist/data-access/runtime/tasks.d.ts +7 -7
- package/dist/db/manage/manage-schema.d.ts +445 -445
- package/dist/db/runtime/runtime-schema.d.ts +288 -288
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -1
- package/dist/middleware/authz-meta.d.ts +15 -0
- package/dist/middleware/authz-meta.js +11 -0
- package/dist/middleware/create-protected-route.d.ts +30 -0
- package/dist/middleware/create-protected-route.js +20 -0
- package/dist/middleware/index.d.ts +5 -0
- package/dist/middleware/index.js +6 -0
- package/dist/middleware/inherited-auth.d.ts +43 -0
- package/dist/middleware/inherited-auth.js +50 -0
- package/dist/middleware/no-auth.d.ts +6 -0
- package/dist/middleware/no-auth.js +11 -0
- package/dist/utils/in-process-fetch.d.ts +30 -0
- package/dist/utils/in-process-fetch.js +51 -0
- package/dist/utils/index.d.ts +2 -1
- package/dist/utils/index.js +2 -1
- package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
- package/dist/validation/schemas.d.ts +1969 -1969
- package/package.json +5 -1
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { registerAuthzMeta } from "./authz-meta.js";
|
|
2
|
+
import { createMiddleware } from "hono/factory";
|
|
3
|
+
|
|
4
|
+
//#region src/middleware/inherited-auth.ts
|
|
5
|
+
/**
|
|
6
|
+
* Documentation-only permission marker for routes whose authentication
|
|
7
|
+
* is already enforced by a parent `app.use()` in createApp.ts.
|
|
8
|
+
*
|
|
9
|
+
* This does NOT perform any auth check itself — it only registers
|
|
10
|
+
* x-authz metadata so the OpenAPI spec accurately reflects the
|
|
11
|
+
* auth requirement.
|
|
12
|
+
*
|
|
13
|
+
* Use this when the route lives under a path that already has
|
|
14
|
+
* middleware applied (e.g. `/manage/tenants/*` has `manageApiKeyOrSessionAuth`).
|
|
15
|
+
*/
|
|
16
|
+
const inheritedAuth = (meta) => {
|
|
17
|
+
const mw = createMiddleware(async (_c, next) => {
|
|
18
|
+
await next();
|
|
19
|
+
});
|
|
20
|
+
registerAuthzMeta(mw, meta);
|
|
21
|
+
return mw;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Marker for routes under `/manage/tenants/*` whose auth is handled
|
|
25
|
+
* by `manageApiKeyOrSessionAuth()` in createApp.ts.
|
|
26
|
+
*
|
|
27
|
+
* No auth check runs at the route level — this is purely for OpenAPI documentation.
|
|
28
|
+
*/
|
|
29
|
+
const inheritedManageTenantAuth = () => inheritedAuth({
|
|
30
|
+
resource: "organization",
|
|
31
|
+
permission: "member",
|
|
32
|
+
description: "Requires organization membership. Auth is enforced by the manageApiKeyOrSessionAuth middleware in createApp.ts."
|
|
33
|
+
});
|
|
34
|
+
/**
|
|
35
|
+
* Marker for routes under `/run/*` whose auth is handled
|
|
36
|
+
* by `runApiKeyAuth()` in createApp.ts.
|
|
37
|
+
*
|
|
38
|
+
* No auth check runs at the route level — this is purely for OpenAPI documentation.
|
|
39
|
+
*/
|
|
40
|
+
const inheritedRunApiKeyAuth = () => inheritedAuth({ description: "Requires a valid API key (Bearer token). Auth is enforced by runApiKeyAuth middleware in createApp.ts." });
|
|
41
|
+
/**
|
|
42
|
+
* Marker for routes under `/work-apps/*` whose auth is handled
|
|
43
|
+
* by `workAppsAuth()` in createApp.ts.
|
|
44
|
+
*
|
|
45
|
+
* No auth check runs at the route level — this is purely for OpenAPI documentation.
|
|
46
|
+
*/
|
|
47
|
+
const inheritedWorkAppsAuth = () => inheritedAuth({ description: "Requires work-apps authentication (OIDC token or Slack signature). Auth is enforced by workAppsAuth middleware in createApp.ts." });
|
|
48
|
+
|
|
49
|
+
//#endregion
|
|
50
|
+
export { inheritedAuth, inheritedManageTenantAuth, inheritedRunApiKeyAuth, inheritedWorkAppsAuth };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
//#region src/utils/in-process-fetch.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* In-process fetch transport for internal self-calls.
|
|
4
|
+
*
|
|
5
|
+
* Routes requests through the Hono app's full middleware stack in-process
|
|
6
|
+
* rather than over the network. This guarantees same-instance execution,
|
|
7
|
+
* which is critical for features that rely on process-local state
|
|
8
|
+
* (e.g. the stream helper registry for real-time SSE streaming).
|
|
9
|
+
*
|
|
10
|
+
* Drop-in replacement for `fetch()` — same signature, same return type.
|
|
11
|
+
* Throws in production if the app hasn't been registered.
|
|
12
|
+
* Falls back to global `fetch` in test environments where the full app
|
|
13
|
+
* may not be initialized.
|
|
14
|
+
*
|
|
15
|
+
* **IMPORTANT**: Any code making internal A2A calls or self-referencing API
|
|
16
|
+
* calls within the agents service MUST use `getInProcessFetch()` instead of
|
|
17
|
+
* global `fetch`. Using regular `fetch` for same-service calls causes requests
|
|
18
|
+
* to leave the process and hit the load balancer, which may route them to a
|
|
19
|
+
* different instance — breaking features that depend on process-local state
|
|
20
|
+
* (e.g. stream helper registry, in-memory caches). This only manifests under
|
|
21
|
+
* load in multi-instance deployments and is extremely difficult to debug.
|
|
22
|
+
*
|
|
23
|
+
* @example
|
|
24
|
+
* import { getInProcessFetch } from '@inkeep/agents-core';
|
|
25
|
+
* const response = await getInProcessFetch()(url, init);
|
|
26
|
+
*/
|
|
27
|
+
declare function registerAppFetch(fn: typeof fetch): void;
|
|
28
|
+
declare function getInProcessFetch(): typeof fetch;
|
|
29
|
+
//#endregion
|
|
30
|
+
export { getInProcessFetch, registerAppFetch };
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { getLogger } from "./logger.js";
|
|
2
|
+
import { trace } from "@opentelemetry/api";
|
|
3
|
+
|
|
4
|
+
//#region src/utils/in-process-fetch.ts
|
|
5
|
+
/**
|
|
6
|
+
* In-process fetch transport for internal self-calls.
|
|
7
|
+
*
|
|
8
|
+
* Routes requests through the Hono app's full middleware stack in-process
|
|
9
|
+
* rather than over the network. This guarantees same-instance execution,
|
|
10
|
+
* which is critical for features that rely on process-local state
|
|
11
|
+
* (e.g. the stream helper registry for real-time SSE streaming).
|
|
12
|
+
*
|
|
13
|
+
* Drop-in replacement for `fetch()` — same signature, same return type.
|
|
14
|
+
* Throws in production if the app hasn't been registered.
|
|
15
|
+
* Falls back to global `fetch` in test environments where the full app
|
|
16
|
+
* may not be initialized.
|
|
17
|
+
*
|
|
18
|
+
* **IMPORTANT**: Any code making internal A2A calls or self-referencing API
|
|
19
|
+
* calls within the agents service MUST use `getInProcessFetch()` instead of
|
|
20
|
+
* global `fetch`. Using regular `fetch` for same-service calls causes requests
|
|
21
|
+
* to leave the process and hit the load balancer, which may route them to a
|
|
22
|
+
* different instance — breaking features that depend on process-local state
|
|
23
|
+
* (e.g. stream helper registry, in-memory caches). This only manifests under
|
|
24
|
+
* load in multi-instance deployments and is extremely difficult to debug.
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* import { getInProcessFetch } from '@inkeep/agents-core';
|
|
28
|
+
* const response = await getInProcessFetch()(url, init);
|
|
29
|
+
*/
|
|
30
|
+
const logger = getLogger("in-process-fetch");
|
|
31
|
+
const GLOBAL_KEY = "__inkeep_appFetch";
|
|
32
|
+
function registerAppFetch(fn) {
|
|
33
|
+
globalThis[GLOBAL_KEY] = fn;
|
|
34
|
+
}
|
|
35
|
+
function getInProcessFetch() {
|
|
36
|
+
const appFetch = globalThis[GLOBAL_KEY];
|
|
37
|
+
if (!appFetch) {
|
|
38
|
+
if (process.env.ENVIRONMENT === "test" || process.env.ENVIRONMENT === "development") return fetch;
|
|
39
|
+
throw new Error("[in-process-fetch] App fetch not registered. Call registerAppFetch() during app initialization before handling requests.");
|
|
40
|
+
}
|
|
41
|
+
return ((input, init) => {
|
|
42
|
+
const url = typeof input === "string" ? input : input instanceof URL ? input.href : input.url;
|
|
43
|
+
const activeSpan = trace.getActiveSpan();
|
|
44
|
+
if (activeSpan) activeSpan.setAttribute("http.route.in_process", true);
|
|
45
|
+
logger.debug({ url }, "Routing request in-process");
|
|
46
|
+
return appFetch(input, init);
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
//#endregion
|
|
51
|
+
export { getInProcessFetch, registerAppFetch };
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -9,6 +9,7 @@ import { getCredentialStoreLookupKeyFromRetrievalParams } from "./credential-sto
|
|
|
9
9
|
import { normalizeDateString, toISODateString } from "./date.js";
|
|
10
10
|
import { CommonCreateErrorResponses, CommonDeleteErrorResponses, CommonGetErrorResponses, CommonUpdateErrorResponses, ERROR_DOCS_BASE_URL, ErrorCode, ErrorCodes, ErrorResponse, ProblemDetails, commonCreateErrorResponses, commonDeleteErrorResponses, commonGetErrorResponses, commonUpdateErrorResponses, createApiError, errorResponseSchema, errorSchemaFactory, handleApiError, problemDetailsSchema } from "./error.js";
|
|
11
11
|
import { LLMMessage, formatMessagesForLLM, formatMessagesForLLMContext } from "./format-messages.js";
|
|
12
|
+
import { getInProcessFetch, registerAppFetch } from "./in-process-fetch.js";
|
|
12
13
|
import { JsonTransformer } from "./JsonTransformer.js";
|
|
13
14
|
import { parseEmbeddedJson } from "./json-parser.js";
|
|
14
15
|
import { MockLanguageModel, createMockModel } from "./mock-provider.js";
|
|
@@ -26,4 +27,4 @@ import "./third-party-mcp-servers/index.js";
|
|
|
26
27
|
import { flushTraces, getTracer, setSpanWithError, unwrapError } from "./tracer-factory.js";
|
|
27
28
|
import { HashedHeaderValue, SignatureVerificationErrorCode, SignatureVerificationResult, TriggerAuthResult, hashAuthenticationHeaders, hashTriggerHeaderValue, validateTriggerHeaderValue, verifySignatureWithConfig, verifyTriggerAuth } from "./trigger-auth.js";
|
|
28
29
|
import { _resetWaitUntilCache, getWaitUntil } from "./wait-until.js";
|
|
29
|
-
export { ApiKeyGenerationResult, CommonCreateErrorResponses, CommonDeleteErrorResponses, CommonGetErrorResponses, CommonUpdateErrorResponses, CredentialScope, ERROR_DOCS_BASE_URL, ErrorCode, ErrorCodes, ErrorResponse, GenerateInternalServiceTokenParams, GenerateServiceTokenParams, HashedHeaderValue, InternalServiceId, InternalServiceTokenPayload, InternalServices, JsonTransformer, JwtVerifyResult, LLMMessage, LoggerFactoryConfig, McpClient, McpClientOptions, McpOAuthFlowResult, McpSSEConfig, McpServerConfig, McpStreamableHttpConfig, McpTokenExchangeResult, MockLanguageModel, ModelFactory, OAuthConfig, ParsedSSEResponse, PinoLogger, PinoLoggerConfig, ProblemDetails, ServiceTokenPayload, SignJwtOptions, SignSlackLinkTokenParams, SignSlackUserTokenParams, SignatureVerificationErrorCode, SignatureVerificationResult, SignedTempToken, SlackAccessTokenPayload, SlackAccessTokenPayloadSchema, SlackLinkTokenPayload, SlackLinkTokenPayloadSchema, TempTokenPayload, TriggerAuthResult, VerifyInternalServiceTokenResult, VerifyJwtOptions, VerifyServiceTokenResult, VerifySlackLinkTokenResult, VerifySlackUserTokenResult, _resetWaitUntilCache, buildComposioMCPUrl, commonCreateErrorResponses, commonDeleteErrorResponses, commonGetErrorResponses, commonUpdateErrorResponses, convertZodToJsonSchema, convertZodToJsonSchemaWithPreview, createApiError, createMockModel, decodeJwtPayload, detectAuthenticationRequired, errorResponseSchema, errorSchemaFactory, exchangeMcpAuthorizationCode, extractBearerToken, extractComposioServerId, extractPreviewFields, extractPublicId, fetchComposioServers, fetchSingleComposioServer, flushTraces, formatMessagesForLLM, formatMessagesForLLMContext, generateApiKey, generateId, generateInternalServiceToken, generateServiceToken, getComposioOAuthRedirectUrl, getComposioUserId, getConversationId, getCredentialStoreLookupKeyFromRetrievalParams, getJwtSecret, getLogger, getMetadataFromApiKey, getTracer, getWaitUntil, handleApiError, hasIssuer, hashApiKey, hashAuthenticationHeaders, hashTriggerHeaderValue, initiateMcpOAuthFlow, interpolateTemplate, isApiKeyExpired, isComposioMCPServerAuthenticated, isInternalServiceToken, isSlackUserToken, isThirdPartyMCPServerAuthenticated, isZodSchema, loggerFactory, maskApiKey, normalizeDateString, parseEmbeddedJson, parseSSEResponse, preview, problemDetailsSchema, setSpanWithError, signJwt, signSlackLinkToken, signSlackUserToken, signTempToken, toISODateString, unwrapError, validateApiKey, validateInternalServiceProjectAccess, validateInternalServiceTenantAccess, validateTargetAgent, validateTenantId, validateTriggerHeaderValue, verifyAuthorizationHeader, verifyInternalServiceAuthHeader, verifyInternalServiceToken, verifyJwt, verifyServiceToken, verifySignatureWithConfig, verifySlackLinkToken, verifySlackUserToken, verifyTempToken, verifyTriggerAuth };
|
|
30
|
+
export { ApiKeyGenerationResult, CommonCreateErrorResponses, CommonDeleteErrorResponses, CommonGetErrorResponses, CommonUpdateErrorResponses, CredentialScope, ERROR_DOCS_BASE_URL, ErrorCode, ErrorCodes, ErrorResponse, GenerateInternalServiceTokenParams, GenerateServiceTokenParams, HashedHeaderValue, InternalServiceId, InternalServiceTokenPayload, InternalServices, JsonTransformer, JwtVerifyResult, LLMMessage, LoggerFactoryConfig, McpClient, McpClientOptions, McpOAuthFlowResult, McpSSEConfig, McpServerConfig, McpStreamableHttpConfig, McpTokenExchangeResult, MockLanguageModel, ModelFactory, OAuthConfig, ParsedSSEResponse, PinoLogger, PinoLoggerConfig, ProblemDetails, ServiceTokenPayload, SignJwtOptions, SignSlackLinkTokenParams, SignSlackUserTokenParams, SignatureVerificationErrorCode, SignatureVerificationResult, SignedTempToken, SlackAccessTokenPayload, SlackAccessTokenPayloadSchema, SlackLinkTokenPayload, SlackLinkTokenPayloadSchema, TempTokenPayload, TriggerAuthResult, VerifyInternalServiceTokenResult, VerifyJwtOptions, VerifyServiceTokenResult, VerifySlackLinkTokenResult, VerifySlackUserTokenResult, _resetWaitUntilCache, buildComposioMCPUrl, commonCreateErrorResponses, commonDeleteErrorResponses, commonGetErrorResponses, commonUpdateErrorResponses, convertZodToJsonSchema, convertZodToJsonSchemaWithPreview, createApiError, createMockModel, decodeJwtPayload, detectAuthenticationRequired, errorResponseSchema, errorSchemaFactory, exchangeMcpAuthorizationCode, extractBearerToken, extractComposioServerId, extractPreviewFields, extractPublicId, fetchComposioServers, fetchSingleComposioServer, flushTraces, formatMessagesForLLM, formatMessagesForLLMContext, generateApiKey, generateId, generateInternalServiceToken, generateServiceToken, getComposioOAuthRedirectUrl, getComposioUserId, getConversationId, getCredentialStoreLookupKeyFromRetrievalParams, getInProcessFetch, getJwtSecret, getLogger, getMetadataFromApiKey, getTracer, getWaitUntil, handleApiError, hasIssuer, hashApiKey, hashAuthenticationHeaders, hashTriggerHeaderValue, initiateMcpOAuthFlow, interpolateTemplate, isApiKeyExpired, isComposioMCPServerAuthenticated, isInternalServiceToken, isSlackUserToken, isThirdPartyMCPServerAuthenticated, isZodSchema, loggerFactory, maskApiKey, normalizeDateString, parseEmbeddedJson, parseSSEResponse, preview, problemDetailsSchema, registerAppFetch, setSpanWithError, signJwt, signSlackLinkToken, signSlackUserToken, signTempToken, toISODateString, unwrapError, validateApiKey, validateInternalServiceProjectAccess, validateInternalServiceTenantAccess, validateTargetAgent, validateTenantId, validateTriggerHeaderValue, verifyAuthorizationHeader, verifyInternalServiceAuthHeader, verifyInternalServiceToken, verifyJwt, verifyServiceToken, verifySignatureWithConfig, verifySlackLinkToken, verifySlackUserToken, verifyTempToken, verifyTriggerAuth };
|
package/dist/utils/index.js
CHANGED
|
@@ -9,6 +9,7 @@ import { extractPublicId, generateApiKey, getMetadataFromApiKey, hashApiKey, isA
|
|
|
9
9
|
import { normalizeDateString, toISODateString } from "./date.js";
|
|
10
10
|
import { ERROR_DOCS_BASE_URL, ErrorCode, commonCreateErrorResponses, commonDeleteErrorResponses, commonGetErrorResponses, commonUpdateErrorResponses, createApiError, errorResponseSchema, errorSchemaFactory, handleApiError, problemDetailsSchema } from "./error.js";
|
|
11
11
|
import { formatMessagesForLLM, formatMessagesForLLMContext } from "./format-messages.js";
|
|
12
|
+
import { getInProcessFetch, registerAppFetch } from "./in-process-fetch.js";
|
|
12
13
|
import { JsonTransformer } from "./JsonTransformer.js";
|
|
13
14
|
import { parseEmbeddedJson } from "./json-parser.js";
|
|
14
15
|
import { McpClient } from "./mcp-client.js";
|
|
@@ -27,4 +28,4 @@ import { flushTraces, getTracer, setSpanWithError, unwrapError } from "./tracer-
|
|
|
27
28
|
import { hashAuthenticationHeaders, hashTriggerHeaderValue, validateTriggerHeaderValue, verifySignatureWithConfig, verifyTriggerAuth } from "./trigger-auth.js";
|
|
28
29
|
import { _resetWaitUntilCache, getWaitUntil } from "./wait-until.js";
|
|
29
30
|
|
|
30
|
-
export { ERROR_DOCS_BASE_URL, ErrorCode, InternalServices, JsonTransformer, McpClient, MockLanguageModel, ModelFactory, PinoLogger, SlackAccessTokenPayloadSchema, SlackLinkTokenPayloadSchema, _resetWaitUntilCache, buildComposioMCPUrl, commonCreateErrorResponses, commonDeleteErrorResponses, commonGetErrorResponses, commonUpdateErrorResponses, convertZodToJsonSchema, convertZodToJsonSchemaWithPreview, createApiError, createMockModel, decodeJwtPayload, detectAuthenticationRequired, errorResponseSchema, errorSchemaFactory, exchangeMcpAuthorizationCode, extractBearerToken, extractComposioServerId, extractPreviewFields, extractPublicId, fetchComposioServers, fetchSingleComposioServer, flushTraces, formatMessagesForLLM, formatMessagesForLLMContext, generateApiKey, generateId, generateInternalServiceToken, generateServiceToken, getComposioOAuthRedirectUrl, getComposioUserId, getConversationId, getCredentialStoreLookupKeyFromRetrievalParams, getJwtSecret, getLogger, getMetadataFromApiKey, getTracer, getWaitUntil, handleApiError, hasIssuer, hashApiKey, hashAuthenticationHeaders, hashTriggerHeaderValue, initiateMcpOAuthFlow, interpolateTemplate, isApiKeyExpired, isComposioMCPServerAuthenticated, isInternalServiceToken, isSlackUserToken, isThirdPartyMCPServerAuthenticated, isZodSchema, loggerFactory, maskApiKey, normalizeDateString, parseEmbeddedJson, parseSSEResponse, preview, problemDetailsSchema, setSpanWithError, signJwt, signSlackLinkToken, signSlackUserToken, signTempToken, toISODateString, unwrapError, validateApiKey, validateInternalServiceProjectAccess, validateInternalServiceTenantAccess, validateTargetAgent, validateTenantId, validateTriggerHeaderValue, verifyAuthorizationHeader, verifyInternalServiceAuthHeader, verifyInternalServiceToken, verifyJwt, verifyServiceToken, verifySignatureWithConfig, verifySlackLinkToken, verifySlackUserToken, verifyTempToken, verifyTriggerAuth };
|
|
31
|
+
export { ERROR_DOCS_BASE_URL, ErrorCode, InternalServices, JsonTransformer, McpClient, MockLanguageModel, ModelFactory, PinoLogger, SlackAccessTokenPayloadSchema, SlackLinkTokenPayloadSchema, _resetWaitUntilCache, buildComposioMCPUrl, commonCreateErrorResponses, commonDeleteErrorResponses, commonGetErrorResponses, commonUpdateErrorResponses, convertZodToJsonSchema, convertZodToJsonSchemaWithPreview, createApiError, createMockModel, decodeJwtPayload, detectAuthenticationRequired, errorResponseSchema, errorSchemaFactory, exchangeMcpAuthorizationCode, extractBearerToken, extractComposioServerId, extractPreviewFields, extractPublicId, fetchComposioServers, fetchSingleComposioServer, flushTraces, formatMessagesForLLM, formatMessagesForLLMContext, generateApiKey, generateId, generateInternalServiceToken, generateServiceToken, getComposioOAuthRedirectUrl, getComposioUserId, getConversationId, getCredentialStoreLookupKeyFromRetrievalParams, getInProcessFetch, getJwtSecret, getLogger, getMetadataFromApiKey, getTracer, getWaitUntil, handleApiError, hasIssuer, hashApiKey, hashAuthenticationHeaders, hashTriggerHeaderValue, initiateMcpOAuthFlow, interpolateTemplate, isApiKeyExpired, isComposioMCPServerAuthenticated, isInternalServiceToken, isSlackUserToken, isThirdPartyMCPServerAuthenticated, isZodSchema, loggerFactory, maskApiKey, normalizeDateString, parseEmbeddedJson, parseSSEResponse, preview, problemDetailsSchema, registerAppFetch, setSpanWithError, signJwt, signSlackLinkToken, signSlackUserToken, signTempToken, toISODateString, unwrapError, validateApiKey, validateInternalServiceProjectAccess, validateInternalServiceTenantAccess, validateTargetAgent, validateTenantId, validateTriggerHeaderValue, verifyAuthorizationHeader, verifyInternalServiceAuthHeader, verifyInternalServiceToken, verifyJwt, verifyServiceToken, verifySignatureWithConfig, verifySlackLinkToken, verifySlackUserToken, verifyTempToken, verifyTriggerAuth };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { z } from "@hono/zod-openapi";
|
|
2
|
-
import * as
|
|
2
|
+
import * as drizzle_zod361 from "drizzle-zod";
|
|
3
3
|
import { AnySQLiteTable } from "drizzle-orm/sqlite-core";
|
|
4
4
|
|
|
5
5
|
//#region src/validation/drizzle-schema-helpers.d.ts
|
|
6
|
-
declare function createSelectSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>):
|
|
7
|
-
declare function createInsertSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>):
|
|
6
|
+
declare function createSelectSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>): drizzle_zod361.BuildSchema<"select", T["_"]["columns"], drizzle_zod361.BuildRefine<T["_"]["columns"], undefined>, undefined>;
|
|
7
|
+
declare function createInsertSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>): drizzle_zod361.BuildSchema<"insert", T["_"]["columns"], drizzle_zod361.BuildRefine<Pick<T["_"]["columns"], keyof T["$inferInsert"]>, undefined>, undefined>;
|
|
8
8
|
declare const createSelectSchema: typeof createSelectSchemaWithModifiers;
|
|
9
9
|
declare const createInsertSchema: typeof createInsertSchemaWithModifiers;
|
|
10
10
|
/**
|