A perfectly asynchronous DisBox API framework.
Project description
disboxpy
A perfectly asynchronous DisBox API framework.
How to install
- install this package with pip (later)
pip install disboxpy
- import to your Python project
from disboxpy import DisBox
client = DisBox(your_webhook_url)
How to use
For example, you can get information about any file by id or file's name.
import asyncio
async def main():
print(await client.get_file_info(10704, "test folder"))
if __name__ == "__main__":
asyncio.run(main())
Output:
{
'id': 10704,
'parent_id': 10636,
'name': 'test_image.jpg',
'type': 'file',
'size': 48367,
'content': ['1164839406260203542'],
'created_at': '2023-10-20T08:15:55.292Z',
'updated_at': '2023-10-26T17:31:29.159Z'
}
Or if you want to download something
import asyncio
async def main():
await client.download_file(10704, "test folder")
if __name__ == "__main__":
asyncio.run(main())
Output:
[FILE] test_image.jpg file is successfully downloaded! (47.23 KB)
Other examples in examples
directory. You can check it.
Todo
- upload_file & upload_folder
- delete_file & delete_folder
- rename_file & rename_folder
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for disboxpy-1.0.0rc0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2d51e739988d663ee2918a4a9993ea150c077f389917b7b7daddc1b0cf56ef32 |
|
MD5 | 052db1dedfa59072abc9e60bcab55bcc |
|
BLAKE2b-256 | 837f3fe72ada2e8a95eb6f56b1bf9761fb59ab7ca8f8d333147eee454f3ecfdd |