Add Basic Authentication, Add error handler