Search code examples
iosgoogle-photos

iOS - Accessing photos from Google Drive account using Objective C


I am working on an application which needs access to Google Photos from Google Drive.

Is it possible to access it?

I am not referring to the images from the My Drive in Google Drive.


Solution

  • Yes it is possible please check below link i have updated my answer, you can also fetch photos from google drive like this

    GTLRDriveQuery_FilesList *query = [GTLRDriveQuery_FilesList query];
        query.q = @"mimeType='image/jpeg'";
        query.spaces = @"photos";
        query.pageSize = 200;
        query.fields = @"nextPageToken,files(id,name,mimeType,thumbnailLink,originalFilename)";
        [self.service executeQuery:query completionHandler:^(GTLRServiceTicket *ticket,
                                                             GTLRDrive_FileList *result, NSError *error)
    

    For full details check below link.

    Fetching Photos from google photos Objective c [iOS]