added duplicate check and database

This commit is contained in:
Christian Krakau-Louis
2025-03-25 13:55:15 +01:00
parent 19c763e595
commit 5eb8fa586b
5 changed files with 125 additions and 20 deletions
+5
View File
@@ -2,6 +2,7 @@
import os
from fastapi import FastAPI, HTTPException, UploadFile, File
from app.database import init_db
from app.config import settings
from app.tasks.upload_to_s3 import upload_to_s3
from app.tasks.upload_to_dropbox import upload_to_dropbox
@@ -12,6 +13,10 @@ from app.frontend import router as frontend_router
app = FastAPI(title="Document Processing API")
@app.on_event("startup")
def on_startup():
init_db() # Create tables if they don't exist
@app.get("/")
def root():
return {"message": "Document Processing API"}