Overview
This endpoint provides pdf analysis example:one functionality.
Authentication
This endpoint requires authentication using a Bearer token.
Authorization
string
default:"sk-***********"
required
Your API key in the format: Bearer YOUR_API_KEY
Request Body
model
string
default:"claude-opus-4-thinking"
required
The model to use for the request
Array of message objects for the conversation
Maximum number of tokens to generate
Whether to stream the response
Request Example
curl -X POST "https://gptproto.com/v1/chat/completions" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "claude-opus-4-thinking",
"messages": [
{
"role": "user",
"content": [
{
"type": "text",
"text": "Summarize the contents of this document"
},
{
"type": "file",
"file": {
"filename": "api-doc.pdf",
"file_data": "https://www.bt.cn/data/api-doc.pdf"
}
}
]
}
],
"max_tokens": 1000,
"stream": false
}'
Response
Error Responses
{
"error": {
"message": "Invalid signature",
"type": "401"
}
}