Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Implementation:Infiniflow Ragflow FileManagerService

From Leeroopedia
Knowledge Sources
Domains Frontend, API, File_Management
Last Updated 2026-02-12 06:00 GMT

Overview

Concrete frontend HTTP API client for file management operations including listing, uploading, moving, and deleting files in the RAGFlow frontend.

Description

The services/file-manager-service.ts module defines API endpoints for: listing files by folder, uploading files, creating folders, moving files, renaming files, deleting files, downloading files, and linking files to knowledge bases.

Usage

Import these service functions in file manager hooks and components that need to communicate with the file management API.

Code Reference

Source Location

Signature

export const listFiles: (params) => Promise<Response>;
export const uploadFile: (data: FormData) => Promise<Response>;
export const createFolder: (data) => Promise<Response>;
export const moveFile: (data) => Promise<Response>;
export const deleteFile: (id: string) => Promise<Response>;
export const renameFile: (data) => Promise<Response>;

Import

import { listFiles, uploadFile, deleteFile } from '@/services/file-manager-service';

I/O Contract

Inputs

Name Type Required Description
params object Varies Query parameters (parentId, page, etc.)
data FormData/object Yes File data or operation parameters

Outputs

Name Type Description
returns Promise<Response> API response with file list or operation result

Usage Examples

import { listFiles, uploadFile } from '@/services/file-manager-service';

const files = await listFiles({ parentId: 'root', page: 1, pageSize: 20 });
const formData = new FormData();
formData.append('file', selectedFile);
await uploadFile(formData);

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment