tanbushi commited on
Commit
6df2efa
·
1 Parent(s): acc8ad9
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -68,12 +68,12 @@ async def proxy_gemini(request: Request, protocol: ProtocolType, host:str, path:
68
 
69
  # 移除FastAPI自带的Host头,避免Gemini校验报错
70
  client_headers.pop("host", None)
71
-
72
  # 将User-Agent改为curl/8.7.1,以模拟curl请求
73
  client_headers["User-Agent"] = "curl/8.7.1"
74
 
75
  # 获取API密钥信息
76
- api_key_info = await get_api_key_info()
77
 
78
  return api_key_info
79
 
 
68
 
69
  # 移除FastAPI自带的Host头,避免Gemini校验报错
70
  client_headers.pop("host", None)
71
+
72
  # 将User-Agent改为curl/8.7.1,以模拟curl请求
73
  client_headers["User-Agent"] = "curl/8.7.1"
74
 
75
  # 获取API密钥信息
76
+ api_key_info = await get_api_key_info('gemini-2.5-flash')
77
 
78
  return api_key_info
79