# Render PDF in visualizer

**URL:** <https://community.postman.com/t/render-pdf-in-visualizer/9193>\
**Category:** Help Hub\
**Created:** [November 22, 2019, 7:26pm UTC](https://community.postman.com/t/render-pdf-in-visualizer/9193 "2019-11-22T19:26:47Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![odanylewycz](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/odanylewycz/32/3240_2.png) [@odanylewycz](https://community.postman.com/u/odanylewycz)\
**Post date:** [November 27, 2019, 5:59pm UTC](https://community.postman.com/t/render-pdf-in-visualizer/9193/4 "2019-11-27T17:59:58Z")

</div>

Hi @john-paul,

When I saw this, it really intrigued me, so I dove in…

From my current testing, it doesnt seem to be possible give then way I was doing it (refer below)

`<object data="data:application/pdf;base64,base64_data_goes_here></object>`

- you can also do `<embed>` or `<iframe>`

The problem I found was this:

`Refused to frame '' because it violates the following Content Security Policy directive: "frame-src 'none'".`

`Refused to load plugin data from 'data:application/pdf;base64,base64_data_here' because it violates the following Content Security Policy directive: "object-src 'none'".`

So Snooping around the html that Postman preloads, I found this:

`<meta http-equiv="Content-Security-Policy" content="default-src 'none'; script-src http: https: 'unsafe-inline'; style-src http: https: 'unsafe-inline' ; img-src http: https: data:; font-src http: https:; connect-src http: https:; media-src http: https:; object-src 'none'; child-src 'none'; frame-src 'none'">`

This is what its complaining about. So if I removed a buncha these tags (defaulf-src, object-src, frame-src), I was able to get a pdf to render! In chrome that is…

But, when sending a request, a new html file is made every time in the temp directory, so there is no way I can get around the auto generated html they have.

However, I should say that the HTML they have in there is regarded as best practice, so nothing bad on their end 😄.

I havent tried javascript libraries (like pdf.js), but I forsee similar issues happening, but I cant confirm that.

I’d say you make this a feature request here #feature-requests.

Hope this helps! (I was secretly hoping I could get this to work)

Orest

---

_[View the full topic](https://community.postman.com/t/render-pdf-in-visualizer/9193)._
