I'm making a call to an API to download a PDF and I receive it back in the request body. The end goal is getting that PDF and emailing it through our own system.
Assuming we don't want to keep the file stored on our filesystem, is there a recommended way for me to get that PDF and send it without permanently storing it?
I have it working right now, but I'm currently creating and storing the PDF file from the response payload, and then sending it. I'm not familiar with whether or not there are best practices for handling temporary files. Otherwise, I could always just make my own temporary directory and delete the file afterwards.
I'm using CentOS with Laravel 5.1.
Thanks in advance.
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire