Fixed api gen scripts