- chatgpt对话
- chatgpt绘图识图
- claude-gemini
- 逆向模型
- 绘图midjourney-proxy-plus
- 音乐
绘图gpt-4o-image
开发中
POST
/v1/chat/completions
请求参数
Authorization
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token示例:
Authorization: Bearer ********************
Header 参数
Authorization
string
可选
示例值:
Bearer {{apikey}}
Body 参数application/json
model
string
必需
messages
array [object {2}]
必需
role
string
可选
content
string
可选
stream
boolean
必需
示例
{
"model": "gpt-4o-image",
"stream": true,
"messages": [
{
"role": "user",
"content": [
{
"type": "text",
"text": "画一只小猫"
}
]
}
]
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.huiyan-ai.cn/v1/chat/completions' \
--header 'Authorization: Bearer ' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "gpt-4o-image",
"stream": true,
"messages": [
{
"role": "user",
"content": [
{
"type": "text",
"text": "画一只小猫"
}
]
}
]
}'
返回响应
🟢200成功
application/json
Body
object {0}
示例
{}
🟠404失败
修改于 2025-05-09 07:39:24