Moved a couple steps away from Flask, parameterized the SQL queries, threw all the API keys and connection notes into a globals.py file.