Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the endpoint export #189

Open
edd34 opened this issue Jul 4, 2022 · 1 comment
Open

Add the endpoint export #189

edd34 opened this issue Jul 4, 2022 · 1 comment

Comments

@edd34
Copy link

edd34 commented Jul 4, 2022

The endpoint GET https://www.googleapis.com/drive/v2/files/:fileId/export seems to be missing

https://developers.google.com/drive/api/v2/reference/files/export

It's a feature that allow you to download a HTML with CSS inlined version of a doc.

@edd34
Copy link
Author

edd34 commented Jul 19, 2022

I have found a solution here :

from pydrive2.drive import GoogleDriveFile
GoogleDriveFile myfile = GoogleDriveFile() # here an instance of GoogleDriveFile
myfile.metadata.get("exportLinks").get("text/html").text

This code snippet, gives you link of a html/css page you can download as a text file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants