What is API command for prune single episode/whole show?

I have few houndreds various episodes/shows that I need to clean and I would rather do this in bulk having control what I am deleting instead of manually clicking using web browser interface. I would say curl -X POST but then what? /prune endpoint does not work