#sudo apt install poppler-utils

curl -s "<url of pdf file>" | pdftotext -layout - -