title: How to add file in an pre-request script using form data on Postman
body: <p>I am trying to create a request in the pre-request script using in the form-data and in the body i would like to upload a pdf file from my working directory.</p>
  <p>I used the following script and the file is not attached in my script.
  Can you please help me to identify my problem?</p>
  <pre><code>&quot;body&quot;:{ 
          &quot;mode&quot;: &quot;formdata&quot;,
          &quot;formdata&quot;: [
              { &quot;key&quot; : &quot;file&quot;,&quot;value&quot;: &quot;X:\\Postman\\files\\test.pdf&quot;, &quot;disabled&quot; : false, &quot;description&quot; : {&quot;content&quot; :&quot;&quot;, &quot;type&quot; :&quot;file&quot;}},
              { &quot;key&quot; : &quot;text&quot;,&quot;value&quot;: &quot;text&quot;, &quot;disabled&quot; : false, &quot;description&quot; : {&quot;content&quot; :&quot;&quot;, &quot;type&quot; :&quot;text&quot;}},
              { &quot;key&quot; : &quot;Number&quot;,&quot;value&quot;: &quot;12345686&quot;, &quot;disabled&quot; : false, &quot;description&quot; : {&quot;content&quot; :&quot;&quot;, &quot;type&quot; :&quot;text&quot;}},
              { &quot;key&quot; : &quot;Text&quot;,&quot;value&quot;: &quot;0011002327&quot;, &quot;disabled&quot; : false, &quot;description&quot; : {&quot;content&quot; :&quot;&quot;, &quot;type&quot; :&quot;text&quot;}},  
              { &quot;key&quot; : &quot;Date&quot;,&quot;value&quot;: &quot;02/12/2020&quot;, &quot;disabled&quot; : false, &quot;description&quot; : {&quot;content&quot; :&quot;&quot;, &quot;type&quot; :&quot;text&quot;}}
          ]}  
  </code></pre>