[c++ engine] refactored engine to start working;
[apiserver] refactored client code to use authlevels;