Skip to main content

Interface: AiSdkPluginOptions

aisdk.AiSdkPluginOptions

Options for the AI SDK plugin

The AI SDK plugin is an experimental feature; APIs may change without notice.

Properties

mcpClientFactories

Optional mcpClientFactories: McpClientFactories

This object contains a mapping of server names to functions which create MCP clients. Any TemporalMCPClient used in a workflow should have its associated servername listed in this object.


mcpConnectionIdleTimeout

Optional mcpConnectionIdleTimeout: Duration

How long an idle worker-process MCP connection is kept open (and reused across listTools/callTool activity invocations) before it's closed. Accepts a millisecond number or duration string (e.g. '5 minutes'), like startToCloseTimeout. Defaults to 5 minutes.

Pass 0 to disable connection reuse and restore the original create-then-close-per-call behavior, for MCP servers/transports that don't tolerate a reused or concurrent session.


modelProvider

modelProvider: ProviderV4