added cloud based login functionality and mongoose schema