{
"model": "gemini-2.5-flash",
"messages": [
{
"role": "user",
"content": [
{
"type": "text",
"text": "文档说了什么,中文回答"
},
{
"type": "image_url",
"image_url": {
"url": "https://www.bt.cn/data/api-doc.pdf"
}
}
]
}
]
}curl --location -g --request POST 'http://api.example.com/v1/chat/completions' \
--header 'Authorization: Bearer sk-xxx' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "gemini-2.5-flash",
"messages": [
{
"role": "user",
"content": [
{
"type": "text",
"text": "文档说了什么,中文回答"
},
{
"type": "image_url",
"image_url": {
"url": "https://www.bt.cn/data/api-doc.pdf"
}
}
]
}
]
}'{}