2015-07-04 42 views
0

我的网站有很多图片,我要上传的所有图像,以谷歌的磁盘,你可以帮我,我怎么可以从链接文件到谷歌盘,无需下载到我的主机和上传到谷歌磁盘后。如何将文件上传到谷歌磁盘API

例如yandex disk这个API,但在谷歌,我不能找到足够的细节

回答

1

1 - 您可以使用PyDrive
这是它如何工作的:

from pydrive.auth import GoogleAuth 
from pydrive.drive import GoogleDrive 

gauth = GoogleAuth() 
gauth.LocalWebserverAuth() 
drive = GoogleDrive(gauth) 
my_file = #the file you want to be uploaded or sth else 
my_file.Upload() 

2 - 或者你可以还没有被很好地证明谷歌这里submit your app包装的帮助下运行你的应用程序,然后这里upload

相关问题