Upload multiple thumbnail images to Google Drive API file?

288 views Asked by At

Using Google Drive API's files.patch, is it possible to provide multiple thumbnail images? Like, a thumbnail for each page of a custom document? The PDF Drive popup preview does this, but how can I?

This is an example of patching the metadata (with javascript); notice that it only allows one thumbnail as documented.

gapi.client.drive.files.patch(
{
        'fileId': file_id,
        'thumbnail':
        {
            'image': thumb_base64urlsafe_data,
            'mimeType': thumb_mimetype
        }
}
1

There are 1 answers

0
Dan McGrath On BEST ANSWER

No, this is not possible. You can submit a single thumbnail for a resource.

Our previewer does its own custom rendering of PDF's to be able to display it.