Created
November 11, 2015 01:04
-
-
Save zhehaowang/b4ac0890d6473f2e31e5 to your computer and use it in GitHub Desktop.
BaiduPan Python API get download url, so that we don't need to use YunGuanJia
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from baidupcsapi import PCS | |
pcs = PCS('XXX','XXX') | |
print pcs.quota().content | |
print pcs.list_files('/').content | |
headers = {'Range': 'bytes=0-99'} | |
ret = pcs.download('/README.md', headers=headers) | |
print(ret.text) | |
ret1 = pcs.download_url(['/README.md'], headers=headers) | |
print(ret1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment