this is my issue; I want to send fax dynamically, the content of the fax is a PDF In order to make this PDF available for Twilio Fax API I have upload the PDF as an asset to Twilio, but I do not see any way to achieve this, I have programmatically created assets, but there is no way (at least I can not see one) to attach a PDF as the 'content' of the asset, maybe I'm wrong and there is other way to make those PDF's available for Twilio Fax API
Any help is appreciated Thanks!
Twilio developer evangelist here.
The Twilio Functions and Assets API is not the best avenue for just uploading a static file to be used as media in a fax. It's built for the creation of application bundles, which is why it comes with the concepts of builds and environments. To upload the actual file, you also need to create an Asset Version.
You could use the Assets section of the Twilio console to upload your PDF, then use the URL in the request.
Alternatively, if you want to do it programmatically, I'd recommend uploading your PDF to something like AWS S3, and then using the resulting URL as the
mediaUrlfor the fax API.Let me know if that helps at all.