disconnect
Terminate the connection to Interactive Brokers TWS or IB Gateway, ending all active data streams and trading sessions.
Instructions
Disconnect from TWS/Gateway.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/ib_async_mcp/server.py:462-466 (handler)The handler logic for the 'disconnect' tool, which sets the 'ib' client to None and calls its disconnect method.
if name == "disconnect": if ib is not None: ib.disconnect() ib = None return {"status": "disconnected"} - src/ib_async_mcp/server.py:80-84 (registration)Registration of the 'disconnect' tool with name, description, and empty input schema.
Tool( name="disconnect", description="Disconnect from TWS/Gateway.", inputSchema={"type": "object", "properties": {}}, ),