Shouldn't cut and paste without updating the function name in the debugMSG; the issue was in checkForServiceAPI, not getToken.