refactor be endpoints