import * as z from "zod"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { CustomMappings, CustomMappings$Outbound } from "./custommappings.js"; import { FileType } from "./filetype.js"; import { LinkedFolder, LinkedFolder$Outbound } from "./linkedfolder.js"; import { Owner, Owner$Outbound } from "./owner.js"; /** * Permissions the current user has on this file. */ export type Permissions = { /** * Whether the current user can download this file. */ download?: boolean | undefined; }; export type UnifiedFile = { /** * A unique identifier for an object. */ id: string; /** * The third-party API ID of original entity */ downstreamId?: string | null | undefined; /** * The name of the file */ name: string | null; /** * Optional description of the file */ description?: string | null | undefined; /** * The type of resource. Could be file, folder or url */ type: FileType | null; /** * The full path of the file or folder (includes the file name) */ path?: string | null | undefined; /** * The MIME type of the file. */ mimeType?: string | null | undefined; /** * Whether the current user can download this file */ downloadable?: boolean | undefined; /** * The size of the file in bytes */ size?: number | null | undefined; owner?: Owner | undefined; /** * The parent folders of the file, starting from the root */ parentFolders?: Array | undefined; /** * Whether the list of parent folders is complete. Some connectors only return the direct parent of a file */ parentFoldersComplete?: boolean | undefined; /** * Permissions the current user has on this file. */ permissions?: Permissions | undefined; /** * Whether the current file is exportable to other file formats. This property is relevant for proprietary file formats such as Google Docs or Dropbox Paper. */ exportable?: boolean | undefined; /** * The available file formats when exporting this file. */ exportFormats?: Array | null | undefined; /** * When custom mappings are configured on the resource, the result is included here. */ customMappings?: CustomMappings | null | undefined; /** * The user who last updated the object. */ updatedBy?: string | null | undefined; /** * The user who created the object. */ createdBy?: string | null | undefined; /** * The date and time when the object was last updated. */ updatedAt?: Date | null | undefined; /** * The date and time when the object was created. */ createdAt?: Date | null | undefined; }; /** @internal */ export declare const Permissions$inboundSchema: z.ZodType; /** @internal */ export type Permissions$Outbound = { download?: boolean | undefined; }; /** @internal */ export declare const Permissions$outboundSchema: z.ZodType; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export declare namespace Permissions$ { /** @deprecated use `Permissions$inboundSchema` instead. */ const inboundSchema: z.ZodType; /** @deprecated use `Permissions$outboundSchema` instead. */ const outboundSchema: z.ZodType; /** @deprecated use `Permissions$Outbound` instead. */ type Outbound = Permissions$Outbound; } export declare function permissionsToJSON(permissions: Permissions): string; export declare function permissionsFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const UnifiedFile$inboundSchema: z.ZodType; /** @internal */ export type UnifiedFile$Outbound = { id: string; downstream_id?: string | null | undefined; name: string | null; description?: string | null | undefined; type: string | null; path?: string | null | undefined; mime_type?: string | null | undefined; downloadable?: boolean | undefined; size?: number | null | undefined; owner?: Owner$Outbound | undefined; parent_folders?: Array | undefined; parent_folders_complete?: boolean | undefined; permissions?: Permissions$Outbound | undefined; exportable?: boolean | undefined; export_formats?: Array | null | undefined; custom_mappings?: CustomMappings$Outbound | null | undefined; updated_by?: string | null | undefined; created_by?: string | null | undefined; updated_at?: string | null | undefined; created_at?: string | null | undefined; }; /** @internal */ export declare const UnifiedFile$outboundSchema: z.ZodType; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export declare namespace UnifiedFile$ { /** @deprecated use `UnifiedFile$inboundSchema` instead. */ const inboundSchema: z.ZodType; /** @deprecated use `UnifiedFile$outboundSchema` instead. */ const outboundSchema: z.ZodType; /** @deprecated use `UnifiedFile$Outbound` instead. */ type Outbound = UnifiedFile$Outbound; } export declare function unifiedFileToJSON(unifiedFile: UnifiedFile): string; export declare function unifiedFileFromJSON(jsonString: string): SafeParseResult; //# sourceMappingURL=unifiedfile.d.ts.map