modied the API class by adding autoload sub classes