Gemini Guides
A comprehensive guide to Gemini API calls on our platform.
Gemini 2.5 Flash support
We currently provides Gemini 2.5 Flash API support in a compatible way with Openai. For quick tasks, you can use the following code to call the model with no thinking:
For complex tasks, simply set the model id to the default gemini-2.5-flash-preview-04-17
to enable thinking.
Gemini 2.5 Flash uses the budget
parameter to control the depth of thinking, ranging from 0 to 24K. The default budget is 1024, and the optimal marginal effect is 16K.
We will use the native Gemini support to allow developers to accurately control the budget.
Gemini Function calling
By using the openai compatible way to call Gemini’s function calling, you need to pass in tool_choice="auto"
in the request body, otherwise it will report an error.
Output Example: