Interface GoogleDriveV1NodeParameters

Source
interface GoogleDriveV1NodeParameters {
    authentication?: "oAuth2" | "serviceAccount";
    binaryData?: boolean;
    binaryPropertyName?: string;
    driveId?: {
        mode: "id" | "list" | "url";
        value: string;
    };
    fileContent?: string;
    fileId?: { mode: "id"
    | "list"
    | "url"; value: string };
    limit?: number;
    name?: string;
    operation?:
        | "create"
        | "get"
        | "update"
        | "list"
        | "delete"
        | "upload"
        | "copy"
        | "download"
        | "share";
    options?: | {
        fileName?: string;
        googleFileConversion?: {
            conversion: {
                docsToFormat?: | "text/html"
                | "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
                | "application/vnd.oasis.opendocument.text"
                | "application/pdf"
                | "application/rtf";
                drawingsToFormat?: | "application/pdf"
                | "image/jpeg"
                | "image/png"
                | "image/svg+xml";
                sheetsToFormat?: | "application/pdf"
                | "application/x-vnd.oasis.opendocument.spreadsheet"
                | "text/csv";
                slidesToFormat?: | "text/plain"
                | "application/pdf"
                | "application/vnd.openxmlformats-officedocument.presentationml.presentation"
                | "application/vnd.oasis.opendocument.presentation";
            };
        };
    }
    | {
        fields?: (
            | "id"
            | "name"
            | "permissions"
            | "*"
            | "kind"
            | "explicitlyTrashed"
            | "exportLinks"
            | "hasThumbnail"
            | "iconLink"
            | "mimeType"
            | "shared"
            | "spaces"
            | "starred"
            | "thumbnailLink"
            | "trashed"
            | "version"
            | "webViewLink"
        )[];
    }
    | {
        corpora?: "user"
        | "domain"
        | "drive"
        | "allDrives";
        driveId?: string;
        emailMessage?: string;
        enforceSingleParent?: boolean;
        fields?: (
            | "id"
            | "name"
            | "permissions"
            | "*"
            | "kind"
            | "explicitlyTrashed"
            | "exportLinks"
            | "hasThumbnail"
            | "iconLink"
            | "mimeType"
            | "shared"
            | "spaces"
            | "starred"
            | "thumbnailLink"
            | "trashed"
            | "version"
            | "webViewLink"
        )[];
        moveToNewOwnersRoot?: boolean;
        name?: string;
        parents?: string;
        sendNotificationEmail?: boolean;
        spaces?: ("*" | "photos" | "drive" | "appDataFolder")[];
        supportsAllDrives?: boolean;
        transferOwnership?: boolean;
        useDomainAdminAccess?: boolean;
    }
    | {
        capabilities?: {
            canAddChildren?: boolean;
            canChangeCopyRequiresWriterPermissionRestriction?: boolean;
            canChangeDomainUsersOnlyRestriction?: boolean;
            canChangeDriveBackground?: boolean;
            canChangeDriveMembersOnlyRestriction?: boolean;
            canComment?: boolean;
            canCopy?: boolean;
            canDeleteChildren?: boolean;
            canDeleteDrive?: boolean;
            canDownload?: boolean;
            canEdit?: boolean;
            canListChildren?: boolean;
            canManageMembers?: boolean;
            canReadRevisions?: boolean;
            canRename?: boolean;
            canRenameDrive?: boolean;
            canShare?: boolean;
            canTrashChildren?: boolean;
        };
        colorRgb?: string;
        createdTime?: string;
        hidden?: boolean;
        restrictions?: {
            adminManagedRestrictions?: boolean;
            copyRequiresWriterPermission?: boolean;
            domainUsersOnly?: boolean;
            driveMembersOnly?: boolean;
        };
    }
    | { useDomainAdminAccess?: boolean }
    | { q?: string; useDomainAdminAccess?: boolean }
    | {
        colorRgb?: string;
        name?: string;
        restrictions?: {
            adminManagedRestrictions?: boolean;
            copyRequiresWriterPermission?: boolean;
            domainUsersOnly?: boolean;
            driveMembersOnly?: boolean;
        };
    }
    | {
        appPropertiesUi?: {
            appPropertyValues: {
                key?: string;
                value?: string;
            }[];
        };
        propertiesUi?: {
            propertyValues: { key?: string; value?: string }[];
        };
    };
    parents?: string;
    permissionsUi?: {
        permissionsValues: {
            allowFileDiscovery?: boolean;
            domain?: string;
            emailAddress?: string;
            role?: | "owner"
            | "commenter"
            | "fileOrganizer"
            | "organizer"
            | "reader"
            | "writer";
            type?: "user"
            | "group"
            | "domain"
            | "anyone";
        };
    };
    queryFilters?: {
        mimeType: {
            customMimeType?: string;
            mimeType?: | "custom"
            | "application/vnd.google-apps.audio"
            | "application/vnd.google-apps.document"
            | "application/vnd.google-apps.drawing"
            | "application/vnd.google-apps.presentation"
            | "application/vnd.google-apps.spreadsheet"
            | "application/vnd.google-apps.photo"
            | "application/vnd.google-apps.video"
            | "application/vnd.google-apps.drive-sdk"
            | "application/vnd.google-apps.script"
            | "application/vnd.google-apps.file"
            | "application/vnd.google-apps.folder"
            | "application/vnd.google-apps.form"
            | "application/vnd.google-apps.fusiontable"
            | "application/vnd.google-apps.map"
            | "application/vnd.google-apps.site"
            | "application/vnd.google-apps.unknown";
        }[];
        name: {
            operation?: "contains"
            | "is"
            | "isNot";
            value?: string;
        }[];
    };
    queryString?: string;
    resolveData?: boolean;
    resource?: "file"
    | "folder"
    | "drive";
    returnAll?: boolean;
    updateFields?: {
        fileName?: string;
        keepRevisionForever?: boolean;
        ocrLanguage?: string;
        parentId?: string;
        trashed?: boolean;
        useContentAsIndexableText?: boolean;
    };
    useQueryString?: boolean;
}

