code: def permission_denied(self, request, message=None):
          
          if not request.successful_authenticator:
              raise exceptions.NotAuthenticated()
          raise exceptions.PermissionDenied(detail=message)
docs: If request is not permitted, determine what kind of exception to raise.