Refactor of web API to all entity models