--- id: "en/developer-api-files" title: "File API" language: "en" description: "Interface paths, methods, parameters, and return fields for the File API." canonical_url: "https://www.babel.cc/public/babelwiki/en/developer-api-files.html" markdown_url: "https://www.babel.cc/public/babelwiki/ai/en/developer-api-files.md" alternates: {"en": "https://www.babel.cc/public/babelwiki/ai/en/developer-api-files.md", "zh": "https://www.babel.cc/public/babelwiki/ai/zh/developer-api-files.md"} reading_note: "文档记录不等于当前部署能力;以实际版本、授权模块与配置为准。保留原文的可选、限制及待确认说明,勿补猜接口。 / Documentation is not a guarantee for every deployment. Preserve optional-module requirements, limitations and unresolved API contracts." --- # File APIs List and manage files, folders, versions, transfers, recycle-bin items and material libraries. Upload requires pre-upload followed by binary transfer. Confirm targets before deletion or replacement. ## Endpoints | Method | Endpoint | Path | | --- | --- | --- | | `GET` | [Get download address of multiple files](https://www.babel.cc/public/babelwiki/en/api-get-api-file-downloadmultifiles-do.html) | `/api/file/downloadMultiFiles.do` | | `GET` | [Get download file thumbnail address](https://www.babel.cc/public/babelwiki/en/api-get-api-file-downloadthumbnail-do.html) | `/api/file/downloadThumbnail.do` | | `GET` | [Get download file address](https://www.babel.cc/public/babelwiki/en/api-get-api-file-getfiledownloadurl-do.html) | `/api/file/getFileDownloadUrl.do` | | `GET` | [Pre-upload files](https://www.babel.cc/public/babelwiki/en/api-get-api-file-preuploadfile-do.html) | `/api/file/preUploadFile.do` | | `GET` | [file log](https://www.babel.cc/public/babelwiki/en/api-get-nd-api-file-file-logs.html) | `/nd/api/file/file_logs` | | `GET` | [Get file information](https://www.babel.cc/public/babelwiki/en/api-get-nd-api-file-fileinfo.html) | `/nd/api/file/fileinfo` | | `GET` | [Get file list](https://www.babel.cc/public/babelwiki/en/api-get-nd-api-file-list-dir.html) | `/nd/api/file/list_dir` | | `GET` | [Get all version information of a file](https://www.babel.cc/public/babelwiki/en/api-get-nd-api-file-versions.html) | `/nd/api/file/versions` | | `POST` | [Copy file progress](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-copy-progress.html) | `/nd/api/file/copy_progress` | | `POST` | [Copy files](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-copy.html) | `/nd/api/file/copy` | | `POST` | [Create folder](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-create-folder.html) | `/nd/api/file/create_folder` | | `POST` | [Create library categories](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-create-material-class.html) | `/nd/api/file/create_material_class` | | `POST` | [Create sub-library](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-create-material-folder.html) | `/nd/api/file/create_material_folder` | | `POST` | [Empty Recycle Bin](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-empty-trash.html) | `/nd/api/file/empty_trash` | | `POST` | [Move files](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-move.html) | `/nd/api/file/move` | | `POST` | [Delete files (to recycle bin)](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-remove-file.html) | `/nd/api/file/remove_file` | | `POST` | [Delete files (from Recycle Bin)](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-remove-from-trash.html) | `/nd/api/file/remove_from_trash` | | `POST` | [Modify file name](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-rename.html) | `/nd/api/file/rename` | | `POST` | [Recover files (from Recycle Bin)](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-restore-file.html) | `/nd/api/file/restore_file` | | `POST` | [Set whether the user has access to the material library](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-set-user-access-material-library.html) | `/nd/api/file/set_user_access_material_library` | | `POST` | [Modify file information](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-update-file.html) | `/nd/api/file/update_file` | | `POST` | [Set the current version of the file](https://www.babel.cc/public/babelwiki/en/api-post-nd-api-file-version.html) | `/nd/api/file/version` | ## Completing an Upload Call [pre-upload](https://www.babel.cc/public/babelwiki/en/api-get-api-file-preuploadfile-do.html), then POST `multipart/form-data` to its returned `url` with binary `file` and `upload_token`. Verify `success`, `code`, `fileId` and `version`. Never hard-code the upload URL; obtain another when used or expired. ## Integration Notes Based on the supplied Babel API reference. Preserve exact endpoint paths and field casing. Confirm unspecified or inconsistent field types during integration rather than assuming undocumented parameters. Use the deployment's HTTPS domain and keep credentials out of public pages. [API overview](https://www.babel.cc/public/babelwiki/en/developer-api-overview.html) · [MCP quick start](https://www.babel.cc/public/babelwiki/en/mcp-integration.html)