Describe the bug
There is a new tool config for Gemini called includeServerSideToolInvocations which allows to use the built-in tooling (like search) in combination with a defined tool list.
Right now if there is more than 0 tools set, the tool config will be fully overwritten.
To Reproduce
Setup the search tool to use, add the IncludeServerSideToolInvocations as true + define any tools, the config will be removed and the Gemini api will return an error:
Error 400, Message: Please enable tool_config.include_server_side_tool_invocations to use Built-in tools with Function calling., Status: INVALID_ARGUMENT
Expected behavior
It should simply forward this config and work without an issue.
Screenshots
Runtime (please complete the following information):
- OS: Linux, MacOS
- Version Ubuntu 25.10, MacOS 26.3.1
Go version
- go version go1.26.1 darwin/arm64
Additional context
Describe the bug
There is a new tool config for Gemini called
includeServerSideToolInvocationswhich allows to use the built-in tooling (like search) in combination with a defined tool list.Right now if there is more than 0 tools set, the tool config will be fully overwritten.
To Reproduce
Setup the search tool to use, add the
IncludeServerSideToolInvocationsas true + define any tools, the config will be removed and the Gemini api will return an error:Expected behavior
It should simply forward this config and work without an issue.
Screenshots
Runtime (please complete the following information):
Go version
Additional context