Adding REST endpoints