Combine Built-in Tools and Function Calling in the Gemini Interactions API
Summary
The Gemini Interactions API now supports combining built-in tools with custom function declarations within a single request, allowing the Gemini model to autonomously decide tool call order and circulate context. This new capability, released on March 24, 2026, streamlines agent development by removing the need for manual orchestration of tool handoffs. An example demonstrates combining Google Search, URL Context, and a custom `file_incident` function to automatically search for a critical CVE, read its advisory, and file an incident with details like `CVE-2025-55182` and `Critical` severity. Additionally, the API introduces cross-turn context circulation, enabling follow-up questions to reason over previous tool results without re-execution, while still allowing new tool calls for fresh data.
Key takeaway
For AI Engineers building sophisticated agents, the Gemini Interactions API's new tool combination feature simplifies complex workflows. You can now declare multiple tools, both built-in and custom, in one request, letting Gemini manage the execution order and context flow. This reduces boilerplate code and allows your agents to handle multi-step tasks like vulnerability research and incident filing more autonomously, accelerating development and deployment of robust AI applications.
Key insights
Gemini API now combines built-in and custom tools, automating orchestration and context circulation for complex agent workflows.
Principles
- Automate tool orchestration
- Circulate context between tools
Method
Define custom functions and pass them alongside built-in tools (e.g., `google_search`, `url_context`) in a single `client.interactions.create` request. For cross-turn context, pass `previous_interaction_id`.
In practice
- Combine Search, URL Context, and custom functions
- File security incidents automatically
- Maintain context across conversational turns
Topics
- Gemini API
- Function Calling
- Tool Orchestration
- Context Circulation
- AI Agents
Best for: AI Engineer, Machine Learning Engineer, Software Engineer
Related on AIssential
Editorial summary, takeaway, and curation by AIssential. Original article published by philschmid.de - RSS feed.