added ApiStop() method