Properties§

Source§

readonly authentication?: "oAuth2" | "serviceAccount"

Default: "serviceAccount"

Source§

readonly binaryData?: boolean

Whether the data to upload should be taken from binary field

Source§

readonly binaryPropertyName?: string

Default: "data"

Source§

readonly driveId?: { mode: "id" | "list" | "url"; value: string }

The ID of the drive Default: {"mode":"list","value":""}

Source§

readonly fileContent?: string

The text content of the file to upload

Source§

readonly fileId?: { mode: "id" | "list" | "url"; value: string }

The ID of the file Default: {"mode":"list","value":""}

Source§

readonly limit?: number

Max number of results to return Default: 50 Type options: {"minValue":1,"maxValue":1000}

Source§

readonly name?: string

The name the file should be saved as

Source§

readonly operation?:
    | "create"
    | "get"
    | "update"
    | "list"
    | "delete"
    | "upload"
    | "copy"
    | "download"
    | "share"

Default: "upload"

Source§

readonly options?:
    | {
        fileName?: string;
        googleFileConversion?: {
            conversion: {
                docsToFormat?: | "text/html"
                | "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
                | "application/vnd.oasis.opendocument.text"
                | "application/pdf"
                | "application/rtf";
                drawingsToFormat?: | "application/pdf"
                | "image/jpeg"
                | "image/png"
                | "image/svg+xml";
                sheetsToFormat?: | "application/pdf"
                | "application/x-vnd.oasis.opendocument.spreadsheet"
                | "text/csv";
                slidesToFormat?: | "text/plain"
                | "application/pdf"
                | "application/vnd.openxmlformats-officedocument.presentationml.presentation"
                | "application/vnd.oasis.opendocument.presentation";
            };
        };
    }
    | {
        fields?: (
            | "id"
            | "name"
            | "permissions"
            | "*"
            | "kind"
            | "explicitlyTrashed"
            | "exportLinks"
            | "hasThumbnail"
            | "iconLink"
            | "mimeType"
            | "shared"
            | "spaces"
            | "starred"
            | "thumbnailLink"
            | "trashed"
            | "version"
            | "webViewLink"
        )[];
    }
    | {
        corpora?: "user"
        | "domain"
        | "drive"
        | "allDrives";
        driveId?: string;
        emailMessage?: string;
        enforceSingleParent?: boolean;
        fields?: (
            | "id"
            | "name"
            | "permissions"
            | "*"
            | "kind"
            | "explicitlyTrashed"
            | "exportLinks"
            | "hasThumbnail"
            | "iconLink"
            | "mimeType"
            | "shared"
            | "spaces"
            | "starred"
            | "thumbnailLink"
            | "trashed"
            | "version"
            | "webViewLink"
        )[];
        moveToNewOwnersRoot?: boolean;
        name?: string;
        parents?: string;
        sendNotificationEmail?: boolean;
        spaces?: ("*" | "photos" | "drive" | "appDataFolder")[];
        supportsAllDrives?: boolean;
        transferOwnership?: boolean;
        useDomainAdminAccess?: boolean;
    }
    | {
        capabilities?: {
            canAddChildren?: boolean;
            canChangeCopyRequiresWriterPermissionRestriction?: boolean;
            canChangeDomainUsersOnlyRestriction?: boolean;
            canChangeDriveBackground?: boolean;
            canChangeDriveMembersOnlyRestriction?: boolean;
            canComment?: boolean;
            canCopy?: boolean;
            canDeleteChildren?: boolean;
            canDeleteDrive?: boolean;
            canDownload?: boolean;
            canEdit?: boolean;
            canListChildren?: boolean;
            canManageMembers?: boolean;
            canReadRevisions?: boolean;
            canRename?: boolean;
            canRenameDrive?: boolean;
            canShare?: boolean;
            canTrashChildren?: boolean;
        };
        colorRgb?: string;
        createdTime?: string;
        hidden?: boolean;
        restrictions?: {
            adminManagedRestrictions?: boolean;
            copyRequiresWriterPermission?: boolean;
            domainUsersOnly?: boolean;
            driveMembersOnly?: boolean;
        };
    }
    | { useDomainAdminAccess?: boolean }
    | { q?: string; useDomainAdminAccess?: boolean }
    | {
        colorRgb?: string;
        name?: string;
        restrictions?: {
            adminManagedRestrictions?: boolean;
            copyRequiresWriterPermission?: boolean;
            domainUsersOnly?: boolean;
            driveMembersOnly?: boolean;
        };
    }
    | {
        appPropertiesUi?: {
            appPropertyValues: {
                key?: string;
                value?: string;
            }[];
        };
        propertiesUi?: {
            propertyValues: { key?: string; value?: string }[];
        };
    }

