File / AES 接口
文件上传 — /api/file
源码:src/business/controller/file/index.ts(multer + raw: true)
http
POST /api/file/upload
Authorization: <token>
Content-Type: multipart/form-data
bucket=<字母数字_- >
files=<file...>- 需登录;
@Log业务类型UPLOAD - 存储:
{UPLOAD_PATH}/{bucket}/{yyyy/MM/dd}/{uuid}{ext} - 静态访问前缀默认
/files(见 环境配置) - 返回数组:
{ name, type, size, data },data为可访问绝对 URL
multipart 不走 AES 请求体加密。
AES 密钥 — /api/aes
http
GET /api/aes/key无需登录。返回 { sessionId, aesKey }。协议细节见 加密传输。