title: IOS: How to Download Google Docs files using ios google drive sdk API?
body: <p>I integrated google drivs sdk with my ios app. At present am using the following code to download the files from my google drive a/c based on download url link. But when i try to download the google docs files (which has mime type <strong>application/vnd.google-apps.document</strong>) there is no download url link from google drive library. In that case how can i download the google docs data?. Can i use <strong>alternateLink</strong> instead of download url link?. Any help must be appreciated.</p>
  
  <p><strong>My Code:</strong></p>
  
  <pre><code>- (void)loadFileContent {
  
  GTMHTTPFetcher *fetcher =
  [self.driveService.fetcherService fetcherWithURLString:[[self.driveFiles objectAtIndex:selectedFileIdx] downloadUrl]];
  
  [fetcher beginFetchWithCompletionHandler:^(NSData *data, NSError *error) {
      if (error == nil) {
          NSLog(@"\nfile %@ downloaded successfully from google drive", [[self.driveFiles objectAtIndex:selectedFileIdx] originalFilename]);
  
          //saving the downloaded data into temporary location
  
      } else {
          NSLog(@"An error occurred: %@", error);            
  
      }
  }];
  </code></pre>
  
  <p>}</p>