Started adding rest endpoint