Update app.py
Browse files
app.py
CHANGED
|
@@ -25,8 +25,8 @@ def load_data():
|
|
| 25 |
def health():
|
| 26 |
return {"status": "ok", "rows": len(lookup)}
|
| 27 |
|
| 28 |
-
@app.get("/
|
| 29 |
-
def
|
| 30 |
score = lookup.get(domain)
|
| 31 |
if score is None:
|
| 32 |
raise HTTPException(status_code=404, detail="Domain not found")
|
|
|
|
| 25 |
def health():
|
| 26 |
return {"status": "ok", "rows": len(lookup)}
|
| 27 |
|
| 28 |
+
@app.get("/by_domain/{domain}")
|
| 29 |
+
def get_score_score(domain: str):
|
| 30 |
score = lookup.get(domain)
|
| 31 |
if score is None:
|
| 32 |
raise HTTPException(status_code=404, detail="Domain not found")
|