TagoIO SDK for JavaScript and TypeScript
    Preparing search index...

    Type Alias UploadOptions

    type UploadOptions = {
        blueprint_devices?: {
            bucket?: GenericID;
            id: GenericID;
            origin: GenericID;
        }[];
        chunkSize?: number;
        contentType?: string;
        dashboard?: string;
        fieldId?: string;
        isPublic?: boolean;
        maxTriesForEachChunk?: number;
        onCancelToken?: (cancel: () => void) => any;
        onProgress?: (percentage: number) => any;
        timeoutForEachFailedChunk?: number;
        widget?: string;
    }
    Index

    Properties

    blueprint_devices?: { bucket?: GenericID; id: GenericID; origin: GenericID }[]

    map blueprint devices to real devices, so BP Device ID path is replaced by the real device ID

    chunkSize?: number

    the byte size of each chunk sent to TagoIO. This will influence how many requests this function will perform

    contentType?: string

    The file's content type. This is optional

    dashboard?: string

    Dashboard ID.

    Uploading files from a widget requires dashboard, widget, and fieldId to be provided.

    fieldId?: string

    ID of the field from the widget where the file is selected.

    Uploading files from a widget requires dashboard, widget, and fieldId to be provided.

    isPublic?: boolean

    if the file can be accessed by anybody with a link or not

    maxTriesForEachChunk?: number

    the maximum amount of tries to upload each chunk to TagoIO. After this many unsuccessful tries of a single chunk, the upload is aborted

    onCancelToken?: (cancel: () => void) => any

    will provide a cancel token for you to cancel the request

    onProgress?: (percentage: number) => any

    will provide the upload percentage for this file

    timeoutForEachFailedChunk?: number

    timeout before trying to upload the same chunk if the request failed

    widget?: string

    Widget ID.

    Uploading files from a widget requires dashboard, widget, and fieldId to be provided.