Exemplo n.º 1
0
def create():
    request_data = get_json(request)

    columns = ', '.join(request_data.keys())
    values = get_values(request_data)

    code, response = Post.insert(columns, values, request_data)
    return json.dumps(
        {'code': code,
         'response': response}
    )