Authorization: Bearer ********************{
"model": "gemini-3.1-pro-preview",
"messages": [
{
"role": "developer",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": "Hello!"
}
]
}'curl --location --request POST 'https://api.ecovai.cn/v1/chat/completions' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "gemini-3.1-pro-preview",
"messages": [
{
"role": "developer",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": "Hello!"
}
]
}'\'''{
"choices": [
{
"finish_reason": "string",
"index": 0,
"message": {
"content": "string",
"role": "string"
}
}
],
"created": 0,
"id": "string",
"model": "string",
"object": "string",
"usage": {
"completion_tokens": 0,
"completion_tokens_details": {
"accepted_prediction_tokens": 0,
"audio_tokens": 0,
"reasoning_tokens": 0,
"rejected_prediction_tokens": 0
},
"prompt_tokens": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cached_tokens": 0
},
"total_tokens": 0
}
}