SDK
Storage
File uploads, downloads and signed URLs.
Create the bucket once (CLI), then upload from the app:
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
File uploads, downloads and signed URLs.
npx @resultdev/cli storage create-bucket uploads # public
npx @resultdev/cli storage create-bucket private-docs --private
const { data } = await backend.storage.from("uploads").uploadAuto(file);
// data.key + data.url - save both to your database; data.url is directly
// usable for public buckets
list() require a signed-in user - anonymous calls are rejected.
Sign the user up or in first.await backend.storage.from("uploads").upload("avatars/me.png", file); // choose the key
const { data: blob } = await backend.storage.from("uploads").download(key);
await backend.storage.from("uploads").remove(key);
const { data: signed } = await backend.storage
.from("private-docs").createSignedUrl(key, 3600); // seconds