curl -v -X POST https://hnd1.aihub.zeabur.ai/v1/chat/completions \
-H "Authorization: Bearer sk-RHb3riFzAGJb7D2QxJsekw" \
-H "Content-Type: application/json" \
-d '{"model": "gpt-5", "messages": [{"role": "user", "content": "Hello"}]}'
注意:不需要使用 -X 或 --request,POST 请求会自动推断。
- 使用代理环境变量
HTTPS_PROXY == 'http://127.0.0.1:1082'
- 正在尝试 127.0.0.1:1082...
- 已连接至 127.0.0.1 (127.0.0.1) 端口 1082
- CONNECT 通道:HTTP/1.1 已协商
- 分配连接缓冲区
- 建立 HTTP 代理通道至 hnd1.aihub.zeabur.ai:443
CONNECT hnd1.aihub.zeabur.ai:443 HTTP/1.1
Host: hnd1.aihub.zeabur.ai:443
User-Agent: curl/8.7.1
Proxy-Connection: Keep-Alive
< HTTP/1.1 200 Connection established
<
- CONNECT 阶段完成
- CONNECT 通道已建立,响应 200
- ALPN: curl 提供 h2,http/1.1
- (304) (OUT), TLS 握手, Client hello (1):
- CAfile: /etc/ssl/cert.pem
- CApath: none
- (304) (IN), TLS 握手, Server hello (2):
- (304) (IN), TLS 握手, Unknown (8):
- (304) (IN), TLS 握手, Certificate (11):
- (304) (IN), TLS 握手, CERT verify (15):
- (304) (IN), TLS 握手, Finished (20):
- (304) (OUT), TLS 握手, Finished (20):
- 使用 TLSv1.3 / AEAD-AES128-GCM-SHA256 / [blank] / UNDEF 的 SSL 连接
- ALPN: 服务器接受 h2
- 服务器证书:
- 主题:CN=*.aihub.zeabur.ai
- 开始日期:Nov 4 00:00:00 2025 GMT
- 过期日期:Dec 3 23:59:59 2026 GMT
- subjectAltName: 主机 "hnd1.aihub.zeabur.ai" 符合证书的 "*.aihub.zeabur.ai"
- 发行者:C=US; O=Amazon; CN=Amazon RSA 2048 M04
- SSL 证书验证成功。
- 使用 HTTP/2
- [HTTP/2] [1] 为 https://hnd1.aihub.zeabur.ai/v1/chat/completions 开启流
- [HTTP/2] [1] [:method: POST]
- [HTTP/2] [1] [:scheme: https]
- [HTTP/2] [1] [:authority: hnd1.aihub.zeabur.ai]
- [HTTP/2] [1] [:path: /v1/chat/completions]
- [HTTP/2] [1] [user-agent: curl/8.7.1]
- [HTTP/2] [1] [accept: /]
- [HTTP/2] [1] [authorization: Bearer sk-RHb3riFzAGJb7D2QxJsekw]
- [HTTP/2] [1] [content-type: application/json]
- [HTTP/2] [1] [content-length: 70]
POST /v1/chat/completions HTTP/2
Host: hnd1.aihub.zeabur.ai
User-Agent: curl/8.7.1
Accept: /
Authorization: Bearer sk-RHb3riFzAGJb7D2QxJsekw
Content-Type: application/json
Content-Length: 70
- 上传已完全发送:70 bytes
< HTTP/2 401
< content-type: application/json
< content-length: 198
< date: Thu, 21 May 2026 00:34:28 GMT
< server: uvicorn
< x-cache: Error from cloudfront
< via: 1.1 0391390c8a406ba1a7bd713ed630aaa8.cloudfront.net (CloudFront)
< x-amz-cf-pop: LAX53-P2
< x-amz-cf-id: nFIaSA_Emt1W05rOE1WKZsbRZDIAN1hnBIb6uKdXvkLnD9f5VbBZ5Q==
<
- 连接 #0 至主机 127.0.0.1 保持完整
{"error":{"message":"user not allowed to access model. This user can only access models=['no_default_models']. Tried to access gpt-5","type":"user_model_access_denied","param":"model","code":"401"}}%