Skip to main content

PyYaDisk is a small wrapper over Yandex Disk Rest API V1

Project description

PyYaDisk

PyYaDisk is a wrapper over Yandex Disk Rest API V1. The library is in creation process. You can check realized features with our roadmap below.

Usage

from pyyadisk import YandexDisk

token = 'ya_oauth_token'
disk = YandexDisk(token=token)  # Make instance
print(disk.path('yandex/disk/path').get())  # Get path info
disk.path('old/yandex/disk/path').move('new/yandex/disk/path')  # Move by path
disk.path('old/yandex/disk/path').copy('new/yandex/disk/path')  # Copy by path
disk.path('yandex/disk/new_path').create()  # Make directory
disk.path('yandex/disk/path').create('new_path')  # Make directory in directory
disk.path('yandex/disk/path').delete()  # Delete directory
print(disk.path('yandex/disk/path').link())  # Get private link
print(disk.path('yandex/disk/path').share())  # Share path and get public link
disk.path('yandex/disk/path').unshare()  # Unshare path
print(disk.last_uploaded())  # Get last uploaded files info
print(disk.list_files())  # Get files list info
disk.path('yandex/disk/path').upload('/home/file.pdf')  # Upload file
disk.path('yandex/disk/path').upload_by_url('file.pdf', 'https://example.com/file.pdf')  # Upload file by url

Roadmap

  • OAuth authorization by token

/v1/disk

  • Get disk metadata

/v1/disk/resources

  • Get metadata of file or directory
  • Create directory
  • Delete file or directory
  • Move file or directory
  • Copy file or directory
  • Get download link (private)
  • Share directory or file and get public link
  • Get download link (public)
  • Get list of files
  • Get last uploaded files
  • Upload file
  • Upload file by url

/v1/disk/resources/save-to-disk

  • Save public file to disk by public key or url

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyyadisk-0.1.2.tar.gz (6.2 kB view details)

Uploaded Source

Built Distribution

pyyadisk-0.1.2-py3-none-any.whl (7.2 kB view details)

Uploaded Python 3

File details

Details for the file pyyadisk-0.1.2.tar.gz.

File metadata

  • Download URL: pyyadisk-0.1.2.tar.gz
  • Upload date:
  • Size: 6.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.6.9

File hashes

Hashes for pyyadisk-0.1.2.tar.gz
Algorithm Hash digest
SHA256 d2aa864d4e04d0ee22816237caadb1786552db8e9a4440ae61ba89b0b70ad550
MD5 b8b65aea376d1ec2f14a368bdb9eaa60
BLAKE2b-256 13838cde1acc7c0d8b91693843ed850b75ec5f5baacb12d8539440d45f60b896

See more details on using hashes here.

File details

Details for the file pyyadisk-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: pyyadisk-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 7.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.6.9

File hashes

Hashes for pyyadisk-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 8cb5bee52294971cb697344f48fe63972f5055b916e0a74e47a8e785ed22f69b
MD5 d3917567fec8898ae69a0827cd7363ee
BLAKE2b-256 8704acd4a91ce63b3bd5ef0d30db7842611d0318b6bb624d85657cb9876b6152

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page