def login_required(obj):
    decorator = request_passes_test(lambda r, *args, **kwargs: r.user.is_authenticated())
    return wrap_object(obj, decorator)
Requires that the user be logged in order to gain access to the resource
dataset/ETHPy150Open croach/django-simple-rest/simple_rest/auth/decorators.py/login_required