class documentation

Temporal-aware MCP toolset implementation.

Warning

This class is experimental and may change in future versions. Use with caution in production environments.

Executes MCP tools as Temporal activities, providing proper isolation and execution guarantees within workflows.

Method __init__ Initializes the Temporal MCP toolset.
Async Method get_tools Retrieves available tools from the MCP toolset.
Instance Variable _config Undocumented
Instance Variable _factory_argument Undocumented
Instance Variable _name Undocumented
Instance Variable _not_in_workflow_toolset Undocumented
def __init__(self, name: str, config: ActivityConfig | None = None, factory_argument: Any | None = None, not_in_workflow_toolset: Callable[[(Any | None)], McpToolset] | None = None): (source)

Initializes the Temporal MCP toolset.

Parameters
name:strName of the toolset (used for activity naming).
config:ActivityConfig | NoneOptional activity configuration.
factory_argument:Any | NoneOptional argument passed to toolset factory.
not_in_workflow_toolset:Callable[[(Any | None)], McpToolset] | NoneOptional factory that returns the underlying McpToolset to use when this wrapper executes outside workflow.in_workflow(), such as local ADK runs. This is not needed during normal workflow execution, but get_tools() raises ValueError outside a workflow if it is omitted.
async def get_tools(self, readonly_context: ReadonlyContext | None = None) -> list[BaseTool]: (source)

Retrieves available tools from the MCP toolset.

Parameters
readonly_context:ReadonlyContext | NoneOptional readonly context (unused in this implementation).
Returns
list[BaseTool]List of available tools wrapped as Temporal activities.

Undocumented

_factory_argument = (source)

Undocumented

Undocumented

_not_in_workflow_toolset = (source)

Undocumented