def hello(): if request.method == 'GET': return api_response( data={ 'test': 'hello world!' } ) elif request.method == 'POST': file = request.file[0][1] file.create('/Users/Eric/hahahaha.md') return request.file
def index(): session['haha'] = 'asdfasdf' return api_response(data=session.data, message='this is the session.')
def test(variable_data): return api_response(data=variable_data)
def post(self, i): variable_data = getattr(self, 'variable_data') return api_response(data=variable_data)