add documentation for server; todo: add doc for angular controller