Skip to main content
Create a signed upload URL for a file upload. This method is ideal when you want to authorize server side but upload on the client; check out this doc for more details.
All the information about the upload such as the name, group, keyvalues, etc. must be part of the signed URL in order for those values to go through. If you have a basic signed URL with no extra parameters and then try to add fields like name, group, etc. they will not go through.

Usage

Returns

  • Type: string
The full signed URL

Parameters

expires

  • Type: number
The number of seconds the signed URL should be valid for

name (Optional)

  • Type: string
Name for the file to be uploaded

mimeTypes (Optional)

  • Type: string[]
Specify allowed file mime types and prevent uploads from files that do not match. Accepts wildcard mime types as well.

maxFileSize (Optional)

  • Type: number
Restrict upload to a specified file size in bytes

groupId (Optional)

  • Type: string
The target groupId the file would be uploaded to

keyvalues (Optional)

  • Type: Record<string, string>
Keyvalue pairs for the uploaded file

date (Optional)

  • Type: number
A UNIX timestamp of the date a URL is signed