Forum Academy Marketplace Showcase Pricing Features

Make a file private already uploaded

Hello there,

I am looking a way to make private a file already uploaded into my database.
Any thoughts on how to achieve this ?


If it is just one file change the uploader element by checking “make this file private”, upload the file again, change reference in the app.

The S3 storage that Bubble uses only allows for write once, read, and delete once. If you want to change anything about a file you will need to do the following, in the order given, to maintain database integrity:

  1. Delete the file from S3
  2. Delete all references (URL) to the file from your database
  3. Upload the new version of the file to S3
  4. Fill all the old references to the file with the reference (URL) to the new file

I get the file from an API, I do not use the bubble uploader. I have no way to make it private when I receive it.
I had in my mind to create an API call from my bubble app to my bubble app where I select the private option, and at the end of the workflow I delete from the file manager DB the file that wasn’t private. But not sure how to achieve that I am not really an expert with API.

If you receive the file in base64 you can use my back-end utilities to save the file. Use the action “Write from base 64” to create a Bubble file, you can even specify it as private and attach it to a specific thing. The action returns the URL handle of the file.

As well, after reading through your struggles with DocuSign, have you considered using their API to create a template from your stored PDF? You would only need to use Bubbles encoded in base 64?


Thanks Aaron I used your plugin.
The file I receive is not in base 64 but I encoded it in base64 in your action write from base64 and make it private. Then I delete the file I receive from API so I do not have 2 identical files in the DB

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.