/** * Canonical file schemas and types for SDK API inputs. * * These helpers model the file objects that Superblocks injects for FilePicker * inputs. Use the minimal file-ref contract when you want to pass files by * reference to storage integrations, and the readable file contract when your * API needs to call `readContentsAsync()` or `readContents()`. */ import { z } from "zod"; /** * Minimal file reference contract. * * Good for by-reference uploads where the storage plugin resolves the file * bytes using `$superblocksId`, such as S3 or GCS `uploadMultipleObjects()`. */ export declare const fileRefSchema: z.ZodObject<{ name: z.ZodString; type: z.ZodOptional; $superblocksId: z.ZodString; }, "strip", z.ZodTypeAny, { name: string; $superblocksId: string; type?: string | undefined; }, { name: string; $superblocksId: string; type?: string | undefined; }>; /** * Runtime-readable file contract. * * Good for APIs that need to inspect file contents in code via * `readContentsAsync()` or `readContents()`. */ export declare const readableFileSchema: z.ZodObject<{ name: z.ZodString; type: z.ZodOptional; $superblocksId: z.ZodString; } & { size: z.ZodOptional; extension: z.ZodOptional; previewUrl: z.ZodOptional; readContentsAsync: z.ZodType<(mode?: string) => Promise, z.ZodTypeDef, (mode?: string) => Promise>; readContents: z.ZodType<(mode?: string) => string | Buffer, z.ZodTypeDef, (mode?: string) => string | Buffer>; }, "passthrough", z.ZodTypeAny, z.objectOutputType<{ name: z.ZodString; type: z.ZodOptional; $superblocksId: z.ZodString; } & { size: z.ZodOptional; extension: z.ZodOptional; previewUrl: z.ZodOptional; readContentsAsync: z.ZodType<(mode?: string) => Promise, z.ZodTypeDef, (mode?: string) => Promise>; readContents: z.ZodType<(mode?: string) => string | Buffer, z.ZodTypeDef, (mode?: string) => string | Buffer>; }, z.ZodTypeAny, "passthrough">, z.objectInputType<{ name: z.ZodString; type: z.ZodOptional; $superblocksId: z.ZodString; } & { size: z.ZodOptional; extension: z.ZodOptional; previewUrl: z.ZodOptional; readContentsAsync: z.ZodType<(mode?: string) => Promise, z.ZodTypeDef, (mode?: string) => Promise>; readContents: z.ZodType<(mode?: string) => string | Buffer, z.ZodTypeDef, (mode?: string) => string | Buffer>; }, z.ZodTypeAny, "passthrough">>; export type FileRef = z.infer; export type ReadableFile = z.infer; //# sourceMappingURL=files.d.ts.map