POST /api/v2.6/files/uploadwith the file details:
sourceproperties are mandatory — all others are optional. You can also attach
lastUpdatedfields with Unix timestamps to set them accordingly. If everything is successful, the PDA will respond with a copy of the metadata as well as additional information:
contentUrlindicating where the file should be uploaded. The upload
contentUrlis signed and has limited duration validity, most likely 5 minutes, after which it becomes invalid. Then uploading itself could be done as (note:
x-amz-server-side-encryptionheader is mandatory):
PUT /api/v2.6/files/file/:fileId/complete. It will again respond with file metadata:
statushas now been marked as
Completedand contains file size in bytes! The request will fail if the file doesn't exist, hasn't been fully uploaded or you do not have permissions to mark the file completed (you will if you started the upload in the first place).
ownercan adjust file permissions by:
GET /api/v2.6/files/allowAccess/:fileId/:userIdto allow a specific user (
:userId) to access a specific file (
:fileId), optionally setting
contentquery parameter to
falseto control content access (
falseby default). Conversely, calling
GET /api/v2.6/files/restrictAccess/:fileId/:userIdto restrict access.
POST /api/v2.6/files/allowAccess/:userIdsending file template to grant access to a set of files (same syntax as for file search!). Conversely, calling
POST /api/v2.6/files/restrictAccess/:userIdto restrict access.
GET /api/v2.6/files/restrictAccessPublic/:fileIdto control public file access.
GET api/v2.6/files/file/:fileIdto list metadata of a file, including
contentUrlpointing to a pre-signed temporary URL for file contents if the user is permitted file access
GET /api/v2.6/files/content/:fileIdto get contents of a file, if file is marked publicly accessible or the client is permitted to access the file. The endpoint redirects to the pre-signed temporary content URL or returns 404 error code (Not Found) if the file does not exist or is not accessible.
fileIdfor an exact match, where one or no files are returned
namefor an exact match on the original name, but multiple files could potentially be returned. Empty string if you do not want to match against
sourcematching all files from a specific source such as
tagsa set of all tags matching files that need to be attached
descriptionfor an approximate, text-based search matching the fields
statusto filter e.g. only files that are marked
POST /api/v2.6/files/searchsending file template to match against. All calls must be authenticated with the user's token and only files the user is allowed to access are returned: