Skip to main content
File Transfer Pavan’s upload service orchestrates every file upload to Supabase Storage. It validates files through a server-side RPC, generates secure share tokens, and provides two modes: single file uploads and bundled file collections. This guide covers both workflows so you can choose the right option for your needs.

Single File Upload

Upload one file at a time with optional PIN or password protection and a real-time progress bar.

File Collection

Bundle multiple files into a single shareable link. Recipients download all files as a ZIP.

Uploading a Single File

Use single file upload when you want to share one file quickly with a unique link.
1

Open the dashboard or home page

Navigate to the File Transfer Pavan home page or your Dashboard.
2

Add a file to the upload zone

Drag and drop a file onto the upload zone, or click the zone to open your file picker.
3

Set optional protection

Add a numeric PIN to restrict access to the download page, and/or a password for additional security. Passwords are hashed server-side with bcrypt and never stored in plain text.
4

Click Upload

The upload triggers the validate_file_upload() RPC to validate the file, then streams the file to Supabase Storage.
5

Track progress

A real-time progress bar shows upload speed and estimated time to completion.
6

Get your share link

On completion, a cryptographically secure share token and link are generated automatically. Copy the link from the success dialog.

Uploading a File Collection

Use file collections when you want to share several files under one link, with a single PIN or password for the whole group.
1

Select multiple files

Choose multiple files. Up to three files upload concurrently at a time.
2

Name and describe the collection

Optionally add a collection name and description to help recipients understand the bundle.
3

Set collection-level protection

Apply a numeric PIN and/or password to the entire collection. Everyone accessing the collection uses the same credentials.
4

Upload

The system manages parallel uploads (up to three at once). Progress is shown for each file.
5

Share the collection link

After upload, you receive a single collection link. Recipients can view the file list and download everything as a ZIP archive.

Security Options

PIN protection adds a numeric code required to access the download page. Recipients must enter the PIN at the PinAccess.tsx page before they can download.
Password protection uses bcrypt hashing on the PostgreSQL server via the insert_file_with_password() RPC. The password is never stored in plain text and is never hashed on the client side. Brute-force cost is set high enough to deter automated guessing.
Cryptographic tokens are URL-safe and generated using a secure random source. The system handles both standard random token generation and base64 variant encoding for compatibility across platforms and messaging apps.

File Previews

Recipients can preview supported file types before downloading:

Upload RPC Functions

These Supabase RPC functions power the upload workflow:

Next Steps