Performance updates and api changes

* Fixed all class prototypes
* Now the api will return arrays of APObjects and APConnections with
search and fetch calls