File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed
Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -59,6 +59,8 @@ dependencies = [
5959 " Werkzeug==3.0.6" ,
6060 " wheel==0.38.1" ,
6161 " data-gemma" ,
62+ " datacommons" ,
63+ " datacommons_client" ,
6264]
6365
6466[tool .uv ]
Original file line number Diff line number Diff line change @@ -92,7 +92,11 @@ async def verify_claim():
9292 return jsonify ({"error" : "Missing 'claim' in request body." }), 400
9393
9494 # Get API Key from header
95+ # Get API Key from header or environment
9596 api_key = request .headers .get ('X-Gemini-Api-Key' )
97+ if not api_key :
98+ api_key = os .environ .get ('GENAI_API_KEY' ) or os .environ .get ('GOOGLE_API_KEY' )
99+
96100 if not api_key :
97101 return jsonify ({"error" : "Missing API Key" }), 401
98102
@@ -134,7 +138,11 @@ async def extract_claims():
134138 return jsonify ({"error" : "Missing 'text' in request body." }), 400
135139
136140 # Get API Key from header
141+ # Get API Key from header or environment
137142 api_key = request .headers .get ('X-Gemini-Api-Key' )
143+ if not api_key :
144+ api_key = os .environ .get ('GENAI_API_KEY' ) or os .environ .get ('GOOGLE_API_KEY' )
145+
138146 if not api_key :
139147 return jsonify ({"error" : "Missing API Key" }), 401
140148
You can’t perform that action at this time.
0 commit comments