ReadFileAsBytes into Perspective PDF Viewer

Hi,

Is it possible to use fonction system.file.readFileAsBytes() and put the result into a Perspective PDF Viewer ?

With the WebDev module. (If you mean a file in the machine running the browser, no, not at all.)

Yes I made an API Post request to send me bytes of a PDF file on my server.

But How can I use my received bytes in my PDF Viewer ?

Make it a GET request so you can put the URL in the viewer.

It works.
How can I use basic Auth securely ?

Is it possible to download the showed PDF in the component ?