add typechecking for oauth user login