@not3/sdk
    Preparing search index...

    Class FilesAPI

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    api: AxiosInstance
    options: ClientOptions

    Methods

    • Complete the file upload.

      Parameters

      • id: string

        The upload ID.

      • etags: string[]

        The ETags of the uploaded chunks.

      Returns Promise<void>

      AxiosError If the request fails.

    • Delete a file.

      Parameters

      • id: string

        The file ID.

      Returns Promise<void>

      AxiosError If the request fails.

    • Get the URL to upload a chunk of the file.

      Parameters

      • id: string

        The upload ID.

      • length: number

        The length of the chunk.

      • Optionalpart: number

        The part number of the chunk.

      Returns Promise<string>

      The URL to upload the chunk.

      AxiosError If the request fails.

    • Start a new file upload session.

      Parameters

      • name: string

        The file name.

      Returns Promise<string>

      The upload ID.

      AxiosError If the request fails.

    • Upload a file chunk to the server.

      Parameters

      • url: string

        The URL to upload the chunk to.

      • data: ArrayBuffer

        The chunk data.

      Returns Promise<string>

      The ETag of the uploaded chunk.

      AxiosError If the request fails.