From e136e957baa2557cabb864e18c2164019be8e8a6 Mon Sep 17 00:00:00 2001 From: xiaolitongxue666 Date: Fri, 20 Feb 2026 20:09:35 +0800 Subject: [PATCH] feat(huiwings): add location /api/v1/coze/ for coze_fastapi proxy Add coze API route to huiwings ai.conf for alchemy-studio.cn deployment Co-authored-by: Cursor --- conf/huiwings/ai.conf | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/conf/huiwings/ai.conf b/conf/huiwings/ai.conf index 30bc339..2013749 100644 --- a/conf/huiwings/ai.conf +++ b/conf/huiwings/ai.conf @@ -49,4 +49,18 @@ server { proxy_pass http://127.0.0.1:5000/; } + + location /api/v1/coze/ { + proxy_set_header Host $host; + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Methods 'GET, POST, OPTIONS' always; + add_header Access-Control-Allow-Headers 'Authorization,HtyAdminToken,HtySudoerToken,HtyHost,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type' always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Max-Age 86400 always; + if ($request_method = 'OPTIONS') { + return 200; + } + + proxy_pass http://127.0.0.1:6000/; + } }