Skip to content

basalt / ai-mcp/src / SessionOptions

Interface: SessionOptions ​

Defined in: ai-mcp/src/session.ts:6

Properties ​

allowProduction? ​

> optional allowProduction?: boolean

Defined in: ai-mcp/src/session.ts:33

Start even when NODE_ENV is production. Default false: the bridge is dev-only and refuses to start there (AiMcpProductionError). The bin's --allow-production flag (or BASALT_AI_MCP_ALLOW_PRODUCTION=1) sets it.


allowUnconfirmedApply? ​

> optional allowUnconfirmedApply?: boolean

Defined in: ai-mcp/src/session.ts:27

Let basalt_make apply WITHOUT a confirmation when the client cannot be asked (no elicitation support — e.g. over HTTP, or a stdio client that did not announce the capability). Default false: such an apply is refused (fail closed). The bin's --allow-unconfirmed-apply flag sets it.


createProvider? ​

> optional createProvider?: () => AIProvider

Defined in: ai-mcp/src/session.ts:20

How to build the AI provider. Defaults to reading the session env. Injected in tests with a mock provider — no network, no keys.

Returns ​

AIProvider


createReader? ​

> optional createReader?: (root) => ProjectReader

Defined in: ai-mcp/src/session.ts:15

How to build a project reader for a root. Defaults to the filesystem (nodeReader). Injected in tests with an in-memory reader — no disk needed.

Parameters ​

root ​

string

Returns ​

ProjectReader


cwd? ​

> optional cwd?: string

Defined in: ai-mcp/src/session.ts:8

Workspace root the tools/resources default to. Defaults to process.cwd().


env? ​

> optional env?: Record<string, string | undefined>

Defined in: ai-mcp/src/session.ts:10

Environment the provider config is read from. Defaults to process.env.

Released under the MIT License.