guys anyone know how to intregrate express js with...
# help
m
guys anyone know how to intregrate express js with supabase storage i tried to upload file and here is what happen, here is the code
Copy code
js
router.post('/test', async (req, res) => {
  const { files } = req;
  const { data, error } = await supabase.storage
    .from('avatars')
    .upload('acara/test.html', files)
    console.log(data);
    console.log(error);
});
n
Hello @mycatisred! This thread has been automatically created from your message in #843999948717555735 a few seconds ago. We have already mentioned the @User so that they can see your message and help you as soon as possible! Want to unsubscribe from this thread? Right-click the thread in Discord (or use the ``...`` menu) and select "Leave Thread" to unsubscribe from future updates. Want to change the title? Use the ``/title`` command! We have solved your problem? Click the button below to archive it.
🆕 Express js + Storage
a
I suspect that `{ files }`is not what supabase expects it to be. I think that
req
is not the file itself. Maybe this can help you a bit further http://expressjs.com/en/resources/middleware/multer.html
n
Express js + Storage
m
thank u so much
n
Thread was archived by @mycatisred. Anyone can send a message to unarchive it.