Skip to content

feat(storage): add create_signed_upload_urls batch helper - #1566

Open
OscarTheWhiteHatHacker wants to merge 1 commit into
supabase:mainfrom
OscarTheWhiteHatHacker:feat/create-signed-upload-urls
Open

feat(storage): add create_signed_upload_urls batch helper#1566
OscarTheWhiteHatHacker wants to merge 1 commit into
supabase:mainfrom
OscarTheWhiteHatHacker:feat/create-signed-upload-urls

Conversation

@OscarTheWhiteHatHacker

Copy link
Copy Markdown

Summary

Adds create_signed_upload_urls(paths, options) to the Storage client, a batch convenience helper that signs upload URLs for multiple object paths at once — mirroring the existing create_signed_urls() download API.

The Storage API does not expose a bulk endpoint for signed upload URLs, so each path is signed individually via the existing create_signed_upload_url() (as proposed in the issue). This removes manual per-path iteration for workflows like multi-image uploads or drag-and-drop batches.

Closes #1559.

What changed

  • _async/file_api.py: new async create_signed_upload_urls signing each path sequentially.
  • _sync/file_api.py: matching sync implementation (kept in parity with the async source used by the unasync generator).
  • tests/test_client.py: offline unit tests (no infra needed) covering the sync + async batch methods and option forwarding. They verify each path is signed, results are returned in order, and x-upsert headers are forwarded.

Verification

  • pytest tests/test_client.py — 22 passed (3 new)
  • mypy src/storage3 tests — no issues
  • ruff check and ruff format --check on changed files — clean

cc @olirice @silentworks

Adds a batch convenience helper to the Storage client that signs
upload URLs for multiple object paths at once, mirroring the existing
create_signed_urls() download API.

The Storage API does not expose a bulk endpoint for signed upload
URLs, so each path is signed individually via create_signed_upload_url.
Sync and async clients both get the new method; options apply to every
path. Closes supabase#1559.
@OscarTheWhiteHatHacker
OscarTheWhiteHatHacker requested review from a team and o-santi as code owners August 7, 2026 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add create_signed_upload_urls() helper to the Python Storage client

1 participant