import { FileKeyEncoded, FileKeyParts } from "../keys.js"; import { UploadChecksum } from "../storage/types.js"; import { FileStatus, UploadStatus } from "../types.js"; import { FileHookPayload, UploadFragmentConfig, UploadFragmentResolvedConfig, UploadTimeoutPayload } from "../config.js"; import { CompletePartsInput, CreateUploadInput, CreateUploadResult, UploadProgressInput } from "../services/uploads.js"; import { ListFilesInput, UpdateFileInput } from "../services/files.js"; import * as _fragno_dev_core49 from "@fragno-dev/core"; import * as _fragno_dev_db202 from "@fragno-dev/db"; import * as _fragno_dev_db_schema427 from "@fragno-dev/db/schema"; import * as zod1807 from "zod"; import * as zod_v4_core148 from "zod/v4/core"; import * as _standard_schema_spec25 from "@standard-schema/spec"; //#region src/routes/index.d.ts declare const uploadRoutes: readonly [_fragno_dev_core49.RouteFactory & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"fileKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"uploaderId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"filename", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"sizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"contentType", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"checksum", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"visibility", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"tags", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"metadata", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"status", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageProvider", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"updatedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"completedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"deletedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"errorCode", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"errorMessage", _fragno_dev_db_schema427.Column<"string", string | null, string | null>>, Record, Record> & Record<"idx_file_key", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey"]>> & Record<"idx_file_key_status", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"string", string, string>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey", "status"]>> & Record<"idx_file_key_uploaderId", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"string", string | null, string | null>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey", "uploaderId"]>> & Record<"idx_file_key_status_uploaderId", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"string", string, string>, _fragno_dev_db_schema427.Column<"string", string | null, string | null>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey", "status", "uploaderId"]>> & Record<"idx_file_uploaderId", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["uploaderId"]>> & Record<"idx_file_createdAt", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["createdAt"]>> & Record<"idx_file_status_createdAt", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["status", "createdAt"]>>>; upload: _fragno_dev_db_schema427.Table & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"fileKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"uploaderId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"filename", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"expectedSizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"contentType", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"checksum", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"visibility", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"tags", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"metadata", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"status", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"strategy", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageProvider", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageUploadId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadUrl", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadHeaders", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"bytesUploaded", _fragno_dev_db_schema427.Column<"bigint", bigint | null, bigint>> & Record<"partsUploaded", _fragno_dev_db_schema427.Column<"integer", number | null, number>> & Record<"partSizeBytes", _fragno_dev_db_schema427.Column<"integer", number | null, number | null>> & Record<"expiresAt", _fragno_dev_db_schema427.Column<"timestamp", _fragno_dev_db202.DbNow | Date, Date>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"updatedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"completedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"errorCode", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"errorMessage", _fragno_dev_db_schema427.Column<"string", string | null, string | null>>, Record, Record> & Record<"idx_upload_file_key", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey"]>> & Record<"idx_upload_status", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["status"]>> & Record<"idx_upload_expiresAt", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["expiresAt"]>>>; upload_part: _fragno_dev_db_schema427.Table & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"uploadId", _fragno_dev_db_schema427.Column<"bigint", string | bigint | _fragno_dev_db_schema427.FragnoId | _fragno_dev_db_schema427.FragnoReference, _fragno_dev_db_schema427.FragnoReference>> & Record<"partNumber", _fragno_dev_db_schema427.Column<"integer", number, number>> & Record<"etag", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"sizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>>, Record & Record<"upload", _fragno_dev_db_schema427.Relation<"one", _fragno_dev_db_schema427.Table & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"fileKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"uploaderId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"filename", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"expectedSizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"contentType", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"checksum", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"visibility", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"tags", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"metadata", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"status", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"strategy", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageProvider", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageUploadId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadUrl", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadHeaders", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"bytesUploaded", _fragno_dev_db_schema427.Column<"bigint", bigint | null, bigint>> & Record<"partsUploaded", _fragno_dev_db_schema427.Column<"integer", number | null, number>> & Record<"partSizeBytes", _fragno_dev_db_schema427.Column<"integer", number | null, number | null>> & Record<"expiresAt", _fragno_dev_db_schema427.Column<"timestamp", _fragno_dev_db202.DbNow | Date, Date>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"updatedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"completedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"errorCode", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"errorMessage", _fragno_dev_db_schema427.Column<"string", string | null, string | null>>, Record, Record> & Record<"idx_upload_file_key", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey"]>> & Record<"idx_upload_status", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["status"]>> & Record<"idx_upload_expiresAt", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["expiresAt"]>>>>>, Record> & Record<"idx_upload_part_upload", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["uploadId"]>> & Record<"idx_upload_part_number", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"integer", number, number>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["uploadId", "partNumber"]>>>; }>>, _fragno_dev_core49.BoundServices<{ findFileByKey: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null>; getFileByKey: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>; listFiles: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, input: ListFilesInput) => _fragno_dev_db202.TxResult<_fragno_dev_db202.CursorResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>, _fragno_dev_db202.CursorResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>>; updateFile: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded, input: UpdateFileInput) => _fragno_dev_db202.TxResult<{ filename: string; visibility: string; tags: unknown; metadata: unknown; updatedAt: Date; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; sizeBytes: bigint; contentType: string; checksum: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; markFileDeleted: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded, fileKeyParts: FileKeyParts, uploadId?: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; checkUploadAvailability: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, input: CreateUploadInput, options: { allowIdempotentReuse: boolean; }) => _fragno_dev_db202.TxResult; createUploadRecord: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, input: CreateUploadInput & { storageInit: Awaited | null; }) => Promise<{ strategy: "direct-single" | "direct-multipart" | "proxy"; storageKey: string; storageUploadId?: string; partSizeBytes?: number; expiresAt: Date; uploadUrl?: string; uploadHeaders?: Record; }>>>; allowIdempotentReuse: boolean; }) => _fragno_dev_db202.TxResult<{ reused: true; result: CreateUploadResult; } | { reused: false; result: CreateUploadResult; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }[]]>; getUploadStatus: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>; getUploadParts: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; uploadId: _fragno_dev_db_schema427.FragnoReference; partNumber: number; etag: string; sizeBytes: bigint; createdAt: Date; }[], { id: _fragno_dev_db_schema427.FragnoId; uploadId: _fragno_dev_db_schema427.FragnoReference; partNumber: number; etag: string; sizeBytes: bigint; createdAt: Date; }[]>; recordUploadProgress: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, input: UploadProgressInput) => _fragno_dev_db202.TxResult<{ bytesUploaded: bigint; partsUploaded: number; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; recordUploadParts: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, input: CompletePartsInput) => _fragno_dev_db202.TxResult<{ partsUploaded: number; bytesUploaded: bigint; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; uploadId: _fragno_dev_db_schema427.FragnoReference; partNumber: number; etag: string; sizeBytes: bigint; createdAt: Date; }[]]>; markUploadComplete: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, fileKey: FileKeyEncoded, options?: { sizeBytes?: bigint; }) => _fragno_dev_db202.TxResult<{ upload: { status: UploadStatus; updatedAt: Date; completedAt: Date; bytesUploaded: bigint; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; errorCode: string | null; errorMessage: string | null; }; file: { fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: {} | null; visibility: string; tags: {} | null; metadata: {} | null; status: FileStatus; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date; deletedAt: null; errorCode: null; errorMessage: null; id: _fragno_dev_db_schema427.FragnoId; }; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; markUploadFailed: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, errorCode: string, errorMessage?: string | null) => _fragno_dev_db202.TxResult<{ upload: { status: UploadStatus; updatedAt: Date; errorCode: string; errorMessage: string | null; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; completedAt: Date | null; }; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; markUploadAborted: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ upload: { status: UploadStatus; updatedAt: Date; errorCode: string; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; completedAt: Date | null; errorMessage: string | null; }; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; getUploadStorageInfo: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>; }>, {}, readonly [_fragno_dev_core49.FragnoRouteConfig<"POST", "/uploads", zod1807.ZodObject<{ keyParts: zod1807.ZodOptional>>; fileKey: zod1807.ZodOptional; filename: zod1807.ZodString; sizeBytes: zod1807.ZodNumber; contentType: zod1807.ZodString; checksum: zod1807.ZodOptional; value: zod1807.ZodString; }, zod_v4_core148.$strip>>>>; tags: zod1807.ZodOptional>; visibility: zod1807.ZodOptional>; uploaderId: zod1807.ZodOptional; metadata: zod1807.ZodOptional>; }, zod_v4_core148.$strip>, zod1807.ZodObject<{ uploadId: zod1807.ZodString; fileKey: zod1807.ZodString; status: zod1807.ZodEnum<{ created: "created"; in_progress: "in_progress"; }>; strategy: zod1807.ZodEnum<{ "direct-single": "direct-single"; "direct-multipart": "direct-multipart"; proxy: "proxy"; }>; expiresAt: zod1807.ZodDate; upload: zod1807.ZodObject<{ mode: zod1807.ZodEnum<{ single: "single"; multipart: "multipart"; }>; transport: zod1807.ZodEnum<{ proxy: "proxy"; direct: "direct"; }>; uploadUrl: zod1807.ZodOptional; uploadHeaders: zod1807.ZodOptional>; partSizeBytes: zod1807.ZodOptional; maxParts: zod1807.ZodOptional; partsEndpoint: zod1807.ZodOptional; completeEndpoint: zod1807.ZodString; contentEndpoint: zod1807.ZodOptional; }, zod_v4_core148.$strip>; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"GET", "/uploads/:uploadId", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ uploadId: zod1807.ZodString; fileKey: zod1807.ZodString; status: zod1807.ZodEnum<{ created: "created"; in_progress: "in_progress"; completed: "completed"; aborted: "aborted"; failed: "failed"; expired: "expired"; }>; strategy: zod1807.ZodEnum<{ "direct-single": "direct-single"; "direct-multipart": "direct-multipart"; proxy: "proxy"; }>; expectedSizeBytes: zod1807.ZodNumber; bytesUploaded: zod1807.ZodNumber; partsUploaded: zod1807.ZodNumber; partSizeBytes: zod1807.ZodNullable; expiresAt: zod1807.ZodDate; createdAt: zod1807.ZodDate; updatedAt: zod1807.ZodDate; completedAt: zod1807.ZodNullable; errorCode: zod1807.ZodNullable; errorMessage: zod1807.ZodNullable; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"POST", "/uploads/:uploadId/progress", zod1807.ZodObject<{ bytesUploaded: zod1807.ZodOptional; partsUploaded: zod1807.ZodOptional; }, zod_v4_core148.$strip>, zod1807.ZodObject<{ bytesUploaded: zod1807.ZodNumber; partsUploaded: zod1807.ZodNumber; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"POST", "/uploads/:uploadId/parts", zod1807.ZodObject<{ partNumbers: zod1807.ZodArray; }, zod_v4_core148.$strip>, zod1807.ZodObject<{ parts: zod1807.ZodArray>; }, zod_v4_core148.$strip>>; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"GET", "/uploads/:uploadId/parts", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ parts: zod1807.ZodArray>; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"POST", "/uploads/:uploadId/parts/complete", zod1807.ZodObject<{ parts: zod1807.ZodArray>; }, zod_v4_core148.$strip>, zod1807.ZodObject<{ bytesUploaded: zod1807.ZodNumber; partsUploaded: zod1807.ZodNumber; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"POST", "/uploads/:uploadId/complete", zod1807.ZodObject<{ parts: zod1807.ZodOptional>>; }, zod_v4_core148.$strip>, zod1807.ZodObject<{ fileKey: zod1807.ZodString; fileKeyParts: zod1807.ZodArray>; uploaderId: zod1807.ZodNullable; filename: zod1807.ZodString; sizeBytes: zod1807.ZodNumber; contentType: zod1807.ZodString; checksum: zod1807.ZodNullable; value: zod1807.ZodString; }, zod_v4_core148.$strip>>; visibility: zod1807.ZodEnum<{ private: "private"; public: "public"; unlisted: "unlisted"; }>; tags: zod1807.ZodNullable>; metadata: zod1807.ZodNullable>; status: zod1807.ZodEnum<{ ready: "ready"; deleted: "deleted"; }>; storageProvider: zod1807.ZodString; createdAt: zod1807.ZodString; updatedAt: zod1807.ZodString; completedAt: zod1807.ZodNullable; deletedAt: zod1807.ZodNullable; errorCode: zod1807.ZodNullable; errorMessage: zod1807.ZodNullable; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"POST", "/uploads/:uploadId/abort", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ ok: zod1807.ZodLiteral; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"PUT", "/uploads/:uploadId/content", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ fileKey: zod1807.ZodString; fileKeyParts: zod1807.ZodArray>; uploaderId: zod1807.ZodNullable; filename: zod1807.ZodString; sizeBytes: zod1807.ZodNumber; contentType: zod1807.ZodString; checksum: zod1807.ZodNullable; value: zod1807.ZodString; }, zod_v4_core148.$strip>>; visibility: zod1807.ZodEnum<{ private: "private"; public: "public"; unlisted: "unlisted"; }>; tags: zod1807.ZodNullable>; metadata: zod1807.ZodNullable>; status: zod1807.ZodEnum<{ ready: "ready"; deleted: "deleted"; }>; storageProvider: zod1807.ZodString; createdAt: zod1807.ZodString; updatedAt: zod1807.ZodString; completedAt: zod1807.ZodNullable; deletedAt: zod1807.ZodNullable; errorCode: zod1807.ZodNullable; errorMessage: zod1807.ZodNullable; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "UPLOAD_METADATA_MISMATCH" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>]>, _fragno_dev_core49.RouteFactory & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"fileKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"uploaderId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"filename", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"sizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"contentType", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"checksum", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"visibility", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"tags", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"metadata", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"status", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageProvider", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"updatedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"completedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"deletedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"errorCode", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"errorMessage", _fragno_dev_db_schema427.Column<"string", string | null, string | null>>, Record, Record> & Record<"idx_file_key", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey"]>> & Record<"idx_file_key_status", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"string", string, string>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey", "status"]>> & Record<"idx_file_key_uploaderId", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"string", string | null, string | null>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey", "uploaderId"]>> & Record<"idx_file_key_status_uploaderId", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"string", string, string>, _fragno_dev_db_schema427.Column<"string", string | null, string | null>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey", "status", "uploaderId"]>> & Record<"idx_file_uploaderId", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["uploaderId"]>> & Record<"idx_file_createdAt", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["createdAt"]>> & Record<"idx_file_status_createdAt", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["status", "createdAt"]>>>; upload: _fragno_dev_db_schema427.Table & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"fileKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"uploaderId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"filename", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"expectedSizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"contentType", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"checksum", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"visibility", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"tags", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"metadata", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"status", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"strategy", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageProvider", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageUploadId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadUrl", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadHeaders", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"bytesUploaded", _fragno_dev_db_schema427.Column<"bigint", bigint | null, bigint>> & Record<"partsUploaded", _fragno_dev_db_schema427.Column<"integer", number | null, number>> & Record<"partSizeBytes", _fragno_dev_db_schema427.Column<"integer", number | null, number | null>> & Record<"expiresAt", _fragno_dev_db_schema427.Column<"timestamp", _fragno_dev_db202.DbNow | Date, Date>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"updatedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"completedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"errorCode", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"errorMessage", _fragno_dev_db_schema427.Column<"string", string | null, string | null>>, Record, Record> & Record<"idx_upload_file_key", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey"]>> & Record<"idx_upload_status", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["status"]>> & Record<"idx_upload_expiresAt", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["expiresAt"]>>>; upload_part: _fragno_dev_db_schema427.Table & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"uploadId", _fragno_dev_db_schema427.Column<"bigint", string | bigint | _fragno_dev_db_schema427.FragnoId | _fragno_dev_db_schema427.FragnoReference, _fragno_dev_db_schema427.FragnoReference>> & Record<"partNumber", _fragno_dev_db_schema427.Column<"integer", number, number>> & Record<"etag", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"sizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>>, Record & Record<"upload", _fragno_dev_db_schema427.Relation<"one", _fragno_dev_db_schema427.Table & Record<"id", _fragno_dev_db_schema427.IdColumn<"varchar(30)", string | _fragno_dev_db_schema427.FragnoId | null, _fragno_dev_db_schema427.FragnoId>> & Record<"fileKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"uploaderId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"filename", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"expectedSizeBytes", _fragno_dev_db_schema427.Column<"bigint", bigint, bigint>> & Record<"contentType", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"checksum", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"visibility", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"tags", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"metadata", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"status", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"strategy", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageProvider", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageKey", _fragno_dev_db_schema427.Column<"string", string, string>> & Record<"storageUploadId", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadUrl", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"uploadHeaders", _fragno_dev_db_schema427.Column<"json", unknown, unknown>> & Record<"bytesUploaded", _fragno_dev_db_schema427.Column<"bigint", bigint | null, bigint>> & Record<"partsUploaded", _fragno_dev_db_schema427.Column<"integer", number | null, number>> & Record<"partSizeBytes", _fragno_dev_db_schema427.Column<"integer", number | null, number | null>> & Record<"expiresAt", _fragno_dev_db_schema427.Column<"timestamp", _fragno_dev_db202.DbNow | Date, Date>> & Record<"createdAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"updatedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date>> & Record<"completedAt", _fragno_dev_db_schema427.Column<"timestamp", (_fragno_dev_db202.DbNow | Date) | null, Date | null>> & Record<"errorCode", _fragno_dev_db_schema427.Column<"string", string | null, string | null>> & Record<"errorMessage", _fragno_dev_db_schema427.Column<"string", string | null, string | null>>, Record, Record> & Record<"idx_upload_file_key", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["fileKey"]>> & Record<"idx_upload_status", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["status"]>> & Record<"idx_upload_expiresAt", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["expiresAt"]>>>>>, Record> & Record<"idx_upload_part_upload", _fragno_dev_db_schema427.Index] & _fragno_dev_db_schema427.AnyColumn[], readonly ["uploadId"]>> & Record<"idx_upload_part_number", _fragno_dev_db_schema427.Index, _fragno_dev_db_schema427.Column<"integer", number, number>] & _fragno_dev_db_schema427.AnyColumn[], readonly ["uploadId", "partNumber"]>>>; }>>, _fragno_dev_core49.BoundServices<{ findFileByKey: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null>; getFileByKey: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>; listFiles: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, input: ListFilesInput) => _fragno_dev_db202.TxResult<_fragno_dev_db202.CursorResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>, _fragno_dev_db202.CursorResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>>; updateFile: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded, input: UpdateFileInput) => _fragno_dev_db202.TxResult<{ filename: string; visibility: string; tags: unknown; metadata: unknown; updatedAt: Date; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; sizeBytes: bigint; contentType: string; checksum: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; markFileDeleted: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, fileKey: FileKeyEncoded, fileKeyParts: FileKeyParts, uploadId?: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; checkUploadAvailability: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, input: CreateUploadInput, options: { allowIdempotentReuse: boolean; }) => _fragno_dev_db202.TxResult; createUploadRecord: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, input: CreateUploadInput & { storageInit: Awaited | null; }) => Promise<{ strategy: "direct-single" | "direct-multipart" | "proxy"; storageKey: string; storageUploadId?: string; partSizeBytes?: number; expiresAt: Date; uploadUrl?: string; uploadHeaders?: Record; }>>>; allowIdempotentReuse: boolean; }) => _fragno_dev_db202.TxResult<{ reused: true; result: CreateUploadResult; } | { reused: false; result: CreateUploadResult; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }[]]>; getUploadStatus: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>; getUploadParts: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; uploadId: _fragno_dev_db_schema427.FragnoReference; partNumber: number; etag: string; sizeBytes: bigint; createdAt: Date; }[], { id: _fragno_dev_db_schema427.FragnoId; uploadId: _fragno_dev_db_schema427.FragnoReference; partNumber: number; etag: string; sizeBytes: bigint; createdAt: Date; }[]>; recordUploadProgress: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, input: UploadProgressInput) => _fragno_dev_db202.TxResult<{ bytesUploaded: bigint; partsUploaded: number; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; recordUploadParts: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, input: CompletePartsInput) => _fragno_dev_db202.TxResult<{ partsUploaded: number; bytesUploaded: bigint; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; uploadId: _fragno_dev_db_schema427.FragnoReference; partNumber: number; etag: string; sizeBytes: bigint; createdAt: Date; }[]]>; markUploadComplete: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, fileKey: FileKeyEncoded, options?: { sizeBytes?: bigint; }) => _fragno_dev_db202.TxResult<{ upload: { status: UploadStatus; updatedAt: Date; completedAt: Date; bytesUploaded: bigint; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; errorCode: string | null; errorMessage: string | null; }; file: { fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: {} | null; visibility: string; tags: {} | null; metadata: {} | null; status: FileStatus; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date; deletedAt: null; errorCode: null; errorMessage: null; id: _fragno_dev_db_schema427.FragnoId; }; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; sizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; storageProvider: string; storageKey: string; createdAt: Date; updatedAt: Date; completedAt: Date | null; deletedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; markUploadFailed: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string, errorCode: string, errorMessage?: string | null) => _fragno_dev_db202.TxResult<{ upload: { status: UploadStatus; updatedAt: Date; errorCode: string; errorMessage: string | null; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; completedAt: Date | null; }; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; markUploadAborted: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ upload: { status: UploadStatus; updatedAt: Date; errorCode: string; id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; completedAt: Date | null; errorMessage: string | null; }; }, [{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; } | null]>; getUploadStorageInfo: (this: _fragno_dev_core49.RequestThisContext & { serviceTx(schema: TSchema): _fragno_dev_db202.ServiceTxBuilder void | Promise; onUploadFailed: (payload: FileHookPayload) => void | Promise; onFileDeleted: (payload: FileHookPayload) => void | Promise; onUploadTimeout: (payload: UploadTimeoutPayload) => void | Promise; }>; }, uploadId: string) => _fragno_dev_db202.TxResult<{ id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }, { id: _fragno_dev_db_schema427.FragnoId; fileKey: string; uploaderId: string | null; filename: string; expectedSizeBytes: bigint; contentType: string; checksum: unknown; visibility: string; tags: unknown; metadata: unknown; status: string; strategy: string; storageProvider: string; storageKey: string; storageUploadId: string | null; uploadUrl: string | null; uploadHeaders: unknown; bytesUploaded: bigint; partsUploaded: number; partSizeBytes: number | null; expiresAt: Date; createdAt: Date; updatedAt: Date; completedAt: Date | null; errorCode: string | null; errorMessage: string | null; }>; }>, {}, readonly [_fragno_dev_core49.FragnoRouteConfig<"POST", "/files", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ fileKey: zod1807.ZodString; fileKeyParts: zod1807.ZodArray>; uploaderId: zod1807.ZodNullable; filename: zod1807.ZodString; sizeBytes: zod1807.ZodNumber; contentType: zod1807.ZodString; checksum: zod1807.ZodNullable; value: zod1807.ZodString; }, zod_v4_core148.$strip>>; visibility: zod1807.ZodEnum<{ private: "private"; public: "public"; unlisted: "unlisted"; }>; tags: zod1807.ZodNullable>; metadata: zod1807.ZodNullable>; status: zod1807.ZodEnum<{ ready: "ready"; deleted: "deleted"; }>; storageProvider: zod1807.ZodString; createdAt: zod1807.ZodString; updatedAt: zod1807.ZodString; completedAt: zod1807.ZodNullable; deletedAt: zod1807.ZodNullable; errorCode: zod1807.ZodNullable; errorMessage: zod1807.ZodNullable; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR" | "FILE_NOT_FOUND" | "SIGNED_URL_UNSUPPORTED", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"GET", "/files", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ files: zod1807.ZodArray>; uploaderId: zod1807.ZodNullable; filename: zod1807.ZodString; sizeBytes: zod1807.ZodNumber; contentType: zod1807.ZodString; checksum: zod1807.ZodNullable; value: zod1807.ZodString; }, zod_v4_core148.$strip>>; visibility: zod1807.ZodEnum<{ private: "private"; public: "public"; unlisted: "unlisted"; }>; tags: zod1807.ZodNullable>; metadata: zod1807.ZodNullable>; status: zod1807.ZodEnum<{ ready: "ready"; deleted: "deleted"; }>; storageProvider: zod1807.ZodString; createdAt: zod1807.ZodString; updatedAt: zod1807.ZodString; completedAt: zod1807.ZodNullable; deletedAt: zod1807.ZodNullable; errorCode: zod1807.ZodNullable; errorMessage: zod1807.ZodNullable; }, zod_v4_core148.$strip>>; cursor: zod1807.ZodOptional; hasNextPage: zod1807.ZodBoolean; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR" | "FILE_NOT_FOUND" | "SIGNED_URL_UNSUPPORTED", "status" | "uploaderId" | "pageSize" | "prefix" | "cursor", _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"GET", "/files/:fileKey", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ fileKey: zod1807.ZodString; fileKeyParts: zod1807.ZodArray>; uploaderId: zod1807.ZodNullable; filename: zod1807.ZodString; sizeBytes: zod1807.ZodNumber; contentType: zod1807.ZodString; checksum: zod1807.ZodNullable; value: zod1807.ZodString; }, zod_v4_core148.$strip>>; visibility: zod1807.ZodEnum<{ private: "private"; public: "public"; unlisted: "unlisted"; }>; tags: zod1807.ZodNullable>; metadata: zod1807.ZodNullable>; status: zod1807.ZodEnum<{ ready: "ready"; deleted: "deleted"; }>; storageProvider: zod1807.ZodString; createdAt: zod1807.ZodString; updatedAt: zod1807.ZodString; completedAt: zod1807.ZodNullable; deletedAt: zod1807.ZodNullable; errorCode: zod1807.ZodNullable; errorMessage: zod1807.ZodNullable; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR" | "FILE_NOT_FOUND" | "SIGNED_URL_UNSUPPORTED", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"PATCH", "/files/:fileKey", zod1807.ZodObject<{ filename: zod1807.ZodOptional; visibility: zod1807.ZodOptional>; tags: zod1807.ZodOptional>>; metadata: zod1807.ZodOptional>>; }, zod_v4_core148.$strip>, zod1807.ZodObject<{ fileKey: zod1807.ZodString; fileKeyParts: zod1807.ZodArray>; uploaderId: zod1807.ZodNullable; filename: zod1807.ZodString; sizeBytes: zod1807.ZodNumber; contentType: zod1807.ZodString; checksum: zod1807.ZodNullable; value: zod1807.ZodString; }, zod_v4_core148.$strip>>; visibility: zod1807.ZodEnum<{ private: "private"; public: "public"; unlisted: "unlisted"; }>; tags: zod1807.ZodNullable>; metadata: zod1807.ZodNullable>; status: zod1807.ZodEnum<{ ready: "ready"; deleted: "deleted"; }>; storageProvider: zod1807.ZodString; createdAt: zod1807.ZodString; updatedAt: zod1807.ZodString; completedAt: zod1807.ZodNullable; deletedAt: zod1807.ZodNullable; errorCode: zod1807.ZodNullable; errorMessage: zod1807.ZodNullable; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR" | "FILE_NOT_FOUND" | "SIGNED_URL_UNSUPPORTED", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"DELETE", "/files/:fileKey", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ ok: zod1807.ZodLiteral; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR" | "FILE_NOT_FOUND" | "SIGNED_URL_UNSUPPORTED", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"GET", "/files/:fileKey/download-url", _standard_schema_spec25.StandardSchemaV1 | undefined, zod1807.ZodObject<{ url: zod1807.ZodString; headers: zod1807.ZodOptional>; expiresAt: zod1807.ZodDate; }, zod_v4_core148.$strip>, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR" | "FILE_NOT_FOUND" | "SIGNED_URL_UNSUPPORTED", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>, _fragno_dev_core49.FragnoRouteConfig<"GET", "/files/:fileKey/content", _standard_schema_spec25.StandardSchemaV1 | undefined, _standard_schema_spec25.StandardSchemaV1 | undefined, "UPLOAD_NOT_FOUND" | "UPLOAD_ALREADY_ACTIVE" | "FILE_ALREADY_EXISTS" | "UPLOAD_EXPIRED" | "UPLOAD_INVALID_STATE" | "INVALID_FILE_KEY" | "INVALID_CHECKSUM" | "INVALID_REQUEST" | "STORAGE_ERROR" | "FILE_NOT_FOUND" | "SIGNED_URL_UNSUPPORTED", string, _fragno_dev_db202.DatabaseRequestContext<{ onFileReady: _fragno_dev_db202.HookFn; onUploadFailed: _fragno_dev_db202.HookFn; onFileDeleted: _fragno_dev_db202.HookFn; onUploadTimeout: _fragno_dev_db202.HookFn; }>>]>]; //#endregion export { uploadRoutes }; //# sourceMappingURL=index.d.ts.map