updates so the config unit test runs successfully after the addition of apiMode config option. Also removing legacy callback code that is no longer used.