added image api endpoint to change user avatar