访问地址:国内 https://4sapi.org、https://4stoken.com;海外https://4sapi.top、https://4sapi.com、https://us.4sapi.com;纯 API 专线https://4sapi.ai;北美低延迟https://4sapi.net。详见《国内外直连域名》。
gemini-3.8-flashgemini-3.8-flash、gemini-4-argon、gemini-3-flash-preview、gemini-3.7-flash、gemini-3.1-pro-preview-customtools、gemini-3.6-flash、gemini-3.1-flash-lite、gemini-3.1-flash-lite-preview 等视频请用 video_url传递(支持 YouTube 公开链接或直链 mp4);参数表暂未单独列出该类型时,可按 OpenAI 多模态 content 数组写法传入。
curl --location 'https://4sapi.org/v1/chat/completions' \
--header 'Accept: application/json' \
--header 'Authorization: sk-' \
--header 'Content-Type: application/json' \
--data '{
"model": "gemini-3.8-flash",
"stream": false,
"messages": [
{
"role": "user",
"content": [
{
"type": "text",
"text": "Please summarize the video in 3 sentences"
},
{
"type": "video_url",
"video_url": {
"url": "https://www.youtube.com/watch?v=9hE5-98ZeCg"
}
}
]
}
]
}'{
"id": "chatcmpl-123",
"object": "chat.completion",
"created": 1677652288,
"model": "gpt-6.1-sol",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "string",
"reasoning_content": "string",
"tool_calls": [
{
"id": "string",
"type": "function",
"function": {
"name": "string",
"arguments": "string"
}
}
],
"refusal": "string"
},
"finish_reason": "stop",
"logprobs": {}
}
],
"usage": {
"prompt_tokens": 0,
"completion_tokens": 0,
"total_tokens": 0,
"prompt_tokens_details": {
"cached_tokens": 0,
"audio_tokens": 0
},
"completion_tokens_details": {
"reasoning_tokens": 0,
"audio_tokens": 0,
"text_tokens": 0
}
},
"system_fingerprint": "string",
"service_tier": "string"
}