Default: {}

Source§

readonly parents?: string

The IDs of the parent folders which contain the file Default: [] Type options: {"multipleValues":true}

Source§

readonly permissionsUi?: {
    permissionsValues: {
        allowFileDiscovery?: boolean;
        domain?: string;
        emailAddress?: string;
        role?:
            | "owner"
            | "commenter"
            | "fileOrganizer"
            | "organizer"
            | "reader"
            | "writer";
        type?: "user"
        | "group"
        | "domain"
        | "anyone";
    };
}

Default: {} Type options: {"multipleValues":false}

Source§

readonly queryFilters?: {
    mimeType: {
        customMimeType?: string;
        mimeType?:
            | "custom"
            | "application/vnd.google-apps.audio"
            | "application/vnd.google-apps.document"
            | "application/vnd.google-apps.drawing"
            | "application/vnd.google-apps.presentation"
            | "application/vnd.google-apps.spreadsheet"
            | "application/vnd.google-apps.photo"
            | "application/vnd.google-apps.video"
            | "application/vnd.google-apps.drive-sdk"
            | "application/vnd.google-apps.script"
            | "application/vnd.google-apps.file"
            | "application/vnd.google-apps.folder"
            | "application/vnd.google-apps.form"
            | "application/vnd.google-apps.fusiontable"
            | "application/vnd.google-apps.map"
            | "application/vnd.google-apps.site"
            | "application/vnd.google-apps.unknown";
    }[];
    name: {
        operation?: "contains"
        | "is"
        | "isNot";
        value?: string;
    }[];
}

Filters to use to return only specific files Default: {} Type options: {"multipleValues":true}

Source§

readonly queryString?: string

Query to use to return only specific files

Source§

readonly resolveData?: boolean

By default the response only contain the ID of the file. If this option gets activated, it will resolve the data automatically.

Source§

readonly resource?: "file" | "folder" | "drive"

Default: "file"

Source§

readonly returnAll?: boolean

Whether to return all results or only up to a given limit

Source§

readonly updateFields?: {
    fileName?: string;
    keepRevisionForever?: boolean;
    ocrLanguage?: string;
    parentId?: string;
    trashed?: boolean;
    useContentAsIndexableText?: boolean;
}

Default: {}

Source§

readonly useQueryString?: boolean

Whether a query string should be used to filter results