Skip to content

Updating visuals

If you see any images containing outdated UI, please bear with us.

We are updating all content as quickly as possible to mirror our new UI.

Return

Save files with WeWeb Storage

Set up WeWeb Storage so users can upload files and you can save the file path for later use.

TEMPLATE AVAILABLE

If you wish to skip the manual setup, there is a workflow template available called Upload a File or Get Signed Download URL. You can find it inside the templates available when creating an API workflow.

Steps at a glance ​

  1. Enable WeWeb Storage in Data & API.
  2. Create an upload API from the WeWeb Storage template.
  3. Call that API from the Interface.
  4. Save the returned file path on the related record.

1) Enable WeWeb Storage ​

  1. Go to Data & API → Storage.
  2. Select WeWeb Storage.
  3. Choose the environment you want to work in.
  4. Click Continue.

2) Create an upload API ​

  1. Go to Data & API → API Endpoints.
  2. Create an upload API endpoint.
  3. Choose whether the file should be Public or Private.
  4. Set a Path such as uploads/ or users/avatars/.
  5. Review the API security settings so only the right users can upload.

3) Upload from the interface ​

  1. In the Interface, add a File Upload element.
  2. Add a button such as Upload file.
  3. On click, call your upload API endpoint.
  4. Map the API file input to the value from the File Upload element.

When the workflow runs, the API returns the uploaded file details.

4) Save the file reference ​

After the upload succeeds, save the returned file information on the related record.

Recommended rule:

  • Always save the file path
  • Only save the url when the file is public

Examples:

  • Save a profile photo path on the user record
  • Save a contract path on the contract record
  • Save a resume path on the application record

Common pitfalls ​

The file uploads but you cannot find it later ​

  • Save the returned path in your data right after the upload.
  • Do not rely only on the upload response shown during testing.

You do not see the file in Storage ​

  • Make sure you are viewing the same environment where the file was uploaded.

Private files do not open directly ​

  • Create a signed download URL API and use that signed URL instead of trying to use a public link.