Forgot to add authentication
Refactored and simplified with more information in output