Methods

  • Creates a new File.

    Parameters

    Returns Promise<number>

  • Deletes a File.

    Parameters

    • id: number

      The id of the File to delete.

    Returns Promise<void>

  • Retrieves information for an existing File. Throws an error if the File does not exist.

    Parameters

    • id: number

      The id of the File to retrieve.

    Returns Promise<SingleFile>

  • Opens a local file picker to allow the user to choose a file.

    Returns Promise<FileContents>

    The contents of the file chosen by the user. All properties will be undefined if the user cancels the overlay.

  • Retrieves the contents of an existing File. Throws an error if the File does not exist.

    Parameters

    • id: number

      The id of the File to retrieve.

    Returns Promise<Blob>

    The contents of the File as a Blob.

  • Updates a File.

    Parameters

    • id: number

      The id of the File to update.

    • options: FileUpdateOptions

      Options to update the File.

    Returns Promise<void>