Exemple #1
0
def register():
    api = EPyTodoAPI()
    return api.register_user(request.json)
Exemple #2
0
def add_task():
    api = EPyTodoAPI()
    return api.add_task(request.json)
Exemple #3
0
def delete_task(id: int):
    api = EPyTodoAPI()
    return api.delete_task(id)
Exemple #4
0
def get_or_update_task(id: int):
    api = EPyTodoAPI()
    if request.method == "POST":
        return api.update_task(id, request.json)
    return api.get_task_infos(id)
Exemple #5
0
def tasks():
    api = EPyTodoAPI()
    return api.get_all_user_tasks()
Exemple #6
0
def user():
    api = EPyTodoAPI()
    return api.get_user_infos()
Exemple #7
0
def logout():
    api = EPyTodoAPI()
    return api.logout_user()
Exemple #8
0
def login():
    api = EPyTodoAPI()
    return api.login_user(request.json)