* feat: Add Daytona to tools docs Signed-off-by: Mislav Ivanda <mislavivanda454@gmail.com> * fix: Sort Daytona tool card alphabetically Signed-off-by: Mislav Ivanda <mislavivanda454@gmail.com> * chore: Daytona ADK plugin link set to Github Signed-off-by: Mislav Ivanda <mislavivanda454@gmail.com> * chore: DaytonaPlugin api key set Signed-off-by: Mislav Ivanda <mislavivanda454@gmail.com> Signed-off-by: Mislav Ivanda <mivanda@daytona.io> --------- Signed-off-by: Mislav Ivanda <mislavivanda454@gmail.com> Signed-off-by: Mislav Ivanda <mivanda@daytona.io> Co-authored-by: Kristopher Overholt <koverholt@google.com>
2.2 KiB
Daytona
The Daytona ADK plugin connects your ADK agent to Daytona sandboxes. This integration gives your agent the ability to execute code, run shell commands, and manage files in isolated environments, enabling secure execution of AI-generated code.
Use cases
-
Secure Code Execution: Run Python, JavaScript, and TypeScript code in isolated sandboxes without risking your local environment.
-
Shell Command Automation: Execute shell commands with configurable timeouts and working directories for build tasks, installations, or system operations.
-
File Management: Upload scripts and datasets to sandboxes, then retrieve generated outputs and results.
Prerequisites
- A Daytona account
- Daytona API key
Installation
pip install daytona-adk
Use with agent
from daytona_adk import DaytonaPlugin
from google.adk.agents import Agent
plugin = DaytonaPlugin(
api_key="your-daytona-api-key" # Or set DAYTONA_API_KEY environment variable
)
root_agent = Agent(
model="gemini-2.5-pro",
name="sandbox_agent",
instruction="Help users execute code and commands in a secure sandbox",
tools=plugin.get_tools(),
)
Available tools
| Tool | Description |
|---|---|
execute_code_in_daytona |
Execute Python, JavaScript, or TypeScript code |
execute_command_in_daytona |
Run shell commands |
upload_file_to_daytona |
Upload scripts or data files to the sandbox |
read_file_from_daytona |
Read script outputs or generated files |
start_long_running_command_daytona |
Start background processes (servers, watchers) |
Learn more
For a detailed guide on building a code generator agent that writes, tests, and verifies code in secure sandboxes, check out this guide.