Skip to main content
POST
/
v1
/
chat
/
completions
gemini-2.5-flash Quick Chat
curl --request POST \
  --url https://api.evolink.ai/v1/chat/completions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "model": "gemini-2.5-flash",
  "messages": [
    {
      "role": "user",
      "content": "Hello, introduce yourself"
    }
  ]
}'
{
  "id": "chatcmpl-20251010015944503180122WJNB8Eid",
  "model": "gemini-2.5-flash",
  "object": "chat.completion",
  "created": 1760032810,
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "Note: This is sample code!\n\nHello! I'm pleased to introduce myself.\n\nI'm a Large Language Model, trained and developed by Google..."
      },
      "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
  }
}

Authorizations

Authorization
string
header
required

##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

application/json
model
enum<string>
default:gemini-2.5-flash
required

Chat model name

Available options:
gemini-2.5-flash
Example:

"gemini-2.5-flash"

messages
object[]
required

List of chat messages

Minimum length: 1
Example:
[
{
"role": "user",
"content": "Hello, introduce yourself"
}
]

Response

Chat completion generated successfully

id
string

Unique identifier for the chat completion

Example:

"chatcmpl-20251010015944503180122WJNB8Eid"

model
string

Model name actually used

Example:

"gemini-2.5-flash"

object
enum<string>

Response type

Available options:
chat.completion
Example:

"chat.completion"

created
integer

Creation timestamp

Example:

1760032810

choices
object[]

List of chat completion choices

usage
object

Token usage statistics