add model API layer foundation

* each model class has a corresponding *Api.js mixin module, whose
  exported functions are copied to the model class prototype on server
  startup
* the "global" model layer API is in a separate module (globalApi.js)
* the API functions are generally intended to be just a thin layer
  above existing model functionality, hence they should not normally
  require additional tests