Gregniuki commited on
Commit
5446ba7
β€’
1 Parent(s): 8f9e79a

Rename main to app.py

Browse files
Files changed (1) hide show
  1. main β†’ app.py +4 -2
main β†’ app.py RENAMED
@@ -1,7 +1,9 @@
1
  from fastapi import FastAPI
2
 
 
3
  app = FastAPI()
4
 
 
5
  @app.get("/")
6
- async def read_root():
7
- return {"Hello": "World!"}
 
1
  from fastapi import FastAPI
2
 
3
+ # Create an instance of the FastAPI class
4
  app = FastAPI()
5
 
6
+ # Define a route for the root endpoint
7
  @app.get("/")
8
+ def read_root():
9
+ return {"message": "Hello, World!"}