title: CUrl download result image from typeform results in log in page
body: <p>I'm rather new at using either curl or the typeform API, so not just anwsers are appreciated but also any links or tutorials to help me on my way.  </p>
  
  <p>The problem I am facing is that when I try to get my uploaded image on typeform using either curl or wget, it does not save the image but rather the log in page from typeform</p>
  
  <p><a href="https://admin.typeform.com/login/" rel="nofollow noreferrer">https://admin.typeform.com/login/</a> </p>
  
  <p>Recovering the download link itself using the API works fine. 
  I used the command  </p>
  
  <blockquote>
    <p>curl --request GET --url <a href="https://api.typeform.com/forms/aLsAcC/responses" rel="nofollow noreferrer">https://api.typeform.com/forms/aLsAcC/responses</a> --header 'Authorization: Bearer {MyId}'</p>
  </blockquote>
  
  <p>This wil return a JSON object with all responses. Inside this JSON file is the following block : </p>
  
  <pre><code>"field":{  
         "id":"SM3co23sAfCQ",  
          "type":"file_upload",  
          "ref":"2953330e-3c0b-4da3-bbb1-78a370152b10"  
          },  
  "type":"file_url",  
  "file_url":"https://admin.typeform.com/form/aLsAcC/field/SM3co23sAfCQ/results/1a4a6ab57b29-IMG_0354.JPG/download"  
  </code></pre>
  
  <p>But then when I try to actually download the file it doesn't seem to work.
  It doesn't matter if I run :   </p>
  
  <pre><code>curl -O https://admin.typeform.com/form/aLsAcC/field/SM3co23sAfCQ/results/1a4a6ab57b29-IMG_0354.JPG/download
  
  curl --request GET --url https://admin.typeform.com/form/aLsAcC/field/SM3co23sAfCQ/results/1a4a6ab57b29-IMG_0354.JPG/download --header 'Authorization: Bearer {MyId}'   
  or   
  wget https://admin.typeform.com/form/aLsAcC/field/SM3co23sAfCQ/results/1a4a6ab57b29-IMG_0354.JPG/download   
  </code></pre>
  
  <p>It always seems to give the same result. </p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
      &lt;head&gt;
          &lt;meta charset="UTF-8" /&gt;
          &lt;meta http-equiv="refresh" content="0;url=https://admin.typeform.com/login/" /&gt;
  
          &lt;title&gt;Redirecting to https://admin.typeform.com/login/&lt;/title&gt;
      &lt;/head&gt;
      &lt;body&gt;
          Redirecting to &lt;a href="https://admin.typeform.com/login/"&gt;https://admin.typeform.com/login/&lt;/a&gt;.
      &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Wich is simply the login page from the site. </p>
  
  <p>The weird thing is that when I use my browser itself it works just fine, so I suspect I am missing some form of authentication. It's probably a very simple problem, but google didn't really help on that front. </p>
  
  <p>So my question is, how do I download the response image. It doesn't matter if the final solution does not use curl, but a commandline tool or library is a must. </p>
  
  <p>Thanks. </p>