The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
fix: add bearer token to resumable-upload-uppy example (#18789)
RilDevb8707817b6b9
diff --git a/examples/storage/resumable-upload-uppy/README.md b/examples/storage/resumable-upload-uppy/README.mdindex bbf4c94a6e4..7d8f2d31420 100644--- a/examples/storage/resumable-upload-uppy/README.md+++ b/examples/storage/resumable-upload-uppy/README.md@@ -13,6 +13,7 @@ This example shows how to use [Supabase Storage](https://supabase.io/docs/refereconst SUPABASE_ANON_KEY = '' // your project's anon keyconst SUPABASE_PROJECT_ID = '' // your project refconst STORAGE_BUCKET = '' // your storage bucket name+const BEARER_TOKEN = '' // your bearer token```Serve the index.html file locally (e.g. with Python Simple HTTP Server) and start uploading:diff --git a/examples/storage/resumable-upload-uppy/index.html b/examples/storage/resumable-upload-uppy/index.htmlindex 450ec4da0b2..437a7885819 100644--- a/examples/storage/resumable-upload-uppy/index.html+++ b/examples/storage/resumable-upload-uppy/index.html@@ -44,9 +44,10 @@Tus,} from 'https://releases.transloadit.com/uppy/v3.6.1/uppy.min.mjs'- const SUPABASE_ANON_KEY = 'repace-with-your-anon-key'- const SUPABASE_PROJECT_ID = 'repace-with-your-project-id'- const STORAGE_BUCKET = 'repace-with-your-bucket-id'+ const SUPABASE_ANON_KEY = 'replace-with-your-anon-key'+ const SUPABASE_PROJECT_ID = 'replace-with-your-project-id'+ const STORAGE_BUCKET = 'replace-with-your-bucket-id'+ const BEARER_TOKEN='replace-with-your-bearer-token'const folder = ''const supabaseStorageURL = `https://${SUPABASE_PROJECT_ID}.supabase.co/storage/v1/upload/resumable`@@ -61,7 +62,7 @@.use(Tus, {endpoint: supabaseStorageURL,headers: {- authorization: `Bearer ${SUPABASE_ANON_KEY}`,+ authorization: `Bearer ${BEARER_TOKEN}`,apikey: SUPABASE_ANON_KEY,},uploadDataDuringCreation: true,