Skip to content

symfonic.tools.mcp.models

models

MCP data models for tool discovery and execution.

MCPToolDefinition dataclass

MCPToolDefinition(name: str, description: str, input_schema: dict[str, Any] = dict(), server_url: str = '')

A tool discovered from an MCP server.

Attributes:

Name Type Description
name str

Unique tool identifier as reported by the server.

description str

Human-readable description of what the tool does.

input_schema dict[str, Any]

JSON Schema object describing accepted arguments.

server_url str

URL of the MCP server that owns this tool.

MCPToolResult dataclass

MCPToolResult(tool_name: str, content: str, is_error: bool = False, metadata: dict[str, Any] = dict())

Result from executing an MCP tool.

Attributes:

Name Type Description
tool_name str

Name of the tool that was called.

content str

Text content returned by the tool.

is_error bool

True when the server reported an error response.

metadata dict[str, Any]

Optional extra data from the server response.