Skip to content

Commit d33d829

Browse files
committed
feat(adk): Package scaffolding & setup
1 parent d806de5 commit d33d829

File tree

5 files changed

+188
-0
lines changed

5 files changed

+188
-0
lines changed

packages/toolbox-adk/README.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Toolbox ADK Integration
2+
3+
This package allows Google ADK agents to natively use tools from the MCP Toolbox.
4+
5+
## Installation
6+
7+
```bash
8+
pip install toolbox-adk
9+
```
10+
11+
## Usage
12+
13+
```python
14+
from toolbox_adk import ToolboxToolset, CredentialStrategy
15+
16+
# Configure auth (e.g., Use the agent's identity)
17+
creds = CredentialStrategy.TOOLBOX_IDENTITY()
18+
19+
# Create the toolset
20+
toolset = ToolboxToolset(
21+
server_url="http://localhost:5000",
22+
credentials=creds
23+
)
24+
25+
# Use in your agent
26+
# agent = Agent(tools=toolset.get_tools())
27+
```
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# Copyright 2025 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
steps:
16+
- id: Install library requirements
17+
name: 'python:${_VERSION}'
18+
dir: 'packages/toolbox-adk'
19+
args:
20+
- install
21+
- '-r'
22+
- 'requirements.txt'
23+
- '--user'
24+
entrypoint: pip
25+
- id: Install test requirements
26+
name: 'python:${_VERSION}'
27+
args:
28+
- install
29+
- '-e'
30+
- 'packages/toolbox-adk[test]'
31+
- '--user'
32+
entrypoint: pip
33+
- id: Run integration tests
34+
name: 'python:${_VERSION}'
35+
dir: 'packages/toolbox-adk'
36+
env:
37+
- TOOLBOX_URL=$_TOOLBOX_URL
38+
- TOOLBOX_VERSION=$_TOOLBOX_VERSION
39+
- GOOGLE_CLOUD_PROJECT=$PROJECT_ID
40+
- TOOLBOX_MANIFEST_VERSION=${_TOOLBOX_MANIFEST_VERSION}
41+
args:
42+
- '-c'
43+
- >-
44+
python -m pytest --cov=src/toolbox_adk --cov-report=term --cov-fail-under=90 tests/
45+
entrypoint: /bin/bash
46+
options:
47+
logging: CLOUD_LOGGING_ONLY
48+
substitutions:
49+
_VERSION: '3.13'
50+
# Default values (can be overridden by triggers)
51+
_TOOLBOX_VERSION: '0.22.0'
52+
_TOOLBOX_MANIFEST_VERSION: '34'
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
[project]
2+
name = "toolbox-adk"
3+
dynamic = ["version"]
4+
description = "ADK Integration for MCP Toolbox"
5+
readme = "README.md"
6+
authors = [{name = "Google LLC", email = "[email protected]"}]
7+
license = {file = "LICENSE"}
8+
classifiers = [
9+
"Intended Audience :: Developers",
10+
"License :: OSI Approved :: Apache Software License",
11+
"Programming Language :: Python",
12+
"Programming Language :: Python :: 3",
13+
"Programming Language :: Python :: 3.10",
14+
"Programming Language :: Python :: 3.11",
15+
"Programming Language :: Python :: 3.12",
16+
"Programming Language :: Python :: 3.13",
17+
"Operating System :: OS Independent",
18+
]
19+
requires-python = ">=3.10"
20+
dependencies = [
21+
"toolbox-core>=0.5.4",
22+
"google-auth>=2.43.0,<3.0.0",
23+
"google-auth-oauthlib>=1.2.0,<2.0.0",
24+
"google-adk>=1.20.0,<2.0.0",
25+
"typing-extensions>=4.0.0"
26+
]
27+
28+
[project.urls]
29+
Homepage = "https://github.com/googleapis/mcp-toolbox-sdk-python/blob/main/packages/toolbox-adk"
30+
Repository = "https://github.com/googleapis/mcp-toolbox-sdk-python.git"
31+
"Bug Tracker" = "https://github.com/googleapis/mcp-toolbox-sdk-python/issues"
32+
Changelog = "https://github.com/googleapis/mcp-toolbox-sdk-python/blob/main/packages/toolbox-adk/CHANGELOG.md"
33+
34+
[project.optional-dependencies]
35+
test = [
36+
"black[jupyter]==25.11.0",
37+
"isort==7.0.0",
38+
"mypy==1.19.0",
39+
"pytest==9.0.1",
40+
"pytest-asyncio==1.3.0",
41+
"pytest-cov==7.0.0",
42+
"pytest-mock==3.15.1"
43+
]
44+
45+
# Tells setuptools that packages are under the 'src' directory
46+
[tool.setuptools]
47+
package-dir = {"" = "src"}
48+
49+
[tool.setuptools.dynamic]
50+
version = {attr = "toolbox_adk.version.__version__"}
51+
52+
[build-system]
53+
requires = ["setuptools>=61.0"]
54+
build-backend = "setuptools.build_meta"
55+
56+
[tool.black]
57+
target-version = ['py310']
58+
59+
[tool.isort]
60+
profile = "black"
61+
62+
[tool.mypy]
63+
python_version = "3.10"
64+
warn_unused_configs = true
65+
disallow_incomplete_defs = true
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Copyright 2025 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
from .version import __version__
16+
from .credentials import CredentialStrategy, CredentialConfig, CredentialType
17+
from .client import ToolboxClient
18+
from .tool import ToolboxTool, ToolboxContext
19+
from .toolset import ToolboxToolset
20+
21+
__all__ = [
22+
"CredentialStrategy",
23+
"CredentialConfig",
24+
"CredentialType",
25+
"ToolboxClient",
26+
"ToolboxTool",
27+
"ToolboxContext",
28+
"ToolboxToolset",
29+
]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Copyright 2025 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
__version__ = "0.0.1"

0 commit comments

Comments
 (0)