I'm attempting to expose a RESTful URL that returns a multi page document. With a PDF it's quite simple in my opinion.
GET /documents/12345.pdf
But I also wish to expose the same document with an image format where each page is a separate jpg. How would I best go about constructing the URL?
So far I'm torn between
GET /documents/12345/page1.jpg
or
GET /documents/12345.jpg?page=1
or
GET /document/12345?page=1&type=jpg
I know there is no absolute right way to do this I'm just looking for what is most intuitive. I've spent so much time looking at this that I can't tell which one I like best or even if there is an alternate approach that would be better.
Thanks!