added error logging to mogreet api