client
client
¶
MCP Client — connects to MCP servers and discovers/calls tools.
Classes¶
MCPClient
¶
MCPClient(transport: MCPTransport)
Client that communicates with an MCP server via a transport.
| PARAMETER | DESCRIPTION |
|---|---|
transport
|
The transport layer to use for communication.
TYPE:
|
Source code in src/openjarvis/mcp/client.py
Functions¶
initialize
¶
Perform the MCP initialize handshake.
Returns the server capabilities.
Source code in src/openjarvis/mcp/client.py
list_tools
¶
list_tools() -> List[ToolSpec]
Discover available tools from the server.
Returns a list of ToolSpec objects.
Source code in src/openjarvis/mcp/client.py
call_tool
¶
Call a tool on the server.
Returns the result dictionary with content and isError fields.