Python SDK for UploadThing
Project description
Installation
pip install uploadthing.py
Quickstart
import asyncio, os
from uploadthing_py import UTApi
async def main():
utapi = UTApi(os.environ["UTAPI_KEY"])
# List the files in your app
res = await utapi.list_files()
print("List files:", res)
# Delete the first file from the list
key = res[0].key
res = await utapi.delete_file(key)
print("Delete file:", res)
# (TODO) Create a new file
# res = await utapi.upload_files()
if __name__ == "__main__":
asyncio.run(main())
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 Distribution
uploadthing_py-0.1.2.tar.gz
(3.8 kB
view hashes)
Built Distribution
Close
Hashes for uploadthing_py-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 06bdfd8b02f81de8600e59668cef37d42d1017867dd188514c156038ca7381ba |
|
MD5 | 2a992024697df278066fbea33013e299 |
|
BLAKE2b-256 | 71d899f40463751ec6fdeda39076d190355271ad722cb599ad3dc799fce1c246 |