add events to json controller for error handler