diff --git a/packages/toolbox-adk/README.md b/packages/toolbox-adk/README.md index 5f08162a..bc9b3ea7 100644 --- a/packages/toolbox-adk/README.md +++ b/packages/toolbox-adk/README.md @@ -67,19 +67,15 @@ You can explicitly select a protocol using the `protocol` option during toolset | Constant | Description | | :--- | :--- | | `Protocol.MCP` | **(Default)** Alias for the default MCP version (currently `2025-06-18`). | -| `Protocol.TOOLBOX` | **DEPRECATED**: The native Toolbox HTTP protocol. Will be removed on March 4, 2026. | | `Protocol.MCP_v20251125` | MCP Protocol version 2025-11-25. | | `Protocol.MCP_v20250618` | MCP Protocol version 2025-06-18. | | `Protocol.MCP_v20250326` | MCP Protocol version 2025-03-26. | | `Protocol.MCP_v20241105` | MCP Protocol version 2024-11-05. | > [!WARNING] -> The **Native Toolbox Protocol** (`Protocol.TOOLBOX`) is deprecated and will be removed on **March 4, 2026**. -> Please migrate to using the **MCP Protocol** (`Protocol.MCP`), which is the default. ### Example -If you wish to use the native Toolbox protocol: ```python from toolbox_adk import ToolboxToolset @@ -87,7 +83,7 @@ from toolbox_core.protocol import Protocol toolset = ToolboxToolset( server_url="http://127.0.0.1:5000", - protocol=Protocol.TOOLBOX + protocol=Protocol.MCP ) ``` diff --git a/packages/toolbox-core/README.md b/packages/toolbox-core/README.md index 0e6555ee..a3c9b474 100644 --- a/packages/toolbox-core/README.md +++ b/packages/toolbox-core/README.md @@ -160,24 +160,20 @@ You can explicitly select a protocol using the `protocol` option during client i | Constant | Description | | :--- | :--- | | `Protocol.MCP` | **(Default)** Alias for the default MCP version (currently `2025-06-18`). | -| `Protocol.TOOLBOX` | **DEPRECATED**: The native Toolbox HTTP protocol. Will be removed on March 4, 2026. | | `Protocol.MCP_v20251125` | MCP Protocol version 2025-11-25. | | `Protocol.MCP_v20250618` | MCP Protocol version 2025-06-18. | | `Protocol.MCP_v20241105` | MCP Protocol version 2024-11-05. | > [!WARNING] -> The **Native Toolbox Protocol** (`Protocol.TOOLBOX`) is deprecated and will be removed on **March 4, 2026**. -> Please migrate to using the **MCP Protocol** (`Protocol.MCP`), which is the default. ### Example -If you wish to use the native Toolbox protocol: ```py from toolbox_core import ToolboxClient from toolbox_core.protocol import Protocol -async with ToolboxClient("http://127.0.0.1:5000", protocol=Protocol.TOOLBOX) as toolbox: +async with ToolboxClient("http://127.0.0.1:5000", protocol=Protocol.MCP) as toolbox: # Use client pass ``` diff --git a/packages/toolbox-core/tests/test_tool.py b/packages/toolbox-core/tests/test_tool.py index 41cf5a72..080a2dd7 100644 --- a/packages/toolbox-core/tests/test_tool.py +++ b/packages/toolbox-core/tests/test_tool.py @@ -35,6 +35,31 @@ TEST_TOOL_NAME = "sample_tool" +class MockTransport(ITransport): + def __init__(self, base_url, session=None): + self._base_url = base_url + self.tool_invoke_mock = AsyncMock() + self.tool_get_mock = AsyncMock() + self.tools_list_mock = AsyncMock() + self.close_mock = AsyncMock() + + @property + def base_url(self): + return self._base_url + + async def tool_invoke(self, *args, **kwargs): + return await self.tool_invoke_mock(*args, **kwargs) + + async def tool_get(self, *args, **kwargs): + return await self.tool_get_mock(*args, **kwargs) + + async def tools_list(self, *args, **kwargs): + return await self.tools_list_mock(*args, **kwargs) + + async def close(self, *args, **kwargs): + return await self.close_mock(*args, **kwargs) + + class MockTransport(ITransport): def __init__(self, base_url, session=None): self._base_url = base_url diff --git a/packages/toolbox-langchain/README.md b/packages/toolbox-langchain/README.md index ce28eaad..7c38841c 100644 --- a/packages/toolbox-langchain/README.md +++ b/packages/toolbox-langchain/README.md @@ -107,25 +107,21 @@ You can explicitly select a protocol using the `protocol` option during client i | Constant | Description | | :--- | :--- | | `Protocol.MCP` | **(Default)** Alias for the default MCP version (currently `2025-06-18`). | -| `Protocol.TOOLBOX` | **DEPRECATED**: The native Toolbox HTTP protocol. Will be removed on March 4, 2026. | | `Protocol.MCP_v20251125` | MCP Protocol version 2025-11-25. | | `Protocol.MCP_v20250618` | MCP Protocol version 2025-06-18. | | `Protocol.MCP_v20250326` | MCP Protocol version 2025-03-26. | | `Protocol.MCP_v20241105` | MCP Protocol version 2024-11-05. | > [!WARNING] -> The **Native Toolbox Protocol** (`Protocol.TOOLBOX`) is deprecated and will be removed on **March 4, 2026**. -> Please migrate to using the **MCP Protocol** (`Protocol.MCP`), which is the default. ### Example -If you wish to use the native Toolbox protocol: ```py from toolbox_langchain import ToolboxClient from toolbox_core.protocol import Protocol -async with ToolboxClient("http://127.0.0.1:5000", protocol=Protocol.TOOLBOX) as toolbox: +async with ToolboxClient("http://127.0.0.1:5000", protocol=Protocol.MCP) as toolbox: # Use client pass ``` diff --git a/packages/toolbox-llamaindex/README.md b/packages/toolbox-llamaindex/README.md index 3cdfdea1..eb26862b 100644 --- a/packages/toolbox-llamaindex/README.md +++ b/packages/toolbox-llamaindex/README.md @@ -111,25 +111,21 @@ You can explicitly select a protocol using the `protocol` option during client i | Constant | Description | | :--- | :--- | | `Protocol.MCP` | **(Default)** Alias for the default MCP version (currently `2025-06-18`). | -| `Protocol.TOOLBOX` | **DEPRECATED**: The native Toolbox HTTP protocol. Will be removed on March 4, 2026. | | `Protocol.MCP_v20251125` | MCP Protocol version 2025-11-25. | | `Protocol.MCP_v20250618` | MCP Protocol version 2025-06-18. | | `Protocol.MCP_v20250326` | MCP Protocol version 2025-03-26. | | `Protocol.MCP_v20241105` | MCP Protocol version 2024-11-05. | > [!WARNING] -> The **Native Toolbox Protocol** (`Protocol.TOOLBOX`) is deprecated and will be removed on **March 4, 2026**. -> Please migrate to using the **MCP Protocol** (`Protocol.MCP`), which is the default. ### Example -If you wish to use the native Toolbox protocol: ```py from toolbox_llamaindex import ToolboxClient from toolbox_core.protocol import Protocol -async with ToolboxClient("http://127.0.0.1:5000", protocol=Protocol.TOOLBOX) as toolbox: +async with ToolboxClient("http://127.0.0.1:5000", protocol=Protocol.MCP) as toolbox: # Use client pass ```