AI开放平台
API列表
帮助文档
帮助文档
  • API接口使用教程
  • AI应用接口文档
下载
下载
  • 下载Apifox
  • 下载调试浏览器插件
API列表
帮助文档
帮助文档
  • API接口使用教程
  • AI应用接口文档
下载
下载
  • 下载Apifox
  • 下载调试浏览器插件
  1. OpenAI
  • 帮助中心
    • AI开放平台首页
  • 智体空间-TokenGate
    • API接口使用教程
    • 外部大模型
      • 国外模型
        • OpenAI
          • gpt-5(对话)
            POST
          • gpt-5-pro(对话)
            POST
          • gpt-5-chat-latest(对话)
            POST
          • gpt-5-nano(对话)
            POST
          • gpt-5-mini(对话)
            POST
          • gpt-5.2(对话)
            POST
          • gpt-5.2-search(对话)
            POST
          • gpt-5.3-codex(对话)
            POST
          • gpt-5.4(对话)
            POST
          • gpt-5.4-pro(对话)
            POST
          • whisper-1(语音转文字)
            POST
          • tts-1-hd(文字生语音)
            POST
          • text-embedding-ada-002(向量)
            POST
          • text-embedding-3-small(向量)
            POST
          • text-embedding-3-large(向量)
            POST
        • Anthropic
          • claude-opus-4-6(对话)
          • claude-sonnet-4-6(对话)
          • claude-sonnet-4.5(对话)
          • claude-opus-4.5(对话)
          • claude-haiku-4.5(对话)
        • X AI
          • grok-4(对话)
          • grok-4-fast-non-reasoning(对话)
          • grok-4-1-fast-non-reasoning(对话)
          • grok-4-fast-reasoning(对话)
          • grok-4-1-fast-reasoning(对话)
          • grok-code-fast-1(对话)
        • Google
          • gemini-3-flash-preview(对话)
          • gemini-3.1-pro-preview(对话)
          • gemini-2.5-flash-image(生图)
          • gemini-3-pro-image-preview(生图)
          • gemini-3.1-flash-image-preview(生图)
    • 内部大模型
      • 国内大模型
        • qianwen
          • Qwen3-VL-8B-Instruct
          • qwen-image-edit(图片编辑)
          • qwen-image(文生图)
          • Qwen3-TTS-12Hz-1.7B-CustomVoice 语音生成
          • wan-t2v 文生视频
          • wan-i2v 图生视频
        • deepseek
          • deepseek3.2
        • minimax
          • minimax2.7
          • minimax2.5
  • suno 即将上线,敬请期待
    • suno
      • sunoV2
        • 音乐查询
        • 创建音乐
        • 扩展音乐
        • 翻唱音乐
        • 上传并扩展音乐
        • 上传并翻唱音乐
        • 修改音乐片段
        • 音乐片段合并
        • 生成人声和伴奏
        • 获取音轨(MDMI)
        • 获取歌词
        • 获取MP4
        • 获取WAV
        • 获取歌词/音频时间线
        • 获取节拍
        • 获取tags
  1. OpenAI

gpt-5(对话)

POST
https://ai.vnet.com/v1/chat/completions

请求参数

Authorization
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token
示例:
Authorization: Bearer ********************
Header 参数

Body 参数application/json必填

示例

返回响应

🟢200成功
application/json
Body

请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://ai.vnet.com/v1/chat/completions' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
  "model": "gpt-5",
  "messages": [
    {
      "role": "user",
      "content": "你好"
    }
  ],
  "temperature": 0.7,
  "max_tokens": 1000
}'
响应示例响应示例
{
    "id": "chatcmpl-WwKP5kjA7rk7yZvARFIPhKF6G9yZ1",
    "object": "chat.completion",
    "created": 1776826935,
    "model": "gpt-5",
    "choices": [
        {
            "index": 0,
            "message": {
                "role": "assistant",
                "content": "你好!有什么可以帮你的吗?"
            },
            "finish_reason": "stop"
        }
    ],
    "usage": {
        "prompt_tokens": 7,
        "completion_tokens": 108,
        "total_tokens": 115,
        "completion_tokens_details": {
            "reasoning_tokens": 64
        }
    }
}
修改于 2026-04-22 08:14:57
上一页
API接口使用教程
下一页
gpt-5-pro(对话)
Built with