@frontmcp/sdk 0.7.2 → 0.8.0
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/agent/adapters/adapter.factory.d.ts +27 -18
- package/agent/adapters/adapter.factory.d.ts.map +1 -1
- package/agent/agent.instance.d.ts +5 -0
- package/agent/agent.instance.d.ts.map +1 -1
- package/agent/agent.scope.d.ts +54 -72
- package/agent/agent.scope.d.ts.map +1 -1
- package/agent/flows/call-agent.flow.d.ts +1 -0
- package/agent/flows/call-agent.flow.d.ts.map +1 -1
- package/app/instances/app.local.instance.d.ts +3 -0
- package/app/instances/app.local.instance.d.ts.map +1 -1
- package/app/instances/app.remote.instance.d.ts +3 -0
- package/app/instances/app.remote.instance.d.ts.map +1 -1
- package/auth/auth.registry.d.ts.map +1 -1
- package/auth/authorization/authorization.types.d.ts +7 -180
- package/auth/authorization/authorization.types.d.ts.map +1 -1
- package/auth/authorization/index.d.ts +2 -0
- package/auth/authorization/index.d.ts.map +1 -1
- package/auth/authorization/orchestrated.accessor.d.ts +161 -0
- package/auth/authorization/orchestrated.accessor.d.ts.map +1 -0
- package/auth/authorization/orchestrated.authorization.d.ts +19 -4
- package/auth/authorization/orchestrated.authorization.d.ts.map +1 -1
- package/auth/authorization/orchestrated.context-extension.d.ts +108 -0
- package/auth/authorization/orchestrated.context-extension.d.ts.map +1 -0
- package/auth/cimd/index.d.ts +14 -0
- package/auth/cimd/index.d.ts.map +1 -0
- package/auth/flows/auth.verify.flow.d.ts.map +1 -1
- package/auth/flows/oauth.authorize.flow.d.ts +30 -3
- package/auth/flows/oauth.authorize.flow.d.ts.map +1 -1
- package/auth/flows/oauth.callback.flow.d.ts +11 -3
- package/auth/flows/oauth.callback.flow.d.ts.map +1 -1
- package/auth/flows/oauth.provider-callback.flow.d.ts +118 -0
- package/auth/flows/oauth.provider-callback.flow.d.ts.map +1 -0
- package/auth/flows/oauth.register.flow.d.ts +1 -1
- package/auth/flows/oauth.token.flow.d.ts +1 -1
- package/auth/flows/session.verify.flow.d.ts +8 -0
- package/auth/flows/session.verify.flow.d.ts.map +1 -1
- package/auth/flows/well-known.jwks.flow.d.ts +3 -3
- package/auth/flows/well-known.oauth-authorization-server.flow.d.ts +3 -2
- package/auth/flows/well-known.oauth-authorization-server.flow.d.ts.map +1 -1
- package/auth/flows/well-known.prm.flow.d.ts +1 -1
- package/auth/instances/instance.local-primary-auth.d.ts +88 -1
- package/auth/instances/instance.local-primary-auth.d.ts.map +1 -1
- package/auth/machine-id.d.ts +14 -0
- package/auth/machine-id.d.ts.map +1 -1
- package/auth/session/encrypted-authorization-vault.d.ts +2 -3
- package/auth/session/encrypted-authorization-vault.d.ts.map +1 -1
- package/auth/session/federated-auth.session.d.ts +252 -0
- package/auth/session/federated-auth.session.d.ts.map +1 -0
- package/auth/session/index.d.ts +6 -2
- package/auth/session/index.d.ts.map +1 -1
- package/auth/session/orchestrated-token.store.d.ts +155 -0
- package/auth/session/orchestrated-token.store.d.ts.map +1 -0
- package/auth/session/record/session.base.d.ts +7 -7
- package/auth/session/record/session.base.d.ts.map +1 -1
- package/auth/session/record/session.mcp.d.ts +11 -0
- package/auth/session/record/session.mcp.d.ts.map +1 -0
- package/auth/session/redis-session.store.d.ts +10 -5
- package/auth/session/redis-session.store.d.ts.map +1 -1
- package/auth/session/session-crypto.d.ts +6 -9
- package/auth/session/session-crypto.d.ts.map +1 -1
- package/{store/store.factory.d.ts → auth/session/session-store.factory.d.ts} +10 -36
- package/auth/session/session-store.factory.d.ts.map +1 -0
- package/auth/session/session.service.d.ts +4 -8
- package/auth/session/session.service.d.ts.map +1 -1
- package/auth/session/session.transport.d.ts +8 -2
- package/auth/session/session.transport.d.ts.map +1 -1
- package/auth/session/session.types.d.ts +5 -5
- package/auth/session/session.types.d.ts.map +1 -1
- package/auth/session/token.refresh.d.ts +1 -2
- package/auth/session/token.refresh.d.ts.map +1 -1
- package/auth/session/transport-session.manager.d.ts +7 -6
- package/auth/session/transport-session.manager.d.ts.map +1 -1
- package/auth/session/utils/session-id.utils.d.ts +18 -1
- package/auth/session/utils/session-id.utils.d.ts.map +1 -1
- package/auth/session/vercel-kv-session.store.d.ts +16 -16
- package/auth/session/vercel-kv-session.store.d.ts.map +1 -1
- package/auth/utils/authorization-id.utils.d.ts +12 -0
- package/auth/utils/authorization-id.utils.d.ts.map +1 -0
- package/auth/utils/index.d.ts +1 -2
- package/auth/utils/index.d.ts.map +1 -1
- package/auth/vault/auth-providers.accessor.d.ts +153 -0
- package/auth/vault/auth-providers.accessor.d.ts.map +1 -0
- package/auth/vault/auth-providers.accessor.impl.d.ts +52 -0
- package/auth/vault/auth-providers.accessor.impl.d.ts.map +1 -0
- package/auth/vault/auth-providers.context-extension.d.ts +68 -0
- package/auth/vault/auth-providers.context-extension.d.ts.map +1 -0
- package/auth/vault/auth-providers.providers.d.ts +40 -0
- package/auth/vault/auth-providers.providers.d.ts.map +1 -0
- package/auth/vault/auth-providers.registry.d.ts +110 -0
- package/auth/vault/auth-providers.registry.d.ts.map +1 -0
- package/auth/vault/auth-providers.vault.d.ts +93 -0
- package/auth/vault/auth-providers.vault.d.ts.map +1 -0
- package/auth/vault/credential-cache.d.ts +13 -0
- package/auth/vault/credential-cache.d.ts.map +1 -0
- package/auth/vault/credential-loaders/eager-loader.d.ts +46 -0
- package/auth/vault/credential-loaders/eager-loader.d.ts.map +1 -0
- package/auth/vault/credential-loaders/index.d.ts +7 -0
- package/auth/vault/credential-loaders/index.d.ts.map +1 -0
- package/auth/vault/credential-loaders/lazy-loader.d.ts +53 -0
- package/auth/vault/credential-loaders/lazy-loader.d.ts.map +1 -0
- package/auth/vault/index.d.ts +56 -0
- package/auth/vault/index.d.ts.map +1 -0
- package/builtin/config/config-resolver.d.ts +162 -0
- package/builtin/config/config-resolver.d.ts.map +1 -0
- package/builtin/config/config.plugin.d.ts +63 -0
- package/builtin/config/config.plugin.d.ts.map +1 -0
- package/builtin/config/config.symbols.d.ts +7 -0
- package/builtin/config/config.symbols.d.ts.map +1 -0
- package/builtin/config/config.types.d.ts +71 -0
- package/builtin/config/config.types.d.ts.map +1 -0
- package/builtin/config/index.d.ts +68 -0
- package/builtin/config/index.d.ts.map +1 -0
- package/builtin/config/providers/config-loader.d.ts +36 -0
- package/builtin/config/providers/config-loader.d.ts.map +1 -0
- package/builtin/config/providers/config.service.d.ts +108 -0
- package/builtin/config/providers/config.service.d.ts.map +1 -0
- package/builtin/config/providers/env-loader.d.ts +76 -0
- package/builtin/config/providers/env-loader.d.ts.map +1 -0
- package/builtin/index.d.ts +7 -0
- package/builtin/index.d.ts.map +1 -0
- package/common/decorators/front-mcp.decorator.d.ts.map +1 -1
- package/common/decorators/hook.decorator.d.ts +0 -10
- package/common/decorators/hook.decorator.d.ts.map +1 -1
- package/common/decorators/index.d.ts +1 -0
- package/common/decorators/index.d.ts.map +1 -1
- package/common/decorators/skill.decorator.d.ts +105 -0
- package/common/decorators/skill.decorator.d.ts.map +1 -0
- package/common/dynamic/dynamic.adapter.d.ts +14 -4
- package/common/dynamic/dynamic.adapter.d.ts.map +1 -1
- package/common/entries/app.entry.d.ts +2 -0
- package/common/entries/app.entry.d.ts.map +1 -1
- package/common/entries/index.d.ts +1 -0
- package/common/entries/index.d.ts.map +1 -1
- package/common/entries/prompt.entry.d.ts +0 -6
- package/common/entries/prompt.entry.d.ts.map +1 -1
- package/common/entries/resource.entry.d.ts +0 -6
- package/common/entries/resource.entry.d.ts.map +1 -1
- package/common/entries/scope.entry.d.ts +2 -0
- package/common/entries/scope.entry.d.ts.map +1 -1
- package/common/entries/skill.entry.d.ts +95 -0
- package/common/entries/skill.entry.d.ts.map +1 -0
- package/common/entries/tool.entry.d.ts +17 -9
- package/common/entries/tool.entry.d.ts.map +1 -1
- package/common/interfaces/agent.interface.d.ts +35 -6
- package/common/interfaces/agent.interface.d.ts.map +1 -1
- package/common/interfaces/execution-context.interface.d.ts +14 -0
- package/common/interfaces/execution-context.interface.d.ts.map +1 -1
- package/common/interfaces/index.d.ts +1 -0
- package/common/interfaces/index.d.ts.map +1 -1
- package/common/interfaces/internal/primary-auth-provider.interface.d.ts +1 -7
- package/common/interfaces/internal/primary-auth-provider.interface.d.ts.map +1 -1
- package/common/interfaces/internal/registry.interface.d.ts +4 -1
- package/common/interfaces/internal/registry.interface.d.ts.map +1 -1
- package/common/interfaces/skill.interface.d.ts +91 -0
- package/common/interfaces/skill.interface.d.ts.map +1 -0
- package/common/interfaces/tool.interface.d.ts +39 -0
- package/common/interfaces/tool.interface.d.ts.map +1 -1
- package/common/metadata/agent.metadata.d.ts +62 -2
- package/common/metadata/agent.metadata.d.ts.map +1 -1
- package/common/metadata/app.metadata.d.ts +168 -169
- package/common/metadata/app.metadata.d.ts.map +1 -1
- package/common/metadata/front-mcp.metadata.d.ts +2182 -721
- package/common/metadata/front-mcp.metadata.d.ts.map +1 -1
- package/common/metadata/index.d.ts +1 -0
- package/common/metadata/index.d.ts.map +1 -1
- package/common/metadata/plugin.metadata.d.ts +8 -1
- package/common/metadata/plugin.metadata.d.ts.map +1 -1
- package/common/metadata/skill.metadata.d.ts +366 -0
- package/common/metadata/skill.metadata.d.ts.map +1 -0
- package/common/metadata/tool.metadata.d.ts +71 -0
- package/common/metadata/tool.metadata.d.ts.map +1 -1
- package/common/records/index.d.ts +1 -0
- package/common/records/index.d.ts.map +1 -1
- package/common/records/skill.record.d.ts +55 -0
- package/common/records/skill.record.d.ts.map +1 -0
- package/common/schemas/annotated-class.schema.d.ts +1 -0
- package/common/schemas/annotated-class.schema.d.ts.map +1 -1
- package/common/schemas/http-output.schema.d.ts +24 -24
- package/common/tokens/app.tokens.d.ts.map +1 -1
- package/common/tokens/front-mcp.tokens.d.ts.map +1 -1
- package/common/tokens/index.d.ts +1 -0
- package/common/tokens/index.d.ts.map +1 -1
- package/common/tokens/plugin.tokens.d.ts +1 -0
- package/common/tokens/plugin.tokens.d.ts.map +1 -1
- package/common/tokens/skill.tokens.d.ts +18 -0
- package/common/tokens/skill.tokens.d.ts.map +1 -0
- package/common/tokens/tool.tokens.d.ts +2 -0
- package/common/tokens/tool.tokens.d.ts.map +1 -1
- package/common/types/auth/session.types.d.ts +21 -0
- package/common/types/auth/session.types.d.ts.map +1 -1
- package/common/types/options/auth/app-auth.schema.d.ts +80 -84
- package/common/types/options/auth/app-auth.schema.d.ts.map +1 -1
- package/common/types/options/auth/index.d.ts +6 -8
- package/common/types/options/auth/index.d.ts.map +1 -1
- package/common/types/options/auth/{auth.interfaces.d.ts → interfaces.d.ts} +17 -48
- package/common/types/options/auth/interfaces.d.ts.map +1 -0
- package/common/types/options/auth/orchestrated.schema.d.ts +160 -84
- package/common/types/options/auth/orchestrated.schema.d.ts.map +1 -1
- package/common/types/options/auth/public.schema.d.ts +0 -21
- package/common/types/options/auth/public.schema.d.ts.map +1 -1
- package/common/types/options/auth/{auth.schema.d.ts → schema.d.ts} +81 -85
- package/common/types/options/auth/schema.d.ts.map +1 -0
- package/common/types/options/auth/shared.schemas.d.ts +12 -0
- package/common/types/options/auth/shared.schemas.d.ts.map +1 -1
- package/common/types/options/auth/transparent.schema.d.ts +0 -21
- package/common/types/options/auth/transparent.schema.d.ts.map +1 -1
- package/common/types/options/auth/typecheck.d.ts +2 -0
- package/common/types/options/auth/typecheck.d.ts.map +1 -0
- package/common/types/options/auth/{auth.utils.d.ts → utils.d.ts} +2 -2
- package/common/types/options/auth/utils.d.ts.map +1 -0
- package/common/types/options/elicitation/index.d.ts +4 -0
- package/common/types/options/elicitation/index.d.ts.map +1 -0
- package/common/types/options/elicitation/interfaces.d.ts +80 -0
- package/common/types/options/elicitation/interfaces.d.ts.map +1 -0
- package/common/types/options/elicitation/schema.d.ts +75 -0
- package/common/types/options/elicitation/schema.d.ts.map +1 -0
- package/common/types/options/ext-apps/index.d.ts +3 -0
- package/common/types/options/ext-apps/index.d.ts.map +1 -0
- package/common/types/options/ext-apps/interfaces.d.ts +2 -0
- package/common/types/options/ext-apps/interfaces.d.ts.map +1 -0
- package/common/types/options/ext-apps/schema.d.ts +80 -0
- package/common/types/options/ext-apps/schema.d.ts.map +1 -0
- package/common/types/options/http/index.d.ts +4 -0
- package/common/types/options/http/index.d.ts.map +1 -0
- package/common/types/options/http/interfaces.d.ts +23 -0
- package/common/types/options/http/interfaces.d.ts.map +1 -0
- package/common/types/options/http/schema.d.ts +18 -0
- package/common/types/options/http/schema.d.ts.map +1 -0
- package/common/types/options/index.d.ts +10 -6
- package/common/types/options/index.d.ts.map +1 -1
- package/common/types/options/logging/index.d.ts +5 -0
- package/common/types/options/logging/index.d.ts.map +1 -0
- package/common/types/options/logging/interfaces.d.ts +41 -0
- package/common/types/options/logging/interfaces.d.ts.map +1 -0
- package/common/types/options/logging/schema.d.ts +24 -0
- package/common/types/options/logging/schema.d.ts.map +1 -0
- package/common/types/options/pagination/index.d.ts +4 -0
- package/common/types/options/pagination/index.d.ts.map +1 -0
- package/common/types/options/pagination/interfaces.d.ts +43 -0
- package/common/types/options/pagination/interfaces.d.ts.map +1 -0
- package/common/types/options/pagination/schema.d.ts +41 -0
- package/common/types/options/pagination/schema.d.ts.map +1 -0
- package/common/types/options/redis/index.d.ts +4 -0
- package/common/types/options/redis/index.d.ts.map +1 -0
- package/common/types/options/redis/interfaces.d.ts +81 -0
- package/common/types/options/redis/interfaces.d.ts.map +1 -0
- package/common/types/options/{redis.options.d.ts → redis/schema.d.ts} +2 -2
- package/common/types/options/redis/schema.d.ts.map +1 -0
- package/common/types/options/server-info/index.d.ts +4 -0
- package/common/types/options/server-info/index.d.ts.map +1 -0
- package/common/types/options/server-info/interfaces.d.ts +27 -0
- package/common/types/options/server-info/interfaces.d.ts.map +1 -0
- package/common/types/options/{server-info.options.d.ts → server-info/schema.d.ts} +13 -10
- package/common/types/options/server-info/schema.d.ts.map +1 -0
- package/common/types/options/session/index.d.ts +4 -0
- package/common/types/options/session/index.d.ts.map +1 -0
- package/common/types/options/session/interfaces.d.ts +66 -0
- package/common/types/options/session/interfaces.d.ts.map +1 -0
- package/common/types/options/session/schema.d.ts +79 -0
- package/common/types/options/session/schema.d.ts.map +1 -0
- package/common/types/options/skills-http/index.d.ts +4 -0
- package/common/types/options/skills-http/index.d.ts.map +1 -0
- package/common/types/options/skills-http/interfaces.d.ts +321 -0
- package/common/types/options/skills-http/interfaces.d.ts.map +1 -0
- package/common/types/options/skills-http/schema.d.ts +139 -0
- package/common/types/options/skills-http/schema.d.ts.map +1 -0
- package/common/types/options/transport/index.d.ts +4 -0
- package/common/types/options/transport/index.d.ts.map +1 -0
- package/common/types/options/transport/interfaces.d.ts +354 -0
- package/common/types/options/transport/interfaces.d.ts.map +1 -0
- package/common/types/options/transport/schema.d.ts +309 -0
- package/common/types/options/transport/schema.d.ts.map +1 -0
- package/common/types/options/transport/typecheck.d.ts +2 -0
- package/common/types/options/transport/typecheck.d.ts.map +1 -0
- package/common/utils/decide-request-intent.utils.d.ts +3 -3
- package/common/utils/decide-request-intent.utils.d.ts.map +1 -1
- package/context/context-extension.d.ts +1 -28
- package/context/context-extension.d.ts.map +1 -1
- package/context/frontmcp-context-storage.d.ts.map +1 -1
- package/context/frontmcp-context.d.ts +36 -39
- package/context/frontmcp-context.d.ts.map +1 -1
- package/context/frontmcp-context.provider.d.ts +3 -9
- package/context/frontmcp-context.provider.d.ts.map +1 -1
- package/context/index.d.ts +5 -20
- package/context/index.d.ts.map +1 -1
- package/context/metadata.utils.d.ts +24 -0
- package/context/metadata.utils.d.ts.map +1 -0
- package/direct/client.types.d.ts +447 -0
- package/direct/client.types.d.ts.map +1 -0
- package/direct/connect.d.ts +188 -0
- package/direct/connect.d.ts.map +1 -0
- package/direct/direct-client.d.ts +7 -0
- package/direct/direct-client.d.ts.map +1 -0
- package/direct/direct-server.d.ts +38 -0
- package/direct/direct-server.d.ts.map +1 -0
- package/direct/direct.types.d.ts +134 -0
- package/direct/direct.types.d.ts.map +1 -0
- package/direct/index.d.ts +15 -0
- package/direct/index.d.ts.map +1 -0
- package/direct/llm-platform.d.ts +94 -0
- package/direct/llm-platform.d.ts.map +1 -0
- package/elicitation/elicitation-fallback.schema.d.ts +32 -0
- package/elicitation/elicitation-fallback.schema.d.ts.map +1 -0
- package/elicitation/elicitation.types.d.ts +160 -0
- package/elicitation/elicitation.types.d.ts.map +1 -0
- package/elicitation/flows/elicitation-request.flow.d.ts +98 -0
- package/elicitation/flows/elicitation-request.flow.d.ts.map +1 -0
- package/elicitation/flows/elicitation-result.flow.d.ts +79 -0
- package/elicitation/flows/elicitation-result.flow.d.ts.map +1 -0
- package/elicitation/flows/index.d.ts +10 -0
- package/elicitation/flows/index.d.ts.map +1 -0
- package/elicitation/helpers/elicit.helper.d.ts +65 -0
- package/elicitation/helpers/elicit.helper.d.ts.map +1 -0
- package/elicitation/helpers/extend-output-schema.d.ts +31 -0
- package/elicitation/helpers/extend-output-schema.d.ts.map +1 -0
- package/elicitation/helpers/fallback.helper.d.ts +60 -0
- package/elicitation/helpers/fallback.helper.d.ts.map +1 -0
- package/elicitation/helpers/index.d.ts +12 -0
- package/elicitation/helpers/index.d.ts.map +1 -0
- package/elicitation/helpers/validate-elicitation-content.d.ts +52 -0
- package/elicitation/helpers/validate-elicitation-content.d.ts.map +1 -0
- package/elicitation/hooks/elicitation.hooks.d.ts +66 -0
- package/elicitation/hooks/elicitation.hooks.d.ts.map +1 -0
- package/elicitation/hooks/index.d.ts +9 -0
- package/elicitation/hooks/index.d.ts.map +1 -0
- package/elicitation/index.d.ts +18 -0
- package/elicitation/index.d.ts.map +1 -0
- package/elicitation/send-elicitation-result.tool.d.ts +18 -0
- package/elicitation/send-elicitation-result.tool.d.ts.map +1 -0
- package/elicitation/store/elicitation-encryption.d.ts +134 -0
- package/elicitation/store/elicitation-encryption.d.ts.map +1 -0
- package/elicitation/store/elicitation-store.factory.d.ts +197 -0
- package/elicitation/store/elicitation-store.factory.d.ts.map +1 -0
- package/elicitation/store/elicitation.store.d.ts +191 -0
- package/elicitation/store/elicitation.store.d.ts.map +1 -0
- package/elicitation/store/encrypted-elicitation.store.d.ts +121 -0
- package/elicitation/store/encrypted-elicitation.store.d.ts.map +1 -0
- package/elicitation/store/index.d.ts +14 -0
- package/elicitation/store/index.d.ts.map +1 -0
- package/elicitation/store/storage-elicitation.store.d.ts +118 -0
- package/elicitation/store/storage-elicitation.store.d.ts.map +1 -0
- package/errors/elicitation.error.d.ts +115 -0
- package/errors/elicitation.error.d.ts.map +1 -0
- package/errors/index.d.ts +1 -0
- package/errors/index.d.ts.map +1 -1
- package/esm/index.mjs +30824 -19537
- package/esm/package.json +13 -7
- package/ext-apps/ext-apps.handler.d.ts +177 -0
- package/ext-apps/ext-apps.handler.d.ts.map +1 -0
- package/ext-apps/ext-apps.types.d.ts +273 -0
- package/ext-apps/ext-apps.types.d.ts.map +1 -0
- package/ext-apps/index.d.ts +13 -0
- package/ext-apps/index.d.ts.map +1 -0
- package/flows/flow.instance.d.ts.map +1 -1
- package/front-mcp/front-mcp.d.ts +64 -2
- package/front-mcp/front-mcp.d.ts.map +1 -1
- package/front-mcp/front-mcp.providers.d.ts +604 -236
- package/front-mcp/front-mcp.providers.d.ts.map +1 -1
- package/index.d.ts +17 -0
- package/index.d.ts.map +1 -1
- package/index.js +31066 -19707
- package/notification/index.d.ts +1 -1
- package/notification/index.d.ts.map +1 -1
- package/notification/notification.service.d.ts +18 -0
- package/notification/notification.service.d.ts.map +1 -1
- package/package.json +13 -7
- package/plugin/plugin.registry.d.ts +2 -0
- package/plugin/plugin.registry.d.ts.map +1 -1
- package/provider/provider.registry.d.ts +8 -3
- package/provider/provider.registry.d.ts.map +1 -1
- package/scope/flows/http.request.flow.d.ts +4 -0
- package/scope/flows/http.request.flow.d.ts.map +1 -1
- package/scope/scope.instance.d.ts +74 -0
- package/scope/scope.instance.d.ts.map +1 -1
- package/server/server.instance.d.ts +3 -3
- package/server/server.instance.d.ts.map +1 -1
- package/skill/auth/index.d.ts +10 -0
- package/skill/auth/index.d.ts.map +1 -0
- package/skill/auth/skill-http-auth.d.ts +112 -0
- package/skill/auth/skill-http-auth.d.ts.map +1 -0
- package/skill/cache/index.d.ts +13 -0
- package/skill/cache/index.d.ts.map +1 -0
- package/skill/cache/skill-http-cache.d.ts +144 -0
- package/skill/cache/skill-http-cache.d.ts.map +1 -0
- package/skill/cache/skill-http-cache.factory.d.ts +83 -0
- package/skill/cache/skill-http-cache.factory.d.ts.map +1 -0
- package/skill/cache/skill-http-cache.holder.d.ts +35 -0
- package/skill/cache/skill-http-cache.holder.d.ts.map +1 -0
- package/skill/errors/index.d.ts +3 -0
- package/skill/errors/index.d.ts.map +1 -0
- package/skill/errors/skill-validation.error.d.ts +110 -0
- package/skill/errors/skill-validation.error.d.ts.map +1 -0
- package/skill/errors/tool-not-allowed.error.d.ts +66 -0
- package/skill/errors/tool-not-allowed.error.d.ts.map +1 -0
- package/skill/flows/http/index.d.ts +12 -0
- package/skill/flows/http/index.d.ts.map +1 -0
- package/skill/flows/http/llm-full-txt.flow.d.ts +70 -0
- package/skill/flows/http/llm-full-txt.flow.d.ts.map +1 -0
- package/skill/flows/http/llm-txt.flow.d.ts +77 -0
- package/skill/flows/http/llm-txt.flow.d.ts.map +1 -0
- package/skill/flows/http/skills-api.flow.d.ts +81 -0
- package/skill/flows/http/skills-api.flow.d.ts.map +1 -0
- package/skill/flows/index.d.ts +13 -0
- package/skill/flows/index.d.ts.map +1 -0
- package/skill/flows/load-skill.flow.d.ts +169 -0
- package/skill/flows/load-skill.flow.d.ts.map +1 -0
- package/skill/flows/search-skills.flow.d.ts +101 -0
- package/skill/flows/search-skills.flow.d.ts.map +1 -0
- package/skill/guards/index.d.ts +2 -0
- package/skill/guards/index.d.ts.map +1 -0
- package/skill/guards/tool-authorization.guard.d.ts +87 -0
- package/skill/guards/tool-authorization.guard.d.ts.map +1 -0
- package/skill/hooks/index.d.ts +2 -0
- package/skill/hooks/index.d.ts.map +1 -0
- package/skill/hooks/skill-tool.hook.d.ts +52 -0
- package/skill/hooks/skill-tool.hook.d.ts.map +1 -0
- package/skill/index.d.ts +74 -0
- package/skill/index.d.ts.map +1 -0
- package/skill/providers/external-skill.provider.d.ts +240 -0
- package/skill/providers/external-skill.provider.d.ts.map +1 -0
- package/skill/providers/index.d.ts +12 -0
- package/skill/providers/index.d.ts.map +1 -0
- package/skill/providers/memory-skill.provider.d.ts +97 -0
- package/skill/providers/memory-skill.provider.d.ts.map +1 -0
- package/skill/session/index.d.ts +4 -0
- package/skill/session/index.d.ts.map +1 -0
- package/skill/session/skill-session-store.interface.d.ts +79 -0
- package/skill/session/skill-session-store.interface.d.ts.map +1 -0
- package/skill/session/skill-session.manager.d.ts +137 -0
- package/skill/session/skill-session.manager.d.ts.map +1 -0
- package/skill/session/skill-session.types.d.ts +303 -0
- package/skill/session/skill-session.types.d.ts.map +1 -0
- package/skill/skill-http.utils.d.ts +107 -0
- package/skill/skill-http.utils.d.ts.map +1 -0
- package/skill/skill-mode.utils.d.ts +53 -0
- package/skill/skill-mode.utils.d.ts.map +1 -0
- package/skill/skill-scope.helper.d.ts +55 -0
- package/skill/skill-scope.helper.d.ts.map +1 -0
- package/skill/skill-storage.factory.d.ts +194 -0
- package/skill/skill-storage.factory.d.ts.map +1 -0
- package/skill/skill-storage.interface.d.ts +230 -0
- package/skill/skill-storage.interface.d.ts.map +1 -0
- package/skill/skill-validator.d.ts +63 -0
- package/skill/skill-validator.d.ts.map +1 -0
- package/skill/skill.events.d.ts +88 -0
- package/skill/skill.events.d.ts.map +1 -0
- package/skill/skill.instance.d.ts +92 -0
- package/skill/skill.instance.d.ts.map +1 -0
- package/skill/skill.registry.d.ts +309 -0
- package/skill/skill.registry.d.ts.map +1 -0
- package/skill/skill.utils.d.ts +90 -0
- package/skill/skill.utils.d.ts.map +1 -0
- package/skill/sync/index.d.ts +16 -0
- package/skill/sync/index.d.ts.map +1 -0
- package/skill/sync/memory-sync-state.store.d.ts +49 -0
- package/skill/sync/memory-sync-state.store.d.ts.map +1 -0
- package/skill/sync/skill-hash.d.ts +65 -0
- package/skill/sync/skill-hash.d.ts.map +1 -0
- package/skill/sync/sync-state.interface.d.ts +125 -0
- package/skill/sync/sync-state.interface.d.ts.map +1 -0
- package/skill/tools/index.d.ts +21 -0
- package/skill/tools/index.d.ts.map +1 -0
- package/skill/tools/load-skills.tool.d.ts +76 -0
- package/skill/tools/load-skills.tool.d.ts.map +1 -0
- package/skill/tools/search-skills.tool.d.ts +61 -0
- package/skill/tools/search-skills.tool.d.ts.map +1 -0
- package/tool/flows/call-tool.flow.d.ts +1 -0
- package/tool/flows/call-tool.flow.d.ts.map +1 -1
- package/tool/flows/tools-list.flow.d.ts +15 -0
- package/tool/flows/tools-list.flow.d.ts.map +1 -1
- package/tool/tool.instance.d.ts +8 -0
- package/tool/tool.instance.d.ts.map +1 -1
- package/tool/tool.registry.d.ts +11 -0
- package/tool/tool.registry.d.ts.map +1 -1
- package/tool/tool.utils.d.ts.map +1 -1
- package/tool/ui/template-helpers.d.ts +0 -5
- package/tool/ui/template-helpers.d.ts.map +1 -1
- package/transport/adapters/streamable-http-transport.d.ts.map +1 -1
- package/transport/adapters/transport.local.adapter.d.ts +54 -9
- package/transport/adapters/transport.local.adapter.d.ts.map +1 -1
- package/transport/adapters/transport.sse.adapter.d.ts +11 -2
- package/transport/adapters/transport.sse.adapter.d.ts.map +1 -1
- package/transport/adapters/transport.streamable-http.adapter.d.ts +21 -2
- package/transport/adapters/transport.streamable-http.adapter.d.ts.map +1 -1
- package/transport/event-stores/event-store.factory.d.ts +96 -0
- package/transport/event-stores/event-store.factory.d.ts.map +1 -0
- package/transport/event-stores/index.d.ts +47 -0
- package/transport/event-stores/index.d.ts.map +1 -0
- package/transport/event-stores/memory.event-store.d.ts +51 -0
- package/transport/event-stores/memory.event-store.d.ts.map +1 -0
- package/transport/event-stores/redis.event-store.d.ts +79 -0
- package/transport/event-stores/redis.event-store.d.ts.map +1 -0
- package/transport/flows/handle.sse.flow.d.ts.map +1 -1
- package/transport/flows/handle.streamable-http.flow.d.ts +3 -1
- package/transport/flows/handle.streamable-http.flow.d.ts.map +1 -1
- package/transport/in-memory-server.d.ts +85 -0
- package/transport/in-memory-server.d.ts.map +1 -0
- package/transport/index.d.ts +47 -0
- package/transport/index.d.ts.map +1 -1
- package/transport/mcp-handlers/complete-request.handler.d.ts +3 -84
- package/transport/mcp-handlers/complete-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/get-prompt-request.handler.d.ts +3 -128
- package/transport/mcp-handlers/get-prompt-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/index.d.ts +463 -490
- package/transport/mcp-handlers/index.d.ts.map +1 -1
- package/transport/mcp-handlers/initialize-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/list-prompts-request.handler.d.ts +3 -70
- package/transport/mcp-handlers/list-prompts-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/list-resource-templates-request.handler.d.ts +3 -72
- package/transport/mcp-handlers/list-resource-templates-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/list-resources-request.handler.d.ts +3 -72
- package/transport/mcp-handlers/list-resources-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/list-tools-request.handler.d.ts +3 -85
- package/transport/mcp-handlers/list-tools-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/read-resource-request.handler.d.ts +3 -61
- package/transport/mcp-handlers/read-resource-request.handler.d.ts.map +1 -1
- package/transport/mcp-handlers/skills-list-request.handler.d.ts +9 -0
- package/transport/mcp-handlers/skills-list-request.handler.d.ts.map +1 -0
- package/transport/mcp-handlers/skills-load-request.handler.d.ts +9 -0
- package/transport/mcp-handlers/skills-load-request.handler.d.ts.map +1 -0
- package/transport/mcp-handlers/skills-mcp.types.d.ts +157 -0
- package/transport/mcp-handlers/skills-mcp.types.d.ts.map +1 -0
- package/transport/mcp-handlers/skills-search-request.handler.d.ts +9 -0
- package/transport/mcp-handlers/skills-search-request.handler.d.ts.map +1 -0
- package/transport/transport.registry.d.ts +9 -1
- package/transport/transport.registry.d.ts.map +1 -1
- package/transport/transport.types.d.ts +1 -8
- package/transport/transport.types.d.ts.map +1 -1
- package/auth/jwks/dev-key-persistence.d.ts +0 -64
- package/auth/jwks/dev-key-persistence.d.ts.map +0 -1
- package/auth/jwks/index.d.ts +0 -4
- package/auth/jwks/index.d.ts.map +0 -1
- package/auth/jwks/jwks.service.d.ts +0 -58
- package/auth/jwks/jwks.service.d.ts.map +0 -1
- package/auth/jwks/jwks.types.d.ts +0 -33
- package/auth/jwks/jwks.types.d.ts.map +0 -1
- package/auth/jwks/jwks.utils.d.ts +0 -5
- package/auth/jwks/jwks.utils.d.ts.map +0 -1
- package/auth/oauth/flows/oauth.authorize.flow.d.ts +0 -32
- package/auth/oauth/flows/oauth.authorize.flow.d.ts.map +0 -1
- package/auth/oauth/flows/oauth.device-authorization.flow.d.ts +0 -47
- package/auth/oauth/flows/oauth.device-authorization.flow.d.ts.map +0 -1
- package/auth/oauth/flows/oauth.introspect.flow.d.ts +0 -27
- package/auth/oauth/flows/oauth.introspect.flow.d.ts.map +0 -1
- package/auth/oauth/flows/oauth.par.flow.d.ts +0 -28
- package/auth/oauth/flows/oauth.par.flow.d.ts.map +0 -1
- package/auth/oauth/flows/oauth.revoke.flow.d.ts +0 -26
- package/auth/oauth/flows/oauth.revoke.flow.d.ts.map +0 -1
- package/auth/oauth/flows/oauth.token.flow.d.ts +0 -58
- package/auth/oauth/flows/oauth.token.flow.d.ts.map +0 -1
- package/auth/oauth/flows/oauth.userinfo.flow.d.ts +0 -23
- package/auth/oauth/flows/oauth.userinfo.flow.d.ts.map +0 -1
- package/auth/oauth/flows/oidc.logout.flow.d.ts +0 -19
- package/auth/oauth/flows/oidc.logout.flow.d.ts.map +0 -1
- package/auth/session/authorization-vault.d.ts +0 -612
- package/auth/session/authorization-vault.d.ts.map +0 -1
- package/auth/session/authorization.store.d.ts +0 -302
- package/auth/session/authorization.store.d.ts.map +0 -1
- package/auth/session/record/session.stateful.d.ts +0 -21
- package/auth/session/record/session.stateful.d.ts.map +0 -1
- package/auth/session/record/session.stateless.d.ts +0 -18
- package/auth/session/record/session.stateless.d.ts.map +0 -1
- package/auth/session/record/session.transparent.d.ts +0 -18
- package/auth/session/record/session.transparent.d.ts.map +0 -1
- package/auth/session/session.crypto.d.ts +0 -8
- package/auth/session/session.crypto.d.ts.map +0 -1
- package/auth/session/session.schema.d.ts +0 -6
- package/auth/session/session.schema.d.ts.map +0 -1
- package/auth/session/token.store.d.ts +0 -36
- package/auth/session/token.store.d.ts.map +0 -1
- package/auth/session/token.vault.d.ts +0 -27
- package/auth/session/token.vault.d.ts.map +0 -1
- package/auth/session/vault-encryption.d.ts +0 -190
- package/auth/session/vault-encryption.d.ts.map +0 -1
- package/auth/utils/audience.validator.d.ts +0 -130
- package/auth/utils/audience.validator.d.ts.map +0 -1
- package/auth/utils/www-authenticate.utils.d.ts +0 -98
- package/auth/utils/www-authenticate.utils.d.ts.map +0 -1
- package/common/migrate/auth-transport.migrate.d.ts +0 -63
- package/common/migrate/auth-transport.migrate.d.ts.map +0 -1
- package/common/migrate/index.d.ts +0 -2
- package/common/migrate/index.d.ts.map +0 -1
- package/common/types/options/auth/auth.interfaces.d.ts.map +0 -1
- package/common/types/options/auth/auth.schema.d.ts.map +0 -1
- package/common/types/options/auth/auth.typecheck.d.ts +0 -2
- package/common/types/options/auth/auth.typecheck.d.ts.map +0 -1
- package/common/types/options/auth/auth.utils.d.ts.map +0 -1
- package/common/types/options/auth/transport.deprecated.d.ts +0 -64
- package/common/types/options/auth/transport.deprecated.d.ts.map +0 -1
- package/common/types/options/http.options.d.ts +0 -15
- package/common/types/options/http.options.d.ts.map +0 -1
- package/common/types/options/logging.options.d.ts +0 -29
- package/common/types/options/logging.options.d.ts.map +0 -1
- package/common/types/options/redis.options.d.ts.map +0 -1
- package/common/types/options/server-info.options.d.ts.map +0 -1
- package/common/types/options/session.options.d.ts +0 -148
- package/common/types/options/session.options.d.ts.map +0 -1
- package/common/types/options/transport.options.d.ts +0 -178
- package/common/types/options/transport.options.d.ts.map +0 -1
- package/context/request-context-storage.d.ts +0 -90
- package/context/request-context-storage.d.ts.map +0 -1
- package/context/request-context.d.ts +0 -185
- package/context/request-context.d.ts.map +0 -1
- package/context/request-context.provider.d.ts +0 -38
- package/context/request-context.provider.d.ts.map +0 -1
- package/context/session-key.provider.d.ts +0 -46
- package/context/session-key.provider.d.ts.map +0 -1
- package/store/adapters/store.base.adapter.d.ts +0 -22
- package/store/adapters/store.base.adapter.d.ts.map +0 -1
- package/store/adapters/store.memory.adapter.d.ts +0 -27
- package/store/adapters/store.memory.adapter.d.ts.map +0 -1
- package/store/adapters/store.redis.adapter.d.ts +0 -34
- package/store/adapters/store.redis.adapter.d.ts.map +0 -1
- package/store/adapters/store.vercel-kv.adapter.d.ts +0 -87
- package/store/adapters/store.vercel-kv.adapter.d.ts.map +0 -1
- package/store/index.d.ts +0 -11
- package/store/index.d.ts.map +0 -1
- package/store/store.factory.d.ts.map +0 -1
- package/store/store.helpers.d.ts +0 -10
- package/store/store.helpers.d.ts.map +0 -1
- package/store/store.registry.d.ts +0 -14
- package/store/store.registry.d.ts.map +0 -1
- package/store/store.tokens.d.ts +0 -4
- package/store/store.tokens.d.ts.map +0 -1
- package/store/store.types.d.ts +0 -65
- package/store/store.types.d.ts.map +0 -1
- package/store/store.utils.d.ts +0 -9
- package/store/store.utils.d.ts.map +0 -1
- package/transport/transport.event-store.d.ts +0 -11
- package/transport/transport.event-store.d.ts.map +0 -1
|
@@ -0,0 +1,354 @@
|
|
|
1
|
+
import type { RedisOptionsInput } from '../redis';
|
|
2
|
+
import type { SessionMode, PlatformMappingEntry, PlatformDetectionConfig } from '../session';
|
|
3
|
+
export type { SessionMode, PlatformMappingEntry, PlatformDetectionConfig };
|
|
4
|
+
/**
|
|
5
|
+
* Session mode option - can be a literal or a function for dynamic selection.
|
|
6
|
+
*
|
|
7
|
+
* When a function is provided, it receives the issuer string and can return
|
|
8
|
+
* the mode synchronously or asynchronously.
|
|
9
|
+
*
|
|
10
|
+
* @example Static mode
|
|
11
|
+
* ```typescript
|
|
12
|
+
* sessionMode: 'stateful'
|
|
13
|
+
* ```
|
|
14
|
+
*
|
|
15
|
+
* @example Dynamic mode based on issuer
|
|
16
|
+
* ```typescript
|
|
17
|
+
* sessionMode: (issuer) => issuer.includes('google') ? 'stateless' : 'stateful'
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
export type SessionModeOption = SessionMode | ((issuer: string) => Promise<SessionMode> | SessionMode);
|
|
21
|
+
/**
|
|
22
|
+
* Protocol preset names for simplified configuration.
|
|
23
|
+
*
|
|
24
|
+
* Presets provide sensible defaults for common deployment scenarios:
|
|
25
|
+
*
|
|
26
|
+
* - `'legacy'` (default): Modern + legacy SSE support.
|
|
27
|
+
* Best for backwards compatibility with older clients.
|
|
28
|
+
*
|
|
29
|
+
* - `'modern'`: SSE + streamable HTTP with strict sessions.
|
|
30
|
+
* Best for production deployments with session management.
|
|
31
|
+
*
|
|
32
|
+
* - `'stateless-api'`: No sessions, pure request/response.
|
|
33
|
+
* Best for public APIs and serverless functions.
|
|
34
|
+
*
|
|
35
|
+
* - `'full'`: All protocols enabled, maximum compatibility.
|
|
36
|
+
* Best when supporting diverse client types.
|
|
37
|
+
*/
|
|
38
|
+
export type ProtocolPreset = 'modern' | 'legacy' | 'stateless-api' | 'full';
|
|
39
|
+
/**
|
|
40
|
+
* Granular protocol configuration.
|
|
41
|
+
*
|
|
42
|
+
* Use this instead of presets when you need fine-grained control
|
|
43
|
+
* over which transport protocols are enabled.
|
|
44
|
+
*
|
|
45
|
+
* @example Enable JSON responses for testing
|
|
46
|
+
* ```typescript
|
|
47
|
+
* protocol: {
|
|
48
|
+
* sse: true,
|
|
49
|
+
* streamable: true,
|
|
50
|
+
* json: true, // Enable JSON-only responses
|
|
51
|
+
* strictSession: true,
|
|
52
|
+
* }
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
export interface ProtocolConfig {
|
|
56
|
+
/**
|
|
57
|
+
* Enable SSE listener for server-initiated messages.
|
|
58
|
+
* Handles GET requests with `Accept: text/event-stream` header.
|
|
59
|
+
* @default true
|
|
60
|
+
*/
|
|
61
|
+
sse?: boolean;
|
|
62
|
+
/**
|
|
63
|
+
* Enable streamable HTTP transport (POST with SSE response).
|
|
64
|
+
* This is the recommended transport for production use.
|
|
65
|
+
* @default true
|
|
66
|
+
*/
|
|
67
|
+
streamable?: boolean;
|
|
68
|
+
/**
|
|
69
|
+
* Enable JSON-only responses (stateful HTTP).
|
|
70
|
+
* Useful for development and debugging.
|
|
71
|
+
* @default false
|
|
72
|
+
*/
|
|
73
|
+
json?: boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Enable stateless HTTP mode (requests without session ID).
|
|
76
|
+
* When enabled, allows requests without prior initialize.
|
|
77
|
+
* @default false
|
|
78
|
+
*/
|
|
79
|
+
stateless?: boolean;
|
|
80
|
+
/**
|
|
81
|
+
* Enable legacy SSE transport (old HTTP+SSE protocol).
|
|
82
|
+
* Enable for backwards compatibility with older clients.
|
|
83
|
+
* @default false
|
|
84
|
+
*/
|
|
85
|
+
legacy?: boolean;
|
|
86
|
+
/**
|
|
87
|
+
* Require session ID for streamable HTTP (non-stateless mode).
|
|
88
|
+
* When false, streamable HTTP requests don't require prior initialize.
|
|
89
|
+
* @default true
|
|
90
|
+
*/
|
|
91
|
+
strictSession?: boolean;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Transport persistence configuration.
|
|
95
|
+
*
|
|
96
|
+
* Enables session persistence to Redis/Vercel KV for transport recreation
|
|
97
|
+
* after server restart. This is essential for serverless deployments.
|
|
98
|
+
*
|
|
99
|
+
* **Auto-enable behavior**: When top-level `redis` is configured at the
|
|
100
|
+
* `@FrontMcp` level, transport persistence is automatically enabled.
|
|
101
|
+
* Set `persistence: false` to explicitly disable.
|
|
102
|
+
*
|
|
103
|
+
* @example Use global redis (auto-configured)
|
|
104
|
+
* ```typescript
|
|
105
|
+
* // At @FrontMcp level:
|
|
106
|
+
* redis: { host: 'localhost' },
|
|
107
|
+
* // persistence auto-enabled using global redis
|
|
108
|
+
* ```
|
|
109
|
+
*
|
|
110
|
+
* @example Override with custom config
|
|
111
|
+
* ```typescript
|
|
112
|
+
* transport: {
|
|
113
|
+
* persistence: {
|
|
114
|
+
* redis: { host: 'different-host' },
|
|
115
|
+
* defaultTtlMs: 7200000, // 2 hours
|
|
116
|
+
* },
|
|
117
|
+
* }
|
|
118
|
+
* ```
|
|
119
|
+
*
|
|
120
|
+
* @example Explicitly disable
|
|
121
|
+
* ```typescript
|
|
122
|
+
* transport: {
|
|
123
|
+
* persistence: false,
|
|
124
|
+
* }
|
|
125
|
+
* ```
|
|
126
|
+
*/
|
|
127
|
+
export interface PersistenceConfig {
|
|
128
|
+
/**
|
|
129
|
+
* Redis/Vercel KV configuration for session storage.
|
|
130
|
+
*
|
|
131
|
+
* If omitted, uses the top-level `redis` configuration from `@FrontMcp`.
|
|
132
|
+
*/
|
|
133
|
+
redis?: RedisOptionsInput;
|
|
134
|
+
/**
|
|
135
|
+
* Default TTL for stored session metadata (milliseconds).
|
|
136
|
+
* @default 3600000 (1 hour)
|
|
137
|
+
*/
|
|
138
|
+
defaultTtlMs?: number;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Distributed mode enabled setting.
|
|
142
|
+
*
|
|
143
|
+
* - `true`: Always enable distributed optimizations
|
|
144
|
+
* - `false`: Disable (default for traditional deployments)
|
|
145
|
+
* - `'auto'`: Auto-detect serverless environment
|
|
146
|
+
*
|
|
147
|
+
* Auto-detection checks for environment variables:
|
|
148
|
+
* - `VERCEL`
|
|
149
|
+
* - `NETLIFY`
|
|
150
|
+
* - `CF_PAGES` (Cloudflare Pages)
|
|
151
|
+
* - `AWS_LAMBDA_FUNCTION_NAME`
|
|
152
|
+
* - `AZURE_FUNCTIONS_ENVIRONMENT`
|
|
153
|
+
* - `K_SERVICE` (Google Cloud Run)
|
|
154
|
+
* - `RAILWAY_ENVIRONMENT`
|
|
155
|
+
* - `RENDER`
|
|
156
|
+
* - `FLY_APP_NAME`
|
|
157
|
+
*/
|
|
158
|
+
export type DistributedEnabled = boolean | 'auto';
|
|
159
|
+
/**
|
|
160
|
+
* EventStore configuration for SSE resumability support.
|
|
161
|
+
*
|
|
162
|
+
* When enabled, clients can reconnect and resume missed SSE messages
|
|
163
|
+
* using the Last-Event-ID header per the MCP protocol.
|
|
164
|
+
*
|
|
165
|
+
* Note: By default, EventStore is disabled because Claude.ai's client
|
|
166
|
+
* doesn't handle the priming events correctly. Only enable if your
|
|
167
|
+
* clients support SSE resumability.
|
|
168
|
+
*
|
|
169
|
+
* @example Memory (single-node)
|
|
170
|
+
* ```typescript
|
|
171
|
+
* eventStore: {
|
|
172
|
+
* enabled: true,
|
|
173
|
+
* provider: 'memory',
|
|
174
|
+
* maxEvents: 10000,
|
|
175
|
+
* ttlMs: 300000,
|
|
176
|
+
* }
|
|
177
|
+
* ```
|
|
178
|
+
*
|
|
179
|
+
* @example Redis (distributed)
|
|
180
|
+
* ```typescript
|
|
181
|
+
* eventStore: {
|
|
182
|
+
* enabled: true,
|
|
183
|
+
* provider: 'redis',
|
|
184
|
+
* redis: { host: 'localhost', port: 6379 },
|
|
185
|
+
* }
|
|
186
|
+
* ```
|
|
187
|
+
*/
|
|
188
|
+
export interface EventStoreConfig {
|
|
189
|
+
/**
|
|
190
|
+
* Whether EventStore is enabled.
|
|
191
|
+
* When true, clients can reconnect and resume missed SSE messages.
|
|
192
|
+
* @default false
|
|
193
|
+
*/
|
|
194
|
+
enabled: boolean;
|
|
195
|
+
/**
|
|
196
|
+
* Storage provider type.
|
|
197
|
+
* - 'memory': In-memory storage (single-node only)
|
|
198
|
+
* - 'redis': Redis-backed storage (distributed)
|
|
199
|
+
* @default 'memory'
|
|
200
|
+
*/
|
|
201
|
+
provider?: 'memory' | 'redis';
|
|
202
|
+
/**
|
|
203
|
+
* Maximum number of events to store before eviction.
|
|
204
|
+
* @default 10000
|
|
205
|
+
*/
|
|
206
|
+
maxEvents?: number;
|
|
207
|
+
/**
|
|
208
|
+
* TTL in milliseconds for stored events.
|
|
209
|
+
* @default 300000 (5 minutes)
|
|
210
|
+
*/
|
|
211
|
+
ttlMs?: number;
|
|
212
|
+
/**
|
|
213
|
+
* Redis configuration (required if provider is 'redis').
|
|
214
|
+
*/
|
|
215
|
+
redis?: RedisOptionsInput;
|
|
216
|
+
}
|
|
217
|
+
/**
|
|
218
|
+
* Transport and session lifecycle configuration for FrontMCP.
|
|
219
|
+
*
|
|
220
|
+
* This interface provides the canonical configuration surface for all
|
|
221
|
+
* transport-related settings, consolidating protocol config, session
|
|
222
|
+
* lifecycle, persistence, and distributed mode.
|
|
223
|
+
*
|
|
224
|
+
* @example Basic configuration (uses defaults)
|
|
225
|
+
* ```typescript
|
|
226
|
+
* transport: {} // Uses 'modern' preset
|
|
227
|
+
* ```
|
|
228
|
+
*
|
|
229
|
+
* @example Legacy setup (backwards compatible)
|
|
230
|
+
* ```typescript
|
|
231
|
+
* transport: {
|
|
232
|
+
* protocol: 'legacy',
|
|
233
|
+
* }
|
|
234
|
+
* ```
|
|
235
|
+
*
|
|
236
|
+
* @example Production with persistence
|
|
237
|
+
* ```typescript
|
|
238
|
+
* redis: { host: 'redis.example.com' },
|
|
239
|
+
* transport: {
|
|
240
|
+
* protocol: 'modern',
|
|
241
|
+
* // persistence auto-enabled
|
|
242
|
+
* }
|
|
243
|
+
* ```
|
|
244
|
+
*
|
|
245
|
+
* @example Serverless deployment
|
|
246
|
+
* ```typescript
|
|
247
|
+
* redis: { provider: 'vercel-kv' },
|
|
248
|
+
* transport: {
|
|
249
|
+
* protocol: 'stateless-api',
|
|
250
|
+
* distributedMode: 'auto',
|
|
251
|
+
* }
|
|
252
|
+
* ```
|
|
253
|
+
*
|
|
254
|
+
* @example Custom protocol configuration
|
|
255
|
+
* ```typescript
|
|
256
|
+
* transport: {
|
|
257
|
+
* protocol: {
|
|
258
|
+
* sse: true,
|
|
259
|
+
* streamable: true,
|
|
260
|
+
* json: true,
|
|
261
|
+
* stateless: false,
|
|
262
|
+
* legacy: false,
|
|
263
|
+
* strictSession: true,
|
|
264
|
+
* },
|
|
265
|
+
* }
|
|
266
|
+
* ```
|
|
267
|
+
*/
|
|
268
|
+
export interface TransportOptionsInterface {
|
|
269
|
+
/**
|
|
270
|
+
* Defines how the session lifecycle and nested tokens are managed.
|
|
271
|
+
*
|
|
272
|
+
* Modes:
|
|
273
|
+
* - `'stateful'`: Session and nested tokens are stored server-side (e.g., Redis).
|
|
274
|
+
* Results in smaller JWTs and supports token refresh.
|
|
275
|
+
* - `'stateless'`: All session data is embedded in the JWT.
|
|
276
|
+
* Simpler but doesn't support token refresh.
|
|
277
|
+
*
|
|
278
|
+
* Can be a function for dynamic selection based on issuer.
|
|
279
|
+
*
|
|
280
|
+
* @default 'stateful'
|
|
281
|
+
*/
|
|
282
|
+
sessionMode?: SessionModeOption;
|
|
283
|
+
/**
|
|
284
|
+
* Configuration for detecting the AI platform from MCP client info.
|
|
285
|
+
*/
|
|
286
|
+
platformDetection?: PlatformDetectionConfig;
|
|
287
|
+
/**
|
|
288
|
+
* Protocol configuration - use a preset or customize individual settings.
|
|
289
|
+
*
|
|
290
|
+
* **Presets:**
|
|
291
|
+
* - `'legacy'` (default): Modern + legacy SSE support
|
|
292
|
+
* - `'modern'`: SSE + streamable HTTP, strict sessions
|
|
293
|
+
* - `'stateless-api'`: No sessions, pure request/response
|
|
294
|
+
* - `'full'`: All protocols enabled
|
|
295
|
+
*
|
|
296
|
+
* @default 'legacy'
|
|
297
|
+
*/
|
|
298
|
+
protocol?: ProtocolPreset | ProtocolConfig;
|
|
299
|
+
/**
|
|
300
|
+
* Transport persistence configuration.
|
|
301
|
+
*
|
|
302
|
+
* When enabled, sessions are persisted to Redis/Vercel KV and transports
|
|
303
|
+
* can be recreated after server restart.
|
|
304
|
+
*
|
|
305
|
+
* **Auto-enable behavior**: Automatically enabled when top-level `redis`
|
|
306
|
+
* is configured, unless explicitly disabled.
|
|
307
|
+
*
|
|
308
|
+
* - `false`: Explicitly disable persistence
|
|
309
|
+
* - `object`: Enable with custom config (redis override, TTL)
|
|
310
|
+
* - `undefined`: Auto-enable when global redis exists
|
|
311
|
+
*/
|
|
312
|
+
persistence?: false | PersistenceConfig;
|
|
313
|
+
/**
|
|
314
|
+
* Enable distributed mode for serverless/multi-instance deployments.
|
|
315
|
+
*
|
|
316
|
+
* When enabled, the SDK optimizes for environments where requests may
|
|
317
|
+
* land on different server instances.
|
|
318
|
+
*
|
|
319
|
+
* - `true`: Always enable distributed optimizations
|
|
320
|
+
* - `false`: Disable (default)
|
|
321
|
+
* - `'auto'`: Auto-detect serverless environment
|
|
322
|
+
*
|
|
323
|
+
* @default false
|
|
324
|
+
*/
|
|
325
|
+
distributedMode?: DistributedEnabled;
|
|
326
|
+
/**
|
|
327
|
+
* Enable provider session caching.
|
|
328
|
+
*
|
|
329
|
+
* When false, CONTEXT-scoped providers are rebuilt on each request.
|
|
330
|
+
* Automatically disabled when `distributedMode` is enabled.
|
|
331
|
+
*
|
|
332
|
+
* @default true (false when distributedMode is enabled)
|
|
333
|
+
*/
|
|
334
|
+
providerCaching?: boolean;
|
|
335
|
+
/**
|
|
336
|
+
* EventStore configuration for SSE resumability support.
|
|
337
|
+
*
|
|
338
|
+
* When enabled, clients can reconnect and resume missed SSE messages
|
|
339
|
+
* using the Last-Event-ID header per the MCP protocol.
|
|
340
|
+
*
|
|
341
|
+
* Note: By default, EventStore is disabled because Claude.ai's client
|
|
342
|
+
* doesn't handle the priming events correctly. Only enable if your
|
|
343
|
+
* clients support SSE resumability.
|
|
344
|
+
*
|
|
345
|
+
* @default undefined (disabled)
|
|
346
|
+
*/
|
|
347
|
+
eventStore?: EventStoreConfig;
|
|
348
|
+
}
|
|
349
|
+
/**
|
|
350
|
+
* Transport options input type - uses this explicit interface for IDE autocomplete.
|
|
351
|
+
* This is the type users should use when configuring transport options.
|
|
352
|
+
*/
|
|
353
|
+
export type TransportOptionsInput = TransportOptionsInterface;
|
|
354
|
+
//# sourceMappingURL=interfaces.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../../../src/common/types/options/transport/interfaces.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAGlD,OAAO,KAAK,EAAE,WAAW,EAAE,oBAAoB,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAG7F,YAAY,EAAE,WAAW,EAAE,oBAAoB,EAAE,uBAAuB,EAAE,CAAC;AAM3E;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,iBAAiB,GAAG,WAAW,GAAG,CAAC,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,WAAW,CAAC,GAAG,WAAW,CAAC,CAAC;AAMvG;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,QAAQ,GAAG,eAAe,GAAG,MAAM,CAAC;AAE5E;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,cAAc;IAC7B;;;;OAIG;IACH,GAAG,CAAC,EAAE,OAAO,CAAC;IAEd;;;;OAIG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB;;;;OAIG;IACH,IAAI,CAAC,EAAE,OAAO,CAAC;IAEf;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IAEjB;;;;OAIG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAMD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;;OAIG;IACH,KAAK,CAAC,EAAE,iBAAiB,CAAC;IAE1B;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAMD;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,MAAM,kBAAkB,GAAG,OAAO,GAAG,MAAM,CAAC;AAMlD;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;;OAIG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IAE9B;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,KAAK,CAAC,EAAE,iBAAiB,CAAC;CAC3B;AAMD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;AACH,MAAM,WAAW,yBAAyB;IAKxC;;;;;;;;;;;;OAYG;IACH,WAAW,CAAC,EAAE,iBAAiB,CAAC;IAEhC;;OAEG;IACH,iBAAiB,CAAC,EAAE,uBAAuB,CAAC;IAM5C;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,EAAE,cAAc,GAAG,cAAc,CAAC;IAM3C;;;;;;;;;;;;OAYG;IACH,WAAW,CAAC,EAAE,KAAK,GAAG,iBAAiB,CAAC;IAMxC;;;;;;;;;;;OAWG;IACH,eAAe,CAAC,EAAE,kBAAkB,CAAC;IAErC;;;;;;;OAOG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAM1B;;;;;;;;;;;OAWG;IACH,UAAU,CAAC,EAAE,gBAAgB,CAAC;CAC/B;AAMD;;;GAGG;AACH,MAAM,MAAM,qBAAqB,GAAG,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,309 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import type { TransportOptionsInterface, PersistenceConfig, ProtocolConfig, ProtocolPreset, SessionModeOption, DistributedEnabled, EventStoreConfig } from './interfaces';
|
|
3
|
+
export type { TransportOptionsInterface, PersistenceConfig, ProtocolConfig, ProtocolPreset, SessionModeOption, DistributedEnabled, EventStoreConfig, };
|
|
4
|
+
/**
|
|
5
|
+
* Protocol preset definitions.
|
|
6
|
+
*
|
|
7
|
+
* Maps preset names to their expanded protocol configurations.
|
|
8
|
+
*/
|
|
9
|
+
export declare const PROTOCOL_PRESETS: Record<ProtocolPreset, Required<ProtocolConfig>>;
|
|
10
|
+
/**
|
|
11
|
+
* Expand a protocol preset or config to a full ProtocolConfig with all fields.
|
|
12
|
+
*
|
|
13
|
+
* @param protocol - Protocol preset name or custom config
|
|
14
|
+
* @returns Fully expanded protocol configuration
|
|
15
|
+
*
|
|
16
|
+
* @example Preset expansion
|
|
17
|
+
* ```typescript
|
|
18
|
+
* expandProtocolConfig('modern')
|
|
19
|
+
* // { sse: true, streamable: true, json: false, stateless: false, legacy: false, strictSession: true }
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
* @example Custom config with defaults
|
|
23
|
+
* ```typescript
|
|
24
|
+
* expandProtocolConfig({ json: true })
|
|
25
|
+
* // { sse: true, streamable: true, json: true, stateless: false, legacy: false, strictSession: true }
|
|
26
|
+
* ```
|
|
27
|
+
*/
|
|
28
|
+
export declare function expandProtocolConfig(protocol: ProtocolPreset | ProtocolConfig | undefined): Required<ProtocolConfig>;
|
|
29
|
+
import { platformDetectionConfigSchema } from '../session';
|
|
30
|
+
/**
|
|
31
|
+
* Simplified persistence config - no explicit 'enabled' flag.
|
|
32
|
+
* - `false`: Explicitly disable persistence
|
|
33
|
+
* - `object`: Enable with custom config
|
|
34
|
+
* - `undefined`: Auto-enable when global redis exists
|
|
35
|
+
*/
|
|
36
|
+
export declare const persistenceConfigSchema: z.ZodObject<{
|
|
37
|
+
redis: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
38
|
+
provider: z.ZodLiteral<"redis">;
|
|
39
|
+
host: z.ZodString;
|
|
40
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
41
|
+
password: z.ZodOptional<z.ZodString>;
|
|
42
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
43
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
44
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
45
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
46
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
47
|
+
provider: z.ZodLiteral<"vercel-kv">;
|
|
48
|
+
url: z.ZodOptional<z.ZodString>;
|
|
49
|
+
token: z.ZodOptional<z.ZodString>;
|
|
50
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
51
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
52
|
+
}, z.core.$strip>, z.ZodPipe<z.ZodObject<{
|
|
53
|
+
host: z.ZodString;
|
|
54
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
55
|
+
password: z.ZodOptional<z.ZodString>;
|
|
56
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
57
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
58
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
59
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
60
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
61
|
+
provider: "redis";
|
|
62
|
+
host: string;
|
|
63
|
+
port: number;
|
|
64
|
+
db: number;
|
|
65
|
+
tls: boolean;
|
|
66
|
+
keyPrefix: string;
|
|
67
|
+
defaultTtlMs: number;
|
|
68
|
+
password?: string | undefined;
|
|
69
|
+
}, {
|
|
70
|
+
host: string;
|
|
71
|
+
port: number;
|
|
72
|
+
db: number;
|
|
73
|
+
tls: boolean;
|
|
74
|
+
keyPrefix: string;
|
|
75
|
+
defaultTtlMs: number;
|
|
76
|
+
password?: string | undefined;
|
|
77
|
+
}>>]>>;
|
|
78
|
+
defaultTtlMs: z.ZodDefault<z.ZodNumber>;
|
|
79
|
+
}, z.core.$strip>;
|
|
80
|
+
/**
|
|
81
|
+
* EventStore configuration schema for SSE resumability support.
|
|
82
|
+
*
|
|
83
|
+
* When enabled, clients can reconnect and resume missed SSE messages.
|
|
84
|
+
* By default, EventStore is disabled because Claude.ai's client
|
|
85
|
+
* doesn't handle priming events correctly.
|
|
86
|
+
*/
|
|
87
|
+
export declare const eventStoreConfigSchema: z.ZodObject<{
|
|
88
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
89
|
+
provider: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
90
|
+
memory: "memory";
|
|
91
|
+
redis: "redis";
|
|
92
|
+
}>>>;
|
|
93
|
+
maxEvents: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
94
|
+
ttlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
95
|
+
redis: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
96
|
+
provider: z.ZodLiteral<"redis">;
|
|
97
|
+
host: z.ZodString;
|
|
98
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
99
|
+
password: z.ZodOptional<z.ZodString>;
|
|
100
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
101
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
102
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
103
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
104
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
105
|
+
provider: z.ZodLiteral<"vercel-kv">;
|
|
106
|
+
url: z.ZodOptional<z.ZodString>;
|
|
107
|
+
token: z.ZodOptional<z.ZodString>;
|
|
108
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
109
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
110
|
+
}, z.core.$strip>, z.ZodPipe<z.ZodObject<{
|
|
111
|
+
host: z.ZodString;
|
|
112
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
113
|
+
password: z.ZodOptional<z.ZodString>;
|
|
114
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
115
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
116
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
117
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
118
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
119
|
+
provider: "redis";
|
|
120
|
+
host: string;
|
|
121
|
+
port: number;
|
|
122
|
+
db: number;
|
|
123
|
+
tls: boolean;
|
|
124
|
+
keyPrefix: string;
|
|
125
|
+
defaultTtlMs: number;
|
|
126
|
+
password?: string | undefined;
|
|
127
|
+
}, {
|
|
128
|
+
host: string;
|
|
129
|
+
port: number;
|
|
130
|
+
db: number;
|
|
131
|
+
tls: boolean;
|
|
132
|
+
keyPrefix: string;
|
|
133
|
+
defaultTtlMs: number;
|
|
134
|
+
password?: string | undefined;
|
|
135
|
+
}>>]>>;
|
|
136
|
+
}, z.core.$strip>;
|
|
137
|
+
/**
|
|
138
|
+
* Transport options schema - the canonical Zod schema for transport configuration.
|
|
139
|
+
*
|
|
140
|
+
* Uses the TransportOptionsInterface for type sync validation.
|
|
141
|
+
*/
|
|
142
|
+
export declare const transportOptionsSchema: z.ZodObject<{
|
|
143
|
+
sessionMode: z.ZodDefault<z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<"stateful">, z.ZodLiteral<"stateless">, z.ZodFunction<z.core.$ZodFunctionArgs, z.core.$ZodFunctionOut>]>>>;
|
|
144
|
+
platformDetection: z.ZodOptional<z.ZodObject<{
|
|
145
|
+
mappings: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
146
|
+
pattern: z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>]>;
|
|
147
|
+
platform: z.ZodEnum<{
|
|
148
|
+
unknown: "unknown";
|
|
149
|
+
continue: "continue";
|
|
150
|
+
openai: "openai";
|
|
151
|
+
claude: "claude";
|
|
152
|
+
gemini: "gemini";
|
|
153
|
+
cursor: "cursor";
|
|
154
|
+
cody: "cody";
|
|
155
|
+
"generic-mcp": "generic-mcp";
|
|
156
|
+
"ext-apps": "ext-apps";
|
|
157
|
+
}>;
|
|
158
|
+
}, z.core.$strip>>>;
|
|
159
|
+
customOnly: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
160
|
+
}, z.core.$strip>>;
|
|
161
|
+
protocol: z.ZodDefault<z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
|
|
162
|
+
modern: "modern";
|
|
163
|
+
legacy: "legacy";
|
|
164
|
+
"stateless-api": "stateless-api";
|
|
165
|
+
full: "full";
|
|
166
|
+
}>, z.ZodObject<{
|
|
167
|
+
sse: z.ZodOptional<z.ZodBoolean>;
|
|
168
|
+
streamable: z.ZodOptional<z.ZodBoolean>;
|
|
169
|
+
json: z.ZodOptional<z.ZodBoolean>;
|
|
170
|
+
stateless: z.ZodOptional<z.ZodBoolean>;
|
|
171
|
+
legacy: z.ZodOptional<z.ZodBoolean>;
|
|
172
|
+
strictSession: z.ZodOptional<z.ZodBoolean>;
|
|
173
|
+
}, z.core.$strip>]>>>;
|
|
174
|
+
persistence: z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<false>, z.ZodObject<{
|
|
175
|
+
redis: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
176
|
+
provider: z.ZodLiteral<"redis">;
|
|
177
|
+
host: z.ZodString;
|
|
178
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
179
|
+
password: z.ZodOptional<z.ZodString>;
|
|
180
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
181
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
182
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
183
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
184
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
185
|
+
provider: z.ZodLiteral<"vercel-kv">;
|
|
186
|
+
url: z.ZodOptional<z.ZodString>;
|
|
187
|
+
token: z.ZodOptional<z.ZodString>;
|
|
188
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
189
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
190
|
+
}, z.core.$strip>, z.ZodPipe<z.ZodObject<{
|
|
191
|
+
host: z.ZodString;
|
|
192
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
193
|
+
password: z.ZodOptional<z.ZodString>;
|
|
194
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
195
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
196
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
197
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
198
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
199
|
+
provider: "redis";
|
|
200
|
+
host: string;
|
|
201
|
+
port: number;
|
|
202
|
+
db: number;
|
|
203
|
+
tls: boolean;
|
|
204
|
+
keyPrefix: string;
|
|
205
|
+
defaultTtlMs: number;
|
|
206
|
+
password?: string | undefined;
|
|
207
|
+
}, {
|
|
208
|
+
host: string;
|
|
209
|
+
port: number;
|
|
210
|
+
db: number;
|
|
211
|
+
tls: boolean;
|
|
212
|
+
keyPrefix: string;
|
|
213
|
+
defaultTtlMs: number;
|
|
214
|
+
password?: string | undefined;
|
|
215
|
+
}>>]>>;
|
|
216
|
+
defaultTtlMs: z.ZodDefault<z.ZodNumber>;
|
|
217
|
+
}, z.core.$strip>]>>;
|
|
218
|
+
distributedMode: z.ZodDefault<z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodLiteral<"auto">]>>>;
|
|
219
|
+
providerCaching: z.ZodOptional<z.ZodBoolean>;
|
|
220
|
+
eventStore: z.ZodOptional<z.ZodObject<{
|
|
221
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
222
|
+
provider: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
223
|
+
memory: "memory";
|
|
224
|
+
redis: "redis";
|
|
225
|
+
}>>>;
|
|
226
|
+
maxEvents: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
227
|
+
ttlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
228
|
+
redis: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
229
|
+
provider: z.ZodLiteral<"redis">;
|
|
230
|
+
host: z.ZodString;
|
|
231
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
232
|
+
password: z.ZodOptional<z.ZodString>;
|
|
233
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
234
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
235
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
236
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
237
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
238
|
+
provider: z.ZodLiteral<"vercel-kv">;
|
|
239
|
+
url: z.ZodOptional<z.ZodString>;
|
|
240
|
+
token: z.ZodOptional<z.ZodString>;
|
|
241
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
242
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
243
|
+
}, z.core.$strip>, z.ZodPipe<z.ZodObject<{
|
|
244
|
+
host: z.ZodString;
|
|
245
|
+
port: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
246
|
+
password: z.ZodOptional<z.ZodString>;
|
|
247
|
+
db: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
248
|
+
tls: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
249
|
+
keyPrefix: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
250
|
+
defaultTtlMs: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
251
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
252
|
+
provider: "redis";
|
|
253
|
+
host: string;
|
|
254
|
+
port: number;
|
|
255
|
+
db: number;
|
|
256
|
+
tls: boolean;
|
|
257
|
+
keyPrefix: string;
|
|
258
|
+
defaultTtlMs: number;
|
|
259
|
+
password?: string | undefined;
|
|
260
|
+
}, {
|
|
261
|
+
host: string;
|
|
262
|
+
port: number;
|
|
263
|
+
db: number;
|
|
264
|
+
tls: boolean;
|
|
265
|
+
keyPrefix: string;
|
|
266
|
+
defaultTtlMs: number;
|
|
267
|
+
password?: string | undefined;
|
|
268
|
+
}>>]>>;
|
|
269
|
+
}, z.core.$strip>>;
|
|
270
|
+
}, z.core.$strip>;
|
|
271
|
+
/**
|
|
272
|
+
* Transport options type (with defaults applied).
|
|
273
|
+
* This is the output type after Zod parsing.
|
|
274
|
+
*/
|
|
275
|
+
export type TransportOptions = z.infer<typeof transportOptionsSchema>;
|
|
276
|
+
/**
|
|
277
|
+
* Transport options input type (for user configuration).
|
|
278
|
+
* Uses the explicit interface for better IDE autocomplete.
|
|
279
|
+
*/
|
|
280
|
+
export type TransportOptionsInput = TransportOptionsInterface;
|
|
281
|
+
/**
|
|
282
|
+
* Persistence configuration type (with defaults applied)
|
|
283
|
+
*/
|
|
284
|
+
export type TransportPersistenceConfig = z.infer<typeof persistenceConfigSchema>;
|
|
285
|
+
/**
|
|
286
|
+
* Persistence configuration input type
|
|
287
|
+
*/
|
|
288
|
+
export type TransportPersistenceConfigInput = z.input<typeof persistenceConfigSchema>;
|
|
289
|
+
/**
|
|
290
|
+
* Platform detection configuration type
|
|
291
|
+
*/
|
|
292
|
+
export type PlatformDetectionConfigType = z.infer<typeof platformDetectionConfigSchema>;
|
|
293
|
+
/**
|
|
294
|
+
* Distributed mode configuration input type (for user configuration)
|
|
295
|
+
*/
|
|
296
|
+
export type DistributedConfigInput = {
|
|
297
|
+
enabled?: DistributedEnabled;
|
|
298
|
+
providerCaching?: boolean;
|
|
299
|
+
};
|
|
300
|
+
/**
|
|
301
|
+
* Check if distributed mode is enabled based on configuration.
|
|
302
|
+
* Handles 'auto' detection for serverless environments.
|
|
303
|
+
*/
|
|
304
|
+
export declare function isDistributedMode(distributedMode?: DistributedEnabled): boolean;
|
|
305
|
+
/**
|
|
306
|
+
* Get effective provider caching setting based on distributed config.
|
|
307
|
+
*/
|
|
308
|
+
export declare function shouldCacheProviders(distributedMode?: DistributedEnabled, providerCaching?: boolean): boolean;
|
|
309
|
+
//# sourceMappingURL=schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../../src/common/types/options/transport/schema.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,OAAO,KAAK,EACV,yBAAyB,EACzB,iBAAiB,EACjB,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,kBAAkB,EAClB,gBAAgB,EACjB,MAAM,cAAc,CAAC;AAMtB,YAAY,EACV,yBAAyB,EACzB,iBAAiB,EACjB,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,kBAAkB,EAClB,gBAAgB,GACjB,CAAC;AAMF;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,cAAc,EAAE,QAAQ,CAAC,cAAc,CAAC,CAoD7E,CAAC;AAEF;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,cAAc,GAAG,cAAc,GAAG,SAAS,GAAG,QAAQ,CAAC,cAAc,CAAC,CAoBpH;AA0CD,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAuB3D;;;;;GAKG;AACH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAGlC,CAAC;AAMH;;;;;;GAMG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAMjC,CAAC;AAMH;;;;GAIG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAwCgB,CAAC;AAMpD;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAEtE;;;GAGG;AACH,MAAM,MAAM,qBAAqB,GAAG,yBAAyB,CAAC;AAE9D;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAEjF;;GAEG;AACH,MAAM,MAAM,+BAA+B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAEtF;;GAEG;AACH,MAAM,MAAM,2BAA2B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAMxF;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC,OAAO,CAAC,EAAE,kBAAkB,CAAC;IAC7B,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B,CAAC;AAEF;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,eAAe,CAAC,EAAE,kBAAkB,GAAG,OAAO,CAsB/E;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,eAAe,CAAC,EAAE,kBAAkB,EAAE,eAAe,CAAC,EAAE,OAAO,GAAG,OAAO,CAQ7G"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"typecheck.d.ts","sourceRoot":"","sources":["../../../../../src/common/types/options/transport/typecheck.ts"],"names":[],"mappings":"AA6IA,OAAO,EAAE,CAAC"}
|