Hmm, I tried it here now, and it fails anyway.
I’d guess it’s due to this:
Why won’t Ghostscript read piped PDF files?
Portable Document Format is a file format which contains forward
and backward links. It is not a stream format like PostScript.
You cannot pipe PDF files to the stdin of Ghostscript. Instead
you must either give the PDF filename on the command line, or
use it as the argument of the Ghostscript run command.
Ghostscript 8.00 and later can read piped PDF by copying
to a temporary file.
I could easily write some bash that would download the pdfs to tempfiles then feed them to gs
, but I’m guessing that won’t work since you can’t save files on heroku, right?