Skip to content

Instantly share code, notes, and snippets.

@amalgjose
Created February 28, 2021 05:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save amalgjose/d038dd0e246e3d7d5a11a539099a0ab9 to your computer and use it in GitHub Desktop.
Save amalgjose/d038dd0e246e3d7d5a11a539099a0ab9 to your computer and use it in GitHub Desktop.
A sample GET API implementation using Python FastAPI. For more details, refer to https://amalgjose.com
from fastapi import FastAPI
app = FastAPI()
@app.get("/")
def my_first_get_api():
"""
Sample GET method implementation using FastAPI
:return:
"""
return {"Hello": "World"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment