fix(types): remove unused and misaligned app-asset types

Remove types that don't match backend API:
- AppAssetFileContentResponse (unused, had extra metadata field)
- CreateFilePayload (unused, FormData built manually)
- metadata field from UpdateFileContentPayload
This commit is contained in:
yyh 2026-01-19 12:43:44 +08:00
parent 0de32f682a
commit 4bd05ed96e
No known key found for this signature in database

View File

@ -63,14 +63,6 @@ export type AppAssetTreeResponse = {
children: AppAssetTreeView[]
}
/**
* File content response (GET /apps/{app_id}/assets/files/{node_id})
*/
export type AppAssetFileContentResponse = {
content: string
metadata?: Record<string, any>
}
/**
* File download URL response (GET /apps/{app_id}/assets/files/{node_id}/download-url)
*/
@ -115,24 +107,12 @@ export type CreateFolderPayload = {
parent_id?: string | null
}
/**
* Request payload for creating a file (form data)
*/
export type CreateFilePayload = {
/** File name (1-255 characters) */
name: string
/** Parent folder ID, empty or undefined for root */
parent_id?: string | null
}
/**
* Request payload for updating file content (JSON)
*/
export type UpdateFileContentPayload = {
/** New file content (UTF-8) */
content: string
/** Optional metadata associated with the file */
metadata?: Record<string, any>
}
/**