# Automate Downloading of PDF Response

**URL:** <https://community.postman.com/t/automate-downloading-of-pdf-response/43867>\
**Category:** Help Hub\
**Tags:** response, pdf\
**Created:** [February 12, 2023, 7:38am UTC](https://community.postman.com/t/automate-downloading-of-pdf-response/43867 "2023-02-12T07:38:34Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ndavaz](https://avatars.discourse-cdn.com/v4/letter/n/3d9bf3/32.png) [@ndavaz](https://community.postman.com/u/ndavaz)\
**Post date:** [February 12, 2023, 7:38am UTC](https://community.postman.com/t/automate-downloading-of-pdf-response/43867/1 "2023-02-12T07:38:34Z")

</div>

Hi all,

I’m looking to automate a file download. In my case, I have a collection that is made of 4 calls (get auth token, search for document, get document url, view document). When running the collection in Postman, everything works correctly and I am able to view the document. I am also able to download the document using the Send and Download option or the Save Response to File option. However, I am interested in having the document automatically download to my local file store. Is this possible either directly in Postman or using Newman?

thank you,

---

<div class="post-metadata">

**Author:** ![michaelderekjones](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/michaelderekjones/32/14819_2.png) [@michaelderekjones](https://community.postman.com/u/michaelderekjones)\
**Post date:** [February 12, 2023, 3:58pm UTC](https://community.postman.com/t/automate-downloading-of-pdf-response/43867/2 "2023-02-12T15:58:38Z")

</div>

Did you search the forum, this question has been posed, many times. The following is the first one that returned when searching.

> [@Automatically to write the response data to a file](https://community.postman.com/t/automatically-to-write-the-response-data-to-a-file/37912):
>
> Hello. I need automatically to write the response data to a file (every day). How can this be done?

Short answer, Postman does not support access to the local file system in this way.

However, you can do this in Newman, but you need to know a bit of node.js.

> **[Postman: How to Write Files to Disk?](https://medium.com/apis-with-valentine/postman-how-to-write-files-to-disk-5ee398624a42)**
>
> Sooner or later you will ask yourself the question: how can a read or write files to disk when using Postman?

---

<div class="post-metadata">

**Author:** ![arlem](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/arlem/32/3078_2.png) [@arlem](https://community.postman.com/u/arlem)\
**Post date:** [February 13, 2023, 2:41pm UTC](https://community.postman.com/t/automate-downloading-of-pdf-response/43867/3 "2023-02-13T14:41:14Z")

</div>

Hey @ndavaz , welcome to the Postman community! 👋

As @michaelderekjones mentioned there are already a few solutions mentioned in the forum, the best way is probably to fork and follow the instructions in this collection: [Postman](https://www.postman.com/postman/workspace/postman-answers/documentation/3407886-888860dd-9e3c-4537-a78e-1c3f3db7535c?entity=&branch=&version=)

---

<div class="post-metadata">

**Author:** ![danny-dainton](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/danny-dainton/32/29401_2.png) [@danny-dainton](https://community.postman.com/u/danny-dainton)\
**Post date:** [October 11, 2023, 6:19pm UTC](https://community.postman.com/t/automate-downloading-of-pdf-response/43867/4 "2023-10-11T18:19:44Z")

</div>

Closed on October 11, 2023, 6:19pm UTC


