Created
May 14, 2022 09:17
-
-
Save twyle/7250a91ec6f09de81b99d9cf9048e13b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
"""This module creates the routes for our API.""" | |
from API import app | |
@app.route('/index', methods=['GET']) | |
@app.route('/', methods=['GET']) | |
def index() -> dict: | |
"""Handle get requests to /index route. | |
Returns | |
------- | |
dict: | |
A dictionary showing: | |
{ | |
"data": 'Hello from github oauth json endpoint' | |
} | |
""" | |
data = { | |
"data": 'Hello from github oauth json endpoint' | |
} | |
return data, 200 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment