change api base class to nsobject