mjs-07 commited on
Commit
013b2e7
·
1 Parent(s): cb019f8

Day 1 - FastAPI backend initialized

Browse files
Files changed (2) hide show
  1. .gitignore +4 -0
  2. backend/app/main.py +13 -0
.gitignore ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ venv/
2
+ __pycache__/
3
+ *.pyc
4
+ .env
backend/app/main.py ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from fastapi import FastAPI # Import FastAPI framework
2
+
3
+ app = FastAPI() # Restaurant Created
4
+
5
+ @app.get("/") # When someone visits '/', run the below function.
6
+ # This is the first endpoint
7
+ def home():
8
+ return {"message": "AI claim verifier backend is running!"}
9
+
10
+ @app.get("/ai") # When someone visits '/health', run the below function
11
+ # This is the second endpoint
12
+ def model():
13
+ return {"status": "working"}