Skip to content

support websocket #204

@gptq

Description

@gptq

Is your feature request related to a problem? Please describe.
I'm always frustrated when reverse_proxy with websocket .Streaming output like gpt

Describe the solution you'd like

{"level":"info","ts":1721899225.2968636,"logger":"http.log.access.log1","msg":"handled request","request":{"remote_ip":"6.11.1.7","remote_port":"37900","client_ip":"6.11.1.7","proto":"HTTP/2.0","method":"POST","host":"api.aigc.it","uri":"/v1/messages","headers":{"Priority":["u=1, i"],"Sec-Ch-Ua":[""Not/A)Brand";v="8", "Chromium";v="126", "Microsoft Edge";v="126", "Microsoft Edge WebView2";v="126""],"Anthropic-Version":["2023-06-01"],"Accept-Encoding":["gzip, deflate, br, zstd"],"Accept":["application/json, text/event-stream"],"X-Api-Key":["sk-1224"],"Referer":["http://tauri.localhost/"],"Sec-Fetch-Site":["cross-site"],"Sec-Fetch-Mode":["cors"],"Accept-Language":["zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6"],"Content-Type":["application/json"],"Sec-Ch-Ua-Platform":[""Windows""],"Origin":["http://tauri.localhost"],"Sec-Fetch-Dest":["empty"],"Content-Length":["345"],"Sec-Ch-Ua-Mobile":["?0"],"User-Agent":["Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0"]},"tls":{"resumed":false,"version":772,"cipher_suite":4865,"proto":"h2","server_name":"api.aigc.it"}},"bytes_read":345,"user_id":"","duration":0.000292049,"size":1249,"status":403,"resp_headers":{"Alt-Svc":["h3=":443"; ma=2592000"],"X-Teler-Msg":["Detects self-executing JavaScript functions"],"X-Teler-Threat":["CommonWebAttack"],"X-Teler-Req-Id":["bff3912d17180f1127c6"],"Content-Type":["text/html"],"Server":["Caddy"]}}

Describe alternatives you've considered
None yet

Additional context
None yet

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions