RockyBai commited on
Commit
5cd697b
·
verified ·
1 Parent(s): 0ccc516

Update api.py

Browse files
Files changed (1) hide show
  1. api.py +13 -0
api.py CHANGED
@@ -203,6 +203,19 @@ def check_hybrid_duplicate(lat, lon, issue_type, current_time, pil_image, descri
203
 
204
  return False, None
205
 
 
 
 
 
 
 
 
 
 
 
 
 
 
206
  @app.post("/sync-history")
207
  async def sync_history(items: List[HistoryItem]):
208
  """
 
203
 
204
  return False, None
205
 
206
+ return False, None
207
+
208
+ # --- MODELS ---
209
+ from pydantic import BaseModel
210
+
211
+ class HistoryItem(BaseModel):
212
+ lat: float
213
+ lon: float
214
+ issue: str
215
+ time: float
216
+ user: str
217
+ hash: Optional[str] = None
218
+
219
  @app.post("/sync-history")
220
  async def sync_history(items: List[HistoryItem]):
221
  """