Refactoring moving model-classes to foundation (messaging between hub
and agent)