adding mail apis and fix the user creation