curl --request POST \
--url https://direct.evolink.ai/v1/chat/completions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "gemini-3.6-flash",
"messages": [
{
"role": "user",
"content": "Please introduce yourself"
}
]
}
'{
"id": "chatcmpl-20251010015944503180122WJNB8Eid",
"model": "gemini-3.6-flash",
"object": "chat.completion",
"created": 1760032810,
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Hello! I'm pleased to introduce myself.\n\nI'm a Large Language Model, trained and developed by Google.\n\nSimply put, you can think of me as a \"smart brain\" that has been trained on massive amounts of text data and is able to understand and generate human language. My core capability is processing and generating text. Specifically, I can do the following:\n\n**1. Information Query & Knowledge Answering**\nI can act like a \"talking encyclopedia,\" answering various questions, whether they're about scientific knowledge, historical events, or everyday facts.\n\n**2. Creative Writing & Text Generation**\nI can create various types of text based on your requirements, such as:\n* **Writing**: Poetry, stories, scripts, emails, speeches, advertising copy, etc.\n* **Planning**: Travel plans, study outlines, event proposals, etc.\n* **Brainstorming**: Working with you to generate new ideas and spark creativity.\n\n**3. Translation & Language Processing**\nI'm proficient in multiple languages and can provide fast, fluent translation services. I can also help you polish, proofread, summarize, or rewrite text to make your expression clearer and more professional.\n\n**4. Programming & Code Assistance**\nI can write code snippets, explain code logic, debug errors, or \"translate\" code from one programming language to another, making me a helpful companion for programmers.\n\n**5. Logical Analysis & Reasoning**\nI can help you analyze complex problems, organize logical chains, and make inferences and summaries based on the information you provide.\n\n---\n\n**In summary**, my goal is to be a powerful and useful tool that helps you obtain information more efficiently, complete tasks, and spark creativity through natural language communication.\n\n**Remember:** I'm an artificial intelligence, my knowledge comes from the data I've learned, and it may not be the most up-to-date. Sometimes I may also make mistakes, so for very important information, I recommend you verify it again.",
"tool_calls": [
{
"id": "<string>",
"type": "function",
"function": {
"name": "<string>",
"arguments": "<string>"
}
}
]
},
"logprobs": {
"content": [
{
"token": "<string>",
"logprob": 123,
"bytes": [
123
],
"top_logprobs": [
{
"token": "<string>",
"logprob": 123,
"bytes": [
123
]
}
]
}
]
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 13,
"completion_tokens": 1891,
"total_tokens": 1904,
"prompt_tokens_details": {
"cached_tokens": 0,
"text_tokens": 13,
"audio_tokens": 0,
"image_tokens": 0
},
"completion_tokens_details": {
"text_tokens": 0,
"audio_tokens": 0,
"reasoning_tokens": 1480
},
"input_tokens": 0,
"output_tokens": 0,
"input_tokens_details": null
}
}{
"error": {
"code": 400,
"message": "Invalid request parameters",
"type": "invalid_request_error"
}
}{
"error": {
"code": 401,
"message": "Invalid or expired token",
"type": "authentication_error"
}
}{
"error": {
"code": 402,
"message": "Insufficient quota",
"type": "insufficient_quota_error",
"fallback_suggestion": "https://evolink.ai/dashboard/credits"
}
}{
"error": {
"code": 403,
"message": "Access denied for this model",
"type": "permission_error",
"param": "model"
}
}{
"error": {
"code": 404,
"message": "Specified model not found",
"type": "not_found_error",
"param": "model",
"fallback_suggestion": "gemini-3.6-flash"
}
}{
"error": {
"code": 413,
"message": "Image file too large",
"type": "request_too_large_error",
"param": "content",
"fallback_suggestion": "compress image to under 10MB"
}
}{
"error": {
"code": 429,
"message": "Rate limit exceeded",
"type": "rate_limit_error",
"fallback_suggestion": "retry after 60 seconds"
}
}{
"error": {
"code": 500,
"message": "Internal server error",
"type": "internal_server_error",
"fallback_suggestion": "try again later"
}
}{
"error": {
"code": 502,
"message": "Upstream AI service unavailable",
"type": "upstream_error",
"fallback_suggestion": "try different model"
}
}{
"error": {
"code": 503,
"message": "Service temporarily unavailable",
"type": "service_unavailable_error",
"fallback_suggestion": "retry after 30 seconds"
}
}Gemini All-Model API - OpenAI-Compatible Format
Select the Gemini text model to call via model in the request body (see the reference table for the model parameter for all available values).
- Uses the OpenAI SDK / Chat Completions format and returns conversation content synchronously
- Plain text / multimodal input: mixed text + image input (
messages[].content) - Streaming: set
stream: trueto return content chunk by chunk
Model specs and differences
- 3.8 behavior: compared with 3.7, it improves software engineering, agents, multi-step reasoning, and multimodal accuracy; it may consume more reasoning / output tokens, especially at
high. Uselowfor latency-sensitive workloads, the defaultmediumfor general use, andhighfor complex code, long video, or multi-step reasoning. - Gemini 4 Argon behavior:
reasoning_effortacceptslow/medium/high; when omitted, the model determines how much to think.minimalis downgraded tolow. Usemax_tokensto limit output; current Gemini routes do not guarantee thatmax_completion_tokenstakes effect.max_tokensaccepts up to 1,048,576, but a single streaming request returns up to 65,536 thinking and answer tokens, or 32,768 non-streaming; reaching the cap returnsfinish_reason: length. The OpenAI-compatible format does not support long-output continuation; for longer output, use Native API reference.extra_body.google.thinking_config.thinking_budgethas no effect on this model. In multi-turn tool calls, return the previoustool_calls[]entries’thought_signatureunchanged, or the request returns 400. - Sampling / penalty parameters
temperature/top_p/frequency_penalty/presence_penalty: consistent across the entire Gemini 3.x series, custom values do not affect the output; atemperature/top_pvalue outside the range returns a 400, andfrequency_penalty/presence_penaltyare ignored and have no effect (no error is raised). - Thinking control
reasoning_effort:minimal/low/medium/high(see thereasoning_effortparameter for the levels supported and the default of each model); effective for the Gemini 3.x / 4 series.gemini-4-argon/gemini-3.8-flash/gemini-3.7-flashand the Pro models do not supportminimal; a passed value is automatically downgraded tolow. - Last-turn role: the
roleof the last message must not beassistant(Gemini 3.5+ will error). - Token limits:
gemini-3.8-flash/gemini-3.7-flash/gemini-3.6-flash/gemini-3.5-flash-litehave a 1,048,576-token context and a maximum output of 65,536.gemini-4-argonshares a 1,048,576-token context across input, thinking, and output; each streaming request returns up to 65,536 tokens, or 32,768 non-streaming, including thinking and the answer. Actual output is also limited by remaining context space. This format does not support continuation. Other models follow their own specifications. - Gemini 2.5 IDs: from 2026-10-19,
gemini-2.5-pro/gemini-2.5-flash/gemini-2.5-flash-liteare served bygemini-3.8-flash/gemini-3.5-flash-lite/gemini-3.1-flash-lite-previewand billed at their rates; responses show the new model ID, and parameter behavior follows the new model.extra_body.google.thinking_config.thinking_budgetis converted toreasoning_effort(seeextra_body).
curl --request POST \
--url https://direct.evolink.ai/v1/chat/completions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "gemini-3.6-flash",
"messages": [
{
"role": "user",
"content": "Please introduce yourself"
}
]
}
'{
"id": "chatcmpl-20251010015944503180122WJNB8Eid",
"model": "gemini-3.6-flash",
"object": "chat.completion",
"created": 1760032810,
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Hello! I'm pleased to introduce myself.\n\nI'm a Large Language Model, trained and developed by Google.\n\nSimply put, you can think of me as a \"smart brain\" that has been trained on massive amounts of text data and is able to understand and generate human language. My core capability is processing and generating text. Specifically, I can do the following:\n\n**1. Information Query & Knowledge Answering**\nI can act like a \"talking encyclopedia,\" answering various questions, whether they're about scientific knowledge, historical events, or everyday facts.\n\n**2. Creative Writing & Text Generation**\nI can create various types of text based on your requirements, such as:\n* **Writing**: Poetry, stories, scripts, emails, speeches, advertising copy, etc.\n* **Planning**: Travel plans, study outlines, event proposals, etc.\n* **Brainstorming**: Working with you to generate new ideas and spark creativity.\n\n**3. Translation & Language Processing**\nI'm proficient in multiple languages and can provide fast, fluent translation services. I can also help you polish, proofread, summarize, or rewrite text to make your expression clearer and more professional.\n\n**4. Programming & Code Assistance**\nI can write code snippets, explain code logic, debug errors, or \"translate\" code from one programming language to another, making me a helpful companion for programmers.\n\n**5. Logical Analysis & Reasoning**\nI can help you analyze complex problems, organize logical chains, and make inferences and summaries based on the information you provide.\n\n---\n\n**In summary**, my goal is to be a powerful and useful tool that helps you obtain information more efficiently, complete tasks, and spark creativity through natural language communication.\n\n**Remember:** I'm an artificial intelligence, my knowledge comes from the data I've learned, and it may not be the most up-to-date. Sometimes I may also make mistakes, so for very important information, I recommend you verify it again.",
"tool_calls": [
{
"id": "<string>",
"type": "function",
"function": {
"name": "<string>",
"arguments": "<string>"
}
}
]
},
"logprobs": {
"content": [
{
"token": "<string>",
"logprob": 123,
"bytes": [
123
],
"top_logprobs": [
{
"token": "<string>",
"logprob": 123,
"bytes": [
123
]
}
]
}
]
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 13,
"completion_tokens": 1891,
"total_tokens": 1904,
"prompt_tokens_details": {
"cached_tokens": 0,
"text_tokens": 13,
"audio_tokens": 0,
"image_tokens": 0
},
"completion_tokens_details": {
"text_tokens": 0,
"audio_tokens": 0,
"reasoning_tokens": 1480
},
"input_tokens": 0,
"output_tokens": 0,
"input_tokens_details": null
}
}{
"error": {
"code": 400,
"message": "Invalid request parameters",
"type": "invalid_request_error"
}
}{
"error": {
"code": 401,
"message": "Invalid or expired token",
"type": "authentication_error"
}
}{
"error": {
"code": 402,
"message": "Insufficient quota",
"type": "insufficient_quota_error",
"fallback_suggestion": "https://evolink.ai/dashboard/credits"
}
}{
"error": {
"code": 403,
"message": "Access denied for this model",
"type": "permission_error",
"param": "model"
}
}{
"error": {
"code": 404,
"message": "Specified model not found",
"type": "not_found_error",
"param": "model",
"fallback_suggestion": "gemini-3.6-flash"
}
}{
"error": {
"code": 413,
"message": "Image file too large",
"type": "request_too_large_error",
"param": "content",
"fallback_suggestion": "compress image to under 10MB"
}
}{
"error": {
"code": 429,
"message": "Rate limit exceeded",
"type": "rate_limit_error",
"fallback_suggestion": "retry after 60 seconds"
}
}{
"error": {
"code": 500,
"message": "Internal server error",
"type": "internal_server_error",
"fallback_suggestion": "try again later"
}
}{
"error": {
"code": 502,
"message": "Upstream AI service unavailable",
"type": "upstream_error",
"fallback_suggestion": "try different model"
}
}{
"error": {
"code": 503,
"message": "Service temporarily unavailable",
"type": "service_unavailable_error",
"fallback_suggestion": "retry after 30 seconds"
}
}https://direct.evolink.ai, which has better support for text models and long-lived connections. https://api.evolink.ai is the primary endpoint for multimodal services and serves as a fallback address for text models.Authorizations
##All APIs require Bearer Token authentication##
Get API Key:
Visit API Key Management Page to get your API Key
Add to request header:
Authorization: Bearer YOUR_API_KEY
Body
Select the Gemini text model to call:
| Model ID | Series | Positioning |
|---|---|---|
gemini-4-argon | 4 Argon | Long reports and large coding tasks; up to 65,536 tokens per streaming request / 32,768 non-streaming; use native API continuation for longer output |
gemini-3.8-flash | 3.8 Flash | Enhanced software engineering / agents / multi-step reasoning / multimodal accuracy |
gemini-3.7-flash | 3.7 Flash | Pro-level agentic / code generation / terminal execution |
gemini-3.6-flash | 3.6 Flash | Multi-step orchestration / code refactoring / general reasoning |
gemini-3.5-flash | 3.5 Flash | General-purpose Flash |
gemini-3.5-flash-lite | 3.5 Flash-Lite | Low cost / high throughput / lightweight agent |
gemini-3.1-pro-preview | 3.1 Pro (Preview) | Advanced reasoning |
gemini-3.1-pro-preview-customtools | 3.1 Pro · CustomTools | Advanced reasoning + custom tools |
gemini-3.1-flash-lite-preview | 3.1 Flash-Lite (Preview) | Low cost |
gemini-3-pro-preview | 3.0 Pro (Preview) | Advanced reasoning |
gemini-3-flash-preview | 3.0 Flash (Preview) | General-purpose Flash |
gemini-2.5-pro | 2.5 Pro | Legacy ID; from 2026-10-19 served by gemini-3.8-flash and billed at its rates |
gemini-2.5-flash | 2.5 Flash | Legacy ID; from 2026-10-19 served by gemini-3.5-flash-lite and billed at its rates |
gemini-2.5-flash-lite | 2.5 Flash-Lite | Legacy ID; from 2026-10-19 served by gemini-3.1-flash-lite-preview and billed at its rates |
gemini-4-argon, gemini-3.8-flash, gemini-3.7-flash, gemini-3.6-flash, gemini-3.5-flash, gemini-3.5-flash-lite, gemini-3.1-pro-preview, gemini-3.1-pro-preview-customtools, gemini-3.1-flash-lite-preview, gemini-3-pro-preview, gemini-3-flash-preview, gemini-2.5-pro, gemini-2.5-flash, gemini-2.5-flash-lite "gemini-3.6-flash"
List of chat messages, supports multi-turn dialogue and multimodal input
1Show child attributes
Show child attributes
Whether to return response in streaming mode
true: Streaming return, receives content in real-time chunksfalse: Returns complete response at once
false
Maximum generated tokens, including thinking and the answer. Use this parameter to limit output length on current Gemini routes.
gemini-3.8-flash / gemini-3.7-flash / gemini-3.6-flash / gemini-3.5-flash-lite support up to 65,536 tokens. For gemini-4-argon, the parameter accepts up to 1,048,576, but a single streaming request returns up to 65,536 tokens, or 32,768 non-streaming, and actual output is limited by remaining context space. Reaching the output limit returns finish_reason: length; this format does not support continuation. Other models follow their own specifications.
1 <= x <= 10485762000
OpenAI compatibility field. Current Gemini routes do not guarantee that this field limits output length, and output may exceed the specified value. Use max_tokens to control output length.
1 <= x <= 10485762000
Sampling temperature, controls output randomness
Description:
- Lower values (e.g., 0.2): More deterministic, focused output
- Higher values (e.g., 1.5): More random, creative output
Consistent across the entire Gemini 3.x series (does not vary by model): custom values within the valid range do not affect the output; a value outside this parameter's valid range returns a 400 rather than being silently ignored.
0 <= x <= 20.7
Nucleus Sampling parameter
Description:
- Controls sampling from tokens within the top cumulative probability
- For example, 0.9 means selecting from tokens whose cumulative probability reaches 90%
- Default: 0.95
Recommendation: Do not adjust temperature and top_p simultaneously
Consistent across the entire Gemini 3.x series (does not vary by model): custom values within the valid range do not affect the output; a value outside this parameter's valid range returns a 400 rather than being silently ignored.
0 <= x <= 10.9
Frequency penalty coefficient. Range: -2.0 to 2.0. Corresponds to Gemini's frequencyPenalty.
Consistent across the entire Gemini 3.x / 4 series: passed values are ignored and have no effect (no error is raised).
-2 <= x <= 20
Presence penalty coefficient. Range: -2.0 to 2.0. Corresponds to Gemini's presencePenalty.
Consistent across the entire Gemini 3.x / 4 series: passed values are ignored and have no effect (no error is raised).
-2 <= x <= 20
Stop sequences. Supports a string or string array, corresponding to Gemini's stopSequences.
Number of candidates to generate
Gemini 3.x only supports 1; passing >1 returns a 400 (equivalent to the candidateCount that has been removed from the native API).
gemini-4-argon: passing >1 does not raise an error; only 1 candidate is returned.
1 <= x <= 11
Limits the thinking effort, corresponding to Gemini's thinking level:
minimal: near-zero thinking, high throughput / low latencylow: less thinking, simple tasksmedium: balanced quality and speedhigh: deep multi-step reasoning
Effective for the Gemini 3.x / 4 series, with different supported levels and defaults per model (consistent with the native API):
| Model | Supported levels | Default |
|---|---|---|
gemini-4-argon | low / medium / high | Long reports and large coding tasks; up to 65,536 tokens per streaming request / 32,768 non-streaming; use native API continuation for longer output |
gemini-3.8-flash | low / medium / high | medium |
gemini-3.7-flash | low / medium / high | medium |
gemini-3.6-flash | minimal / low / medium / high | medium |
gemini-3.5-flash | minimal / low / medium / high | medium |
gemini-3.5-flash-lite | minimal / low / medium / high | minimal |
gemini-3.1-flash-lite-preview | minimal / low / medium / high | minimal |
gemini-3-flash-preview | minimal / low / medium / high | medium |
gemini-3.1-pro-preview | low / medium / high | high |
gemini-3.1-pro-preview-customtools | low / medium / high | high |
gemini-3-pro-preview | low / medium / high | high |
Passing a level a model does not support (e.g., passing minimal to a Pro model or to gemini-4-argon / gemini-3.8-flash / gemini-3.7-flash) is automatically downgraded to low and does not raise an error.
minimal, low, medium, high "minimal"
Random seed used to make output as reproducible as possible, corresponding to Gemini's seed.
12345
Response format settings, supporting JSON mode and JSON Schema, corresponding to Gemini's responseMimeType, responseSchema and responseJsonSchema.
- Option 1
- Option 2
Show child attributes
Show child attributes
Streaming response options. Can be set when stream is true.
Show child attributes
Show child attributes
List of tool definitions for Function Calling.
Show child attributes
Show child attributes
Controls tool-calling behavior.
none, auto, required Gemini extension parameters.
Show child attributes
Show child attributes
Response
Chat completion generated successfully
Unique identifier for the chat completion
"chatcmpl-20251010015944503180122WJNB8Eid"
Model name actually used
"gemini-3.6-flash"
Response type
chat.completion "chat.completion"
Creation timestamp
1760032810
List of chat completion choices
Show child attributes
Show child attributes
Token usage statistics
Show child attributes
Show child attributes