Skip to main content

Supabase Storage client for Python.

Project description

Storage-py

Python Client library to interact with Supabase Storage.

How to use

As it takes some effort to get the headers. We suggest that you use the storage functionality through the main Supabase Python Client

from storage3 import AsyncStorageClient

url = "https://<your_supabase_id>.supabase.co/storage/v1"
key = "<your api key>"
headers = {"apiKey": key, "Authorization": f"Bearer {key}"}

storage_client = AsyncStorageClient(url, headers)

async def get_buckets():
  await storage_client.list_buckets()

Uploading files

When uploading files, make sure to set the correct mimetype by using the file_options argument:

async def file_upload():
  await storage_client.from_("bucket").upload("/folder/file.png", file_object, {"content-type": "image/png"})

If no mime type is given, the default text/plain will be used.

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

storage3-2.28.2.tar.gz (20.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

storage3-2.28.2-py3-none-any.whl (28.2 kB view details)

Uploaded Python 3

File details

Details for the file storage3-2.28.2.tar.gz.

File metadata

  • Download URL: storage3-2.28.2.tar.gz
  • Upload date:
  • Size: 20.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.8.2

File hashes

Hashes for storage3-2.28.2.tar.gz
Algorithm Hash digest
SHA256 da91700de2579605e28bef7b9c30f25e0281d57867fd721ea20baf12c1bf2cc0
MD5 2d6cc83d5e5a00c40ce4c76a596f0727
BLAKE2b-256 3dc5f2463a1b8f4a63da5f6256bc28070489db289c15a8c3fd819fc2170ab648

See more details on using hashes here.

File details

Details for the file storage3-2.28.2-py3-none-any.whl.

File metadata

  • Download URL: storage3-2.28.2-py3-none-any.whl
  • Upload date:
  • Size: 28.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.8.2

File hashes

Hashes for storage3-2.28.2-py3-none-any.whl
Algorithm Hash digest
SHA256 2ed66d048d7f2e9b549a66f16aa41080991f460b6c3a6897d45e27185a6a46a7
MD5 a46e46993875bc58925a4059d141095e
BLAKE2b-256 42aa7cd66c2eea089e0e35d8d0d0b6610a48a7561e8659706b340b518b3225f5

See more details on using hashes here.

Supported by

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