Ruby class to take a URL template and traverse pages on a website