-
-
Save jennielees/cebac0ac3f11c3c85040 to your computer and use it in GitHub Desktop.
Static API
This file contains 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
from flask import Flask, jsonify | |
app = Flask(__name__) | |
SIMPLE_DICTIONARY = { | |
"Lannisters": ["Cersei", "Jaime", "Tyrion"], | |
"Baratheons": ["Robert", "Renly", "Stannis"] | |
} | |
@app.route('/') | |
def index(): | |
return jsonify(SIMPLE_DICTIONARY) | |
if __name__ == '__main__': | |
app.run(debug=True) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment