Added delete api functionality to the api views