title: Exporting file from google drive using googleapi in node.js
body: <p>I am using googleapi to export the file from a google drive. I have the following code in my export.js. When I run this file, even though i have given the mimeType it throws an error saying "The API returned an error: Error: Required parameter: mimeType" </p>
  
  <pre><code>var drive = google.drive({
    version: 'v3',
    auth: auth
  });
  
  var dest = fs.createWriteStream('./public/data/myfile.txt');
  drive.files.export({
    fileId : fileID,
    mimeType : 'text/plain'
  }, function(err, response) {
    if (err) {
    console.log('The API returned an error: ' + err);
    return;
    }
    console.log('Received %d bytes', response.length);
    fs.writeFileSync(dest, response);
  });
  </code></pre>