Update app.py
Browse files
app.py
CHANGED
|
@@ -1,7 +1,11 @@
|
|
| 1 |
from fastapi import FastAPI
|
|
|
|
| 2 |
|
| 3 |
app = FastAPI()
|
| 4 |
|
|
|
|
|
|
|
|
|
|
| 5 |
@app.get("/")
|
| 6 |
-
def
|
| 7 |
-
return {"
|
|
|
|
| 1 |
from fastapi import FastAPI
|
| 2 |
+
from routes.hello import router as hello_router
|
| 3 |
|
| 4 |
app = FastAPI()
|
| 5 |
|
| 6 |
+
# Incluindo a rota separada
|
| 7 |
+
app.include_router(hello_router)
|
| 8 |
+
|
| 9 |
@app.get("/")
|
| 10 |
+
def root():
|
| 11 |
+
return {"message": "Welcome to the API!"}
|