API Reference > itwin-client > iTwinServiceClients > FileHandler FileHandler Interface Beta Handler for file system, and upload / download. TODO: Move this to parent directory -- it is not iModelHub-specific. Methods Name Description basename(filePath: string): string Get file name from the path. downloadFile(requestContext: AuthorizedClientRequestContext, downloadUrl: string, path: string, fileSize?: number, progress?: ProgressCallback, cancelRequest?: CancelRequest): Promise<void> Download a file. exists(filePath: string): boolean Check if path exists. getFileSize(filePath: string): number Get size of a file. isDirectory(filePath: string): boolean Check if path is a directory. join(...paths: string[]): string Join multiple strings into a single path. unlink(filePath: string): void Deletes file. uploadFile(requestContext: AuthorizedClientRequestContext, uploadUrlString: string, path: string, progress?: ProgressCallback): Promise<void> Upload a file. Properties Name Type Description agent undefined | Agent Defined in clients/itwin/src/FileHandler.ts Line 54 Last Updated: 11 June, 2024