Skip to main content

RemoteStorageAdapter

Experimental Alpha

RemoteStorageAdapter defines the interface for remote storage operations. Implementations handle uploading, downloading, and deleting files from remote storage.

This is currently experimental and may change without a major version bump.

Methods

deleteFile()

deleteFile(attachment): Promise<void>;

Alpha

Deletes a file from remote storage.

Parameters

ParameterTypeDescription
attachmentAttachmentRecordThe attachment describing the file to delete

Returns

Promise<void>


downloadFile()

downloadFile(attachment): Promise<ArrayBuffer>;

Alpha

Downloads a file from remote storage.

Parameters

ParameterTypeDescription
attachmentAttachmentRecordThe attachment describing the file to download

Returns

Promise<ArrayBuffer>

The binary data of the downloaded file


uploadFile()

uploadFile(fileData, attachment): Promise<void>;

Alpha

Uploads a file to remote storage.

Parameters

ParameterTypeDescription
fileDataArrayBufferThe binary content of the file to upload
attachmentAttachmentRecordThe associated attachment metadata

Returns

Promise<void>