gpt对话支持上下文

GET

gpt对话支持上下文

https://api.aiys.net/api/chatgptpro
https://api.aiys.net/api/chatgptpro/?id=123&text=你好&type=1

请求参数

将 Key 放到 Header 中使用 Authorization 请求头,按 Bearer Token 方式传递
Authorization:Bearer YOUR_API_KEY

返回参数

接口指标

QPS 上限
10次/秒
平均响应时间
3511.8ms
今日调用量
0
累计调用量
75

请求示例

Shell
JavaScript
Python
PHP
Java
Go
C#
Ruby
curl -X GET 'https://api.aiys.net/api/chatgptpro?type=int&id=string&model=string&instructions=string&text=问题' \
  -H 'Authorization: Bearer YOUR_API_KEY'

返回示例

{
  "code": 0,
  "msg": "success",
  "type": 1,
  "id": "123",
  "text": "你好",
  "reply": "你好!请问有什么需要帮忙的?",
  "response_id": "chatcmpl_0d2ffe08b2784e440169c244fa9a0881988a0457b7235f7245",
  "message_ids": {
    "user": "msg_be62a4d177671745c79fb2bd39748a46",
    "assistant": "msg_06ecaa221588b2348efd51f4ff4ca922"
  },
  "session_expire_seconds": 1800,
  "gc": {
    "expired_count": 0,
    "expired_session_ids": []
  },
  "usage": {
    "completion_tokens": 14,
    "prompt_tokens": 417,
    "total_tokens": 431
  }
}